Y
Hacker News
new
|
ask
|
show
|
jobs
by
DarkWiiPlayer
1641 days ago
`sudo !!` is just very useful, just as most other things you can do with history substitution. Ctrl-R has its own usefulness but it only does a fraction of what history substitution can do.
1 comments
abdusco
1641 days ago
I like fish shell's approach: [Alt]+[E] prepends the command with `sudo`.
So you hit arrow up to bring up the last command, then [Alt]+[E] to sudo-ify it.
link
So you hit arrow up to bring up the last command, then [Alt]+[E] to sudo-ify it.