I copied the following Bash script from MacScripter and combined it with TextExpander's ability to execute Apple Script in order to give me the ability to switch to the Login screen via a keyboard shortcut (I mapped it to 'ffus').
BASH:
-
#!/bin/sh
-
# Fast User Switching from the command line
-
# I saved mine as /usr/local/bin/fus
-
-
CGSession='/System/Library/CoreServices/Menu Extras/User.menu/Contents/Resources/CGSession'
-
-
case "$#" in
-
0)
-
# display login screen
-
exec "$CGSession" -suspend
-
exit
-
;;
-
esac
-
-
# No reason to display the login panel for the current user
-
case "$1" in
-
"$USER" | "$UID")
-
exit 0
-
;;
-
esac
-
-
# can pass in a (short) username or userid
-
id=`/usr/bin/id -u "$1"` || exit
-
-
# display login panel for user
-
exec "$CGSession" -switchToUserID "$id"
The Apple Script I use to invoke this from TextExpander is:
APPLESCRIPT:
-
do shell script "/usr/local/bin/fus "
Tags: Mac
MagLev is a Ruby VM in the works by Gemstone that is targeted for a first release around September of 2008. I am really excited about this development. The VM will hook up to the caches and persistent store that Gemstone provides.
Avi Bryant gave a nice demo of 100 days of work on the VM. It does simple things in the typical Gemstone distributed fashion. Talking with some Gemstone folks afterward, I found out that in 100 days they have implemented about 20% or 30% of the Core library. In the MagLev talk they mentioned that they are effectively (and impressively) running about 38 of the rubyspecs defined by the Rubinius team.
Great stuff.
Tags: Rails · Ruby · Smalltalk
I went to a tutorial for Powering Rails with AIR at the RailsConf2008. There are some neat capabilities there. One cool app they showed was their TwitterFriends which is a related-objects-graph application. I could care less for Twitter, but I could imagine using this same thing for analyzing informal networks within a company (eg. hooking into an Exchange server and building a network based on email To: and Cc: headers).
Tags: Ruby
Our pastor, Shiva Tewari, had a really inspiring thought in today's service (well, actually he had a lot of inspiring thoughts, but here's just one...)
If religion is your god, you are certainly in bondage. However, if God is your religion you are certainly free.
It's a bit out of context but the thought is simple enough to understand: the church today is so full of impersonating spirits that most of Christianity is not really an inspired life, but instead a copy of someone else's inspiration.
Instead of praying from the heart, people learn to copy others' prayers. Instead of fasting out of inspiration, it's a formula by which we expect to earn some favor from God.
We may quote Galatians 2:20, "I am crucified with Christ, therefore I no longer live..." but is it really so? To be crucified with Christ is to be fully identified with the message of His crucifixion, the message of the cross. To know why Christ died, and what it has accomplished in my life!!
Oh that I might truly be crucified with Christ...
Tags: Christ
Scott Chacon put out a good tutorial video at http://jointheconversation.org/railsgit for using git and Capistrano with Rails development.
Tags: Ruby