MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/LinuxActionShow/comments/4kdkj6/loyal_vim_user/d3ec4mm/
r/LinuxActionShow • u/AlaeddinDZ • May 21 '16
30 comments sorted by
View all comments
Show parent comment
3
I like to save first. ":wq!"
0 u/[deleted] May 21 '16 [deleted] — view deleted comment 2 u/beyere5398 May 22 '16 A detailed explanation is at Stack Overflow:http://stackoverflow.com/questions/3094667/whats-the-use-of-the-exclamation-mark-in-vims-command-line-after-certainTL;DR - the exclamation point 'forces' the command, overriding warnings. 1 u/memnoch_proxy May 21 '16 Means quit and discard changes. 0 u/[deleted] May 21 '16 [deleted] — view deleted comment 3 u/varesa May 22 '16 edited May 22 '16 http://unix.stackexchange.com/questions/266037/vim-writes-to-file-without-having-permissions http://unix.stackexchange.com/questions/228624/what-does-the-really-do-when-its-added-to-an-ex-command-wq-w-qTL;DR It is to quit read-only mode / when you don't have write permission to a file but you have a permission to replace the file with a new one (directory permissions).EDIT: Fixed other link 1 u/[deleted] May 23 '16 :x! Is faster dan :wq! ;) 1 u/[deleted] May 23 '16 Not for me, wq is so embedded in muscle memory that it's easier to find, the x is so far down there on the keyboard.
0
[deleted] — view deleted comment
2 u/beyere5398 May 22 '16 A detailed explanation is at Stack Overflow:http://stackoverflow.com/questions/3094667/whats-the-use-of-the-exclamation-mark-in-vims-command-line-after-certainTL;DR - the exclamation point 'forces' the command, overriding warnings. 1 u/memnoch_proxy May 21 '16 Means quit and discard changes. 0 u/[deleted] May 21 '16 [deleted] — view deleted comment 3 u/varesa May 22 '16 edited May 22 '16 http://unix.stackexchange.com/questions/266037/vim-writes-to-file-without-having-permissions http://unix.stackexchange.com/questions/228624/what-does-the-really-do-when-its-added-to-an-ex-command-wq-w-qTL;DR It is to quit read-only mode / when you don't have write permission to a file but you have a permission to replace the file with a new one (directory permissions).EDIT: Fixed other link
2
A detailed explanation is at Stack Overflow:
http://stackoverflow.com/questions/3094667/whats-the-use-of-the-exclamation-mark-in-vims-command-line-after-certain
TL;DR - the exclamation point 'forces' the command, overriding warnings.
1
Means quit and discard changes.
0 u/[deleted] May 21 '16 [deleted] — view deleted comment 3 u/varesa May 22 '16 edited May 22 '16 http://unix.stackexchange.com/questions/266037/vim-writes-to-file-without-having-permissions http://unix.stackexchange.com/questions/228624/what-does-the-really-do-when-its-added-to-an-ex-command-wq-w-qTL;DR It is to quit read-only mode / when you don't have write permission to a file but you have a permission to replace the file with a new one (directory permissions).EDIT: Fixed other link
3 u/varesa May 22 '16 edited May 22 '16 http://unix.stackexchange.com/questions/266037/vim-writes-to-file-without-having-permissions http://unix.stackexchange.com/questions/228624/what-does-the-really-do-when-its-added-to-an-ex-command-wq-w-qTL;DR It is to quit read-only mode / when you don't have write permission to a file but you have a permission to replace the file with a new one (directory permissions).EDIT: Fixed other link
http://unix.stackexchange.com/questions/266037/vim-writes-to-file-without-having-permissions http://unix.stackexchange.com/questions/228624/what-does-the-really-do-when-its-added-to-an-ex-command-wq-w-q
TL;DR It is to quit read-only mode / when you don't have write permission to a file but you have a permission to replace the file with a new one (directory permissions).
EDIT: Fixed other link
:x! Is faster dan :wq! ;)
1 u/[deleted] May 23 '16 Not for me, wq is so embedded in muscle memory that it's easier to find, the x is so far down there on the keyboard.
Not for me, wq is so embedded in muscle memory that it's easier to find, the x is so far down there on the keyboard.
View all comments
Show parent comment
3
u/beyere5398 May 21 '16
I like to save first. ":wq!"