In Linux, the alias command allows you to create short commands for longer commands.
This makes it easier and quicker to run frequently used commands by typing only the alias.
Aliases are created using the alias command followed by the desired alias name, an equal sign (=), and the command you want to associate with the alias.
It's important to note that aliases are only valid for the current session. If you want to make the alias permanent, you need to add it to your shell startup file, such as .bashrc
After adding an alias to your .bashrc file, you need to reload the file in order to make the alias available in your current terminal session.
Using "Group commands" in alias allows you to automate a series of frequently used commands and run them all with a single, easy-to-remember alias.
For example, if you regularly run the following commands to update your system.
apt update
apt upgrade
apt autoremove
apt autoclean
You could create a single alias named update with the following command.
alias update='apt update && apt upgrade && apt autoremove && apt autoclean'
Now, whenever you need to update your system, you can simply run the update alias instead of typing out the entire series of commands.
PLEASE SUBSCRIBE :)
PLEASE HIT LIKE IF IT HELPED :)
GIVE SUPPORT - / lazysysad
BUY ME A COFFEE - https://www.buymeacoffee.com/lazysysad
PAYPAL - https://www.paypal.com/donate/?hosted...
Drop me your feedback and comments.
That's all for now.
If this video helped you in any way, please like share and subscribe!
Thank you!!!
Смотрите видео The easiest and quickest way to run frequently used commands in онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь The Lazy SysAdmin 30 Январь 2023, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 1,740 раз и оно понравилось 125 людям.