3 ms·
I hope that you are joking since you just have to press `Alt` + `S` to rerun the previous command with sudo in fish-shell: > `Alt` + `S` Prepends sudo to the c
by 7839284023 3y ago
I hope that you are joking since you just have to press `Alt` + `S` to rerun the previous command with sudo in fish-shell:
> `Alt` + `S` Prepends sudo to the current commandline. If the commandline is empty, prepend sudo to the last commandline.
https://fishshell.com/docs/current/interactive.html#shared-bindings https://fishshell.com/docs/current/interactive.html#shared-b...
- JNRowe 3y agoThat is a recent(-ish) addition¹, arriving in 3.1. Your interpretation of recent may be a different length to mine, but one Debian release in this instance ;) ¹ https://github.com/fish-shell/fish-shell/pull/6140 https://github.com/fish-shell/fish-shell/pull/6140
- winter_blue 3y agoI guess he wasn't aware. I use fish, and I'm learning this now too. I probably really should give the fish docs a read-through, as I imagine it could significantly improve my shell efficiency.
- istjohn 3y agoGlad to hear that's changed. There were strident statements from the developer on Github last time I researched it to the effect that implementing '!'-style history expansion was contrary to the fish philosophy and that people just need to learn the fish-y way. Looking back it, I probably could have fixed the issue for myself by setting up vi-mode in fish, but I didn't come across that option at the time.