I downloaded the Octave app bundle from here. The app is in /⁨Applications⁩. I have been unable to open it from the terminal. I tried the command 'octave' and some other variations from the documentation.

My goal is to be able to run a file /⁨Users/[me]/Documents⁩/OctavePrograms/firstlast.m⁩ in the command line by typing octave firstlast.m or some variation of it. I would like to understand why I have been unable to run my program.

  • Try open -a "Octave" ~/Documents⁩/OctavePrograms/firstlast.m
    – airsquared
    Nov 10, 2018 at 19:21

1 Answer 1


You can use the following to open Octave with a file:

open -a "Octave" /path/to/file

If you want, alias this to octave by adding this line to your ~/.bash_profile:

alias octave="open -a \"Octave\""

Now you should be able to use octave /path/to/file anywhere.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .