Opening files in apps using terminal

Written in

by

Sometimes it’s so handy to open a certain, probably hidden, file with your favourite code editor or at least TextEdit or Notepad. Take that, nano!

The following command will help you out with that. Let’s open Homestead.yaml, located in ~/.homestead with good old Sublime Text:

open -a 'Sublime Text' ~/.homestead/Homestead.yaml

If the app name doesn’t contain spaces, you can lose the quotes.

Tags