On occasion (actually today was the first time) there is need to downgrade a package in Arch Linux. Yesterday I did a `pacman -Syu`, which upgraded gcc from 4.4.3 to 4.5.0. Today, I learned that 4.5.0 is unable to compile Moab. You'd think that a new release of your trusty compiler would work at least as good as the last one, but that's a topic (spelled R-A-N-T) for another day. When this catastrophe strikes, you can do the following to recover.
- Feel free to leave constructive criticism, or point out a better way to do something.
- Personal attacks or flames, on me or anyone else, will be deleted.
- Past history has shown that 99% of comments I can't read (i.e. those in other languages) to be spam. Therefore, any comment I can't read will be removed.
- I'm pretty mellow concerning profanity, but excessive (as determined subjectively by me), bad language will be removed.
Friday, April 30, 2010
Thursday, April 8, 2010
A recent system upgrade broke my terminal colors. I don't know what exactly it was, or how it happened, but I opened a new terminal window, did a `ls`, and all my directories were bold and blue again. I personally find this difficult to read as I use a very dark blue background in my terminals (something on the order of #111133).
Run the following command to create a default dir_colors file (the file that generates the colors for the ls command):
`dircolors -p > ~/.dir_colors`Then, add the following to your .bashrc file:
# set the TERM variable to a color-enabled type (xterm-color)
# source my own .dir_colors file
if [ -f $HOME/.dir_colors ]
eval `dircolors -b $HOME/.dir_colors
- DIR 01;34
+ DIR 00;36 # directories are cyan and non-bold
Friday, March 5, 2010
I realize it's been over a year since my last post, and I have a bunch of stuff stacked up. But this was pretty slick and frankly, I don't want to lose it. So here goes.
do shell script "/System/Library/CoreServices/backupd.bundle/Contents/Resources/backupd-helper >/dev/null 2>&1 &"
property nullStr : ""
set defaultSrc to "/path/to/project/dir"
set defaultDest to "/path/to/destination/dir/in/Dropbox"
--- cancel actions from either of these dialogs will effectively cancel the script
set dropBoxSource to text returned of (display dialog "Dropbox backup source?" default answer defaultSrc)
set dropBoxDest to text returned of (display dialog "Dropbox backup destination?" default answer defaultDest)
if dropBoxSource is not equal to "" and dropBoxDest is not equal to "" then
set rsyncCmd to "rsync -rav " & dropBoxSource & " " & dropBoxDest
display dialog ("Run: '" & rsyncCmd & "'")
--- if the user cancels the dialog here, the rsync won't run. this is just what we want :)
--- set a 2-hour timeout for the rsync command
with timeout of 7200 seconds
do shell script rsyncCmd