Spell update, other rust plug-in for vscode, fix votion journal bug
parent
12cc4a2ad3
commit
0a7dcd55e2
|
@ -352,7 +352,7 @@ function! plug#end()
|
|||
endif
|
||||
let lod = { 'ft': {}, 'map': {}, 'cmd': {} }
|
||||
|
||||
if exists('g:did_load_filetypes')
|
||||
if get(g:, 'did_load_filetypes', 0)
|
||||
filetype off
|
||||
endif
|
||||
for name in g:plugs_order
|
||||
|
@ -2621,26 +2621,34 @@ function! s:preview_commit()
|
|||
|
||||
let sha = matchstr(getline('.'), '^ \X*\zs[0-9a-f]\{7,9}')
|
||||
if empty(sha)
|
||||
return
|
||||
let name = matchstr(getline('.'), '^- \zs[^:]*\ze:$')
|
||||
if empty(name)
|
||||
return
|
||||
endif
|
||||
let title = 'HEAD@{1}..'
|
||||
let command = 'git diff --no-color HEAD@{1}'
|
||||
else
|
||||
let title = sha
|
||||
let command = 'git show --no-color --pretty=medium '.sha
|
||||
let name = s:find_name(line('.'))
|
||||
endif
|
||||
|
||||
let name = s:find_name(line('.'))
|
||||
if empty(name) || !has_key(g:plugs, name) || !isdirectory(g:plugs[name].dir)
|
||||
return
|
||||
endif
|
||||
|
||||
if exists('g:plug_pwindow') && !s:is_preview_window_open()
|
||||
execute g:plug_pwindow
|
||||
execute 'e' sha
|
||||
execute 'e' title
|
||||
else
|
||||
execute 'pedit' sha
|
||||
execute 'pedit' title
|
||||
wincmd P
|
||||
endif
|
||||
setlocal previewwindow filetype=git buftype=nofile nobuflisted modifiable
|
||||
setlocal previewwindow filetype=git buftype=nofile bufhidden=wipe nobuflisted modifiable
|
||||
let batchfile = ''
|
||||
try
|
||||
let [sh, shellcmdflag, shrd] = s:chsh(1)
|
||||
let cmd = 'cd '.plug#shellescape(g:plugs[name].dir).' && git show --no-color --pretty=medium '.sha
|
||||
let cmd = 'cd '.plug#shellescape(g:plugs[name].dir).' && '.command
|
||||
if s:is_win
|
||||
let [batchfile, cmd] = s:batchfile(cmd)
|
||||
endif
|
||||
|
@ -2766,9 +2774,9 @@ function! s:snapshot(force, ...) abort
|
|||
1
|
||||
let anchor = line('$') - 3
|
||||
let names = sort(keys(filter(copy(g:plugs),
|
||||
\'has_key(v:val, "uri") && !has_key(v:val, "commit") && isdirectory(v:val.dir)')))
|
||||
\'has_key(v:val, "uri") && isdirectory(v:val.dir)')))
|
||||
for name in reverse(names)
|
||||
let sha = s:git_revision(g:plugs[name].dir)
|
||||
let sha = has_key(g:plugs[name], 'commit') ? g:plugs[name].commit : s:git_revision(g:plugs[name].dir)
|
||||
if !empty(sha)
|
||||
call append(anchor, printf("silent! let g:plugs['%s'].commit = '%s'", name, sha))
|
||||
redraw
|
||||
|
|
|
@ -11,8 +11,9 @@ tags: [journal]
|
|||
def create_daily_journal():
|
||||
file_name = datetime.datetime.now().strftime("journal-%Y-%m-%d.md")
|
||||
file_path = os.path.join("/home/felixm/owc/archive/2022", file_name)
|
||||
with open(file_path, "w") as f:
|
||||
f.write(FILE_TEMPLATE)
|
||||
if not os.path.isfile(file_path):
|
||||
with open(file_path, "w") as f:
|
||||
f.write(FILE_TEMPLATE)
|
||||
return file_path
|
||||
|
||||
file_path = create_daily_journal()
|
||||
|
|
|
@ -0,0 +1,2 @@
|
|||
iSYSTEM
|
||||
Regensburg
|
Binary file not shown.
21
vim/vimrc
21
vim/vimrc
|
@ -156,7 +156,7 @@ augroup END
|
|||
" Filetype css {{{
|
||||
augroup filetype_css
|
||||
autocmd!
|
||||
autocmd FileType css setlocal tabstop=4 softtabstop=0 expandtab shiftwidth=4 smarttab
|
||||
autocmd FileType css setlocal tabstop=2 softtabstop=0 expandtab shiftwidth=2 smarttab
|
||||
autocmd FileType css setlocal foldmethod=marker
|
||||
autocmd FileType css setlocal foldmarker=/begin,/end
|
||||
augroup END
|
||||
|
@ -200,11 +200,19 @@ augroup END
|
|||
" Filetype lua {{{
|
||||
augroup filetype_lua
|
||||
autocmd!
|
||||
autocmd FileType lua setlocal tabstop=4
|
||||
autocmd FileType lua setlocal shiftwidth=4
|
||||
autocmd FileType lua setlocal expandtab
|
||||
autocmd FileType lua setlocal autoindent
|
||||
autocmd FileType lua setlocal foldmethod=marker
|
||||
augroup END
|
||||
" }}}
|
||||
" Filetype tex {{{
|
||||
augroup filetype_tex
|
||||
autocmd!
|
||||
autocmd FileType tex setlocal tabstop=2
|
||||
autocmd FileType tex setlocal shiftwidth=2
|
||||
autocmd FileType tex setlocal expandtab
|
||||
autocmd FileType tex setlocal autoindent
|
||||
augroup END
|
||||
augroup filetype_cpp
|
||||
autocmd!
|
||||
autocmd FileType cpp setlocal tabstop=4 shiftwidth=4 expandtab autoindent smarttab formatoptions=croql nu
|
||||
augroup END
|
||||
" }}}
|
||||
" Filetype xml {{{
|
||||
|
@ -345,6 +353,7 @@ call plug#begin('~/.vim/plugged')
|
|||
Plug 'vim-airline/vim-airline'
|
||||
Plug 'godlygeek/tabular'
|
||||
Plug 'felixio@git.felixm.de:felixm/votion.git', {'for': 'markdown'}
|
||||
Plug 'dhruvasagar/vim-table-mode', {'for': 'markdown'}
|
||||
" Plug 'flazz/vim-colorschemes'
|
||||
" Plug 'vimwiki/vimwiki'
|
||||
call plug#end()
|
||||
|
|
|
@ -82,7 +82,7 @@
|
|||
},
|
||||
"[rust]": {
|
||||
"editor.formatOnSave": true,
|
||||
"editor.defaultFormatter": "rust-lang.rust"
|
||||
"editor.defaultFormatter": "matklad.rust-analyzer"
|
||||
},
|
||||
"workbench.editorAssociations": {
|
||||
"*.ipynb": "jupyter.notebook.ipynb"
|
||||
|
@ -91,5 +91,6 @@
|
|||
"[jsonc]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"workbench.startupEditor": "none"
|
||||
"workbench.startupEditor": "none",
|
||||
"window.zoomLevel": 1
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue