bash - Print terminal alias command as well as executing it -


as terminal noob, i've created aliases pretty do. problem i've started forgetting few commands know because of it. on top of that, need edit variable in previous command.

so i'd if when use alias, first line printed actual command represents, proceed execute command. since pressing , !! reprints alias, i'm not sure how reference underlying command.

thanks.

you can use:

  • alias list aliases, or
  • alias name show specification of alias name.

so in fact can define alias as

alias myalias="alias myalias; <do stuff>" 

i think chepner's answer alt-control-e more practical, posting completeness.


Comments

Popular posts from this blog

user interface - How to replace the Python logo in a Tkinter-based Python GUI app? -

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -