• sndrtj
    link
    fedilink
    arrow-up
    10
    ·
    11 months ago

    Something I did to someone who needed to know the effects of not locking ones screen when away: alias ls to echo 'Error: file not found'. Took them a good hour to figure out what was wrong with their machine 😅

    • FIST_FILLET@lemmy.ml
      link
      fedilink
      arrow-up
      2
      ·
      11 months ago

      linux rookie here, what’s the command to reverse an alias then? do you just “alias ls ls” to overwrite it?

      • sndrtj
        link
        fedilink
        arrow-up
        4
        ·
        11 months ago

        Backlash. \ls would get you regular ls. Note that ls already is aliased on some popular distros with some common flags.

      • Chobbes@lemmy.world
        link
        fedilink
        arrow-up
        3
        ·
        11 months ago

        You can use unalias, or you can use a backslash in front of an aliased command or surround it in double quotes to ignore the alias temporarily.