This commit is contained in:
Adam Stankiewicz
2017-12-06 12:56:27 +01:00
parent 30c87b73de
commit dce9e8dec5
20 changed files with 366 additions and 93 deletions

View File

@@ -152,4 +152,13 @@ function! s:DotPackagesFile() abort
return [v:false, '']
endfunction
" Prevent writes to files in the pub cache.
function! dart#setModifiable() abort
let full_path = expand('%:p')
if full_path =~# '.pub-cache' ||
\ full_path =~# 'Pub\Cache'
setlocal nomodifiable
endif
endfunction
endif