I would like to a shortcut command in Mac as I frequently call commands that are a bit long in Terminal. How can I do that?
2 Answers
alias if you're using Bash.
-
the problem is that it resets everytime I close and open Terminal. Is there a way to make it permanent?– TamApr 9, 2010 at 4:37
-
3Put the alias into your .bashrc.– WhirlWindApr 9, 2010 at 4:40
-
Or a function, depending on how complicated the shortcut in. Aliases are simple text substitutions. functions can have parameters and code behind it. But functions require some simple shell coding knowledge. Aug 14, 2012 at 21:47
Save it as a .command but you may have to tamper around with the visibility settings.