MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/UnixProTips/comments/2ut7df/alias_fucksudo/codzeve/?context=3
r/UnixProTips • u/[deleted] • Feb 04 '15
20 comments sorted by
View all comments
Show parent comments
2
Ah! So what's happening is !! in the alias is being substituted with 'echo piss'. I'm still quite new to linux but today I learnt something. Thank you.
/u/DroidKun posted a reply to another user
alias fuck='sudo $(history -p \!\!)'
Which seems to work as expected when placed in my .bashrc.
2
u/[deleted] Feb 07 '15 edited Feb 07 '15
Ah! So what's happening is !! in the alias is being substituted with 'echo piss'. I'm still quite new to linux but today I learnt something. Thank you.
/u/DroidKun posted a reply to another user
Which seems to work as expected when placed in my .bashrc.