What is Bash alias commands scripting using shell for linux, unix OS machines?

How to create bash alias permanent?

bash alias is straight forward just declare it to bashrc and run bashrc

How to declare bash alias?

alias alias_name="command_to_run"

(the alias name that your providing and command name is linux command)
Steps to create bash alias?
  1. gedit ~/.bashrc

  2. alias km="cd /var/www/html/project/"

  3. . ~/.bashrc

  4. More useful explaination articles about bash alias dynamic functions and usage

Generate Bash Alias script
Bash

Bash is shell compatible command language interpreter that executes commands read from the standard input or from a file

Alias

Creating or naming to something for the convinient

LINUX UNIX Machines

Both are operating systems

Shell

Shell is a scripting lanugage

why should you create bash alias?

When software and networking people like us use to work on command line a lot, Think of the commands you use repeatedly say long commands or set of commands, If you could just simple rap it to shorter one your time will be saved

What is bashrc?

Its a file located in linux unix system which used to add commands, bash to it whenever runs

How to create bash alias with dynamic line parameters and functions?

alias a='_aa () { git add "$@"; }; _aa'

How to create add bash alias with conditons based dynamic line parameters and functions?

alias d='_fn () { if [ -z "$@" ]; then git diff; else git diff "$@"; fi }; _fn'

How to create condition based bash alias with dynamic line parameters and functions?

alias ud='_gd () { if [ -z "$@" ]; then git diff; else git diff "$@"; fi }; _gd'