Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
Status
Not open for further replies.
Dock is custom made...


Screenshot2010-09-01at15938AM.png
 
Here's my desktop. Using Geektool for the date, current weather, top labels, lines and in conjunction with icalBuddy for the calendar stuff. Bowtie is for itunes (Zukunft Condensed White theme) and WideScape weather for Yahoo Widgets for the forecast. Dateline for the date bar at the bottom.

Let me know what you think!

I have never used geektool/nerdtool, but intend to learn..

would you mind explaining how you got the calendar/to-do info to appear on your desktop?

and quick question: does that setup make your data accessible/changeable through the desktop?
 
Can someone tell me how to mix data and my own wording on a single line?

I want a line displayed like this:

Tomorrow: Sunny, High of 88, Low of 68

Sunny and the 2 temperatures being the data I pull from weather.

Everything I have tried only give me a single thing on 1 line like:

Tomorrow:
Sunny
Low:
68
High:
88
 
Can someone tell me how to mix data and my own wording on a single line?

Code:
curl --silent "http://weather.yahooapis.com/forecastrss?p=USNY0996&u=f" | grep -e "Forecast:" -A 2 | tail -n 1 | sed -e 's/<br \/>//' | sed -e 's/.* -/Tomorrow:/' | sed -e 's/High: /High of /' | sed -e 's/Low:/- Low of/'
this code outputs:
Code:
Tomorrow: Mostly Sunny. High of 90 - Low of 71
 
Here's my desktop. Using Geektool for the date, current weather, top labels, lines and in conjunction with icalBuddy for the calendar stuff. Bowtie is for itunes (Zukunft Condensed White theme) and WideScape weather for Yahoo Widgets for the forecast. Dateline for the date bar at the bottom.

Let me know what you think!

amazing, any chance you could share the script?
 
amazing, any chance you could share the script?

Thanks! and for sure. The scripts are below (for info on customizing icalbuddy, it's best to read the man page and look at the examples provided by the developer, they are really well done. icalbuddy home page: http://hasseg.org/icalBuddy/). All headings are done in their own shell box in the form:
Code:
echo "HEADING GOES HERE"

Todo:
Code:
/usr/local/bin/icalBuddy -f -sd -ic Personal -df "%a, %b %d" -nc uncompletedTasks

Events Today:
Code:
/usr/local/bin/icalBuddy -f -n -eep notes -eep url -sd -df "%a, %b %e" -ec Automator eventsToday

Events Tomorrow/Day after tomorrow (I got the script originally from the icalbuddy website in the FAQ and modified it to do day after tomorrow):
Code:
#!/bin/bash
# 
# Prints tomorrow's events using icalBuddy
# 

day_in_seconds=86400
two_days_in_seconds=172800

# get current seconds since the epoch
sec=`date +%s`

# get tomorrows date as seconds since the epoch
sec_tomorrow=`expr ${sec} + ${day_in_seconds}`
sec_day_after_tomorrow=`expr ${sec} + ${two_days_in_seconds}`

# 'start' date/time, in the format required by icalBuddy
start_dt="`date -r ${sec_tomorrow} +'%Y-%m-%d 00:00:00 %z'`"

# 'end' date/time, in the format required by icalBuddy
end_dt="`date -r ${sec_day_after_tomorrow} +'%Y-%m-%d 23:59:59 %z'`"

/usr/local/bin/icalBuddy -f -sd -eep * -df "%a, %b %e" -ec Automator eventsFrom:"${start_dt}" to:"${end_dt}"

#/usr/local/bin/icalBuddy eventsFrom:"${start_dt}" to:"${end_dt}"

Homework (Simply a calendar for each course in iCal where each assignment/test is a todo item):
Code:
/usr/local/bin/icalBuddy -f -sc -ec Personal -df "%a, %b %d" -nc uncompletedTasks

Day:
Code:
date "+%A"
Day Number:
Code:
date +%d
Month:
Code:
date +%B

Weather from Yahoo (To change to your city, browse to city regularly in Yahoo weather. Then take the set of numbers at the end of the URL and put them in the script where it currently has "8775", without the quotes) :
Code:
curl --silent "http://weather.yahooapis.com/forecastrss?w=8775&u=c" | grep -E '(Current Conditions:|C<BR)' | sed -e 's/Current Conditions://' -e 's/<br \/>//' -e 's/<b>//' -e 's/<\/b>//' -e 's/<BR \/>//' -e 's/<description>//' -e 's/<\/description>//' -e 's/\(.*\) C/\1°C/' | tail -n1

Let me know if you need any more explanation and I'll try my best to help (although I'm certainly no wiz in the terminal :p)!
 
