diff options
| author | CH-DanReif <35710107+CH-DanReif@users.noreply.github.com> | 2018-04-30 11:19:20 -0700 | 
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-04-30 11:19:20 -0700 | 
| commit | fb8c5fa8e92a29a1927044ccd18092d185743c80 (patch) | |
| tree | b414ce9a24249bf48d623464e4e166e93ef416a6 | |
| parent | cab6866e21341cab7419cdb4ae1fd18437d31bb0 (diff) | |
| parent | ddc64d8db27064dd295b0a8379fb54aebb68cccb (diff) | |
| download | vim-polyglot-fb8c5fa8e92a29a1927044ccd18092d185743c80.tar.gz vim-polyglot-fb8c5fa8e92a29a1927044ccd18092d185743c80.zip | |
Merge pull request #293 from CH-DanReif/disable_individual_ftdetect
Allow disabling individual ftdetects via `g:polyglot_disabled`
| -rwxr-xr-x | build | 18 | 
1 files changed, 10 insertions, 8 deletions
| @@ -59,14 +59,16 @@ extract() {  	continue      fi -    for f in ${dir}/ftdetect/*; do -      ( -        echo "augroup filetypedetect"; -        echo '" '"$pack"; -        cat "${f}"; -        echo "augroup END"; -        echo -      ) >> tmp/polyglot.vim; +    for f in "${dir}/ftdetect/"*; do +      cat <<EOF >> tmp/polyglot.vim +if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, '${pack%%:*}') == -1 +  augroup filetypedetect +  " ${pack%%:*}, from ${f##*/ftdetect/} in ${pack#*:} +$(cat "${f}") +  augroup end +endif + +EOF      done    done | 
