For example if I have a setup like:

 alias llaa = pwd && ll'''

Will the second command work, or would I have to set it up in a more verbose manner (like ```alias llaa = pwd && ls -la```)
  • @[email protected]
    link
    fedilink
    9
    edit-2
    3 months ago

    Should work. Just try it out and see if you get what you want. I tried:

    alias llaa='pwd && ll'
    

    then ran llaa and it did what I expected, current directory and the output of ls -al which is aliased.

  • @7uWqKj
    link
    73 months ago

    Yes. How about just trying it out?

  • @solrize
    link
    73 months ago

    I think you don’t want the spaces around the= sign. Preferred over alias is function llaa { … }. Alias is for backwards compatibility.

    • @[email protected]
      link
      fedilink
      13 months ago

      Preferred over alias is function llaa { … }. Alias is for backwards compatibility.

      Again what learned. What is wrong with having spaces around the equals sign, though?