DEV Community

Discussion on: Linux aliases set up simple!

Collapse
 
anonyco profile image
Jack Giffin • Edited

Two important edits:

  1. Combine steps one and two. There's no reason to separate them:

    nano ~/.bashrc
    

    For step #3:

    . ~/.bashrc
    

    . should be introduced to readers, not source. The source command is a bashism and should be avoided in favour of . so that readers gain a more generalized and useful knowledge.

  2. Clarify that alias expansion is not standard POSIX and only works for bash in conjunction with the shopt -s expand_aliases bash option (which happens to be enabled by default). It's safe if you follow your steps because only bash will read ~/.bashrc, but I and some other people take examples from posts we read and apply them elsewhere, so this is important notice.

Collapse
 
ivayloiv profile image
Ivaylo Ivanov

Thank you very much for your feedback. I will take it into account.