Skip to content

Instantly share code, notes, and snippets.

@sergioPerez-e
Last active March 20, 2025 03:10
Show Gist options
  • Save sergioPerez-e/c5a80113a7a7aa1b2aedeaded56bd8cc to your computer and use it in GitHub Desktop.
Save sergioPerez-e/c5a80113a7a7aa1b2aedeaded56bd8cc to your computer and use it in GitHub Desktop.
Adding alias to a command on Linux

Adding a permaent alias to a command on Linux

I will create a permanent alias of gnome-text-editor to text to be more aficient.

  1. edit bashrc.
nano ~/.bashrc  
  1. Add alias into a alias section
alias text='gnome-text-editor'
  1. Save Ctrl + O, Ctrl + X and apply changes.
source ~/.bashrc 

For Zsh (Oh my Zsh) edit zshrc

nano ~/.zshrc
touch ~/.zshrc   

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment