multiple date format and renaming files with date

Hi all,
I just bought Hazel and just discovered that there is no manual so I'm falling back on the forum and you, the experts.
I am trying to do the following:
The problem I have is due to the date. I want to add the billing date to the file name but this particular company varies its format from long to short just to make Hazel sweat a bit.
I tried to be smart and put both long and short date in the name thinking Hazel would fill a blank if the variable was never filled.. but instead it does this:
It basically takes the long date and crops the year after the second digit.
I have reach the end of my skills before falling onto a shell script.
Can this be done without a script?
Am I doing the rule the right way or is there a better way?
This is my first day at it so please bare with me.
I just bought Hazel and just discovered that there is no manual so I'm falling back on the forum and you, the experts.
I am trying to do the following:
- Code: Select all
if all
if any
contain match = bank account
contain match = other account
if any
contain match = date_short (DD/MM/YY)
contain match = date_long (DD/MM/YYYY)
Do
move to folder = test
rename with pattern = Company Name <date_long><date_short><extension>
The problem I have is due to the date. I want to add the billing date to the file name but this particular company varies its format from long to short just to make Hazel sweat a bit.
I tried to be smart and put both long and short date in the name thinking Hazel would fill a blank if the variable was never filled.. but instead it does this:
- Code: Select all
Company Name 2016-0520-05.pdf
It basically takes the long date and crops the year after the second digit.
I have reach the end of my skills before falling onto a shell script.
Can this be done without a script?
Am I doing the rule the right way or is there a better way?
This is my first day at it so please bare with me.