I have a couple of questions about iCalBuddy..

Can you change the "today", "tomorrow" and "day after tomorrow" to be capitalised?

Can you use colors other than "green" and "blue" etc., I'd like a light grey, but "grey" doesn't work.

Can you change what is displayed when there are no events, instead of "Nothing." I'd like No Events or something.

Thanks!!
 

Attachments

  • Screen shot 2010-09-03 at 20.42.00.png
    Screen shot 2010-09-03 at 20.42.00.png
    29.5 KB · Views: 1,838
Can you change the "today", "tomorrow" and "day after tomorrow" to be capitalised?
As far as I know, those are hard-coded in, so no you cannot capitalize them (if you really want them, email the developer from the icalbuddy website and suggest it :))

Can you change what is displayed when there are no events, instead of "Nothing." I'd like No Events or something.
That's changeable in the config file. Get to it by entering:
Code:
icalBuddy editConfig
in the terminal (if you haven't opened the config file before, then it does not exist and will be created automatically). Then, expand "formatting" and add a child. Enter "noItems" (without the quotes; case sensitive) for the key, and whatever you want stated when there are no items for the value (without quotes). Type is always string.

Can you use colors other than "green" and "blue" etc., I'd like a light grey, but "grey" doesn't work.
The colours available to icalbuddy to use are the 16 colours via the ANSI escape sequences (http://en.wikipedia.org/wiki/ANSI_escape_code#Colors) so that's what you have to choose from. The event title colour by default is chosen to try to match the colour used for the calendar in iCal. If it can't match it, then white is used. To change the colour of the event title, for example, follow the same process as above to change the config file, but use "titleValue" for the key (again, no quotes; case sensitive) and the color (from the available colours on the Wikipedia page) for the value.

Take a look at the man page for the config file (http://hasseg.org/icalBuddy/config-man.html) for all of the formatting options for icalbuddy (there's a ton!) and some of the finer details.

Hope that helps! Let me know if you have any more questions.
 
I have never used geektool/nerdtool, but intend to learn..

would you mind explaining how you got the calendar/to-do info to appear on your desktop?

and quick question: does that setup make your data accessible/changeable through the desktop?

Sorry I'm late replying, didn't get notified that you had replied to my post :eek:

Anyways, to get the calendar/to-do on my desktop I used a terminal-based program called icalbuddy (http://hasseg.org/icalBuddy/) so you have to install that first and then you access through a command in the command line (or geektool in this case). See my post a few up for all my scripts (icalbuddy ones included). The best way to learn how to use icalbuddy is through the examples on the developers website. The examples can be found here: http://hasseg.org/icalBuddy/examples.html.

As for whether you can change stuff through the desktop: no you cannot. All geektool does is take the output (read: not input) of a command and route it to display on the desktop. The stuff on the desktop by geektool is un-clickable (unless you have the preference pane open) and becomes one with your wallpaper essentially :)
 
The colours available to icalbuddy to use are the 16 colours via the ANSI escape sequences (http://en.wikipedia.org/wiki/ANSI_escape_code#Colors) so that's what you have to choose from. The event title colour by default is chosen to try to match the colour used for the calendar in iCal. If it can't match it, then white is used. To change the colour of the event title, for example, follow the same process as above to change the config file, but use "titleValue" for the key (again, no quotes; case sensitive) and the color (from the available colours on the Wikipedia page) for the value.

Take a look at the man page for the config file (http://hasseg.org/icalBuddy/config-man.html) for all of the formatting options for icalbuddy (there's a ton!) and some of the finer details.

Hope that helps! Let me know if you have any more questions.
can we do an "if" fonction for the colors? what I want to do is put the different color for the calendar names (calendarNameInTitle). is it possible? i tried changing the type, putting the if in the the key, and in the value, but it didnt work...

thanks for the help! :)
 
can we do an "if" fonction for the colors? what I want to do is put the different color for the calendar names (calendarNameInTitle). is it possible? i tried changing the type, putting the if in the the key, and in the value, but it didnt work...

thanks for the help! :)

As far as I know you can't do if statements (without modifying the source code anyways). At least I certainly haven't read anywhere about being able to do that (I think config files in general don't support the "if" function, they are pretty basic).
 
As far as I know you can't do if statements (without modifying the source code anyways). At least I certainly haven't read anywhere about being able to do that (I think config files in general don't support the "if" function, they are pretty basic).

ok :(
thanks anyway for the quick answer!

edit: couldnt we use the "formattedKeywords" key for it? I didnt understand its fonction... :S
 
ok :(
thanks anyway for the quick answer!

edit: couldnt we use the "formattedKeywords" key for it? I didnt understood its fonction... :S

I actually had just noticed this as well....was looking at the man page again! You just add an item under root (same level as "formatting") that is called "formattedKeywords" and make it's type "dictionary", then add children to that. The key of each of those children is the keyword you want formatted and the value is how you want them formatted. I have tested this and it does work :D

So, for an example, say you want every instance of the word "Big" that ever appears in the output to be coloured cyan, you add a child to "formattedKeywords" with a key of "Big" and a value of "cyan" (all without quotes of course). Each child is a different keyword.
 
I actually had just noticed this as well....was looking at the man page again! You just add an item under root (same level as "formatting") that is called "formattedKeywords" and make it's type "dictionary", then add children to that. The key of each of those children is the keyword you want formatted and the value is how you want them formatted. I have tested this and it does work :D

So, for an example, say you want every instance of the word "Big" that ever appears in the output to be coloured cyan, you add a child to "formattedKeywords" with a key of "Big" and a value of "cyan" (all without quotes of course). Each child is a different keyword.
ok, got it... I think that when I tried last time, I've put the child in the root key rather than the formattedKeywords one... :D
only problem is, when "Big" for example is in your event (case sensitive), it appears in the different color...
 
Thank a lot for your help bobbob101!!

That's changeable in the config file. Get to it by entering:
Code:
icalBuddy editConfig
in the terminal (if you haven't opened the config file before, then it does not exist and will be created automatically). Then, expand "formatting" and add a child. Enter "noItems" (without the quotes; case sensitive) for the key, and whatever you want stated when there are no items for the value (without quotes). Type is always string.

I can't get this to work though, whatever I change it to, it still comes up as Nothing.

I have:

Code:
<key>noItems</key>
<string>No Events</string>

in the config file.


Thanks!
 
Thank a lot for your help bobbob101!!



I can't get this to work though, whatever I change it to, it still comes up as Nothing.

I have:

Code:
<key>noItems</key>
<string>No Events</string>

in the config file.


Thanks!

same here... but I have something that might work (once again, I have the feeling thats it, but I cant make it work... :()
http://hasseg.org/icalBuddy/localization-man.html

edit: i just need to know what this means...
"The icalBuddy localization file should be saved in ~/.icalBuddyLocalization.plist"
After, its a piece of cake! I really cant find it! :mad:

edit2: lol well im glad it worked! :)
 
same here... but I have something that might work (once again, I have the feeling thats it, but I cant make it work... :()
http://hasseg.org/icalBuddy/localization-man.html

That works!! Good call on that one! :D

Open up "Property List Editor" (application...don't know if you need developer tools to have it).

Save a new file in your home directory as ".icalBuddyLocalization.plist" (don't forget the "." in front of the name!).

Add a child to "root" with a key of "noItems", and the value is the text you want displayed instead of "Nothing.". Of course, everything without the quotes ;)

Can you change the "today", "tomorrow" and "day after tomorrow" to be capitalised?

Following a similar process, but with different keys (as listed on the man page) you can also get the capitals for "today, etc" and change pretty well everything (it looks like this part was designed for translation, but eh, this works as well! :D)
 
Displaying of system log and Read privileges.

I did have Geek tool displaying the system log on my desktop. But after taking away admin privileges from my account after creating an Admin account, I then lost the display.

Now I know that I had to modify the reading privileges for 'others' on the file, as I'm not in the admin group and that worked for a short while. But when the file reaches a certain size the system bzip's the file and creates another system log with the old user and group and the old privileges. The privileges are root:admin and -rw-r--r--.

Now without permanently adding my account to the admin group, is there another way of approaching this.

Thanks


Andy
 
Here's mine so far. Haven't decided what to do with iCal events yet! I want them somewhere, just don't know where! :D
 

Attachments

  • desktop.png
    desktop.png
    740 KB · Views: 555
That works!! Good call on that one! :D

Open up "Property List Editor" (application...don't know if you need developer tools to have it).

Save a new file in your home directory as ".icalBuddyLocalization.plist" (don't forget the "." in front of the name!).

Add a child to "root" with a key of "noItems", and the value is the text you want displayed instead of "Nothing.". Of course, everything without the quotes ;)



Following a similar process, but with different keys (as listed on the man page) you can also get the capitals for "today, etc" and change pretty well everything (it looks like this part was designed for translation, but eh, this works as well! :D)



Sup,

I followed your steps but for some odd reason I did not get the outcome that everyone has gotten.

Did I miss something in the process?

regards
 
Sup,

I followed your steps but for some odd reason I did not get the outcome that everyone has gotten.

Did I miss something in the process?

regards

First of all, what results are you getting? Simply no change from the defaults, or is something funky happening?

Second of all, what are you trying to change? The "noItems" display, the "today" label, or something else?

I need some more info to be able to help you properly.

Trying to think up some easy places to make a mistake:
- Check your capitalization for the keys (all the keys are case sensitive)
- Make sure that your items are children of "root" (not something else)
- Ensure that the .plist file is saved in your home directory ("/Users/yourUserName/")
- Ensure that the .plist is called ".icalBuddyLocalization.plist"
- Make sure to check spelling, capitalization and don't forget the period (".") in front of the file name to make it a system (hidden) file (I forgot the period the first time I tried :p)

Anyways, hope one of those helps, but if you provide some more info as to what is happening at your end I can hopefully provide some more specific assistance.
 
same here... but I have something that might work (once again, I have the feeling thats it, but I cant make it work... :()
http://hasseg.org/icalBuddy/localization-man.html

edit: i just need to know what this means...
"The icalBuddy localization file should be saved in ~/.icalBuddyLocalization.plist"
After, its a piece of cake! I really cant find it! :mad:

edit2: lol well im glad it worked! :)

Don't know whether you've figured this out already, but the "~" (tilde) in a directory location means your home directory (so on OS X that is: /Users/yourUserName/). So what that statement means in the man page is save a new .plist file in your home directory called .icalBuddyLocalization.plist

As for finding the file after the fact, you need to enable viewing of system files before you will be able to see it. Follow the instructions here (http://www.macworld.com/article/51830/2006/07/showallfinder.html) to show system (hidden) files in finder so you can see your newly created file in Finder.
 
Here's mine so far. Haven't decided what to do with iCal events yet! I want them somewhere, just don't know where! :D

Very nice start! I'm liking the vertical labels! :)

you could try putting your calendar events where you have them in the middle there with a vertical label as well....other option, depending on the maximum number of friends you would have displayed would be to put the events under your friends list. The only issue there is vertical expansion space for both lists.
 
Status
Not open for further replies.
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.