mirror of
https://github.com/sheerun/vim-polyglot.git
synced 2025-11-08 11:33:52 -05:00
Fix all warning messages
This commit is contained in:
@@ -111,7 +111,7 @@ let s:globs = {
|
||||
\ 'idris': '*.idr,*.lidr,idris-response',
|
||||
\ 'idris2': '*.idr,*.ipkg,idris-response',
|
||||
\ 'ion': '*.ion',
|
||||
\ 'javascript': '*.js,*._js,*.bones,*.cjs,*.es,*.es6,*.frag,*.gs,*.jake,*.jsb,*.jscad,*.jsfl,*.jsm,*.jss,*.mjs,*.njs,*.pac,*.sjs,*.ssjs,*.xsjs,*.xsjslib,Jakefile',
|
||||
\ 'javascript': '*.js,*._js,*.bones,*.cjs,*.es,*.es6,*.frag,*.gs,*.jake,*.jsb,*.jscad,*.jsfl,*.jsm,*.jss,*.mjs,*.njs,*.pac,*.sjs,*.ssjs,*.xsjs,*.xsjslib,*.javascript,Jakefile',
|
||||
\ 'javascriptreact': '*.jsx',
|
||||
\ 'jq': '*.jq,.jqrc,.jqrc*',
|
||||
\ 'json': '*.json,*.avsc,*.geojson,*.gltf,*.har,*.ice,*.JSON-tmLanguage,*.jsonl,*.mcmeta,*.tfstate,*.tfstate.backup,*.topojson,*.webapp,*.webmanifest,*.yy,*.yyp,*.jsonp,*.template,.arcconfig,.htmlhintrc,.tern-config,.tern-project,.watchmanconfig,composer.lock,mcmod.info,Pipfile.lock',
|
||||
@@ -228,7 +228,7 @@ let s:globs = {
|
||||
\ 'zephir': '*.zep',
|
||||
\ 'zig': '*.zig,*.zir',
|
||||
\ 'zir': '*.zir',
|
||||
\ 'zsh': '*.zsh,.zshrc,.zshenv,.zlogin,.zprofile,.zlogout,.zlog*,.zcompdump*,.zfbfmarks',
|
||||
\ 'zsh': '*.zsh,.zshrc,.zshenv,.zlogin,.zprofile,.zlogout,.zlog*,.zcompdump*,.zfbfmarks,.zsh*',
|
||||
\}
|
||||
|
||||
func! sleuth#GlobForFiletype(type)
|
||||
|
||||
@@ -291,7 +291,7 @@ if !has_key(s:disabled_packages, 'go')
|
||||
endif
|
||||
|
||||
if !has_key(s:disabled_packages, 'javascript')
|
||||
au! BufRead,BufNewFile *.js,*.cjs,*.es,*.gs,*.mjs,*.pac
|
||||
au! BufRead,BufNewFile *.js,*.cjs,*.es,*.gs,*.mjs,*.pac,*.javascript
|
||||
endif
|
||||
|
||||
if !has_key(s:disabled_packages, 'jsx')
|
||||
@@ -427,7 +427,7 @@ if !has_key(s:disabled_packages, 'scss')
|
||||
endif
|
||||
|
||||
if !has_key(s:disabled_packages, 'sh')
|
||||
au! BufRead,BufNewFile */etc/udev/cdsymlinks.conf,*.zsh,.zshrc,.zshenv,.zlogin,.zprofile,.zlogout,.zlog*,.zcompdump*,.zfbfmarks
|
||||
au! BufRead,BufNewFile */etc/udev/cdsymlinks.conf,*.zsh,.zshrc,.zshenv,.zlogin,.zprofile,.zlogout,.zlog*,.zcompdump*,.zfbfmarks,.zsh*
|
||||
endif
|
||||
|
||||
if !has_key(s:disabled_packages, 'smt2')
|
||||
@@ -1075,6 +1075,7 @@ if !has_key(s:disabled_packages, 'javascript')
|
||||
au BufNewFile,BufRead *.frag set ft=javascript
|
||||
au BufNewFile,BufRead *.gs set ft=javascript
|
||||
au BufNewFile,BufRead *.jake set ft=javascript
|
||||
au BufNewFile,BufRead *.javascript set ft=javascript
|
||||
au BufNewFile,BufRead *.js set ft=javascript
|
||||
au BufNewFile,BufRead *.jsb set ft=javascript
|
||||
au BufNewFile,BufRead *.jscad set ft=javascript
|
||||
@@ -1794,6 +1795,7 @@ if !has_key(s:disabled_packages, 'sh')
|
||||
au BufNewFile,BufRead {.,}zlogin set ft=zsh
|
||||
au BufNewFile,BufRead {.,}zlogout set ft=zsh
|
||||
au BufNewFile,BufRead {.,}zprofile set ft=zsh
|
||||
au BufNewFile,BufRead {.,}zsh* call s:StarSetf('zsh')
|
||||
au BufNewFile,BufRead {.,}zshenv set ft=zsh
|
||||
au BufNewFile,BufRead {.,}zshrc set ft=zsh
|
||||
endif
|
||||
|
||||
@@ -850,6 +850,8 @@ ignored_dirs:
|
||||
filetypes:
|
||||
- name: javascript
|
||||
linguist: JavaScript
|
||||
extra_extensions:
|
||||
- javascript
|
||||
- name: flow
|
||||
extensions:
|
||||
- flow
|
||||
@@ -1510,6 +1512,7 @@ filetypes:
|
||||
- '.zlog*'
|
||||
- '.zcompdump*'
|
||||
- '.zfbfmarks'
|
||||
- '.zsh*'
|
||||
---
|
||||
name: zinit
|
||||
remote: zinit-zsh/zplugin-vim-syntax
|
||||
|
||||
@@ -657,7 +657,6 @@ def expand_all(pattern, all = false)
|
||||
if e3.match(/\*\.[a-z]/)
|
||||
results << "*." + e3[2].upcase + e3[3..-1]
|
||||
end
|
||||
results << "*"
|
||||
end
|
||||
results
|
||||
end
|
||||
@@ -737,17 +736,18 @@ def show_warnings(all_filetypes, expected_filetypes)
|
||||
(f["extensions"] || []).map { |e| "*." + e } + (f["filenames"] || [])
|
||||
end
|
||||
|
||||
|
||||
all_handled = process_list(all_filetypes, all_expected) do |f|
|
||||
[f["filenames"], f["ignored_filenames"], f["ignored_warnings"]].compact.flatten +
|
||||
[f["extensions"], f["ignored_extensions"]].compact.flatten.map { |e| "*." + e }
|
||||
end
|
||||
|
||||
all_handled_regexps = Hash[all_handled.group_by { |a, b| a }.map { |a, b| [a, b[1]] }.map do |a, b|
|
||||
[a, Regexp.union(b.map { |x| Regexp.escape(x).gsub('\\*', '.*') })]
|
||||
all_handled_regexps = Hash[all_handled.group_by { |a, b| a }.map do |a, b|
|
||||
[a, Regexp.union(b.map { |x| Regexp.new(Regexp.escape(x[1]).gsub('\\*', '.*')) })]
|
||||
end]
|
||||
|
||||
for name, e in all_expected - all_handled
|
||||
if all_handled_regexps[name].match?(e)
|
||||
if all_handled_regexps[name].match?(e) || e == "*"
|
||||
next
|
||||
end
|
||||
puts "Missing for #{name}: #{e}"
|
||||
|
||||
@@ -18,8 +18,6 @@ def run_vimscript(src)
|
||||
func! Log(msg)
|
||||
if $DEV != '1'
|
||||
echo a:msg
|
||||
else
|
||||
echon '.'
|
||||
endif
|
||||
endfunc
|
||||
EOM
|
||||
|
||||
@@ -2,6 +2,7 @@ function! TestExtension(filetype, filename, content)
|
||||
call Log('Detecting ' . a:filetype . ' filetype (' . a:filename . ')...')
|
||||
|
||||
try
|
||||
set shortmess+=F
|
||||
let g:message = ""
|
||||
exec "noautocmd n " . a:filename
|
||||
silent put =a:content
|
||||
|
||||
Reference in New Issue
Block a user