Geektool: More Then 1 Function in Command Line?

Discussion in 'macOS' started by thriii, Nov 15, 2010.

  1. thriii macrumors 6502

    Joined:
    Feb 14, 2007
    #1
    im trying to display "Monday | November 15" and I have "date +%A" to display the weekday, "date +%B" to display the month, and "date +%d" to display the date number.. but somethin like "date +%A | date +%B date +%d" doesnt work.. I know I can create 3 shell boxes to do this, but I rather learn for the future so how do I do this all at once?
     
  2. Hal Itosis, Nov 15, 2010
    Last edited: Nov 15, 2010

    Hal Itosis macrumors 6502a

    Hal Itosis

    Joined:
    Feb 20, 2010
    #2
    Create and save a shell script somewhere. It can have as many lines as you need. Don't forget to make it executable. Then, simply put the path to that script in GeekTool. (i.e., one line)

    Edit: BTW, the syntax you posted there doesn't work on the command line either. If all you're doing is that formatted date, then do it like this:

    date '+%A | %B %d'

     

Share This Page