Jump to content

Recommended Posts

Select a file in Finder and hit your hotkey.

 

 

Adds the date to the filename before the suffix


E.g.

 

Item Name.xxx -> Item Name-03-25-2013.xxx

 

Add Date To Filename.alfredworkflow

 

Default date format changed to YYYYMMDD per advice from atadams.

 
Now: Item Name.xxx -> Item Name-20130523.xxx
 
Edited by stouty

Share this post


Link to post

It it possible to make this output the following format;

 

 

2013-03-25 08-46 PM
 
I'd like to insert "2013-03-25 08-46 PM" before the file name, I find it's better for sorting and finding files.
 
I tried it myself, but I failed as it was in Automator and I have no coding skills whatsoever (even though one might argue Automator doesn't require any.)
 
I have another extension I found from some one using bash to copy the date and time to the clipboard. I was able to modify that script for the above format. Since this is an automator action, I tried everything I could think of, I just fail in coding.
 
If not, no worries, right now I just manually replace the filename or I save it correctly at the time of creation. I also use the current date and time, not the created date.
 
Regardless, thanks, always appreciate new workflows.

Share this post


Link to post

Nice. Although I did modify the Automater workflow to use a YYYYMMDD format. I find this format much better for filenames.

 

Yes, I'd like to re-write so it takes options for the date/time format and insert location. Easier to re-write as a shell script I think if I want that.

Share this post


Link to post

It it possible to make this output the following format;

 

 

2013-03-25 08-46 PM
 
I'd like to insert "2013-03-25 08-46 PM" before the file name, I find it's better for sorting and finding files.
 
I tried it myself, but I failed as it was in Automator and I have no coding skills whatsoever (even though one might argue Automator doesn't require any.)
 
I have another extension I found from some one using bash to copy the date and time to the clipboard. I was able to modify that script for the above format. Since this is an automator action, I tried everything I could think of, I just fail in coding.
 
If not, no worries, right now I just manually replace the filename or I save it correctly at the time of creation. I also use the current date and time, not the created date.
 
Regardless, thanks, always appreciate new workflows.

 

Here you go: Add Date and Time Before Filename.alfredworkflow

 

Only tested briefly, so let me know if you have any issues.

Share this post


Link to post

@stouty The advantage of having YYYYMMDD at the end of the filename is a sort by name will also sort similar files by date. 

 

I'll change it so YYYYMMDD is the default. I've been working on a way for the user to choose from some defaults or add their own

Share this post


Link to post

@stouty The advantage of having YYYYMMDD at the end of the filename is a sort by name will also sort similar files by date. 

 

The original workflow used date created .. I actually meant the current timestamp. What do you think people would prefer?

Share this post


Link to post

See below workflow. You are able to add the creation date or a custom date to your file names before or after the filename.

 

date.JPG

 

This will as an example rename the item as follows: 

 

2013-2-30 16-40 Test.jpg

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...