Tag Archives: command line

Use JSBeautifier from the command line on Mac OS X

Recently I read a post about how to use JSBeautify in Textmate via the filter selection command. It was also nice in that it gave an example of how to install JSBeautify on your system – I think it will work for any linux machine, but I was using OS X. The jsbeautifier.org has a nice interface, good results, and lots of options: To install on Mac OSX, to install JSBeautify, you can use the following commands: cd /tmp git clone https://github.com/einars/js-beautify.git cd js-beautify/python python setup.py install Then you can simply use js-beautify /path/to/filename.js to have it run. All the power of jsbeautifier.org right at your fingertips as a command-line tool!

Posted in Mac, Tech Tips, Web Development | Tagged , , , | Leave a comment

Send Folders to CodeKit via the Command Line

If you’re doing some web development with CodeKit and want to be able to send folders to the program via the command line (I was really hoping to do this via Quicksilver), then you can use this little tidbit: open -a /Applications/CodeKit.app “/path/to/your/project” The CodeKit application apparently does not associate itself with being able to open files and so it doesn’t register with folders or files as being an available “Open With” application for opening them. Again I was hoping to do this via a quicksilver action, something like: If it did then quicksilver would stick it in the third pane when using the “Open With” action, wouldn’t that be nice! It is possible to get it into the third pane but you need to have the path to the application in your clipboard (/Applications/CodeKit.app) and then: Select the Folder Choose “Open With” Tab to the third pane and paste the path to the application in. That’s demonstrated in the screenshot above. CodeKit’s not too bad, some aspects seem sluggish and I wish there were more features to customize it – like inclusion and exclusion rules and a finer grained control of which tabs refresh in the browser – also maybe some explanation of their partial CSS injection-on-update feature they have in the preferences.

Posted in Mac, Tech Tips, Web Development | Tagged , , , , | Leave a comment