running applications from the unix prompt

Discussion in 'Mac Basics and Help' started by ghanwani, Oct 24, 2010.

  1. ghanwani macrumors 6502a

    Joined:
    Dec 8, 2008
    #1
    If I'm browsing my directories in the terminal using unix commands, is it possible to start an applications such as Pages directly from the prompt?

    I do most of my file management via unix, but when I need to edit or view something, I go through the Finder which is kind of a pain.

    In Windows, just typing the file name at the command prompt would bring up the file in the appropriate application (based on file extension).

    Thanks,
    Anoop
     
  2. mulo macrumors 68020

    mulo

    Joined:
    Aug 22, 2010
    Location:
    Behind you
    #2
    you can with CLI apps, never tried with GUI apps
     
  3. Detektiv-Pinky macrumors 6502a

    Detektiv-Pinky

    Joined:
    Feb 25, 2006
    Location:
    Berlin, Germany
    #3
    open /Applications/TextEdit.app/ opens TextEdit
     
  4. ghanwani thread starter macrumors 6502a

    Joined:
    Dec 8, 2008
    #4
    Beautiful...just what I was looking for! It works for all applications!!!
    So now at the command prompt if I type:

    open /Applications/iWork\ \'09/Pages.app/ foo.doc, then it opens up Pages with foo.doc.

    Now all I need to do is create aliases/functions for all the apps and I'll be able to just type "Pages foo.doc" from any directory and it will work.

    Thanks!

    Anoop
     

Share This Page