mirror of
https://github.com/kmein/niveum
synced 2026-03-16 10:11:08 +01:00
vim: disable copilot by default or else it reads my passwords
This commit is contained in:
@@ -129,9 +129,7 @@ autocmd! User GoyoEnter Limelight
|
||||
autocmd! User GoyoLeave Limelight!
|
||||
|
||||
|
||||
" Disable Copilot for files larger than 100kb
|
||||
autocmd BufReadPre *
|
||||
\ let f=getfsize(expand("<afile>"))
|
||||
\ | if f > 100000 || f == -2
|
||||
\ | let b:copilot_enabled = v:false
|
||||
\ | endif
|
||||
" Disable Copilot by default
|
||||
let b:copilot_enabled = v:false
|
||||
" keymap to toggle it enabled
|
||||
nnoremap <leader>gc :let b:copilot_enabled = !b:copilot_enabled<CR>
|
||||
|
||||
Reference in New Issue
Block a user