pytrainer: unpin python 3.10
[NixPkgs.git] / pkgs / applications / editors / vim / plugins / vim-command-check-hook.sh
blob402910fd0cbde99270e7de643218756ba7bc7adf
1 # Setup hook for checking whether a vim command exists
2 echo "Sourcing vim-command-check-hook.sh"
4 vimCommandCheckHook () {
5 echo "Executing vimCommandCheckHook"
7 if [ -n "$vimCommandCheck" ]; then
8 echo "Check whether the following modules can be imported: $vimCommandCheck"
10 # editorconfig-checker-disable
11 export HOME="$TMPDIR"
12 @vimBinary@ -es -n -u NONE -i NONE --clean -V1 --cmd "set rtp+=$out" \
13 --cmd "runtime! plugin/*.vim" <<-EOF
14 if exists(":$vimCommandCheck") == 2
15 cquit 0
16 else
17 cquit 1
19 EOF
23 echo "Using vimCommandCheckHook"
24 appendToVar preDistPhases vimCommandCheckHook