Jump to content
Sign in to follow this  
alex.agat

Show Date and Time in Large Type

Recommended Posts

Great...but why does it show day in english even on a non-english OSX? Can this workflow be adapted to localization settings somehow? Thanks!

Share this post


Link to post

Great...but why does it show day in english even on a non-english OSX? Can this workflow be adapted to localization settings somehow? Thanks!

 

Not sure - I'm not familiar with how to adapt this. Hopefully somebody else can help out here.

Share this post


Link to post

I have updated my original script to include the +num and -num functionality to show dates in the past and future given an option argument.


 


So for example, given that today is Sunday April 28, 2013:


 


date +3 would print: Wednesday May 1st, 2013


date -7 would print: Sunday April 21st, 2013


 


Here ya go: http://cl.ly/3w0O0p3Q3j0X

Share this post


Link to post

I'm very curious ... that Applescript looks so complex and long. Why not just use the terminal command:

 

date '+%A %B %d, %Y' 

to output the date in the exact format you want?

Share this post


Link to post

I'm very curious ... that Applescript looks so complex and long. Why not just use the terminal command:

 

date '+%A %B %d, %Y' 

to output the date in the exact format you want?

 

Yes, while this does accomplish much of what the script does, the extra lines are for particular formatting (adding the "rd" or "th" after the day number) and adding the + and - num functionality. I'm sure I could shorten it up - but I wrote it out so that I could mess around with each variable.

 

For instance, the lines where I output the date as a string I have as 8 lines and I could easily shorten to 1 line. I just did this for formality.

Share this post


Link to post

Could you please add a second line to the output displaying the weeknumer?

 

 

As in the week of the year? Please give me an example and I'm more than happy to make this for you.

Share this post


Link to post

As in the week of the year? Please give me an example and I'm more than happy to make this for you.

Today is the 29th of April and the start of week 18 which will last untill the 5th of May. Then next week is week 19 and so on and so forth :)

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.

Sign in to follow this  
×
×
  • Create New...