summaryrefslogtreecommitdiffstats
path: root/content
diff options
context:
space:
mode:
authorbreadcat2021-02-11 11:24:32 +0000
committerbreadcat2021-02-11 11:24:32 +0000
commit9c2bb2fdb4335095be46b47f22152ceae967fcb5 (patch)
tree55a145ff299dddfd770e4060a4ab302ad0ae5ae6 /content
parent41b42742751f1056a615418aae9632d4a26123e5 (diff)
downloadblog.minskio.co.uk-9c2bb2fdb4335095be46b47f22152ceae967fcb5.tar.gz
blog.minskio.co.uk-9c2bb2fdb4335095be46b47f22152ceae967fcb5.tar.bz2
blog.minskio.co.uk-9c2bb2fdb4335095be46b47f22152ceae967fcb5.zip
Update vim notes about line breaks
Diffstat (limited to 'content')
-rw-r--r--content/posts/personal-vim-cheatsheet.md5
1 files changed, 4 insertions, 1 deletions
diff --git a/content/posts/personal-vim-cheatsheet.md b/content/posts/personal-vim-cheatsheet.md
index f4fcfaf..764c9ae 100644
--- a/content/posts/personal-vim-cheatsheet.md
+++ b/content/posts/personal-vim-cheatsheet.md
@@ -1,6 +1,7 @@
---
title: "Personal VIM cheatsheet"
date: 2020-06-14T12:58:00
+lastmod: 2021-02-11T11:23:00
tags : [ "Guides", "Learning", "Linux", "Servers", "Snippets", "Software", ]
---
@@ -119,10 +120,12 @@ Add the below to your `init.vim` file (if using neovim):
autocmd BufWritepre * %s/\n\+\%$//e
```
-Another point worth adding is sometimes files formatted outside vim will contain '^@' symbols scattered between letters. These represent null characters and can be removed by running:
+Another point worth adding is sometimes files formatted outside vim will contain '^@' or '^M' symbols scattered between letters. These represent null or line break characters and can be removed by running:
```
%s/[\x0]//g
+%s/\r//g
```
* **Edit 2020-12-02:** Added notes regarding reading file contents and command output.
* **Edit 2021-01-02:** Added null character removal note.
+* **Edit 2021-02-11:** Added additional line break removal note.