Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dotfiles
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Chris Coley
dotfiles
Compare revisions
0792b214ff406dfec3e690ab1c247bb3d9c2ab6c to ef4d74c729af177f70c67d4d9e0c685ae742560c
Compare revisions
Changes are shown as if the
source
revision was being merged into the
target
revision.
Learn more about comparing revisions.
Source
chris/dotfiles
Select target project
No results found
ef4d74c729af177f70c67d4d9e0c685ae742560c
Select Git revision
Loading items
Swap
Target
chris/dotfiles
Select target project
chris/dotfiles
1 result
0792b214ff406dfec3e690ab1c247bb3d9c2ab6c
Select Git revision
Loading items
Show changes
Only incoming changes from source
Include changes to target since source was created
Compare
Commits on Source (2)
Update the 'listchars' in the vimrc
· 79e91282
Chris Coley
authored
5 years ago
79e91282
Add wrap to the modeline for markdown files
· ef4d74c7
Chris Coley
authored
5 years ago
ef4d74c7
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
vimrc
+6
-4
6 additions, 4 deletions
vimrc
with
6 additions
and
4 deletions
vimrc
View file @
ef4d74c7
...
...
@@ -11,13 +11,15 @@ set showmatch " Show matching [] () {} etc...
set showcmd " Show commands as you type them
set smartindent " Let vim help with indentation
set nowrap " Do not wrap lines longer than the window
set linebreak " Wrap long lines on whitespace instead of mid-word
set scrolloff=5 " Minimum number of lines to keep above/below the cursor
syntax enable " Syntax highlighting
set backspace=2 " Make Backspace work like you expect
set formatoptions+=ro " Automatically insert the comment character when you
" hit <Enter> (r) or o/O (o) in a comment block
set showbreak=└\ " Prefix wrapped continuation lines with '└ '
set commentstring=#%s " The default comment style for line comments
let mapleader='\' " The <leader> key
let mapleader='\' " The <leader> key
for key maps
" Tab options
...
...
@@ -56,7 +58,7 @@ cmap w!! w !sudo tee > /dev/null %
" Show invisible characters with `:set list!` or <F10>
set nolist
set listchars=tab:
»-
,trail:·,extends:>,precedes:<,eol:¬
set listchars=tab:
\|·
,trail:·,
nbsp:¤,
extends:>,precedes:<,eol:¬
nnoremap <F10> :set list!<CR>
...
...
@@ -89,7 +91,7 @@ autocmd VimLeave * let &titleold = $USER . "@" . hostname() | setlocal title
" Append a modeline at the end of a file. Uses '#' comment character
nnoremap <leader>ml :call AppendModeline()<CR>
function! AppendModeline()
let l:modeline = printf(&commentstring, printf(" vi: set ts=%d sw=%d %set ft=%s:", &ts, &sw, &et ? '' : 'no', &ft))
let l:modeline = printf(&commentstring, printf(" vi: set ts=%d sw=%d %set
%s
ft=%s:", &ts, &sw, &et ? '' : 'no',
&wrap ? 'wrap ' : '',
&ft))
call append(line("$"), l:modeline)
endfunction
...
...
@@ -102,7 +104,7 @@ autocmd FileType gitconfig setlocal commentstring=;%s
autocmd FileType go setlocal commentstring=//%s
autocmd FileType html setlocal commentstring=<!--%s-->
autocmd FileType less setlocal commentstring=/*%s*/
autocmd FileType markdown setlocal commentstring=[_modeline]:\ #\ (%s\ )
autocmd FileType markdown setlocal
wrap
commentstring=[_modeline]:\ #\ (%s\ )
autocmd FileType php setlocal commentstring=//%s
autocmd FileType plsql setlocal commentstring=--%s
autocmd FileType sass setlocal commentstring=//%s
...
...
This diff is collapsed.
Click to expand it.