diff options
author | Adam Stankiewicz <sheerun@sher.pl> | 2020-09-24 18:56:07 +0200 |
---|---|---|
committer | Adam Stankiewicz <sheerun@sher.pl> | 2020-09-24 18:56:07 +0200 |
commit | 4c028b37bf97294710b3ef55ea2a3ec84a1b7a3d (patch) | |
tree | c232489d4bc282ec46a5b6474a5e8e8c048e7c72 | |
parent | 9ff714cb6c43b920fd76ff793641c5191bf2e991 (diff) | |
download | vim-polyglot-4c028b37bf97294710b3ef55ea2a3ec84a1b7a3d.tar.gz vim-polyglot-4c028b37bf97294710b3ef55ea2a3ec84a1b7a3d.zip |
Add warning to generated files
-rw-r--r-- | autoload/polyglot.vim | 4 | ||||
-rw-r--r-- | ftdetect/polyglot.vim | 4 | ||||
-rwxr-xr-x | scripts/build | 3 |
3 files changed, 6 insertions, 5 deletions
diff --git a/autoload/polyglot.vim b/autoload/polyglot.vim index ee03e989..d0e95b75 100644 --- a/autoload/polyglot.vim +++ b/autoload/polyglot.vim @@ -1,4 +1,4 @@ -""" autoload/polyglot.vim +" Please do not edit this file directly, instead modify polyglot.vim or scripts/build " Line continuation is used here, remove 'C' from 'cpoptions' let s:cpo_save = &cpo @@ -700,4 +700,4 @@ if exists('g:polyglot_disabled') endif " restore Vi compatibility settings -let &cpo = s:cpo_save +let &cpo = s:cpo_save
\ No newline at end of file diff --git a/ftdetect/polyglot.vim b/ftdetect/polyglot.vim index cba8cf86..343d4528 100644 --- a/ftdetect/polyglot.vim +++ b/ftdetect/polyglot.vim @@ -1,4 +1,4 @@ -""" ftdetect/polyglot.vim +" Please do not edit this file directly, instead modify polyglot.vim or scripts/build " don't spam the user when Vim is started in Vi compatibility mode let s:cpo_save = &cpo @@ -2224,4 +2224,4 @@ if exists('g:polyglot_disabled') endif " restore Vi compatibility settings -let &cpo = s:cpo_save +let &cpo = s:cpo_save
\ No newline at end of file diff --git a/scripts/build b/scripts/build index 0ed76045..482ffcf6 100755 --- a/scripts/build +++ b/scripts/build @@ -13,7 +13,8 @@ Dir.chdir(File.dirname(__dir__)) BASE_URL = 'https://raw.githubusercontent.com/github/linguist/master' def read_section(name) - File.read('polyglot.vim').match(/""" #{Regexp.escape(name)}.*\n(?=\n""")/m)[0] + "\" Please do not edit this file directly, instead modify polyglot.vim or scripts/build\n\n" + + File.read('polyglot.vim').match(/""" #{Regexp.escape(name)}\n*(.*)\n(?=\n""")/m)[1] end def camelize(str) |