Tom Morris



2007.07.15

  No. 618 

Being able to trigger things in the future using QuickSilver is very useful. Who needs to bother with those shareware iTunes alarms? Just point QuickSilver to a playlist and tell it to run it at a certain time. The power of this little piece of software really is mind-blowing sometimes. 2007-07-15T22:05:53ZUntitled entry permalink

Using oxygen from the command line 2007-07-15T17:36:01ZPermalink

I spend a lot of time at the command line, and I always end up doing stupid things like trying to edit XML files in SubEthaEdit or, worse, nano. It's stupid, because I've got this gigantic, fully-featured XML editor on my desktop. But because it's less mental effort to type "see foo.xml" than to go to my Dock, click Oxygen and then navigate the OS X tree to find it, I never bother.

Today I thought I may as well set up bash to let me edit stuff in Oxygen. On the Mac, Oxygen has a shell script - 'oxygenMac.sh' - but it does some silly crap with the current working directory.

I've written a script called oxygen.py which you should be able to use. To install it, put it in ~/bin or wherever else you run your scripts from.

I've edited my .bash_profile to add an alias:

alias oxygen="python /Users/tom/code/oxygen.py "

You can use this from the command line in two ways:

oxygen [filename]

or by piping in data as STDIN

If you specify a filename, Oxygen will open that file. If you do not specify a filename, STDIN will be read in to a temporary file, and that will be opened in Oxygen.

Total programming time? Half an hour or so. Amount of time saved? Quite a lot, hopefully.

Tags: , ,

Comments | TrackBack

Comments
blog comments powered by Disqus


Tom Morris 9f4907d871750fd4c9b9bad7086701b51d6abd10 bd9f81a05283ed85e699175ed057b4a497f20b77 802c68123e12bf69d99a25a87cef360f18813fe4
Currently in: Kent, England
Usually in: East Sussex, England

I am a , an , like to code in and (and Java, but let’s not talk about that), and noodle about with and the .

I have an MA in philosophy from Heythrop College, University of London. My philosophical interests are in analytic metaphysics, ontology, modality, the work of , , , and . I have a strange, unfulfilled interest in . I’ve been influenced by Gadamer, by , , and .

Musically, I like jazz fusion, soul and P-Funk. My musical nirvana would be a mixture of Beethoven, Miles Davis and George Clinton topped with a side-serving of Erykah, Jill and Angie.

I also write for the Citizendium, an online encyclopedia project. If you know about stuff, you should join in. I occasionally produce audio recordings for The Pod Delusion.

Elsewhere:

  • GPG Key
  • del.icio.us
  • Flickr
  • Twitter
  • Jaiku
  • LinkedIn
  • ma.gnolia
  • blip.tv
  • upcoming.org
  • MetaFilter
  • LiveJournal
  • CiteULike
  • Technorati Profile

RSS Feed Subscribe:

RDF

« July 2007 »
SuMoTuWeThFrSa
1234567
891011121314
15161718192021
22232425262728
293031 

View in month context

On this day in: 2006 2009 2010