> im in ur x, y'ing ur z_ 

c u t u p @ c u t u p . o r g

 xml 

[quicksilver filehere] last modified: 03/25/2007 02:05 pm

Thanks to this hint, I was able to integrate creating a new file in the current Finder directory rather nicely into Quicksilver.

It involves an applescript. Copy/paste the code into Script Editor and save as "File Here.scpt" in ~/Library/Application Support/Quicksilver/Actions/. You may have to create this folder. I had to quit and restart Quicksilver to get it to recognize the new action.

You might need to have "Enable access for assistive devices" enabled under Universal Access in System Preferences, or that might just be something necessary for the script this was based on.

To use:

  1. activate Quicksilver
  2. type "." (i.e. hit the period key)
  3. type the file name you want to create (i.e. newfile.txt)
  4. press tab
  5. start typing "File Here"
  6. once Quicksilver finds "File Here.scpt", press return
  7. A new file will be created in the front Finder window, or on the Desktop if no window is open

Caveats apply. It works great for me so far, but though I've tried to use it as many ways as I can to test it, I can't say there won't be any bugs. Please let me know (djbidi@gmail.com) if you have any problems or suggested improvements.

If you use an editor that has a command line tool, such as TextMate, bbEdit, or Smultron, you can replace touch in the applescript with the full path to the command - for example I use TexMate and would use /usr/local/bin/mate

Then, instead of creating a new file, it will open the editor with the file all set up to save in the right spot. And if you quit the editor without saving, the file is never created.




[All Posts] [top]

tags:

filehere
quicksilver