Is it possible to tell Excel to open a file from the command line?
In Linux, I could do this using the command
libreoffice --calc test.xlsx
Ask Different is a question and answer site for power users of Apple hardware and software. It only takes a minute to sign up.Sign up to join this community
You can use the open command:
This will use the default application for the file type, which may not be the desired application.
or, to specify the application explicitly:
open test.xlsx -a /Applications/Microsoft\ Office\ 2011/Microsoft\ Excel.app/
open test.xlsx -a "Microsoft Excel"
A really useful way of doing this is to make an alias to Excel (in your
alias xl='open -a "Microsoft Excel"'
Then you can just type the following to open an file in Excel: