Bash Aliasing Create an Alias

Help us to keep this website almost Ad Free! It takes only 10 seconds of your time:
> Step 1: Go view our video on YouTube: EF Core Bulk Extensions
> Step 2: And Like the video. BONUS: You can also share it!

Example

alias word='command'

Invoking word will run command. Any arguments supplied to the alias are simply appended to the target of the alias:

alias myAlias='some command --with --options'
myAlias foo bar baz

The shell will then execute:

some command --with --options foo bar baz

To include multiple commands in the same alias, you can string them together with &&. For example:

alias print_things='echo "foo" && echo "bar" && echo "baz"'


Got any Bash Question?