=== modified file 'vim/bundle/SearchParty/.git/config' (properties changed: -x to +x) === modified file 'vim/bundle/SearchParty/.git/hooks/applypatch-msg.sample' --- vim/bundle/SearchParty/.git/hooks/applypatch-msg.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/hooks/applypatch-msg.sample 2015-02-13 09:59:55 +0000 @@ -10,6 +10,6 @@ # To enable this hook, rename this file to "applypatch-msg". . git-sh-setup -commitmsg="$(git rev-parse --git-path hooks/commit-msg)" -test -x "$commitmsg" && exec "$commitmsg" ${1+"$@"} +test -x "$GIT_DIR/hooks/commit-msg" && + exec "$GIT_DIR/hooks/commit-msg" ${1+"$@"} : === modified file 'vim/bundle/SearchParty/.git/hooks/pre-applypatch.sample' --- vim/bundle/SearchParty/.git/hooks/pre-applypatch.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/hooks/pre-applypatch.sample 2015-02-13 09:59:55 +0000 @@ -9,6 +9,6 @@ # To enable this hook, rename this file to "pre-applypatch". . git-sh-setup -precommit="$(git rev-parse --git-path hooks/pre-commit)" -test -x "$precommit" && exec "$precommit" ${1+"$@"} +test -x "$GIT_DIR/hooks/pre-commit" && + exec "$GIT_DIR/hooks/pre-commit" ${1+"$@"} : === modified file 'vim/bundle/SearchParty/.git/hooks/pre-push.sample' --- vim/bundle/SearchParty/.git/hooks/pre-push.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/hooks/pre-push.sample 2015-02-13 09:59:55 +0000 @@ -24,6 +24,7 @@ z40=0000000000000000000000000000000000000000 +IFS=' ' while read local_ref local_sha remote_ref remote_sha do if [ "$local_sha" = $z40 ] === modified file 'vim/bundle/SearchParty/.git/hooks/update.sample' --- vim/bundle/SearchParty/.git/hooks/update.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/hooks/update.sample 2015-02-13 09:59:55 +0000 @@ -1,6 +1,6 @@ #!/bin/sh # -# An example hook script to block unannotated tags from entering. +# An example hook script to blocks unannotated tags from entering. # Called by "git receive-pack" with arguments: refname sha1-old sha1-new # # To enable this hook, rename this file to "update". === modified file 'vim/bundle/SearchParty/.git/index' Binary files vim/bundle/SearchParty/.git/index 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/index 2015-08-25 11:56:54 +0000 differ === modified file 'vim/bundle/SearchParty/.git/logs/HEAD' --- vim/bundle/SearchParty/.git/logs/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/logs/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 f0d68ee68d8cb6824181e01f3463fd2dd7963e93 Jan Pobrislo 1470298361 +0200 clone: from https://github.com/dahu/SearchParty.git +0000000000000000000000000000000000000000 61aa4f431a29b065238554b37206187febb31967 Jan Pobrislo 1440501775 +0200 clone: from https://github.com/dahu/SearchParty.git === modified file 'vim/bundle/SearchParty/.git/logs/refs/heads/master' --- vim/bundle/SearchParty/.git/logs/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/logs/refs/heads/master 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 f0d68ee68d8cb6824181e01f3463fd2dd7963e93 Jan Pobrislo 1470298361 +0200 clone: from https://github.com/dahu/SearchParty.git +0000000000000000000000000000000000000000 61aa4f431a29b065238554b37206187febb31967 Jan Pobrislo 1440501775 +0200 clone: from https://github.com/dahu/SearchParty.git === modified file 'vim/bundle/SearchParty/.git/logs/refs/remotes/origin/HEAD' --- vim/bundle/SearchParty/.git/logs/refs/remotes/origin/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/logs/refs/remotes/origin/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 f0d68ee68d8cb6824181e01f3463fd2dd7963e93 Jan Pobrislo 1470298361 +0200 clone: from https://github.com/dahu/SearchParty.git +0000000000000000000000000000000000000000 61aa4f431a29b065238554b37206187febb31967 Jan Pobrislo 1440501775 +0200 clone: from https://github.com/dahu/SearchParty.git === added directory 'vim/bundle/SearchParty/.git/objects/04' === added file 'vim/bundle/SearchParty/.git/objects/04/69dd58c1d5e5d3ad646caa3705e187e6b235d8' Binary files vim/bundle/SearchParty/.git/objects/04/69dd58c1d5e5d3ad646caa3705e187e6b235d8 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/04/69dd58c1d5e5d3ad646caa3705e187e6b235d8 2015-08-25 11:56:54 +0000 differ === added directory 'vim/bundle/SearchParty/.git/objects/15' === added file 'vim/bundle/SearchParty/.git/objects/15/2ba0c88ece14f67ab9b1c8f888cb32ca1abd24' Binary files vim/bundle/SearchParty/.git/objects/15/2ba0c88ece14f67ab9b1c8f888cb32ca1abd24 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/15/2ba0c88ece14f67ab9b1c8f888cb32ca1abd24 2015-02-13 09:59:55 +0000 differ === removed file 'vim/bundle/SearchParty/.git/objects/16/8e6f185aa5f180ce5d1157f0ffd4f0aed29b0d' Binary files vim/bundle/SearchParty/.git/objects/16/8e6f185aa5f180ce5d1157f0ffd4f0aed29b0d 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/16/8e6f185aa5f180ce5d1157f0ffd4f0aed29b0d 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/1c' === removed file 'vim/bundle/SearchParty/.git/objects/1c/25234e0c6796c6e26f1b4533b3e50e2d47907f' Binary files vim/bundle/SearchParty/.git/objects/1c/25234e0c6796c6e26f1b4533b3e50e2d47907f 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/1c/25234e0c6796c6e26f1b4533b3e50e2d47907f 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/21' === removed file 'vim/bundle/SearchParty/.git/objects/21/b3cea3812af6e14e462f2a61af10ad6453dbfd' Binary files vim/bundle/SearchParty/.git/objects/21/b3cea3812af6e14e462f2a61af10ad6453dbfd 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/21/b3cea3812af6e14e462f2a61af10ad6453dbfd 1970-01-01 00:00:00 +0000 differ === removed file 'vim/bundle/SearchParty/.git/objects/2a/76ce6bd5adc08e1073a561285605f19b9a140a' Binary files vim/bundle/SearchParty/.git/objects/2a/76ce6bd5adc08e1073a561285605f19b9a140a 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/2a/76ce6bd5adc08e1073a561285605f19b9a140a 1970-01-01 00:00:00 +0000 differ === added file 'vim/bundle/SearchParty/.git/objects/2a/c86beb7c65c049354cec894ae2d5dc9e27004c' Binary files vim/bundle/SearchParty/.git/objects/2a/c86beb7c65c049354cec894ae2d5dc9e27004c 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/2a/c86beb7c65c049354cec894ae2d5dc9e27004c 2015-08-25 11:56:54 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/30' === removed file 'vim/bundle/SearchParty/.git/objects/30/cd69c7b9c0b6957b688f3f18ac0e3833341c11' Binary files vim/bundle/SearchParty/.git/objects/30/cd69c7b9c0b6957b688f3f18ac0e3833341c11 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/30/cd69c7b9c0b6957b688f3f18ac0e3833341c11 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/3b' === removed file 'vim/bundle/SearchParty/.git/objects/3b/701ee11798dc4cc19ea9e2e6c795f3ba4180e4' Binary files vim/bundle/SearchParty/.git/objects/3b/701ee11798dc4cc19ea9e2e6c795f3ba4180e4 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/3b/701ee11798dc4cc19ea9e2e6c795f3ba4180e4 1970-01-01 00:00:00 +0000 differ === added directory 'vim/bundle/SearchParty/.git/objects/46' === added file 'vim/bundle/SearchParty/.git/objects/46/2234af8a4dffd1bc5ad80c1c948fccf4ccd397' Binary files vim/bundle/SearchParty/.git/objects/46/2234af8a4dffd1bc5ad80c1c948fccf4ccd397 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/46/2234af8a4dffd1bc5ad80c1c948fccf4ccd397 2015-02-13 09:59:55 +0000 differ === added file 'vim/bundle/SearchParty/.git/objects/4a/7435407c3fd0f6c3dcff082b32be7e56aa7f26' Binary files vim/bundle/SearchParty/.git/objects/4a/7435407c3fd0f6c3dcff082b32be7e56aa7f26 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/4a/7435407c3fd0f6c3dcff082b32be7e56aa7f26 2015-02-13 09:59:55 +0000 differ === removed file 'vim/bundle/SearchParty/.git/objects/4a/7c9274d0394b0422f1077283d95312f343e14c' --- vim/bundle/SearchParty/.git/objects/4a/7c9274d0394b0422f1077283d95312f343e14c 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/objects/4a/7c9274d0394b0422f1077283d95312f343e14c 1970-01-01 00:00:00 +0000 @@ -1,6 +0,0 @@ -xTMO0_8BС$MAL/>)x)F3{xyPQ,S'NYX_$Q/~ G5x2,_*(x<$ -O 8 1]_LF"]2Uw-:oUUjS'&yYu%M) -A4b B -= -b2m(0iuIH'Hs]Bb@̘llD![L:VQ>u||Y2Lz -WJ1HTqD\eްMǰm) :˳,-Ւ~wqka2tr` \ No newline at end of file === removed directory 'vim/bundle/SearchParty/.git/objects/55' === removed file 'vim/bundle/SearchParty/.git/objects/55/db4a147e81af9b62186cb74c0e43c0e643cc33' Binary files vim/bundle/SearchParty/.git/objects/55/db4a147e81af9b62186cb74c0e43c0e643cc33 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/55/db4a147e81af9b62186cb74c0e43c0e643cc33 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/59' === removed file 'vim/bundle/SearchParty/.git/objects/59/b2745886cd40a97b858856823407bd51cd3e32' Binary files vim/bundle/SearchParty/.git/objects/59/b2745886cd40a97b858856823407bd51cd3e32 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/59/b2745886cd40a97b858856823407bd51cd3e32 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/5e' === removed file 'vim/bundle/SearchParty/.git/objects/5e/82189b93de69d007c261d91d7388664826abcc' Binary files vim/bundle/SearchParty/.git/objects/5e/82189b93de69d007c261d91d7388664826abcc 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/5e/82189b93de69d007c261d91d7388664826abcc 1970-01-01 00:00:00 +0000 differ === removed file 'vim/bundle/SearchParty/.git/objects/5e/aba0def5f16302875feb890b3294071367f1fe' Binary files vim/bundle/SearchParty/.git/objects/5e/aba0def5f16302875feb890b3294071367f1fe 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/5e/aba0def5f16302875feb890b3294071367f1fe 1970-01-01 00:00:00 +0000 differ === added directory 'vim/bundle/SearchParty/.git/objects/61' === added file 'vim/bundle/SearchParty/.git/objects/61/aa4f431a29b065238554b37206187febb31967' --- vim/bundle/SearchParty/.git/objects/61/aa4f431a29b065238554b37206187febb31967 1970-01-01 00:00:00 +0000 +++ vim/bundle/SearchParty/.git/objects/61/aa4f431a29b065238554b37206187febb31967 2015-08-25 11:56:54 +0000 @@ -0,0 +1,1 @@ +xMJ1]%;D x2?c:x{ W_U:ceMD#S"JViU蓊3[]1Rtpש FXwAw"Tzx5>Xst`DF*;Uý k\=cuϗǩ B+!RwZ}P\iL;m΀HK{~=L֦} e\Co.[ QnY \ No newline at end of file === removed directory 'vim/bundle/SearchParty/.git/objects/6e' === removed file 'vim/bundle/SearchParty/.git/objects/6e/ff6095ac4f2f4b5a050838eaadd3a77e3ba775' Binary files vim/bundle/SearchParty/.git/objects/6e/ff6095ac4f2f4b5a050838eaadd3a77e3ba775 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/6e/ff6095ac4f2f4b5a050838eaadd3a77e3ba775 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/79' === removed file 'vim/bundle/SearchParty/.git/objects/79/00985e752f3299a577db8b3b53931c3b03de80' --- vim/bundle/SearchParty/.git/objects/79/00985e752f3299a577db8b3b53931c3b03de80 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/objects/79/00985e752f3299a577db8b3b53931c3b03de80 1970-01-01 00:00:00 +0000 @@ -1,2 +0,0 @@ -xQk08 -Mײ=ACJ)l{1uw B$&_K"."xFWptXzjAYu"{3N27y`x2jƘPʘ(@[u,"%bk-D$oK|` ӌ= >;!D!mMM"ט揶E!h0BM <M62vPy&%3>ӉЇ!N;fE'.Z.C~I$;]Ajwc z2ZEeI5FuNI?SiTh \ No newline at end of file === added directory 'vim/bundle/SearchParty/.git/objects/82' === added file 'vim/bundle/SearchParty/.git/objects/82/faec3c27750e6d6c8714af186959d466623565' Binary files vim/bundle/SearchParty/.git/objects/82/faec3c27750e6d6c8714af186959d466623565 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/82/faec3c27750e6d6c8714af186959d466623565 2015-08-25 11:56:54 +0000 differ === added directory 'vim/bundle/SearchParty/.git/objects/90' === added file 'vim/bundle/SearchParty/.git/objects/90/a0ac269de856d3fa169236b12fefd01f57fa21' Binary files vim/bundle/SearchParty/.git/objects/90/a0ac269de856d3fa169236b12fefd01f57fa21 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/90/a0ac269de856d3fa169236b12fefd01f57fa21 2015-02-13 09:59:55 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/91' === removed file 'vim/bundle/SearchParty/.git/objects/91/c34e685a960525b87fb9a54482f6092435782c' Binary files vim/bundle/SearchParty/.git/objects/91/c34e685a960525b87fb9a54482f6092435782c 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/91/c34e685a960525b87fb9a54482f6092435782c 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/96' === removed file 'vim/bundle/SearchParty/.git/objects/96/f895b95f4234c82a343b71e3c6e3c3ac998fde' Binary files vim/bundle/SearchParty/.git/objects/96/f895b95f4234c82a343b71e3c6e3c3ac998fde 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/96/f895b95f4234c82a343b71e3c6e3c3ac998fde 1970-01-01 00:00:00 +0000 differ === removed file 'vim/bundle/SearchParty/.git/objects/a0/384c05e5965cc725f44ab380ec6c0623299969' Binary files vim/bundle/SearchParty/.git/objects/a0/384c05e5965cc725f44ab380ec6c0623299969 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/a0/384c05e5965cc725f44ab380ec6c0623299969 1970-01-01 00:00:00 +0000 differ === added file 'vim/bundle/SearchParty/.git/objects/a0/62e92d3cd3e14ae061198f5db4cc3092f82210' Binary files vim/bundle/SearchParty/.git/objects/a0/62e92d3cd3e14ae061198f5db4cc3092f82210 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/a0/62e92d3cd3e14ae061198f5db4cc3092f82210 2015-08-25 11:56:54 +0000 differ === added file 'vim/bundle/SearchParty/.git/objects/a0/bc246f528f783fb0e593738c00bb4a25ec8484' Binary files vim/bundle/SearchParty/.git/objects/a0/bc246f528f783fb0e593738c00bb4a25ec8484 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/a0/bc246f528f783fb0e593738c00bb4a25ec8484 2015-02-13 09:59:55 +0000 differ === added directory 'vim/bundle/SearchParty/.git/objects/a9' === added file 'vim/bundle/SearchParty/.git/objects/a9/2484251c55bf8c3dc84e5ab11488b18625a1d7' Binary files vim/bundle/SearchParty/.git/objects/a9/2484251c55bf8c3dc84e5ab11488b18625a1d7 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/a9/2484251c55bf8c3dc84e5ab11488b18625a1d7 2015-08-25 11:56:54 +0000 differ === added file 'vim/bundle/SearchParty/.git/objects/ab/83cea3f7bfc86ce0f7bf77425266a8dde0d24c' Binary files vim/bundle/SearchParty/.git/objects/ab/83cea3f7bfc86ce0f7bf77425266a8dde0d24c 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/ab/83cea3f7bfc86ce0f7bf77425266a8dde0d24c 2015-02-13 09:59:55 +0000 differ === removed file 'vim/bundle/SearchParty/.git/objects/ab/ea45ae04958f7680ec114e4c2c834eb8f31a45' --- vim/bundle/SearchParty/.git/objects/ab/ea45ae04958f7680ec114e4c2c834eb8f31a45 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/objects/ab/ea45ae04958f7680ec114e4c2c834eb8f31a45 1970-01-01 00:00:00 +0000 @@ -1,3 +0,0 @@ -xuQK0}ί8dB(`IEqC^B6) -r{.tml[^78{;b 'g4 -yDaᇦClJ nl+f֩6˕6#ӌAk) MQ|;Ma|偢=Ik"g_]K`1o 8W硎c_xmY \ No newline at end of file === removed directory 'vim/bundle/SearchParty/.git/objects/ae' === removed file 'vim/bundle/SearchParty/.git/objects/ae/bd87c046ef2aae73ecb0d7457bc74fda832bba' --- vim/bundle/SearchParty/.git/objects/ae/bd87c046ef2aae73ecb0d7457bc74fda832bba 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/objects/ae/bd87c046ef2aae73ecb0d7457bc74fda832bba 1970-01-01 00:00:00 +0000 @@ -1,1 +0,0 @@ -x+)JMU01f040031QNM,JH,*+eQUIvQ| \ No newline at end of file === removed directory 'vim/bundle/SearchParty/.git/objects/b2' === removed file 'vim/bundle/SearchParty/.git/objects/b2/ca851ebbf4162a90f443cdb3c7af2799646aba' Binary files vim/bundle/SearchParty/.git/objects/b2/ca851ebbf4162a90f443cdb3c7af2799646aba 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/b2/ca851ebbf4162a90f443cdb3c7af2799646aba 1970-01-01 00:00:00 +0000 differ === removed file 'vim/bundle/SearchParty/.git/objects/c6/0bfcb2bfb83bcd6c49503f9c27173fa4989f1c' Binary files vim/bundle/SearchParty/.git/objects/c6/0bfcb2bfb83bcd6c49503f9c27173fa4989f1c 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/c6/0bfcb2bfb83bcd6c49503f9c27173fa4989f1c 1970-01-01 00:00:00 +0000 differ === added file 'vim/bundle/SearchParty/.git/objects/c6/37fc2888a895603675ded9ac22ed12174274fe' Binary files vim/bundle/SearchParty/.git/objects/c6/37fc2888a895603675ded9ac22ed12174274fe 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/c6/37fc2888a895603675ded9ac22ed12174274fe 2015-02-13 09:59:55 +0000 differ === added directory 'vim/bundle/SearchParty/.git/objects/c9' === added file 'vim/bundle/SearchParty/.git/objects/c9/8e49ffe5a328e473cbf3d26580723981e4519c' Binary files vim/bundle/SearchParty/.git/objects/c9/8e49ffe5a328e473cbf3d26580723981e4519c 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/c9/8e49ffe5a328e473cbf3d26580723981e4519c 2015-08-25 11:56:54 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/ce' === removed file 'vim/bundle/SearchParty/.git/objects/ce/ca8db3422fa5f9435b25a7040900edda28e3d3' Binary files vim/bundle/SearchParty/.git/objects/ce/ca8db3422fa5f9435b25a7040900edda28e3d3 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/ce/ca8db3422fa5f9435b25a7040900edda28e3d3 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/e1' === removed file 'vim/bundle/SearchParty/.git/objects/e1/81ae75632792235f2476e3961098aefbeba2e7' Binary files vim/bundle/SearchParty/.git/objects/e1/81ae75632792235f2476e3961098aefbeba2e7 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/e1/81ae75632792235f2476e3961098aefbeba2e7 1970-01-01 00:00:00 +0000 differ === added directory 'vim/bundle/SearchParty/.git/objects/e8' === added file 'vim/bundle/SearchParty/.git/objects/e8/b39b99c36a95d89dd2fa7fdeb1a9117623464a' Binary files vim/bundle/SearchParty/.git/objects/e8/b39b99c36a95d89dd2fa7fdeb1a9117623464a 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/.git/objects/e8/b39b99c36a95d89dd2fa7fdeb1a9117623464a 2015-08-25 11:56:54 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/f0' === removed file 'vim/bundle/SearchParty/.git/objects/f0/d68ee68d8cb6824181e01f3463fd2dd7963e93' Binary files vim/bundle/SearchParty/.git/objects/f0/d68ee68d8cb6824181e01f3463fd2dd7963e93 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/f0/d68ee68d8cb6824181e01f3463fd2dd7963e93 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/SearchParty/.git/objects/f2' === removed file 'vim/bundle/SearchParty/.git/objects/f2/109df017f62e640b49dfa0b6bec6dc06b37279' Binary files vim/bundle/SearchParty/.git/objects/f2/109df017f62e640b49dfa0b6bec6dc06b37279 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/f2/109df017f62e640b49dfa0b6bec6dc06b37279 1970-01-01 00:00:00 +0000 differ === removed file 'vim/bundle/SearchParty/.git/objects/f2/69e8450953c6bdcbe4e81463666f96313dd615' --- vim/bundle/SearchParty/.git/objects/f2/69e8450953c6bdcbe4e81463666f96313dd615 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/objects/f2/69e8450953c6bdcbe4e81463666f96313dd615 1970-01-01 00:00:00 +0000 @@ -1,3 +0,0 @@ -x}N0E -KDy6 ,1T4(';/['7&M7TUuԃz9'׽^ߊUNšÙS/kۋ-'xɮ9;hr]>'f7xwo9K̺^X(f\X %,rM5rm2 -Gm#Q KRk2x{D5'䞔6Q.74ɍzp%MnTimm`EE4h(V7aE?BX|Mǯa3ZN٢9-Wi3[T4:3Q̜[`F9( \ No newline at end of file === removed directory 'vim/bundle/SearchParty/.git/objects/f5' === removed file 'vim/bundle/SearchParty/.git/objects/f5/fa37b568d4c4e282a65c6a36020cea0b71fd49' --- vim/bundle/SearchParty/.git/objects/f5/fa37b568d4c4e282a65c6a36020cea0b71fd49 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/objects/f5/fa37b568d4c4e282a65c6a36020cea0b71fd49 1970-01-01 00:00:00 +0000 @@ -1,1 +0,0 @@ -x_K0}| },a`{kiiۻ-MY( ߽tG͎GO7hbySbRK3Pdo+xAPEfH1]TM[AXYV عWQM>p ?bHU}Z_ѥIKVo 'VC.3{Y\Q}r6'ΏEA;H=E̹eߟ2 3A}t"ldH"MhN7 {mg/Rr8ݤ`8QS%;ճ *sˈ=}ZAqLdd8 (lHa J Z۵ZNc / \ No newline at end of file === removed directory 'vim/bundle/SearchParty/.git/objects/f8' === removed file 'vim/bundle/SearchParty/.git/objects/f8/88c4d659b50a0e6afea88a7892005820c2a9d2' Binary files vim/bundle/SearchParty/.git/objects/f8/88c4d659b50a0e6afea88a7892005820c2a9d2 2016-08-04 08:15:09 +0000 and vim/bundle/SearchParty/.git/objects/f8/88c4d659b50a0e6afea88a7892005820c2a9d2 1970-01-01 00:00:00 +0000 differ === modified file 'vim/bundle/SearchParty/.git/packed-refs' --- vim/bundle/SearchParty/.git/packed-refs 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/packed-refs 2015-08-25 11:56:54 +0000 @@ -1,2 +1,2 @@ # pack-refs with: peeled fully-peeled -f0d68ee68d8cb6824181e01f3463fd2dd7963e93 refs/remotes/origin/master +61aa4f431a29b065238554b37206187febb31967 refs/remotes/origin/master === modified file 'vim/bundle/SearchParty/.git/refs/heads/master' --- vim/bundle/SearchParty/.git/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/refs/heads/master 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -f0d68ee68d8cb6824181e01f3463fd2dd7963e93 +61aa4f431a29b065238554b37206187febb31967 === modified file 'vim/bundle/SearchParty/.git/shallow' --- vim/bundle/SearchParty/.git/shallow 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.git/shallow 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -f0d68ee68d8cb6824181e01f3463fd2dd7963e93 +61aa4f431a29b065238554b37206187febb31967 === removed file 'vim/bundle/SearchParty/.gitignore' --- vim/bundle/SearchParty/.gitignore 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/.gitignore 1970-01-01 00:00:00 +0000 @@ -1,5 +0,0 @@ -tags -doc/tags -test/*.msgout -test/*.tap -searchparty_user_maps.vim === modified file 'vim/bundle/SearchParty/README.asciidoc' --- vim/bundle/SearchParty/README.asciidoc 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/README.asciidoc 2015-08-25 11:56:54 +0000 @@ -1,4 +1,5 @@ -== SearchParty +SearchParty +----------- _Enhanced searches, highlights and matches for Vim_ @@ -6,59 +7,15 @@ https://www.gittip.com/bairuidahu/[tips] or http://of-vim-and-vigor.blogspot.com/[beverages]. -== Version 0.7 - -__July 2016__ - -* Search Party maps are now defined in `searchparty_user_maps.vim`, the - loading of which is controlled by `g:searchparty_load_user_maps`. -* Added a new option, `g:searchparty_visual_find_sets_search`: -** 0 (default) -- A visual find operation (`* / #`) will - not set the search register (`@/`). -** 1 -- A visual find operation will set the search register, staying in - visual mode. -** 2 -- A visual find operation will set the search register, returning - to normal mode. -* Removed the experimental SearchHighlightReplace functionality. -* Added some tests. - -== SearchParty Features - -=== User Maps - -Search Party provides 18 user-maps and shadows the following eight -built-in normal-mode commands: - - / ? * # g* g# n N - -The shadowed commands have been designed to play nice with -https://github.com/henrik/vim-indexed-search[vim-indexed-search] and -https://github.com/osyo-manga/vim-anzu[vim-anzu]. - -The 18 user-maps have default keys as specified in the -`searchparty_default_maps.vim` file. - -If a corresponding `searchparty_user_maps.vim` exists, then all of the -mappings within it will be loaded unless the target has already been -mapped to another key sequence (possibly in your +~/.vimrc+). - -If `searchparty_user_maps.vim` doesn't exist, it is created as a copy of -`searchparty_default_maps.vim`. - -Customise `searchparty_user_maps.vim` to your needs. - -To completely disable the default user-maps processing, add this line -to your +~/.vimrc+: - - let g:searchparty_load_user_maps = 0 - -=== AfterSearch Event +AfterSearch Event +~~~~~~~~~~~~~~~~~ Functions matching the pattern `/AfterSearch_[0-9]/` will be called in numeric order after a search operation: `/` `?` `n` `N` `*` `#` `g*` `g#`. -=== Visual Searches +Visual Searches +~~~~~~~~~~~~~~~ * +*+ Searches for the next occurrence of the currently selected visual text. +SearchPartyVisualFindNext+ @@ -69,36 +26,8 @@ * +&+ Starts a +:substitute+ using the currently selected visual text. +SearchPartyVisualFindSubstitute+ -* +g&+ Repeats the most recent change within the current visual selection. - +SearchPartyVisualChangeAll+ - -* +gg&+ Just like `g&` but don't put `\<` and `\>` around the word. - +SearchPartyVisualChangeAllBare+ - -NOTE: The visual mode `g&` map replaces all occurrences of `"-` with `".` -within the current visual selection. The `gg&` version does not wrap the -search term ( `"-` ) within `\<` and `\>` and so occurrences of the word -within other words will also be changed. This is similar to the behaviour of -the existing `*` vs `g*` in Vim. - -The option `g:searchparty_visual_find_sets_search` controls whether the -`SearchPartyVisualFindNext` and `SearchPartyVisualFindPrev` -commands update the current search pattern (`@/`) and whether visual -mode is retained or not. The default value is `0`. The allowed values are: - -[cols="1,2",width="55%",options="header"] -|==== -|Value | Effects -| 0 | Don't set `@/`. Stay in visual mode. (default) -| 1 | Set `@/`. Stay in visual mode. -| 2 | Set `@/`. Leave visual mode. -|==== - -To alter this option, add a line like this to your `~/.vimrc`: - - let searchparty_visual_find_sets_search = 1 - -=== Literal Search +Literal Search +~~~~~~~~~~~~~~ * +/+ Prompts for a literal string to search for. This does NOT use a regular expression, so the characters you type @@ -107,14 +36,16 @@ literal search history. +SearchPartyFindLiteral+ -=== Ranged Search +Ranged Search +~~~~~~~~~~~~~ 7,12 RSearch foo Searches for "foo" only within the range from lines 7 through 12, both inclusive. The default range is % (the whole buffer). -=== Multiple Replacements +Multiple Replacements +~~~~~~~~~~~~~~~~~~~~~ * +mp+ Prompts for a Search Term and then prompts for Replacement Terms (space separated). The current line is @@ -122,7 +53,24 @@ minus one, and the Search Term is then replaced on each line with each successive Replacement. -=== Search Highlighting +Search Highlight Replace +~~~~~~~~~~~~~~~~~~~~~~~~ + +* +mar+ Prompts for a Search Term and a Replace Term and + whether you want to use global replacement. The + currently highlighted search terms will then have + Search Term replaced with Replace Term. This map works + in normal mode on the current line and in visual mode + on the range given. There is a corresponding command: ++ + :[range] SearchHighlightReplace + +NOTE: This feature is experimental and may not work properly or may +have adverse side effects. Please contact the plugin developer if you +experience any grief with this feature. + +Search Highlighting +~~~~~~~~~~~~~~~~~~~ * ++ Temporarily clears search highlight. +SearchPartyHighlightClear+ @@ -141,7 +89,8 @@ * +g*+ Highlights all occurrences of +WORD+ under the cursor. +SearchPartyHighlightWORD+ -=== Highlighting Print Command +Highlighting Print Command +~~~~~~~~~~~~~~~~~~~~~~~~~~ E.g.: @@ -150,14 +99,16 @@ Will show the matching lines with all occurrences of `something` on those lines highlighted. -=== Set Search +Set Search +~~~~~~~~~~ * +ms+ Prompts for a pattern and sets the current search to that pattern without moving the cursor to the next match of that pattern. +SearchPartySetSearch+ -=== Matches +Matches +~~~~~~~ * +mm+ Prompts for a pattern and uses +matchadd()+ to highlight all occurrences of that pattern in the current window. @@ -174,19 +125,14 @@ + NOTE: Do this after you have set your colorscheme. -* +md+ Shows the list of existing matches and prompts for a number - or pattern to clear. If a number is given, the corresponding - match is cleared. If a pattern is given, all matching matches - will be cleared. - +SearchPartyDeleteMatch+ - The following functions and commands are available for Search Party matches: -* +SearchPartyMatchDelete(item)+ - clear match by number or pattern +* +SearchPartyMatchDelete(number)+ - clear match by number * +SearchPartyMatchList+ - list all match patterns * +SearchPartyMatchNumber(number)+ - reset match number (+1-6+) -=== M.A.S.H. +M.A.S.H. +~~~~~~~~ Mash is a motion activated (lol - er, I mean, when you press ++n/N/\#/\*/g#/g*++) current search match highlighter. Breaking that down for you, it highlights @@ -194,9 +140,5 @@ :set hlsearch activated). If you don't use hlsearch, then it will still highlight the current match. -=== Cooperation - -SearchParty plays nice with: - -* https://github.com/henrik/vim-indexed-search[vim-indexed-search] -* https://github.com/osyo-manga/vim-anzu[vim-anzu] +SearchParty's MASH now plays nice with +https://github.com/henrik/vim-indexed-search[vim-indexed-search] === modified file 'vim/bundle/SearchParty/autoload/searchparty/arbitrary_matches.vim' --- vim/bundle/SearchParty/autoload/searchparty/arbitrary_matches.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/autoload/searchparty/arbitrary_matches.vim 2015-02-13 09:59:55 +0000 @@ -47,31 +47,16 @@ if empty(num) return endif - if num =~ '^\d\+$' - let num -= 1 - endif - endif - if num =~ '^\d\+$' - if get(s:matches, num, 0) != 0 - call matchdelete(s:matches[num]) - let s:matches[num] = 0 - endif - else - let matches = map(filter(searchparty#arbitrary_matches#getmatches(), 'v:val[1] =~ "' . escape(num, '"\\') . '"'), 'matchstr(v:val[0], "\\d$")') - for n in matches - let num = n - 1 - call matchdelete(s:matches[num]) - let s:matches[num] = 0 - endfor - endif -endfunction - -function! searchparty#arbitrary_matches#getmatches() - return map(filter(getmatches(), 'v:val["group"] =~ "SPM"'), '[v:val["group"], v:val["pattern"]]') + let num -= 1 + endif + if get(s:matches, num, 0) != 0 + call matchdelete(s:matches[num]) + let s:matches[num] = 0 + endif endfunction function! searchparty#arbitrary_matches#match_list(...) - let matches = map(searchparty#arbitrary_matches#getmatches(), '[v:val[0], substitute(v:val[0], "SPM", "Search Party Match #", "") . " = " . v:val[1]]') + let matches = map(filter(getmatches(), 'v:val["group"] =~ "SPM"'), '[v:val["group"], substitute(v:val["group"], "SPM", "Search Party Match #", "") . " = " . v:val["pattern"]]') for match in matches exe "echohl " . match[0] echo match[1] === modified file 'vim/bundle/SearchParty/autoload/searchparty/mash.vim' --- vim/bundle/SearchParty/autoload/searchparty/mash.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/autoload/searchparty/mash.vim 2015-08-25 11:56:54 +0000 @@ -14,7 +14,6 @@ function! searchparty#mash#mash() call searchparty#mash#init() call searchparty#mash#unmash() - let b:mash_state = 1 let b:searching = 1 if exists('b:mash_use_fow') && b:mash_use_fow let b:mash_fow_item = matchadd('MashFOW', '.*', 1) @@ -25,25 +24,12 @@ if exists(':ShowSearchIndex') ShowSearchIndex endif - if exists(':AnzuUpdateSearchStatus') - AnzuUpdateSearchStatus - endif endfunction function! searchparty#mash#unmash() - let b:mash_state = 0 try call matchdelete(b:mash_search_item) call matchdelete(b:mash_fow_item) catch /^Vim\%((\a\+)\)\=:E/ endtry endfunction - -function! searchparty#mash#toggle() - if ! &hlsearch - call searchparty#mash#mash() - else - call searchparty#mash#unmash() - endif - return b:mash_state -endfunction === modified file 'vim/bundle/SearchParty/autoload/searchparty/search_highlights.vim' --- vim/bundle/SearchParty/autoload/searchparty/search_highlights.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/autoload/searchparty/search_highlights.vim 2015-02-13 09:59:55 +0000 @@ -6,13 +6,12 @@ au! augroup END augroup! SearchPartyTAHW - call feedkeys("\SearchPartyHighlightClear") - else - augroup SearchPartyTAHW - au! CursorHold * call feedkeys("\SearchPartyHighlightWord") - augroup END - endif -endfunction + else + augroup SearchPartyTAHW + au! CursorHold * call feedkeys("\SearchPartyHighlightWord") + augroup END + endif + endfunction " PrintWithHighlighting @@ -47,3 +46,58 @@ echon line . "\n" endfor endfunction + + +" Replace Within SearchHighlights + +function! searchparty#search_highlights#replace() range + let save_wrapscan = &ws + let save_gdefault = &gd + set nows + set nogd + let mtch = @/ + let srch = input('Search: /') + let repl = input('Replace: /') + let glbl = input('All? [gy]==yes ') =~# '[yg]' ? 'g' : '' + + if srch == '' + let srch = mtch + endif + + " mark the matches + exe 'normal! ' . a:firstline . 'gg0' + let counter = Series(0, 1, '%03d') + let found = search(mtch, 'cW') + while found && (found <= a:lastline) + let c = counter.next() + exe "normal! iSHR>_" . c . "\x02\" + call search(mtch, 'ceW') + exe "normal! a\x02SHR<_" . c . "\" + let found = search(mtch, 'cW') + endwhile + + " sweep the marks + exe 'normal! ' . a:firstline . 'gg0' + let counter = Series(0, 1, '%03d') + let c = counter.next() + let found = search("SHR>_" . c . "\x02.", 'ceW') + while found + try + silent! exe 'normal! v/' . mtch . '\ze.SHR<_' . c . "/e\l\" + catch /^Vim\%((\a\+)\)\=:E385/ + break + endtry + exe 'silent! s/\m\%V' . srch . '\m\%V/' . repl . '/e' . glbl + call histdel('/', -1) + let c = counter.next() + let found = search("SHR>_" . c . "\x02.", 'ceW') + endwhile + + " remove marks + silent! exe a:firstline . ',' . a:lastline . 's/SHR>_\d\{3}.//ge' + silent! exe a:firstline . ',' . a:lastline . 's/.SHR<_\d\{3}//ge' + + let &ws = save_wrapscan + let &gd = save_gdefault + let @/ = mtch +endfunction === modified file 'vim/bundle/SearchParty/autoload/searchparty/visual.vim' --- vim/bundle/SearchParty/autoload/searchparty/visual.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/autoload/searchparty/visual.vim 2015-02-13 09:59:55 +0000 @@ -13,12 +13,7 @@ let old_sc = &smartcase set nosmartcase if search(term, flags) - if g:searchparty_visual_find_sets_search - let @/ = term - endif - if g:searchparty_visual_find_sets_search <= 1 - silent! exe 'normal! ' . visualmode() . '/' . term . "/e\" - endif + silent! exe 'normal! ' . visualmode() . '/' . term . "/e\" endif let &sc = old_sc endfunction === modified file 'vim/bundle/SearchParty/doc/SearchParty.txt' --- vim/bundle/SearchParty/doc/SearchParty.txt 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/doc/SearchParty.txt 2015-02-13 09:59:55 +0000 @@ -21,18 +21,12 @@ ============================================================================== 2. USAGE *SearchParty-usage* - *SearchParty-user-maps* -User maps are defined in `searchparty_user_maps.vim` which is automatically -generated from `searchparty_default_maps.vim` if the corresponding `user` maps -file doesn't exist. The loading of this file is controlled by the boolean -`g:searchparty_load_user_maps` option. Whether the user-maps file is loaded or -not, all of the default maps shown below can be overridden using the +Note: All of the default maps shown below can be overridden using the maps given. - *SearchParty-visual-searches* Visual Searches~ -SearchParty provides three |visual-mode| search tools: +SearchParty provides three visual mode search tools: * Searches for the next occurrence of the currently selected visual text. SearchPartyVisualFindNext @@ -43,27 +37,6 @@ & Starts a |:substitute| using the currently selected visual text. SearchPartyVisualFindSubstitute - The `g:searchparty_visual_find_sets_search` option: - * 0 (default) -- A visual find operation (`* / #`) will - not set the search register (|@/|). - * 1 -- A visual find operation will set the search register, staying in - visual mode. - * 2 -- A visual find operation will set the search register, returning - to normal mode. - - g& Repeats the most recent change within the current visual selection. - SearchPartyVisualChangeAll - - gg& Just like `g&` but don't put `\<` and `\>` around the word. - +SearchPartyVisualChangeAllBare+ - -NOTE: The visual mode `g&` map replaces all occurrences of |"-| with |".| -within the current visual selection. The `gg&` version does not wrap the -search term ( |"-| ) within |\<| and |\>| and so occurrences of the word -within other words will also be changed. This is similar to the behaviour of -the existing |*| vs |g*| in Vim. - - *SearchParty-literal-searches* Literal Search~ SearchParty provides a normal mode literal text (without regular expression @@ -75,7 +48,6 @@ || key scrolls through prior literal search history. SearchPartyFindLiteral - *SearchParty-ranged-searches* Ranged Search~ E.g.: @@ -85,7 +57,6 @@ Searches for "foo" only within the range from lines 7 through 12, both inclusive. The default range is % (the whole buffer). - *SearchParty-multiple-replacements* Multiple Replacements~ mp Prompts for a Search Term and then prompts for @@ -94,7 +65,12 @@ minus one, and the Search Term is then replaced on each line with each successive Replacement. - *SearchParty-search-highlighting* + mar Prompts for a Search Term and a Replace Term and whether + you want to use global replacement. The currently + highlighted search terms will then have Search Term + replaced with Replace Term. This command honours a given + range. + Search Highlighting~ SearchParty provides the following normal mode search highlight tools: @@ -122,7 +98,6 @@ SearchPartyHighlightVisual - *SearchParty-print-highlighting* Highlighting Print Command~ SearchParty provides a command, :P, which highlights the current search term @@ -140,14 +115,12 @@ Will show lines 10 through 20, highlighting all occurrences of the current search pattern. - *SearchParty-set-search* Set Search~ ms Prompts for a pattern and sets the current search to that pattern without moving the cursor to the next match of that pattern. SearchPartySetSearch - *SearchParty-matches* Matches~ mm Prompts for a pattern and uses |matchadd()| to highlight all @@ -166,18 +139,11 @@ < NOTE: Do this after you have set your colorscheme. - - md Shows the list of existing matches and prompts for a number - or pattern to clear. If a number is given, the corresponding - match is cleared. If a pattern is given, all matching matches - will be cleared. - - - *SearchPartyMatchDelete* *SearchPartyMatchList* - *SearchPartyMatchNumber* + *SearchPartyMatchDelete* *SearchPartyMatchList* + *SearchPartyMatchNumber* The following functions and commands are available for Search Party matches: - * SearchPartyMatchDelete(item) - clear by number or pattern + * SearchPartyMatchDelete(number) - clear match by number * SearchPartyMatchList - list all match patterns * SearchPartyMatchNumber(number) - reset match number (1-6) === modified file 'vim/bundle/SearchParty/plugin/SearchParty.vim' --- vim/bundle/SearchParty/plugin/SearchParty.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/plugin/SearchParty.vim 2015-08-25 11:56:54 +0000 @@ -2,9 +2,11 @@ " Extended search tools for Vim " Maintainers: Barry Arthur " Israel Chauca F. -" Version: 0.7 +" Version: 0.6 " Description: Commands and maps for extended searches in Vim +" Last Change: 2014-09-30 " License: Vim License (see :help license) +" Location: plugin/SearchParty.vim " Website: https://github.com/dahu/SearchParty " " See SearchParty.txt for help. This can be accessed by doing: @@ -12,7 +14,7 @@ " :helptags ~/.vim/doc " :help SearchParty """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" -let s:SearchParty_version = '0.7' " Allow custom user maps +let s:SearchParty_version = '0.6' " play nice with vim-indexed-search " Vimscript Setup: {{{1 " Allow use of line continuation. @@ -29,120 +31,40 @@ " finish "endif let g:loaded_SearchParty = 1 -let s:plugin_root = expand(':p:h:h') - -" Global Options: {{{1 - -if !exists('g:searchparty_visual_find_sets_search') - let g:searchparty_visual_find_sets_search = 0 -endif - -if !exists('g:searchparty_load_user_maps') - let g:searchparty_load_user_maps = 1 -endif - -" Load User Maps: {{{1 - -function! s:Carp(msg) - echohl WarningMsg - echomsg a:msg - echohl None - return 0 -endfunction - -function! SPLoadUserMaps() - if ! g:searchparty_load_user_maps - return - endif - let sp_default_maps_file = s:plugin_root . '/searchparty_default_maps.vim' - let sp_user_maps_file = s:plugin_root . '/searchparty_user_maps.vim' - if ! filereadable(sp_user_maps_file) - if ! filereadable(sp_default_maps_file) - return s:Carp('SPLoadUserMaps: Cannot find default maps file (' . sp_default_maps_file .')') - endif - if writefile(readfile(sp_default_maps_file), sp_user_maps_file) == -1 - return s:Carp('SPLoadUserMaps: Cannot copy default maps to user maps file (' . sp_user_maps_file .')') - endif - endif - - for line in readfile(sp_user_maps_file) - if line =~ '^\s*\(".*\)\?$' - continue - endif - if line !~ '^\s*.\(nore\)\?map' - call s:Carp('SPLoadUserMaps: Not a map command! (' . line . ')') - continue - endif - let lhs = matchstr(line, '\c\s*\(\)\?\s*\zs\S\+') - let plug = matchstr(line, '\c\S\+') - let mode = matchstr(line, '^\s*\zs.') - let existing = maparg(lhs, mode) - if existing != '' - call s:Carp('SPLoadUserMaps: Mapping ' . lhs . ' already mapped to ' . existing) - continue - endif - if !hasmapto(plug, mode) - exe line - endif - endfor -endfunction - -" Autocommands: {{{1 - -augroup SearchPartySearching - au! - au VimEnter * call SPInitialiseSearchMaps() - au BufEnter * let b:searching = 0 - au CursorHold * call SPAfterSearch() -augroup END - -function! SPInitialiseSearchMaps() - let rhs = ':call searchparty#mash#unmash()let b:searching=1' - if exists(':ShowSearchIndex') - let ssi = 'ShowSearchIndex' - else - let ssi = '' - endif - exe 'nnoremap SearchPartySearchFwd ' . rhs . ssi . '/' - exe 'nnoremap SearchPartySearchBkwd ' . rhs . ssi . '?' - nmap / SearchPartySearchFwd - nmap ? SearchPartySearchBkwd - call SPLoadUserMaps() -endfunction - - -" After Search Callbacks: {{{1 - -function! SPAfterSearch() - if exists('b:searching') && b:searching - call searchparty#mash#mash() - for x in range(10) - if exists('*AfterSearch_' . x) - call call('AfterSearch_' . x, []) - endif - endfor - endif - let b:searching = 0 -endfunction - -" Plug Maps: {{{1 - -" Literal Search: {{{2 + + +" Literal Search {{{1 nnoremap SearchPartyFindLiteralFwd \ :call searchparty#literal_search#find_literal(1) +if !hasmapto('SearchPartyFindLiteralFwd') + nmap / SearchPartyFindLiteralFwd +endif + nnoremap SearchPartyFindLiteralBkwd \ :call searchparty#literal_search#find_literal(0) -" SearchParty Arbitrary Matches: {{{2 +if !hasmapto('SearchPartyFindLiteralBkwd') + nmap ? SearchPartyFindLiteralBkwd +endif + +" SearchParty Arbitrary Matches {{{1 nnoremap SearchPartySetMatch \ :call searchparty#arbitrary_matches#match() +if !hasmapto('SearchPartySetMatch') + nmap mm SearchPartySetMatch +endif + nnoremap SearchPartyDeleteMatch \ :call searchparty#arbitrary_matches#match_delete() +if !hasmapto('SearchPartyDeleteMatch') + nmap md SearchPartyDeleteMatch +endif + command! -bar -nargs=0 SearchPartyMatchList \ call searchparty#arbitrary_matches#match_list() @@ -152,7 +74,7 @@ command! -bar -nargs=1 SearchPartyMatchNumber \ call searchparty#arbitrary_matches#match_number() -" MASH Movement Activated Search Highlight: {{{2 +" M.A.S.H {{{1 hi MashFOW ctermfg=black ctermbg=NONE guifg=black guibg=NONE @@ -170,82 +92,169 @@ endif endfor +function! SPAfterSearch() + if exists('b:searching') && b:searching + for x in range(10) + if exists('*AfterSearch_' . x) + call call('AfterSearch_' . x, []) + endif + endfor + endif + let b:searching = 0 +endfunction + +augroup SearchPartySearching + au! + au VimEnter * call SPInitialiseSearchMaps() + au BufEnter * let b:searching = 0 + au CursorHold * call SPAfterSearch() +augroup END + +function! SPInitialiseSearchMaps() + if exists(':ShowSearchIndex') + nnoremap / :call searchparty#mash#unmash()let b:searching=1ShowSearchIndex/ + nnoremap ? :call searchparty#mash#unmash()let b:searching=1ShowSearchIndex? + else + nnoremap / :call searchparty#mash#unmash()let b:searching=1/ + nnoremap ? :call searchparty#mash#unmash()let b:searching=1? + endif +endfunction + + + nnoremap SearchPartyMashFOWToggle \ :let b:mash_use_fow = b:mash_use_fow ? 0 : 1 \:call searchparty#mash#mash() +if !hasmapto('SearchPartyMashFOWToggle') + nmap mf SearchPartyMashFOWToggle +endif + " backwards compatible to my deprecated vim-MASH plugin nmap MashFOWToggle SearchPartyMashFOWToggle -" Multiple Replacements: {{{2 +" Multiple Replacements {{{1 nnoremap SearchPartyMultipleReplace \ :call searchparty#multiple_replacements#multiply_replace() -" Search Highlighting: {{{2 +if !hasmapto('SearchPartyMultipleReplace') + nmap mp SearchPartyMultipleReplace +endif +" Search Highlighting {{{1 +"-------------------- " Temporarily clear highlighting nnoremap SearchPartyHighlightClear \ :let b:mash_use_fow = 0 - \:call searchparty#mash#unmash()noh + \:call searchparty#mash#unmash():noh + +if !hasmapto('SearchPartyHighlightClear') + nmap SearchPartyHighlightClear +endif " Toggle search highlighting -nnoremap SearchPartyHighlightToggle :let &hlsearch = searchparty#mash#toggle()set hlsearch? +nnoremap SearchPartyHighlightToggle :set invhlsearch hlsearch? + +if !hasmapto('SearchPartyHighlightToggle') + nmap SearchPartyHighlightToggle +endif " Highlight all occurrences of word under cursor -nnoremap SearchPartyHighlightWord +nnoremap SearchPartyHighlightWord \ :let @/='\<'.expand('').'\>'set hlsearchviwo +if !hasmapto('SearchPartyHighlightWord') + nmap * SearchPartyHighlightWord +endif + " Highlight all occurrences of visual selection xnoremap SearchPartyHighlightVisual \ :let @/=searchparty#visual#element()set hlsearch +if !hasmapto('SearchPartyHighlightVisual') + xmap * SearchPartyHighlightVisual +endif + " Highlight all occurrences of WORD under cursor -nnoremap SearchPartyHighlightWORD - \ :let @/='\V'.escape(expand(''), '\\')set hlsearchviWo - -" Manual Search Term From Input +nnoremap SearchPartyHighlightWORD + \ :let @/=expand('')set hlsearch + +if !hasmapto('SearchPartyHighlightWORD') + nmap g* SearchPartyHighlightWORD +endif + +" Manual Search Term from input +" ----------------------------- nnoremap SearchPartySetSearch \ :let @/=input("set search: ")set hlsearch -" Visual Search And Replace: {{{2 +if !hasmapto('SearchPartySetSearch') + nmap ms SearchPartySetSearch +endif -" The default expected mappings: +" Visual Search & Replace +" ----------------------- " Use * and # in visual mode to search for visual selection " Use & in visual mode to prime a substitute based on visual selection -" Use g& in visual mode to repeat the prior change - -xnoremap SearchPartyVisualFindNext :call searchparty#visual#find('/') -xnoremap SearchPartyVisualFindPrev :call searchparty#visual#find('?') -xnoremap SearchPartyVisualSubstitute :%s/=searchparty#visual#element() -xnoremap SearchPartyVisualChangeAll :s/\<-\>/\=@./g -xnoremap SearchPartyVisualChangeAllBare :s/-/\=@./g - -" Toggle Auto Highlight Cursor Word: {{{2 + +xnoremap SearchPartyVisualFindNext :call searchparty#visual#find('/') + +if !hasmapto('SearchPartyVisualFindNext') + xmap * SearchPartyVisualFindNext +endif + +xnoremap SearchPartyVisualFindPrev :call searchparty#visual#find('?') + +if !hasmapto('SearchPartyVisualFindPrev') + xmap # SearchPartyVisualFindPrev +endif + +xnoremap SearchPartyVisualSubstitute :%s/=searchparty#visual#element() + +if !hasmapto('SearchPartyVisualSubstitute') + xmap & SearchPartyVisualSubstitute +endif + +" Toggle Auto Highlight Cursor Word {{{1 +" --------------------------------- nnoremap SearchPartyToggleAutoHighlightWord \ :call searchparty#search_highlights#toggle_AHCW() -" Print With Highlighting: {{{2 +if !hasmapto('SearchPartyToggleAutoHighlightWord') + nmap mah SearchPartyToggleAutoHighlightWord +endif + +" PrintWithHighlighting {{{1 command! -range=% -nargs=* P \ ,call searchparty#search_highlights#print() -" Replace Within Search Highlights: {{{2 +" Replace Within SearchHighlights {{{1 noremap SearchPartySearchHighlightReplace \ :call searchparty#search_highlights#replace() +if !hasmapto('SearchPartySearchHighlightReplace', 'n') + nmap mar SearchPartySearchHighlightReplace +endif + +if !hasmapto('SearchPartySearchHighlightReplace', 'v') + xmap mar SearchPartySearchHighlightReplace +endif + command! -range=% -nargs=0 SearchHighlightReplace \ ,call searchparty#search_highlights#replace() -" Search Within A Range: {{{2 +" Search Within A Range {{{1 command! -range=% -nargs=* RSearch \ exe '/\%(\%>'.(-1).'l\%<'.(+1).'l\)\&\%(\)/' - " Teardown:{{{1 +"reset &cpo back to users setting let &cpo = s:save_cpo " vim: set sw=2 sts=2 et fdm=marker: +" === added file 'vim/bundle/SearchParty/search_party_cheat_sheet.odt' Binary files vim/bundle/SearchParty/search_party_cheat_sheet.odt 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/search_party_cheat_sheet.odt 2015-02-13 09:59:55 +0000 differ === added file 'vim/bundle/SearchParty/search_party_cheat_sheet.pdf' Binary files vim/bundle/SearchParty/search_party_cheat_sheet.pdf 1970-01-01 00:00:00 +0000 and vim/bundle/SearchParty/search_party_cheat_sheet.pdf 2015-02-13 09:59:55 +0000 differ === removed file 'vim/bundle/SearchParty/searchparty_default_maps.adoc' --- vim/bundle/SearchParty/searchparty_default_maps.adoc 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/searchparty_default_maps.adoc 1970-01-01 00:00:00 +0000 @@ -1,32 +0,0 @@ -= SearchParty Default User Maps -v1.0, Barry Arthur, 2016-07-06 - -== Normal Mode - -[cols="1m,4m",width="55%"] -|==== -|md | SearchPartyDeleteMatch -|? | SearchPartyFindLiteralBkwd -|/ | SearchPartyFindLiteralFwd -| | SearchPartyHighlightClear -| | SearchPartyHighlightToggle -|g* | SearchPartyHighlightWORD -|* | SearchPartyHighlightWord -|mf | SearchPartyMashFOWToggle -|mp | SearchPartyMultipleReplace -|mm | SearchPartySetMatch -|ms | SearchPartySetSearch -|mah | SearchPartyToggleAutoHighlightWord -|==== - -== Visual Mode - -[cols="1m,4m",width="55%"] -|==== -|* | SearchPartyHighlightVisual -|g& | SearchPartyVisualChangeAll -|gg& | SearchPartyVisualChangeAllBare -|* | SearchPartyVisualFindNext -|# | SearchPartyVisualFindPrev -|& | SearchPartyVisualSubstitute -|==== === removed file 'vim/bundle/SearchParty/searchparty_default_maps.vim' --- vim/bundle/SearchParty/searchparty_default_maps.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/searchparty_default_maps.vim 1970-01-01 00:00:00 +0000 @@ -1,24 +0,0 @@ -" Normal Mode -nmap md SearchPartyDeleteMatch -nmap ? SearchPartyFindLiteralBkwd -nmap / SearchPartyFindLiteralFwd -nmap SearchPartyHighlightClear -nmap SearchPartyHighlightToggle -nmap g* SearchPartyHighlightWORD -nmap * SearchPartyHighlightWord -nmap mf SearchPartyMashFOWToggle -nmap mp SearchPartyMultipleReplace -nmap mar SearchPartySearchHighlightReplace -nmap mm SearchPartySetMatch -nmap ms SearchPartySetSearch -nmap mah SearchPartyToggleAutoHighlightWord - -" Visual Mode - -xmap * SearchPartyHighlightVisual -xmap mar SearchPartySearchHighlightReplace -xmap g& SearchPartyVisualChangeAll -xmap gg& SearchPartyVisualChangeAllBare -xmap * SearchPartyVisualFindNext -xmap # SearchPartyVisualFindPrev -xmap & SearchPartyVisualSubstitute === removed directory 'vim/bundle/SearchParty/test' === removed file 'vim/bundle/SearchParty/test/001_shadow_maps.tap' --- vim/bundle/SearchParty/test/001_shadow_maps.tap 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/001_shadow_maps.tap 1970-01-01 00:00:00 +0000 @@ -1,47 +0,0 @@ -1..46 -ok 1 - LineColPos Line, Test 1: normal 1G0*. -ok 2 - LineColPos Column, Test 1: normal 1G0*. -ok 3 - LineColPos Line, Test 2: normal *. -ok 4 - LineColPos Column, Test 2: normal *. -ok 5 - LineColPos Line, Test 3: normal 1G0viw*. -ok 6 - LineColPos Column, Test 3: normal 1G0viw*. -ok 7 - LineColPos Line, Test 4: normal *. -ok 8 - LineColPos Column, Test 4: normal *. -ok 9 - LineColPos Line, Test 5: normal *. -ok 10 - LineColPos Column, Test 5: normal *. -ok 11 - LineColPos Line, Test 6: normal 1G0#. -ok 12 - LineColPos Column, Test 6: normal 1G0#. -ok 13 - LineColPos Line, Test 7: normal #. -ok 14 - LineColPos Column, Test 7: normal #. -ok 15 - LineColPos Line, Test 8: normal 1G0viw#. -ok 16 - LineColPos Column, Test 8: normal 1G0viw#. -ok 17 - LineColPos Line, Test 9: normal #. -ok 18 - LineColPos Column, Test 9: normal #. -ok 19 - LineColPos Line, Test 10: normal #. -ok 20 - LineColPos Column, Test 10: normal #. -ok 21 - LineColPos Line, Test 11: normal 1G0g*. -ok 22 - LineColPos Column, Test 11: normal 1G0g*. -ok 23 - LineColPos Line, Test 12: normal g*. -ok 24 - LineColPos Column, Test 12: normal g*. -ok 25 - LineColPos Line, Test 13: normal g*. -ok 26 - LineColPos Column, Test 13: normal g*. -ok 27 - LineColPos Line, Test 14: normal g*. -ok 28 - LineColPos Column, Test 14: normal g*. -ok 29 - LineColPos Line, Test 15: normal g*. -ok 30 - LineColPos Column, Test 15: normal g*. -ok 31 - LineColPos Line, Test 16: normal 1G0g#. -ok 32 - LineColPos Column, Test 16: normal 1G0g#. -ok 33 - LineColPos Line, Test 17: normal g#. -ok 34 - LineColPos Column, Test 17: normal g#. -ok 35 - LineColPos Line, Test 18: normal 1G09|*. -ok 36 - LineColPos Column, Test 18: normal 1G09|*. -ok 37 - LineColPos Line, Test 19: normal n. -ok 38 - LineColPos Column, Test 19: normal n. -ok 39 - LineColPos Line, Test 20: normal n. -ok 40 - LineColPos Column, Test 20: normal n. -ok 41 - LineColPos Line, Test 21: normal N. -ok 42 - LineColPos Column, Test 21: normal N. -ok 43 - LineColPos Line, Test 22: normal N. -ok 44 - LineColPos Column, Test 22: normal N. -ok 45 - LineColPos Line, Test 23: normal N. -ok 46 - LineColPos Column, Test 23: normal N. === removed file 'vim/bundle/SearchParty/test/001_shadow_maps.vim' --- vim/bundle/SearchParty/test/001_shadow_maps.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/001_shadow_maps.vim 1970-01-01 00:00:00 +0000 @@ -1,44 +0,0 @@ -call vimtest#StartTap() -call vimtap#Plan(46) " <== XXX Keep plan number updated. XXX -"call vimtap#Diag('Test') -append -abc abc xyz ijk -abcd abcd xyz ijk lmn -abcde xyz -. - -call LineColPos(1, 5, 'normal 1G0*') " <== XXX Account for 2 tests each call XXX -call LineColPos(1, 1, 'normal *') - -call LineColPos(1, 7, "normal 1G0viw*") -call LineColPos(2, 3, 'normal *') -call LineColPos(2, 8, 'normal *') -exe "normal \" - -call LineColPos(1, 5, 'normal 1G0#') -call LineColPos(1, 1, 'normal #') - -call LineColPos(3, 3, 'normal 1G0viw#') -call LineColPos(2, 8, 'normal #') -call LineColPos(2, 3, 'normal #') -exe "normal \" - -call LineColPos(1, 5, 'normal 1G0g*') -call LineColPos(2, 1, 'normal g*') -call LineColPos(2, 6, 'normal g*') -call LineColPos(3, 1, 'normal g*') -call LineColPos(3, 1, 'normal g*') - -call LineColPos(3, 1, 'normal 1G0g#') -call LineColPos(3, 1, 'normal g#') - -call LineColPos(2, 11, 'normal 1G09|*') -" RunVimTests isn't setting @/ on * ?! -let @/ = '\' -call LineColPos(3, 7, 'normal n') -call LineColPos(1, 9, 'normal n') -call LineColPos(3, 7, 'normal N') -call LineColPos(2, 11, 'normal N') -call LineColPos(1, 9, 'normal N') - -call vimtest#Quit() === removed file 'vim/bundle/SearchParty/test/002_find_literal.tap' --- vim/bundle/SearchParty/test/002_find_literal.tap 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/002_find_literal.tap 1970-01-01 00:00:00 +0000 @@ -1,5 +0,0 @@ -1..4 -ok 1 - LineColPos Line, Test 1: normal 1G0\/abc* . -ok 2 - LineColPos Column, Test 1: normal 1G0\/abc* . -ok 3 - LineColPos Line, Test 2: normal 2G0\?abcd$ . -ok 4 - LineColPos Column, Test 2: normal 2G0\?abcd$ . === removed file 'vim/bundle/SearchParty/test/002_find_literal.vim' --- vim/bundle/SearchParty/test/002_find_literal.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/002_find_literal.vim 1970-01-01 00:00:00 +0000 @@ -1,13 +0,0 @@ -call vimtest#StartTap() -call vimtap#Plan(4) " <== XXX Keep plan number updated. XXX -"call vimtap#Diag('Test') -append -abc* abc xyz ijk -abcd$ abc* xyz ijk lmn -abcd$ xyz -. - -call LineColPos(2, 7, "normal 1G0\\/abc*\") " <== XXX Account for 2 tests each call XXX -call LineColPos(3, 1, "normal 2G0\\?abcd$\") - -call vimtest#Quit() === removed file 'vim/bundle/SearchParty/test/003_highlight.vim' --- vim/bundle/SearchParty/test/003_highlight.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/003_highlight.vim 1970-01-01 00:00:00 +0000 @@ -1,19 +0,0 @@ -call vimtest#StartTap() -call vimtap#Plan(9) " <== XXX Keep plan number updated. XXX -"call vimtap#Diag('Test') -append -abc abc(*) xyz 1 -abcd abc abc(*) xyz ijk lmn -abcd xyz -. - -call LineColPos(1, 1, 'normal 1G0\*') " <== XXX Account for 2 tests each call XXX -call VisualMatch("abc") - -call LineColPos(2, 1, 'normal 2G0\*') -call VisualMatch("abcd") - -call LineColPos(2, 10, 'normal 1G0w\g*n') -call VisualMatch('abc(*)') - -call vimtest#Quit() === removed file 'vim/bundle/SearchParty/test/004_multi_replace.vim' --- vim/bundle/SearchParty/test/004_multi_replace.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/004_multi_replace.vim 1970-01-01 00:00:00 +0000 @@ -1,11 +0,0 @@ -call vimtest#StartTap() -call vimtap#Plan(1) " <== XXX Keep plan number updated. XXX -"call vimtap#Diag('Test') -append -192.168.1.1 localhost -. - -exe 'normal 1G0\mp' . "1\\ze \2 3 4 5\" -call Is(getline(1,'$'), ['192.168.1.1 localhost', '192.168.1.2 localhost', '192.168.1.3 localhost', '192.168.1.4 localhost', '192.168.1.5 localhost'], "") - -call vimtest#Quit() === removed file 'vim/bundle/SearchParty/test/005_visual.vim' --- vim/bundle/SearchParty/test/005_visual.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/005_visual.vim 1970-01-01 00:00:00 +0000 @@ -1,28 +0,0 @@ -call vimtest#StartTap() -call vimtap#Plan(15) " <== XXX Keep plan number updated. XXX -"call vimtap#Diag('Test') -append -foo bar baz bar -foo bar baz bar -foo bar baz bar -foobar baz bar -. - -call LineColPos(4, 1, "normal 1G0wviw&/goo\") " <== XXX Account for 2 tests each call XXX -call Is(getline(1), 'foo goo baz bar', "") -call Is(getline(1, '$'), ['foo goo baz bar', 'foo goo baz bar', 'foo goo baz bar', 'foogoo baz bar'], "") - -call LineColPos(2, 7, "normal 2G0wcwzoo\") -call Is(getline(2), 'foo zoo baz bar', "") - -normal jVg& -call Is(getline(3), 'foo zoo baz bar', "") -call Is(getline(4), 'foogoo baz bar', "") - -call LineColPos(1, 7, "normal 1G0wcwbus\") -call Is(getline(1), 'foo bus baz bar', "") - -call LineColPos(4, 1, "normal 4GVgg&") -call Is(getline(4), 'foobus baz bar', "") - -call vimtest#Quit() === removed file 'vim/bundle/SearchParty/test/006_set_search.vim' --- vim/bundle/SearchParty/test/006_set_search.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/006_set_search.vim 1970-01-01 00:00:00 +0000 @@ -1,16 +0,0 @@ -call vimtest#StartTap() -call vimtap#Plan(4) " <== XXX Keep plan number updated. XXX -"call vimtap#Diag('Test') -append -abc abc(*) xyz 1 -abcd abc abc(*) xyz ijk lmn -abcd xyz -. - -call LineColPos(1, 1, 'normal 1G0\*') " <== XXX Account for 2 tests each call XXX -call Is(@/, '\', "") - -exe "normal \\msabcd\" -call Is(@/, 'abcd', "") - -call vimtest#Quit() === removed file 'vim/bundle/SearchParty/test/README' --- vim/bundle/SearchParty/test/README 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/README 1970-01-01 00:00:00 +0000 @@ -1,13 +0,0 @@ -The plugins runVimTests (http://www.vim.org/scripts/script.php?script_id=2565) -and VimTAP (http://www.vim.org/scripts/script.php?script_id=2213) are needed to -run these tests. - -Besides the _setup.vim configuration file present in this repo you need to -create a global one and place it in the same dir where the runVimTests -executable is located. Assuming the executable is at '~/bin/runVimTests' this -global configuration file should be '~/bin/runVimTestsSetup.vim' and should -have something like the following lines inside of it: - -" Prepend tests repos to &rtp -let &runtimepath = '/path/to/runVimTests_dir,' . &rtp -let &runtimepath = '/path/to/vimTAP_dir,' . &rtp === removed file 'vim/bundle/SearchParty/test/_setup.vim' --- vim/bundle/SearchParty/test/_setup.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/SearchParty/test/_setup.vim 1970-01-01 00:00:00 +0000 @@ -1,36 +0,0 @@ -let &rtp = expand(':p:h:h') . ',' . &rtp . ',' . expand(':p:h:h') . '/after' - -let @* = '' -runtime plugin/SearchParty.vim -" Nexus is needed for SearchHighlightReplace -runtime plugin/Nexus.vim - -" Have to manually call SPLoadUserMaps() because RunVimTests doesn't seem to be -" triggering the VimEnter autocommand. -call SPLoadUserMaps() - -function! Is(got, expected, description) - let qgot = string(a:got) - call vimtap#Is(a:got, a:expected, qgot, a:description) -endfunction - -let g:test_count = 0 -function! LineColPos(line, col, ...) - for cmd in a:000 - exec cmd - endfor - let g:test_count += 1 - let msg = join(a:000, '|') . '.' - let l = line('.') - let c = col('.') - call Is(l, a:line, 'LineColPos Line, Test ' . g:test_count . ': ' . msg) - call Is(c, a:col, 'LineColPos Column, Test ' . g:test_count . ': ' . msg) -endfunction - -function! VisualMatch(expected) - call Is(@*, a:expected, 'VisualMatch. Test ' . g:test_count) -endfunction - -function! LineMatch(line, expected) - call Is(getline(a:line), a:expected, 'LineMatch. Test ' . g:test_count) -endfunction === modified file 'vim/bundle/csv.vim/.git/config' (properties changed: -x to +x) === modified file 'vim/bundle/csv.vim/.git/hooks/applypatch-msg.sample' --- vim/bundle/csv.vim/.git/hooks/applypatch-msg.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/hooks/applypatch-msg.sample 2015-02-13 09:59:55 +0000 @@ -10,6 +10,6 @@ # To enable this hook, rename this file to "applypatch-msg". . git-sh-setup -commitmsg="$(git rev-parse --git-path hooks/commit-msg)" -test -x "$commitmsg" && exec "$commitmsg" ${1+"$@"} +test -x "$GIT_DIR/hooks/commit-msg" && + exec "$GIT_DIR/hooks/commit-msg" ${1+"$@"} : === modified file 'vim/bundle/csv.vim/.git/hooks/pre-applypatch.sample' --- vim/bundle/csv.vim/.git/hooks/pre-applypatch.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/hooks/pre-applypatch.sample 2015-02-13 09:59:55 +0000 @@ -9,6 +9,6 @@ # To enable this hook, rename this file to "pre-applypatch". . git-sh-setup -precommit="$(git rev-parse --git-path hooks/pre-commit)" -test -x "$precommit" && exec "$precommit" ${1+"$@"} +test -x "$GIT_DIR/hooks/pre-commit" && + exec "$GIT_DIR/hooks/pre-commit" ${1+"$@"} : === modified file 'vim/bundle/csv.vim/.git/hooks/pre-push.sample' --- vim/bundle/csv.vim/.git/hooks/pre-push.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/hooks/pre-push.sample 2015-02-13 09:59:55 +0000 @@ -24,6 +24,7 @@ z40=0000000000000000000000000000000000000000 +IFS=' ' while read local_ref local_sha remote_ref remote_sha do if [ "$local_sha" = $z40 ] === modified file 'vim/bundle/csv.vim/.git/hooks/update.sample' --- vim/bundle/csv.vim/.git/hooks/update.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/hooks/update.sample 2015-02-13 09:59:55 +0000 @@ -1,6 +1,6 @@ #!/bin/sh # -# An example hook script to block unannotated tags from entering. +# An example hook script to blocks unannotated tags from entering. # Called by "git receive-pack" with arguments: refname sha1-old sha1-new # # To enable this hook, rename this file to "update". === modified file 'vim/bundle/csv.vim/.git/index' Binary files vim/bundle/csv.vim/.git/index 2016-08-04 08:15:09 +0000 and vim/bundle/csv.vim/.git/index 2015-08-25 11:56:54 +0000 differ === modified file 'vim/bundle/csv.vim/.git/logs/HEAD' --- vim/bundle/csv.vim/.git/logs/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/logs/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 16634f646c9d1f5756d34ed35dbd6b9d5bf34fa0 Jan Pobrislo 1470298359 +0200 clone: from https://github.com/chrisbra/csv.vim +0000000000000000000000000000000000000000 ae623607a28383ddb92568d2448081982ef4eeb5 Jan Pobrislo 1440501757 +0200 clone: from https://github.com/chrisbra/csv.vim === modified file 'vim/bundle/csv.vim/.git/logs/refs/heads/master' --- vim/bundle/csv.vim/.git/logs/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/logs/refs/heads/master 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 16634f646c9d1f5756d34ed35dbd6b9d5bf34fa0 Jan Pobrislo 1470298359 +0200 clone: from https://github.com/chrisbra/csv.vim +0000000000000000000000000000000000000000 ae623607a28383ddb92568d2448081982ef4eeb5 Jan Pobrislo 1440501757 +0200 clone: from https://github.com/chrisbra/csv.vim === modified file 'vim/bundle/csv.vim/.git/logs/refs/remotes/origin/HEAD' --- vim/bundle/csv.vim/.git/logs/refs/remotes/origin/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/logs/refs/remotes/origin/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 16634f646c9d1f5756d34ed35dbd6b9d5bf34fa0 Jan Pobrislo 1470298359 +0200 clone: from https://github.com/chrisbra/csv.vim +0000000000000000000000000000000000000000 ae623607a28383ddb92568d2448081982ef4eeb5 Jan Pobrislo 1440501757 +0200 clone: from https://github.com/chrisbra/csv.vim === removed directory 'vim/bundle/csv.vim/.git/objects/03' === removed file 'vim/bundle/csv.vim/.git/objects/03/04f5b4814ce03af7f82056112d4d8c2233df29' --- vim/bundle/csv.vim/.git/objects/03/04f5b4814ce03af7f82056112d4d8c2233df29 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/objects/03/04f5b4814ce03af7f82056112d4d8c2233df29 1970-01-01 00:00:00 +0000 @@ -1,1 +0,0 @@ -x+)JMU0`040031QH+M..+(ai{jw%L$cwο?I \ No newline at end of file === removed file 'vim/bundle/csv.vim/.git/objects/03/fecb5ff1da944cf0d146c120b6e597d30b12cf' Binary files vim/bundle/csv.vim/.git/objects/03/fecb5ff1da944cf0d146c120b6e597d30b12cf 2016-08-04 08:15:09 +0000 and vim/bundle/csv.vim/.git/objects/03/fecb5ff1da944cf0d146c120b6e597d30b12cf 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/csv.vim/.git/objects/14' === removed file 'vim/bundle/csv.vim/.git/objects/14/8f0c86e1253ed45614538b889e0b6cfe68fc93' Binary files vim/bundle/csv.vim/.git/objects/14/8f0c86e1253ed45614538b889e0b6cfe68fc93 2016-08-04 08:15:09 +0000 and vim/bundle/csv.vim/.git/objects/14/8f0c86e1253ed45614538b889e0b6cfe68fc93 1970-01-01 00:00:00 +0000 differ === removed file 'vim/bundle/csv.vim/.git/objects/14/a3ba6185188d16696238e57ecb211358f28e08' Binary files vim/bundle/csv.vim/.git/objects/14/a3ba6185188d16696238e57ecb211358f28e08 2016-08-04 08:15:09 +0000 and vim/bundle/csv.vim/.git/objects/14/a3ba6185188d16696238e57ecb211358f28e08 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/csv.vim/.git/objects/16' === removed file 'vim/bundle/csv.vim/.git/objects/16/634f646c9d1f5756d34ed35dbd6b9d5bf34fa0' Binary files vim/bundle/csv.vim/.git/objects/16/634f646c9d1f5756d34ed35dbd6b9d5bf34fa0 2016-08-04 08:15:09 +0000 and vim/bundle/csv.vim/.git/objects/16/634f646c9d1f5756d34ed35dbd6b9d5bf34fa0 1970-01-01 00:00:00 +0000 differ === removed file 'vim/bundle/csv.vim/.git/objects/1d/0f12cfe99557d8fb8a456212ac8a08e3b11374' --- vim/bundle/csv.vim/.git/objects/1d/0f12cfe99557d8fb8a456212ac8a08e3b11374 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/.git/objects/1d/0f12cfe99557d8fb8a456212ac8a08e3b11374 1970-01-01 00:00:00 +0000 @@ -1,1 +0,0 @@ -x+)JMU06e040031QH..+e۪'՞m[7M+Ph \ No newline at end of file === added file 'vim/bundle/csv.vim/.git/objects/1d/4ba9c9a73350b45d767e44f9f4382cb80b4e63' Binary files vim/bundle/csv.vim/.git/objects/1d/4ba9c9a73350b45d767e44f9f4382cb80b4e63 1970-01-01 00:00:00 +0000 and vim/bundle/csv.vim/.git/objects/1d/4ba9c9a73350b45d767e44f9f4382cb80b4e63 2015-08-25 11:56:54 +0000 differ === added directory 'vim/bundle/csv.vim/.git/objects/23' === added file 'vim/bundle/csv.vim/.git/objects/23/a4134ac224c8be07dccdcfcc477c8d457ab54f' --- vim/bundle/csv.vim/.git/objects/23/a4134ac224c8be07dccdcfcc477c8d457ab54f 1970-01-01 00:00:00 +0000 +++ vim/bundle/csv.vim/.git/objects/23/a4134ac224c8be07dccdcfcc477c8d457ab54f 2015-08-25 11:56:54 +0000 @@ -0,0 +1,4 @@ +xXmoWݯ-lݱ)i0 H2+VB) ֧>3wGJlm3e^]_/R9[,sCl -|ƖvK:oL]PZU4Ɣ\W"[l(ޕϟ?rӐ鵡 amE.1eZeJfcdg6UI臣l47L qkpᯡfK)3;`ՙɗ٪LHvj^9KXn>oߋEU7TJE׆tm`umaT8UAЬY櫹- UËۗ&]Ty +[HF1V8 Eg(֥ZCJSiVuIxd\&cOHe(' ^Ҝ#al$!L~"cQPuŸGݳ` ܘ| H[֮S%עYtXy47 r(p"Zs]W+ 0^ 4yks61wz▹mj|G2ISϞA )~bO -[g=qUՌlgz7H}0*<'H8QiBf"nLF6k@l63|3ZF&9;{L+a]Fr57ŲMde@o88ULi̕$xD^e˶Fֽg'+Lh< +!Y!E撸enQpinJ7Ʉ^ni8!-M??$]*XLQ%ZrF $^rW:toMd!<^I72A@I]?w**o_*Mpel?C7=H)HhQM&aa&hb(";A  B\Gr ~gn ) mi˸t{\-fL)9@'Sh^4?~Wp|6SOXן[C.b\dyv/ն Nk%CCU7W@[(]8Z_J89&̤(V2BEiW~'na]኿1;c!{!y1ŀIytyYlg_ 6+5a=3㭜:z榙j9A_ው.(]fv+g\?vU4}*Q27 j .7 9̥$(λf~{;A!`1)ƅc~{ANRg |Is8SuP9O !+;OЏАw#>8 'Q0Ƨx,Ő{r1ٟQR\Itڜy M"6|zn?|stjC8 94 +>k0&5*Fsځ|=9b?GrZa<3´Ń]')yKKҫq7y #x Xo%<4=S;e_B3OY`I/h[& ʷј0u!psO-{a݂# " Version: 0.31 @@ -15,26 +15,19 @@ " Some ideas are taken from the wiki http://vim.wikia.com/wiki/VimTip667 " though, implementation differs. -" Plugin folklore "{{{1 -if v:version < 700 || exists('b:did_ftplugin') - finish -endif -let b:did_ftplugin = 1 - -let s:cpo_save = &cpo -set cpo&vim +" Plugin folklore "{{{2 fu! DetermineSID() let s:SID = matchstr(expand(''), '\zs\d\+\ze_DetermineSID$') endfu call s:DetermineSID() delf s:DetermineSID -let s:csv_numeric_sort = v:version > 704 || v:version == 704 && has("patch341") -if !s:csv_numeric_sort "{{{2 - fu! CSVSortValues(i1, i2) "{{{3 - return (a:i1+0) == (a:i2+0) ? 0 : (a:i1+0) > (a:i2+0) ? 1 : -1 - endfu +let s:numeric_sort = v:version > 704 || v:version == 704 && has("patch341") +if !s:numeric_sort + fu! CSVSortValues(i1, i2) "{{{3 + return (a:i1+0) == (a:i2+0) ? 0 : (a:i1+0) > (a:i2+0) ? 1 : -1 + endfu endif -" Function definitions: "{{{1 + fu! CSVArrangeCol(first, last, bang, limit) range "{{{2 if &ft =~? 'csv' call ArrangeCol(a:first, a:last, a:bang, a:limit) @@ -43,6 +36,15 @@ endif endfu +if v:version < 700 || exists('b:did_ftplugin') + finish +endif +let b:did_ftplugin = 1 + +let s:cpo_save = &cpo +set cpo&vim + +" Function definitions: "{{{2 " Script specific functions "{{{2 fu! Warn(mess) "{{{3 echohl WarningMsg @@ -153,9 +155,7 @@ " enable CSV Menu call Menu(1) call DisableFolding() - if !exists("b:current_syntax") - silent do Syntax - endif + silent do Syntax unlet! b:csv_start b:csv_end " Remove configuration variables @@ -216,20 +216,20 @@ endfu fu! DoAutoCommands() "{{{3 - " Highlight column, on which the cursor is - if exists("g:csv_highlight_column") && g:csv_highlight_column =~? 'y' - exe "aug CSV_HI".bufnr('') + " Highlight column, on which the cursor is? + if exists("g:csv_highlight_column") && g:csv_highlight_column =~? 'y' && + \ !exists("#CSV_HI#CursorMoved") + aug CSV_HI au! - exe "au CursorMoved HiColumn" - exe "au BufWinLeave HiColumn!" + au CursorMoved HiColumn aug end " Set highlighting for column, on which the cursor is currently HiColumn - else - exe "aug CSV_HI".bufnr('') - exe "au! CursorMoved " + elseif exists("#CSV_HI#CursorMoved") + aug CSV_HI + au! CursorMoved aug end - exe "aug! CSV_HI".bufnr('') + aug! CSV_HI " Remove any existing highlighting HiColumn! endif @@ -247,6 +247,7 @@ augroup END endif endfu + fu! GetPat(colnr, maxcolnr, pat, allowmore) "{{{3 " if a:allowmmore, allows more to match after the pattern if a:colnr > 1 && a:colnr < a:maxcolnr @@ -263,10 +264,10 @@ elseif a:colnr == a:maxcolnr if !exists("b:csv_fixed_width_cols") return '^' . GetColPat(a:colnr - 1,0) . - \ '\zs' . a:pat . '\ze' . (a:allowmore ? '' : '$') + \ '\zs' . a:pat . '\ze$' else return '\%' . b:csv_fixed_width_cols[-1] . - \ 'c\zs' . a:pat . '\ze' . (a:allowmore ? '' : '$') + \ 'c\zs' . a:pat . '\ze$' endif else " colnr = 1 if !exists("b:csv_fixed_width_cols") @@ -279,6 +280,7 @@ endif return '' endfu + fu! SearchColumn(arg) "{{{3 try let arglist=split(a:arg) @@ -335,6 +337,8 @@ echohl Normal endtry endfu + + fu! DeleteColumn(arg) "{{{3 let _wsv = winsaveview() if a:arg =~ '^[/]' @@ -357,6 +361,7 @@ endif call winrestview(_wsv) endfu + fu! DelColumn(colnr) "{{{3 let maxcolnr = MaxColumns() let _p = getpos('.') @@ -394,12 +399,13 @@ setl ro endif endfu + fu! HiCol(colnr, bang) "{{{3 + if a:colnr > MaxColumns() && !a:bang + call Warn("There exists no column " . a:colnr) + return + endif if !a:bang - if a:colnr > MaxColumns() - call Warn("There exists no column " . a:colnr) - return - endif if empty(a:colnr) let colnr=WColumn() else @@ -423,6 +429,9 @@ " Additionally, filter all matches, that could have been used earlier let matchlist=getmatches() call filter(matchlist, 'v:val["group"] !~ s:hiGroup') + " remove matches, that come from matchaddpos() + " setmatches() can't handle them. + call filter(matchlist, 'has_key(v:val, "pattern")') call setmatches(matchlist) if a:bang return @@ -432,6 +441,7 @@ exe ":2match " . s:hiGroup . ' /' . pat . '/' endif endfu + fu! GetDelimiter(first, last) "{{{3 if !exists("b:csv_fixed_width_cols") let _cur = getpos('.') @@ -465,6 +475,7 @@ return '' endif endfu + fu! WColumn(...) "{{{3 " Return on which column the cursor is let _cur = getpos('.') @@ -474,7 +485,7 @@ " line is empty let line = getline(line('.')-1) else - let line = getline('.') + let line=getline('.') endif " move cursor to end of field "call search(b:col, 'ec', line('.')) @@ -484,7 +495,7 @@ let ret=len(fields) if exists("a:1") && a:1 > 0 " bang attribute: Try to get the column name - let head = split(getline(get(b:, 'csv_headerline', 1)),b:col.'\zs') + let head = split(getline(1),b:col.'\zs') " remove preceeding whitespace if len(head) < ret call Warn("Header has no field ". ret) @@ -498,7 +509,7 @@ let temp=getpos('.')[2] let j=1 let ret = 1 - for i in sort(b:csv_fixed_width_cols, s:csv_numeric_sort ? 'n' : 's:CSVSortValues') + for i in sort(b:csv_fixed_width_cols, s:numeric_sort ? 'n' : 's:CSVSortValues') if temp >= i let ret = j endif @@ -508,16 +519,22 @@ call setpos('.',_cur) return ret endfu + fu! MaxColumns(...) "{{{3 - let this_col = exists("a:1") + if exists("a:0") && a:0 == 1 + let this_col = 1 + else + let this_col = 0 + endif "return maximum number of columns in first 10 lines if !exists("b:csv_fixed_width_cols") - let i = this_col ? a:1 : get(b:, 'csv_headerline', 1) + if this_col + let i = a:1 + else + let i = 1 + endif while 1 - let l = getline(i, (this_col ? i : i+10)) - if empty(l) && i >= line('$') - break - endif + let l = getline(i, i+10) " Filter comments out let pat = '^\s*\V'. escape(b:csv_cmt[0], '\\') @@ -543,6 +560,7 @@ return len(b:csv_fixed_width_cols) endif endfu + fu! ColWidth(colnr, ...) "{{{3 " if a:1 is given, specifies the row, for which to calculate the width " @@ -572,9 +590,15 @@ endif try for item in b:csv_list - call add(tlist, get(item, a:colnr-1, '')) + call add(tlist, item[a:colnr-1]) endfor + " we have a list of the first 10 rows + " Now transform it to a list of field a:colnr + " and then return the maximum strlen + " That could be done in 1 line, but that would look ugly + "call map(list, 'split(v:val, b:col."\\zs")[a:colnr-1]') " do not strip leading whitespace + " call map(tlist, 'substitute(v:val, ''^\s*'', "", "g")') call map(tlist, 'substitute(v:val, ".", "x", "g")') call map(tlist, 'strlen(v:val)') return max(tlist) @@ -596,6 +620,7 @@ endif endif endfu + fu! ArrangeCol(first, last, bang, limit, ...) range "{{{3 " a:1, optional width parameter of line from which to take the width " @@ -607,48 +632,18 @@ endif let cur=winsaveview() if a:bang || (exists("a:1") && !empty(a:1)) - if a:bang && exists("b:col_width") - " Unarrange, so that if csv_arrange_align has changed - " it will be adjusted automaticaly - call PrepUnArrangeCol(a:first, a:last) - endif " Force recalculating the Column width unlet! b:csv_list b:col_width elseif a:limit > -1 && a:limit < getfsize(fnamemodify(bufname(''), ':p')) return endif - let first = a:first - let last = a:last - if exists("b:csv_headerline") - if a:first < b:csv_headerline - let first = b:csv_headerline - endif - if a:last < b:csv_headerline - let last = b:csv_headerline - endif - endif - if first > line('$') - let first=line('$') - endif - if last > line('$') - let last=line('$') - endif - if &vbs - echomsg printf("ArrangeCol Start: %d, End: %d", first, last) - endif - if !exists("b:col_width") " Force recalculation of Column width let row = exists("a:1") ? a:1 : '' call CalculateColumnWidth(row) endif - " abort on empty file - if !len(b:col_width) - call Warn("No column data detected, aborting ArrangeCol command!") - return - endif if &ro " Just in case, to prevent the Warning " Warning: W10: Changing read-only file @@ -659,10 +654,10 @@ endif let s:count = 0 let _stl = &stl - let s:max = (last - first + 1) * len(b:col_width) + let s:max = (a:last - a:first + 1) * len(b:col_width) let s:temp = 0 try - exe "sil". first . ',' . last .'s/' . (b:col) . + exe "sil". a:first . ',' . a:last .'s/' . (b:col) . \ '/\=Columnize(submatch(0))/' . (&gd ? '' : 'g') finally " Clean up variables, that were only needed for Columnize() function @@ -675,8 +670,9 @@ call winrestview(cur) endtry endfu + fu! ProgressBar(cnt, max) "{{{3 - if get(g:, 'csv_no_progress', 0) || a:max == 0 + if get(g:, 'csv_no_progress', 0) return endif let width = 40 " max width of progressbar @@ -691,6 +687,7 @@ let s:temp = s:val endif endfu + fu! PrepUnArrangeCol(first, last) "{{{3 " Because of the way, Vim works with " a:firstline and a:lastline parameter, @@ -712,20 +709,24 @@ " Clean up variables, that were only needed for Columnize() function call winrestview(cur) endfu + fu! UnArrangeCol(match) "{{{3 " Strip leading white space, also trims empty records: + "if get(b:, 'csv_arrange_leftalign',0) + " return substitute(a:match, '\s\+\ze'. b:delimiter. '\?$', '', '') + "else + " return substitute(a:match, '^\s\+', '', '') + "endif return substitute(a:match, '\%(^\s\+\)\|\%(\s\+\ze'.b:delimiter. '\?$\)', '', 'g') + " only strip leading white space, if a non-white space follows: + "return substitute(a:match, '^\s\+\ze\S', '', '') endfu + fu! CalculateColumnWidth(row) "{{{3 " Internal function, not called from external, " does not work with fixed width columns let b:col_width=[] try - if exists("b:csv_headerline") - if line('.') < b:csv_headerline - call cursor(b:csv_headerline,1) - endif - endif let s:max_cols=MaxColumns(line('.')) for i in range(1,s:max_cols) if empty(a:row) @@ -743,6 +744,7 @@ " this was only necessary for calculating the max width unlet! b:csv_list s:columnize_count s:decimal_column endfu + fu! Columnize(field) "{{{3 " Internal function, not called from external, " does not work with fixed width columns @@ -786,7 +788,7 @@ let has_delimiter = (a:field[-1:] is? b:delimiter) if align is? 'l' " left-align content - return printf("%-*S%s", width-1, + return printf("%-*S%s", width+1 , \ (has_delimiter ? a:field[:-2] : a:field), \ (has_delimiter ? b:delimiter : ' ')) elseif align is? 'c' @@ -845,6 +847,7 @@ return printf("%*S", width+1 , a:field) endif endfun + fu! GetColPat(colnr, zs_flag) "{{{3 " Return Pattern for given column if a:colnr > 1 @@ -869,26 +872,16 @@ endif return pat . (a:zs_flag ? '\zs' : '') endfu + fu! SetupAutoCmd(window,bufnr) "{{{3 " Setup QuitPre autocommand to quit cleanly aug CSV_QuitPre au! exe "au QuitPre * call CSV_CloseBuffer(".winbufnr(a:window).")" - if !exists("##OptionSet") - exe "au CursorHold call CSV_SetSplitOptions(".a:window.")" - else - exe "au OptionSet foldcolumn,number,relativenumber call CSV_SetOption(".a:bufnr. - \ ", ".bufnr('%').", expand(''), v:option_new)" - endif - exe "au VimResized,FocusLost,FocusGained call CSV_SetSplitOptions(".a:window.")" + exe "au CursorHold call CSV_SetSplitOptions(".a:window.")" aug END endfu -fu! CSV_SetOption(csvfile, header, option, value) "{{{3 - " only trigger if the option is called in the correct buffer - if getbufvar(a:csvfile, 'csv_SplitWindow') && bufnr('') == a:csvfile - call setbufvar(a:header, '&'.a:option, a:value) - endif -endfu + fu! SplitHeaderLine(lines, bang, hor) "{{{3 if exists("b:csv_fixed_width_cols") call Warn("Header does not work with fixed width column!") @@ -973,33 +966,29 @@ if !exists("b:csv_SplitWindow") return endif + exe b:csv_SplitWindow . "wincmd w" + if exists("_stl") + let &l:stl = _stl + endif + if exists("_sbo") + let &sbo = _sbo + endif + setl noscrollbind nocursorbind try - let winnr = winnr() - if winnr == b:csv_SplitWindow || winbufnr(b:csv_SplitWindow) == bufnr('') - " window already closed - return - endif - exe b:csv_SplitWindow . "wincmd w" - if exists("_stl") - let &l:stl = _stl - endif - if exists("_sbo") - let &sbo = _sbo - endif - setl noscrollbind nocursorbind - call CSV_CloseBuffer(bufnr('%')) + noa wincmd c catch /^Vim\%((\a\+)\)\=:E444/ " cannot close last window catch /^Vim\%((\a\+)\)\=:E517/ " buffer already wiped " no-op - finally - unlet! b:csv_SplitWindow - aug CSV_Preview - au! - aug END - aug! CSV_Preview endtry + "pclose! + unlet! b:csv_SplitWindow + aug CSV_Preview + au! + aug END + aug! CSV_Preview endif endfu + fu! SplitHeaderToggle(hor) "{{{3 if !exists("b:csv_SplitWindow") :call SplitHeaderLine(1,0,a:hor) @@ -1007,6 +996,7 @@ :call SplitHeaderLine(1,1,a:hor) endif endfu + " TODO: from here on add logic for fixed-width csv files! fu! MoveCol(forward, line, ...) "{{{3 " Move cursor position upwards/downwards left/right @@ -1128,22 +1118,15 @@ call setpos('.', a) endif endfun + fu! SortComplete(A,L,P) "{{{3 return join(range(1,MaxColumns()),"\n") endfun + fu! Sort(bang, line1, line2, colnr) range "{{{3 - " :Sort command +" :Sort command let wsv = winsaveview() let flag = matchstr(a:colnr, '[nixo]') - call CheckHeaderLine() - let line1 = a:line1 - let line2 = a:line2 - if line1 <= s:csv_fold_headerline - let line1 += s:csv_fold_headerline - endif - if line2 <= s:csv_fold_headerline - let line2 += s:csv_fold_headerline - endif let col = (empty(a:colnr) || a:colnr !~? '\d\+[nixo]\?') ? WColumn() : a:colnr+0 if col != 1 if !exists("b:csv_fixed_width_cols") @@ -1154,10 +1137,11 @@ else let pat= '^' . GetColPat(col,0) endif - exe line1. ','. line2. "sort". (a:bang ? '!' : '') . + exe a:line1. ','. a:line2. "sort". (a:bang ? '!' : '') . \' r'. flag. ' /' . pat . '/' call winrestview(wsv) endfun + fu! CopyCol(reg, col, cnt) "{{{3 " Return Specified Column into register reg let col = a:col == "0" ? WColumn() : a:col+0 @@ -1204,6 +1188,7 @@ return a endif endfu + fu! MoveColumn(start, stop, ...) range "{{{3 " Move column behind dest " Explicitly give the range as argument, @@ -1259,8 +1244,11 @@ call setline(i, join(fields, '')) endfor + call winrestview(wsv) + endfu + fu! AddColumn(start, stop, ...) range "{{{3 " Add new empty column " Explicitly give the range as argument, @@ -1327,8 +1315,10 @@ " comments should by default be skipped (pattern shouldn't match) exe printf("sil %d,%ds/%s/%s/e", a:start, a:stop, pat, subst) endif + call winrestview(wsv) endfu + fu! SumColumn(list) "{{{3 " Sum a list of values, but only consider the digits within each value " parses the digits according to the given format (if none has been @@ -1391,22 +1381,12 @@ endtry call add(result, has("float") ? str2float(nr) : nr+0) endfor - let result = sort(result, s:csv_numeric_sort ? 'n' : 's:CSVSortValues') + let result = sort(result, s:numeric_sort ? 'n' : 's:CSVSortValues') let ind = len(result) > 9 ? 9 : len(result) - if has_key(get(s:, 'additional', {}), 'distinct') && s:additional['distinct'] - if exists("*uniq") - let result=uniq(result) - else - let l = {} - for item in result - let l[item] = get(l, 'item', 0) - endfor - let result = keys(l) - endif - endif return s:additional.ismax ? reverse(result)[:ind] : result[:ind] endif endfu + fu! CountColumn(list) "{{{3 if empty(a:list) return 0 @@ -1424,6 +1404,7 @@ return len(a:list) endif endfu + fu! DoForEachColumn(start, stop, bang) range "{{{3 " Do something for each column, " e.g. generate SQL-Statements, convert to HTML, @@ -1491,7 +1472,9 @@ new call append('$', result) 1d _ + endfun + fu! PrepareDoForEachColumn(start, stop, bang) range"{{{3 let pre = exists("g:csv_pre_convert") ? g:csv_pre_convert : '' let g:csv_pre_convert=input('Pre convert text: ', pre) @@ -1504,6 +1487,7 @@ fu! EscapeValue(val) "{{{3 return '\V' . escape(a:val, '\') endfu + fu! FoldValue(lnum, filter) "{{{3 call CheckHeaderLine() @@ -1524,6 +1508,7 @@ endfor return (result > 0) endfu + fu! PrepareFolding(add, match) "{{{3 if !has("folding") return @@ -1562,7 +1547,7 @@ let col = WColumn() let max = MaxColumns() - let a = GetColumn(line('.'), col, 0) + let a = GetColumn(line('.'), col) let a = ProcessFieldValue(a) let pat = '\%(^\|'.b:delimiter. '\)\@<='.EscapeValue(a). \ '\m\ze\%('.b:delimiter.'\|$\)' @@ -1598,6 +1583,7 @@ endif call winrestview(cpos) endfu + fu! ProcessFieldValue(field) "{{{3 let a = a:field if !exists("b:csv_fixed_width") @@ -1651,7 +1637,7 @@ if s:csv_fold_headerline echo printf("%02d\t% 2s\t%02d\t%10.10s\t%s", \ item.id, (item.match ? '+' : '-'), item.col, - \ substitute(GetColumn(1, item.col, 0), + \ substitute(GetColumn(1, item.col), \ b:col.'$', '', ''), item.orig) else echo printf("%02d\t% 2s\t%02d\t%s", @@ -1670,11 +1656,13 @@ endif endif endfu + fu! SortFilter(a, b) "{{{3 return a:a.id == a:b.id ? 0 : \ a:a.id > a:b.id ? 1 : -1 endfu -fu! GetColumn(line, col, strip) "{{{3 + +fu! GetColumn(line, col) "{{{3 " Return Column content at a:line, a:col let a=getline(a:line) " Filter comments out @@ -1692,12 +1680,9 @@ else let a = matchstr(a, GetColPat(a:col, 0)) endif - if a:strip - return substitute(a, '^\s\+\|\s\+$', '', 'g') - else - return a - endif + return substitute(a, '^\s\+\|\s\+$', '', 'g') endfu + fu! RemoveLastItem(count) "{{{3 for [key,value] in items(b:csv_filter) if value.id == a:count @@ -1705,12 +1690,14 @@ endif endfor endfu + fu! DisableFolding() "{{{3 setl nofen fdm=manual fdc=0 fdl=0 if !get(g:, 'csv_disable_fdt',0) && exists("s:fdt") && exists("s:fcs") exe printf("setl fdt=%s fcs=%s", s:fdt, escape(s:fcs, '\\|')) endif endfu + fu! NumberFormat() "{{{3 let s:nr_format = [',', '.'] if exists("b:csv_thousands_sep") @@ -1720,6 +1707,7 @@ let s:nr_format[1] = b:csv_decimal_sep endif endfu + fu! CheckHeaderLine() "{{{3 if !exists("b:csv_headerline") let s:csv_fold_headerline = 1 @@ -1727,6 +1715,7 @@ let s:csv_fold_headerline = b:csv_headerline endif endfu + fu! AnalyzeColumn(...) "{{{3 let maxcolnr = MaxColumns() if len(a:000) == 1 @@ -1755,7 +1744,7 @@ let res[item]+=1 endfor - let max_items = reverse(sort(values(res), s:csv_numeric_sort ? 'n' : 's:CSVSortValues')) + let max_items = reverse(sort(values(res), s:numeric_sort ? 'n' : 's:CSVSortValues')) " What about the minimum 5 items? let count_items = keys(res) if len(max_items) > 5 @@ -1797,13 +1786,10 @@ endfor endfor echo printf("%s", repeat('=', strdisplaywidth(title))) - if &columns > 40 - echo printf("different values in column %d: %d", colnr, len(count_items)) - else - echo printf("different values: %d", len(count_items)) - endif + echo printf("different values: %d", len(count_items)) unlet max_items endfunc + fu! Vertfold(bang, col) "{{{3 if a:bang do Syntax @@ -1834,26 +1820,26 @@ exe "syn match CSVFold /" . pat . "/ conceal cchar=+" endif endfu + fu! InitCSVFixedWidth() "{{{3 if !exists("+cc") - call Warn("Command disabled: 'colorcolumn' option not available") + " TODO: make this work with a custom matchadd() command for older + " Vims, that don't have 'colorcolumn' + call Warn("'colorcolumn' option not available") return endif " Turn off syntax highlighting syn clear - let max_line = line('$') > 10 ? 10 : line('$') - let t = getline(1, max_line) - let max_len = max(map(t, 'len(split(v:val, ''\zs''))')) + let max_len = len(split(getline(1), '\zs')) let _cc = &l:cc let &l:cc = 1 redraw! let Dict = {'1': 1} " first column is always the start of a new column let tcc = &l:cc let &l:cc = 1 - echo ", , , , , ?" + echo ", , , , ..." let char=getchar() while 1 - let skip_mess = 0 if char == "\" || char == "\" let tcc = eval('tcc'.(char=="\" ? '-' : '+').'1') if tcc < 0 @@ -1876,39 +1862,24 @@ elseif char == "\" || char == "\n" || char == "\r" " Enter let Dict[tcc] = 1 break - elseif char == char2nr('?') - redraw! - echohl Title - echo "Key\tFunction" - echo "==================" - echohl Normal - echo "\tDefine new column" - echo "\tMove left" - echo "\tMove right" - echo "\tAbort" - echo "\tDelete last column definition" - echo "?\tShow this help\n" - let skip_mess = 1 else - let Dict={} break endif let &l:cc=tcc . (!empty(keys(Dict))? ',' . join(keys(Dict), ','):'') - if !skip_mess - redraw! - echo ", , , , ..." - endif + redraw! + echo ", , , , ..." let char=getchar() endw let b:csv_fixed_width_cols=[] let tcc=0 - let b:csv_fixed_width_cols = sort(keys(Dict), s:csv_numeric_sort ? 'n' : 's:CSVSortValues') - let b:csv_fixed_width = join(sort(keys(Dict), s:csv_numeric_sort ? 'n' : 's:CSVSortValues'), ',') + let b:csv_fixed_width_cols = sort(keys(Dict), s:numeric_sort ? 'n' : 's:CSVSortValues') + let b:csv_fixed_width = join(sort(keys(Dict), s:numeric_sort ? 'n' : 's:CSVSortValues'), ',') call Init(1, line('$')) let &l:cc=_cc redraw! endfu + fu! NewRecord(line1, line2, count) "{{{3 if a:count =~ "\D" call Warn("Invalid count specified") @@ -1943,6 +1914,7 @@ call append(nr, line) endfor endfu + fu! MoveOver(outer) "{{{3 " Move over a field " a:outer means include the delimiter @@ -1978,6 +1950,7 @@ call winrestview(_wsv) let @/ = _s endfu + fu! CSVMappings() "{{{3 call Map('noremap', 'W', ':call MoveCol(1, line("."))') call Map('noremap', '', ':call MoveCol(1, line("."))') @@ -2011,6 +1984,7 @@ call Map('nnoremap', '', '') call Map('nnoremap', '', '') endfu + fu! CommandDefinitions() "{{{3 call LocalCmd("WhatColumn", ':echo WColumn(0)', \ '-bang') @@ -2027,7 +2001,7 @@ call LocalCmd("UnArrangeColumn", \':call PrepUnArrangeCol(, )', \ '-range') - call LocalCmd("CSVInit", ':call Init(,,0)', + call LocalCmd("InitCSV", ':call Init(,,0)', \ '-bang -range=%') call LocalCmd('Header', \ ':call SplitHeaderLine(,0,1)', @@ -2086,6 +2060,7 @@ call LocalCmd('Substitute', ':call SubstituteInColumn(,,)', \ '-nargs=1 -range=%') endfu + fu! Map(map, name, definition, ...) "{{{3 let keyname = substitute(a:name, '[<>]', '', 'g') let expr = (exists("a:1") && a:1 == 'expr' ? '' : '') @@ -2109,6 +2084,7 @@ let b:undo_ftplugin .= "| " . unmap . " " . a:name endif endfu + fu! LocalCmd(name, definition, args) "{{{3 if !exists(':'.a:name) exe "com! -buffer " a:args a:name a:definition @@ -2119,10 +2095,11 @@ call LocalCmd('CSV'.a:name, a:definition, a:args) endif endfu + fu! Menu(enable) "{{{3 if a:enable " Make a menu for the graphical vim - amenu CSV.&Init\ Plugin :CSVInit + amenu CSV.&Init\ Plugin :InitCSV amenu CSV.SetUp\ &fixedwidth\ Cols :CSVFixed amenu CSV.-sep1- amenu &CSV.&Column.&Number :WhatColumn @@ -2149,6 +2126,7 @@ sil! amenu disable CSV endif endfu + fu! SaveOptions(list) "{{{3 let save = {} for item in a:list @@ -2156,6 +2134,7 @@ endfor return save endfu + fu! NewDelimiter(newdelimiter, firstl, lastl) "{{{3 let save = SaveOptions(['ro', 'ma']) if exists("b:csv_fixed_width_cols") @@ -2203,6 +2182,7 @@ endif unlet! _delim endfu + fu! IN(list, value) "{{{3 for item in a:list if item == a:value @@ -2211,6 +2191,7 @@ endfor return 0 endfu + fu! DuplicateRows(columnlist) "{{{3 let duplicates = {} let cnt = 0 @@ -2249,6 +2230,7 @@ fu! CompleteColumnNr(A,L,P) "{{{3 return join(range(1,MaxColumns()), "\n") endfu + fu! CheckDuplicates(list) "{{{3 let string = a:list if string =~ '\d\s\?-\s\?\d' @@ -2258,6 +2240,7 @@ let list=split(string, ',') call DuplicateRows(list) endfu + fu! Transpose(line1, line2) "{{{3 " Note: - Comments will be deleted. " - Does not work with fixed-width columns @@ -2289,7 +2272,7 @@ endif let r = [] for row in range(1,columns) - let field = GetColumn(line, row, 0) + let field = GetColumn(line, row) call add(r, field) endfor call add(matrix, r) @@ -2335,15 +2318,22 @@ unlet! transposed call winrestview(_wsv) endfu + + fu! NrColumns(bang) "{{{3 - try - let cols = empty(a:bang) ? MaxColumns() : MaxColumns(line('.')) - catch - " No column or comment line - call Warn("No valid CSV Column!") - endtry + if !empty(a:bang) + try + let cols = MaxColumns(line('.')) + catch + " No column or comment line + call Warn("No valid CSV Column!") + endtry + else + let cols = MaxColumns() + endif echo cols endfu + fu! Tabularize(bang, first, last) "{{{3 if match(split(&ft, '\.'),'csv') == -1 call Warn("No CSV filetype, aborting!") @@ -2404,8 +2394,6 @@ new call setline(1,content) let b:delimiter=delim - let csv_highlight_column = get(g:, 'csv_highlight_column', '') - unlet! g:csv_highlight_column call Init(1,line('$'), 1) if exists("b:csv_fixed_width_cols") let cols=copy(b:csv_fixed_width_cols) @@ -2478,11 +2466,9 @@ syn clear let &l:ma = _ma - if !empty(csv_highlight_column) - let g:csv_highlight_column = csv_highlight_column - endif call winrestview(_c) endfu + fu! SubstituteInColumn(command, line1, line2) range "{{{3 " Command can be something like 1,2/foobar/foobaz/ to replace in 1 and second column " Command can be something like /foobar/foobaz/ to replace in the current column @@ -2544,20 +2530,6 @@ for colnr in columns let @/ = GetPat(colnr, maxcolnr, cmd[1], 1) while search(@/) - let curpos = getpos('.') - " safety check - if (WColumn() != colnr) - break - endif - if len(split(getline('.'), '\zs')) > curpos[2] && GetCursorChar() is# b:delimiter - " Cursor is on delimiter and next char belongs to the - " next field, skip this match - norm! l - if (WColumn() != colnr) - break - endif - call setpos('.', curpos) - endif exe printf("%d,%ds//%s%s", a:line1, a:line2, cmd[2], (has_flags ? '/'. cmd[3] : '')) if !has_flags || (has_flags && cmd[3] !~# 'g') break @@ -2585,6 +2557,7 @@ call call('setreg', _search) endtry endfu + fu! ColumnMode() "{{{3 let mode = mode() if mode =~# 'R' @@ -2599,30 +2572,20 @@ fu! Timeout(start) "{{{3 return localtime()-a:start < 2 endfu -fu! GetCursorChar() "{{{3 - let register = ['a', getreg('a'), getregtype('a')] - try - norm! v"ay - let s=getreg('a') - return s - finally - call call('setreg', register) - endtry -endfu fu! SameFieldRegion() "{{{3 " visually select the region, that has the same value in the cursor field let col = WColumn() let max = MaxColumns() - let field = GetColumn(line('.'), col, 0) + let field = GetColumn(line('.'), col) let line = line('.') - + let limit = [line, line] " Search upwards and downwards from the current position and find the " limit of the current selection while line > 1 let line -= 1 - if GetColumn(line, col, 0) ==# field + if GetColumn(line, col) ==# field let limit[0] = line else break @@ -2631,7 +2594,7 @@ let line = line('.') while line > 1 && line < line('$') let line += 1 - if GetColumn(line, col, 0) ==# field + if GetColumn(line, col) ==# field let limit[1] = line else break @@ -2639,8 +2602,6 @@ endw exe printf(':norm! %dGV%dG',limit[0],limit[1]) endfu - - fu! CSV_CloseBuffer(buffer) "{{{3 " Setup by SetupAutoCmd autocommand try @@ -2656,6 +2617,7 @@ augroup! CSV_QuitPre endtry endfu + fu! CSV_SetSplitOptions(window) "{{{3 if exists("s:local_stl") " local horizontal statusline @@ -2670,6 +2632,7 @@ endif endif endfun + " Global functions "{{{2 fu! csv#EvalColumn(nr, func, first, last, ...) range "{{{3 " Make sure, the function is called for the correct filetype. @@ -2744,6 +2707,7 @@ call winrestview(save) endtry endfu + " return field index (x,y) with leading/trailing whitespace and trailing " delimiter stripped (only when a:0 is not given) fu! CSVField(x, y, ...) "{{{3 @@ -2781,6 +2745,7 @@ "call setcmdpos(pos) return pat endfu + fu! CSVSum(col, fmt, first, last) "{{{3 let first = a:first let last = a:last @@ -2837,10 +2802,7 @@ fu! CSV_WCol(...) "{{{3 " Needed for airline try - if line('$') == 1 && empty(getline(1)) - " Empty file - return '' - elseif exists("a:1") && (a:1 == 'Name' || a:1 == 1) + if exists("a:1") && (a:1 == 'Name' || a:1 == 1) return printf("%s", WColumn(1)) else return printf(" %d/%d", WColumn(), MaxColumns()) @@ -2861,7 +2823,7 @@ " Vim Modeline " {{{2 " vim: set foldmethod=marker et: doc/ft-csv.txt [[[1 -1923 +1884 *ft-csv.txt* For Vim version 7.4 Last Change: Thu, 15 Jan 2015 Author: Christian Brabandt @@ -3106,9 +3068,6 @@ align the third column and all following columns right align. (Note: decimal aligning might slow down Vim and additionally, if the value is no decimal number it will be right aligned). -If you change the alignment parameter, you need to use the "!" attribute, the -next time you run the |:ArrangeCol| command, otherwise for performance -reasons, it won't be considered. Note, arranging the columns can be very slow on large files or many columns (see |csv-slow| on how to increase performance for this command). For large files, @@ -3165,8 +3124,8 @@ < will delete all columns where the pattern "foobar" matches. - *:CSVInit* -3.8 CSVInit + *:CSVInitCSV* +3.8 InitCSV *InitCSV* ----------- Reinitialize the Plugin. Use this, if you have changed the configuration of the plugin (see |csv-configuration| ). @@ -3779,8 +3738,8 @@ You can let Vim output the 10 maximum/minimum values of a column using the `:CSVMaxCol` command > - :[range]MaxCol [nr][distinct] [/format/] - :[range]MinCol [nr][distinct] [/format/] + :[range]MaxCol [nr] [/format/] + :[range]MinCol [nr] [/format/] This outputs the result of the column within the range given. If no range is given, this will calculate the max value of the whole column. If is not @@ -3805,8 +3764,6 @@ uses the Space as thousands separator and the '.' as decimal separator. -If [distinct] is given, only returns the number of distinct values. - Note, if you Vim is compiled without floating point number format (|+float|), Vim will only aggregate the integer part and therefore won't use the 'y' argument in the /format/ specifier. @@ -4198,10 +4155,6 @@ ------------------------------------------------------ Returns the 10 smallest values for column col. -5.8 CSVAvg(col, fmt, startline, endline) *CSVAvg()* ------------------------------------------------------- -Returns the average value for column col. - ============================================================================== 6. CSV Tips and Tricks *csv-tips* @@ -4344,8 +4297,6 @@ This will evaluate the average of column seven (assuming, line 1 is the header line, which should not be taken into account). - Note: this plugin already defines an average function. - 6.4 Autocommand on opening/closing files *csv-arrange-autocmd* ---------------------------------------- If you want your CSV files to always be displayed like a table, you can @@ -4466,36 +4417,8 @@ https://github.com/chrisbra/csv.vim/issues/60, thanks!) - Make |UnArrangeColumn_CSV| strip leading and trailing whitespace (reported by SuperFluffy at https://github.com/chrisbra/csv.vim/issues/62, thanks!) -- Do not sort headerlines (reported by jungle-booke at https://github.com/chrisbra/csv.vim/issues/63, - thanks!) -- Do not error out in |:ArrangeCol| command, if line does not have that many - columns (reported by SuperFluffy at https://github.com/chrisbra/csv.vim/issues/64, thanks) -- Use |OptionSet|autocommand to adjust window for |CSV_Header| command -- when doing |:ArrangeCol| with bang attribute, unarrange first, so that if - the alignment changed, it will be adjusted accordingly -- Allow distinct keyword for |MaxCol_CSV| and |MinCol_CSV| command (reported - by jungle-boogie at https://github.com/chrisbra/csv.vim/issues/67, thanks!) -- When left-aligning columns, don't add trailing whitespace (reported by - jjaderberg at https://github.com/chrisbra/csv.vim/issues/66, thanks!) -- Do not remove highlighting when calling ":CSVTabularize" (reported by - hyiltiz at https://github.com/chrisbra/csv.vim/issues/70, thanks!) -- Make |:ArrangeCol| respect given headerlines -- when checking Header/comment lines at beginning of file, make sure to escape - the comment pattern correctly. -- use b:csv_headerline variable for checking column name and column numbers - (reported by Werner Freund at https://github.com/chrisbra/csv.vim/issues/78, - thanks!) -- Statusline function could cause a hang in an empty file (reported by Jeet - Sukumaran in issue https://github.com/chrisbra/csv.vim/issues/80, thanks!) -- Wrong headerline highlighting when creating a new file (reported by Jeet - Sukumaran in issue https://github.com/chrisbra/csv.vim/issues/79, thanks!) -- Do not strip leading whitespace, when applying filters (reported by - blubb123muh in https://github.com/chrisbra/csv.vim/issues/87, thanks!) -- display column name on |:Analyze_CSV| command (suggested by indera in - https://github.com/chrisbra/csv.vim/issues/88, thanks!) 0.31 Jan 15, 2015 {{{1 -- supports for Vim 7.3 dropped - fix that H on the very first cell, results in an endless loop (https://github.com/chrisbra/csv.vim/issues/31, reported by lahvak, thanks!) - fix that count for |AddColumn| did not work (according to the documentation) @@ -4786,7 +4709,7 @@ vim:tw=78:ts=8:ft=help:norl:et:fdm=marker:fdl=0 syntax/csv.vim [[[1 -185 +169 " A simple syntax highlighting, simply alternate colors between two " adjacent columns " Init {{{2 @@ -4810,10 +4733,7 @@ echohl Normal endfu -fu! Esc(val, char) "{{{3 - if empty(a:val) - return a:val - endif +fu! Esc(val, char) "{{2 return '\V'.escape(a:val, '\\'.a:char).'\m' endfu @@ -4835,10 +4755,8 @@ " Check Comment setting if !exists("g:csv_comment") let b:csv_cmt = split(&cms, '%s') - elseif match(g:csv_comment, '%s') >= 0 + else let b:csv_cmt = split(g:csv_comment, '%s') - else - let b:csv_cmt = [g:csv_comment] endif @@ -4851,26 +4769,15 @@ " Try a simple highlighting, if the defaults from the ftplugin " don't exist - let s:col = exists("b:col") && !empty(b:col) ? b:col : s:col_def + let s:col = exists("b:col") && !empty(b:col) ? b:col + \ : s:col_def let s:col_end = exists("b:col_end") && !empty(b:col_end) ? b:col_end \ : s:col_def_end let s:del = exists("b:delimiter") && !empty(b:delimiter) ? b:delimiter \ : s:del_def - let s:cmts = b:csv_cmt[0] - let s:cmte = len(b:csv_cmt) == 2 ? b:csv_cmt[1] : '' - " Make the file start at the first actual CSV record (issue #71) - if !exists("b:csv_headerline") - let cmts = Esc(s:cmts, '') - let pattern = '\%^\(\%('.cmts.'.*\n\)\|\%(\s*\n\)\)\+' - let start = search(pattern, 'nWe', 10) - " don't do it, on an empty file - if start > 0 && !empty(getline(start)) - let b:csv_headerline = start+1 - endif - endif - " escape '/' for syn match command - let s:cmts=Esc(s:cmts, '/') - let s:cmte=Esc(s:cmte, '/') + let s:cmts = exists("b:csv_cmt") ? b:csv_cmt[0] : split(&cms, '&s')[0] + let s:cmte = exists("b:csv_cmt") && len(b:csv_cmt) == 2 ? b:csv_cmt[1] + \ : '' if line('$') > 1 && (!exists("b:col") || empty(b:col)) " check for invalid pattern, ftplugin hasn't been loaded yet @@ -4927,8 +4834,8 @@ endfor endif " Comment regions - exe 'syn match CSVComment /'. s:cmts. '.*'. - \ (!empty(s:cmte) ? '\%('. s:cmte. '\)\?' + exe 'syn match CSVComment /'. Esc(s:cmts, '/'). '.*'. + \ (!empty(s:cmte) ? '\%('. Esc(s:cmte, '/'). '\)\?' \: ''). '/' hi def link CSVComment Comment endfun @@ -4978,7 +4885,7 @@ au BufRead,BufNewFile *.csv,*.dat,*.tsv,*.tab set filetype=csv plugin/csv.vim [[[1 -94 +93 if exists('g:loaded_csv') && g:loaded_csv finish endif @@ -5054,11 +4961,10 @@ unlet! b:col_width b:csv_list catch finally - " move back to previous window - noa wincmd p if !empty(indent) - " undo removing the indent - u + " Added one line above a:line1 and several lines below, so need to + " correct the range + exe printf(':sil %d,%ds/^/%s/e', (line1 - 1), (line2 + line('$') - last), indent) endif if has("conceal") let [ &l:lz, &l:syntax, &l:ft, &l:sol, &l:tw, &l:wrap, &l:cole, &l:cocu, &l:fen, &l:fdm, &l:fdl, &l:fdc, &l:fml, &l:fdt, &l:ma, &l:ml] = _a === modified file 'vim/bundle/csv.vim/doc/ft-csv.txt' --- vim/bundle/csv.vim/doc/ft-csv.txt 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/doc/ft-csv.txt 2015-08-25 11:56:54 +0000 @@ -301,8 +301,8 @@ < will delete all columns where the pattern "foobar" matches. - *:CSVInit* -3.8 CSVInit + *:CSVInitCSV* +3.8 InitCSV *InitCSV* ----------- Reinitialize the Plugin. Use this, if you have changed the configuration of the plugin (see |csv-configuration| ). @@ -1334,10 +1334,6 @@ ------------------------------------------------------ Returns the 10 smallest values for column col. -5.8 CSVAvg(col, fmt, startline, endline) *CSVAvg()* ------------------------------------------------------- -Returns the average value for column col. - ============================================================================== 6. CSV Tips and Tricks *csv-tips* @@ -1480,8 +1476,6 @@ This will evaluate the average of column seven (assuming, line 1 is the header line, which should not be taken into account). - Note: this plugin already defines an average function. - 6.4 Autocommand on opening/closing files *csv-arrange-autocmd* ---------------------------------------- If you want your CSV files to always be displayed like a table, you can @@ -1611,24 +1605,6 @@ the alignment changed, it will be adjusted accordingly - Allow distinct keyword for |MaxCol_CSV| and |MinCol_CSV| command (reported by jungle-boogie at https://github.com/chrisbra/csv.vim/issues/67, thanks!) -- When left-aligning columns, don't add trailing whitespace (reported by - jjaderberg at https://github.com/chrisbra/csv.vim/issues/66, thanks!) -- Do not remove highlighting when calling ":CSVTabularize" (reported by - hyiltiz at https://github.com/chrisbra/csv.vim/issues/70, thanks!) -- Make |:ArrangeCol| respect given headerlines -- when checking Header/comment lines at beginning of file, make sure to escape - the comment pattern correctly. -- use b:csv_headerline variable for checking column name and column numbers - (reported by Werner Freund at https://github.com/chrisbra/csv.vim/issues/78, - thanks!) -- Statusline function could cause a hang in an empty file (reported by Jeet - Sukumaran in issue https://github.com/chrisbra/csv.vim/issues/80, thanks!) -- Wrong headerline highlighting when creating a new file (reported by Jeet - Sukumaran in issue https://github.com/chrisbra/csv.vim/issues/79, thanks!) -- Do not strip leading whitespace, when applying filters (reported by - blubb123muh in https://github.com/chrisbra/csv.vim/issues/87, thanks!) -- display column name on |:Analyze_CSV| command (suggested by indera in - https://github.com/chrisbra/csv.vim/issues/88, thanks!) 0.31 Jan 15, 2015 {{{1 - supports for Vim 7.3 dropped === modified file 'vim/bundle/csv.vim/ftplugin/csv.vim' --- vim/bundle/csv.vim/ftplugin/csv.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/ftplugin/csv.vim 2015-08-25 11:56:54 +0000 @@ -29,6 +29,23 @@ return (a:i1+0) == (a:i2+0) ? 0 : (a:i1+0) > (a:i2+0) ? 1 : -1 endfu endif +if !exists("##OptionSet") "{{{2 + " No OptionSet autocommands + fu! CSV_SetSplitOptions(window) "{{{3 + if exists("s:local_stl") + " local horizontal statusline + for opt in items({'&nu': &l:nu, '&rnu': &l:rnu, '&fdc': &fdc}) + if opt[1] != getwinvar(a:window, opt[0]) + call setwinvar(a:window, opt[0], opt[1]) + endif + endfor + " Check statusline (airline might change it) + if getwinvar(a:window, '&l:stl') != s:local_stl + call setwinvar(a:window, '&stl', s:local_stl) + endif + endif + endfun +endif " Function definitions: "{{{1 fu! CSVArrangeCol(first, last, bang, limit) range "{{{2 if &ft =~? 'csv' @@ -148,9 +165,7 @@ " enable CSV Menu call Menu(1) call DisableFolding() - if !exists("b:current_syntax") - silent do Syntax - endif + silent do Syntax unlet! b:csv_start b:csv_end " Remove configuration variables @@ -211,20 +226,20 @@ endfu fu! DoAutoCommands() "{{{3 - " Highlight column, on which the cursor is - if exists("g:csv_highlight_column") && g:csv_highlight_column =~? 'y' - exe "aug CSV_HI".bufnr('') + " Highlight column, on which the cursor is? + if exists("g:csv_highlight_column") && g:csv_highlight_column =~? 'y' && + \ !exists("#CSV_HI#CursorMoved") + aug CSV_HI au! - exe "au CursorMoved HiColumn" - exe "au BufWinLeave HiColumn!" + au CursorMoved HiColumn aug end " Set highlighting for column, on which the cursor is currently HiColumn - else - exe "aug CSV_HI".bufnr('') - exe "au! CursorMoved " + elseif exists("#CSV_HI#CursorMoved") + aug CSV_HI + au! CursorMoved aug end - exe "aug! CSV_HI".bufnr('') + aug! CSV_HI " Remove any existing highlighting HiColumn! endif @@ -258,10 +273,10 @@ elseif a:colnr == a:maxcolnr if !exists("b:csv_fixed_width_cols") return '^' . GetColPat(a:colnr - 1,0) . - \ '\zs' . a:pat . '\ze' . (a:allowmore ? '' : '$') + \ '\zs' . a:pat . '\ze$' else return '\%' . b:csv_fixed_width_cols[-1] . - \ 'c\zs' . a:pat . '\ze' . (a:allowmore ? '' : '$') + \ 'c\zs' . a:pat . '\ze$' endif else " colnr = 1 if !exists("b:csv_fixed_width_cols") @@ -390,11 +405,11 @@ endif endfu fu! HiCol(colnr, bang) "{{{3 + if a:colnr > MaxColumns() && !a:bang + call Warn("There exists no column " . a:colnr) + return + endif if !a:bang - if a:colnr > MaxColumns() - call Warn("There exists no column " . a:colnr) - return - endif if empty(a:colnr) let colnr=WColumn() else @@ -418,6 +433,9 @@ " Additionally, filter all matches, that could have been used earlier let matchlist=getmatches() call filter(matchlist, 'v:val["group"] !~ s:hiGroup') + " remove matches, that come from matchaddpos() + " setmatches() can't handle them. + call filter(matchlist, 'has_key(v:val, "pattern")') call setmatches(matchlist) if a:bang return @@ -469,7 +487,7 @@ " line is empty let line = getline(line('.')-1) else - let line = getline('.') + let line=getline('.') endif " move cursor to end of field "call search(b:col, 'ec', line('.')) @@ -479,7 +497,7 @@ let ret=len(fields) if exists("a:1") && a:1 > 0 " bang attribute: Try to get the column name - let head = split(getline(get(b:, 'csv_headerline', 1)),b:col.'\zs') + let head = split(getline(1),b:col.'\zs') " remove preceeding whitespace if len(head) < ret call Warn("Header has no field ". ret) @@ -507,12 +525,9 @@ let this_col = exists("a:1") "return maximum number of columns in first 10 lines if !exists("b:csv_fixed_width_cols") - let i = this_col ? a:1 : get(b:, 'csv_headerline', 1) + let i = this_col ? a:1 : 1 while 1 let l = getline(i, (this_col ? i : i+10)) - if empty(l) && i >= line('$') - break - endif " Filter comments out let pat = '^\s*\V'. escape(b:csv_cmt[0], '\\') @@ -613,37 +628,12 @@ return endif - let first = a:first - let last = a:last - if exists("b:csv_headerline") - if a:first < b:csv_headerline - let first = b:csv_headerline - endif - if a:last < b:csv_headerline - let last = b:csv_headerline - endif - endif - if first > line('$') - let first=line('$') - endif - if last > line('$') - let last=line('$') - endif - if &vbs - echomsg printf("ArrangeCol Start: %d, End: %d", first, last) - endif - if !exists("b:col_width") " Force recalculation of Column width let row = exists("a:1") ? a:1 : '' call CalculateColumnWidth(row) endif - " abort on empty file - if !len(b:col_width) - call Warn("No column data detected, aborting ArrangeCol command!") - return - endif if &ro " Just in case, to prevent the Warning " Warning: W10: Changing read-only file @@ -654,10 +644,10 @@ endif let s:count = 0 let _stl = &stl - let s:max = (last - first + 1) * len(b:col_width) + let s:max = (a:last - a:first + 1) * len(b:col_width) let s:temp = 0 try - exe "sil". first . ',' . last .'s/' . (b:col) . + exe "sil". a:first . ',' . a:last .'s/' . (b:col) . \ '/\=Columnize(submatch(0))/' . (&gd ? '' : 'g') finally " Clean up variables, that were only needed for Columnize() function @@ -671,7 +661,7 @@ endtry endfu fu! ProgressBar(cnt, max) "{{{3 - if get(g:, 'csv_no_progress', 0) || a:max == 0 + if get(g:, 'csv_no_progress', 0) return endif let width = 40 " max width of progressbar @@ -716,11 +706,6 @@ " does not work with fixed width columns let b:col_width=[] try - if exists("b:csv_headerline") - if line('.') < b:csv_headerline - call cursor(b:csv_headerline,1) - endif - endif let s:max_cols=MaxColumns(line('.')) for i in range(1,s:max_cols) if empty(a:row) @@ -781,7 +766,7 @@ let has_delimiter = (a:field[-1:] is? b:delimiter) if align is? 'l' " left-align content - return printf("%-*S%s", width-1, + return printf("%-*S%s", width+1 , \ (has_delimiter ? a:field[:-2] : a:field), \ (has_delimiter ? b:delimiter : ' ')) elseif align is? 'c' @@ -875,7 +860,6 @@ exe "au OptionSet foldcolumn,number,relativenumber call CSV_SetOption(".a:bufnr. \ ", ".bufnr('%').", expand(''), v:option_new)" endif - exe "au VimResized,FocusLost,FocusGained call CSV_SetSplitOptions(".a:window.")" aug END endfu fu! CSV_SetOption(csvfile, header, option, value) "{{{3 @@ -1557,7 +1541,7 @@ let col = WColumn() let max = MaxColumns() - let a = GetColumn(line('.'), col, 0) + let a = GetColumn(line('.'), col) let a = ProcessFieldValue(a) let pat = '\%(^\|'.b:delimiter. '\)\@<='.EscapeValue(a). \ '\m\ze\%('.b:delimiter.'\|$\)' @@ -1646,7 +1630,7 @@ if s:csv_fold_headerline echo printf("%02d\t% 2s\t%02d\t%10.10s\t%s", \ item.id, (item.match ? '+' : '-'), item.col, - \ substitute(GetColumn(1, item.col, 0), + \ substitute(GetColumn(1, item.col), \ b:col.'$', '', ''), item.orig) else echo printf("%02d\t% 2s\t%02d\t%s", @@ -1669,7 +1653,7 @@ return a:a.id == a:b.id ? 0 : \ a:a.id > a:b.id ? 1 : -1 endfu -fu! GetColumn(line, col, strip) "{{{3 +fu! GetColumn(line, col) "{{{3 " Return Column content at a:line, a:col let a=getline(a:line) " Filter comments out @@ -1687,11 +1671,7 @@ else let a = matchstr(a, GetColPat(a:col, 0)) endif - if a:strip - return substitute(a, '^\s\+\|\s\+$', '', 'g') - else - return a - endif + return substitute(a, '^\s\+\|\s\+$', '', 'g') endfu fu! RemoveLastItem(count) "{{{3 for [key,value] in items(b:csv_filter) @@ -1792,11 +1772,7 @@ endfor endfor echo printf("%s", repeat('=', strdisplaywidth(title))) - if &columns > 40 - echo printf("different values in column %d: %d", colnr, len(count_items)) - else - echo printf("different values: %d", len(count_items)) - endif + echo printf("different values: %d", len(count_items)) unlet max_items endfunc fu! Vertfold(bang, col) "{{{3 @@ -1831,24 +1807,23 @@ endfu fu! InitCSVFixedWidth() "{{{3 if !exists("+cc") - call Warn("Command disabled: 'colorcolumn' option not available") + " TODO: make this work with a custom matchadd() command for older + " Vims, that don't have 'colorcolumn' + call Warn("'colorcolumn' option not available") return endif " Turn off syntax highlighting syn clear - let max_line = line('$') > 10 ? 10 : line('$') - let t = getline(1, max_line) - let max_len = max(map(t, 'len(split(v:val, ''\zs''))')) + let max_len = len(split(getline(1), '\zs')) let _cc = &l:cc let &l:cc = 1 redraw! let Dict = {'1': 1} " first column is always the start of a new column let tcc = &l:cc let &l:cc = 1 - echo ", , , , , ?" + echo ", , , , ..." let char=getchar() while 1 - let skip_mess = 0 if char == "\" || char == "\" let tcc = eval('tcc'.(char=="\" ? '-' : '+').'1') if tcc < 0 @@ -1871,28 +1846,12 @@ elseif char == "\" || char == "\n" || char == "\r" " Enter let Dict[tcc] = 1 break - elseif char == char2nr('?') - redraw! - echohl Title - echo "Key\tFunction" - echo "==================" - echohl Normal - echo "\tDefine new column" - echo "\tMove left" - echo "\tMove right" - echo "\tAbort" - echo "\tDelete last column definition" - echo "?\tShow this help\n" - let skip_mess = 1 else - let Dict={} break endif let &l:cc=tcc . (!empty(keys(Dict))? ',' . join(keys(Dict), ','):'') - if !skip_mess - redraw! - echo ", , , , ..." - endif + redraw! + echo ", , , , ..." let char=getchar() endw let b:csv_fixed_width_cols=[] @@ -2022,7 +1981,7 @@ call LocalCmd("UnArrangeColumn", \':call PrepUnArrangeCol(, )', \ '-range') - call LocalCmd("CSVInit", ':call Init(,,0)', + call LocalCmd("InitCSV", ':call Init(,,0)', \ '-bang -range=%') call LocalCmd('Header', \ ':call SplitHeaderLine(,0,1)', @@ -2117,7 +2076,7 @@ fu! Menu(enable) "{{{3 if a:enable " Make a menu for the graphical vim - amenu CSV.&Init\ Plugin :CSVInit + amenu CSV.&Init\ Plugin :InitCSV amenu CSV.SetUp\ &fixedwidth\ Cols :CSVFixed amenu CSV.-sep1- amenu &CSV.&Column.&Number :WhatColumn @@ -2284,7 +2243,7 @@ endif let r = [] for row in range(1,columns) - let field = GetColumn(line, row, 0) + let field = GetColumn(line, row) call add(r, field) endfor call add(matrix, r) @@ -2399,8 +2358,6 @@ new call setline(1,content) let b:delimiter=delim - let csv_highlight_column = get(g:, 'csv_highlight_column', '') - unlet! g:csv_highlight_column call Init(1,line('$'), 1) if exists("b:csv_fixed_width_cols") let cols=copy(b:csv_fixed_width_cols) @@ -2473,9 +2430,6 @@ syn clear let &l:ma = _ma - if !empty(csv_highlight_column) - let g:csv_highlight_column = csv_highlight_column - endif call winrestview(_c) endfu fu! SubstituteInColumn(command, line1, line2) range "{{{3 @@ -2539,20 +2493,6 @@ for colnr in columns let @/ = GetPat(colnr, maxcolnr, cmd[1], 1) while search(@/) - let curpos = getpos('.') - " safety check - if (WColumn() != colnr) - break - endif - if len(split(getline('.'), '\zs')) > curpos[2] && GetCursorChar() is# b:delimiter - " Cursor is on delimiter and next char belongs to the - " next field, skip this match - norm! l - if (WColumn() != colnr) - break - endif - call setpos('.', curpos) - endif exe printf("%d,%ds//%s%s", a:line1, a:line2, cmd[2], (has_flags ? '/'. cmd[3] : '')) if !has_flags || (has_flags && cmd[3] !~# 'g') break @@ -2594,30 +2534,19 @@ fu! Timeout(start) "{{{3 return localtime()-a:start < 2 endfu -fu! GetCursorChar() "{{{3 - let register = ['a', getreg('a'), getregtype('a')] - try - norm! v"ay - let s=getreg('a') - return s - finally - call call('setreg', register) - endtry -endfu - fu! SameFieldRegion() "{{{3 " visually select the region, that has the same value in the cursor field let col = WColumn() let max = MaxColumns() - let field = GetColumn(line('.'), col, 0) + let field = GetColumn(line('.'), col) let line = line('.') - + let limit = [line, line] " Search upwards and downwards from the current position and find the " limit of the current selection while line > 1 let line -= 1 - if GetColumn(line, col, 0) ==# field + if GetColumn(line, col) ==# field let limit[0] = line else break @@ -2626,7 +2555,7 @@ let line = line('.') while line > 1 && line < line('$') let line += 1 - if GetColumn(line, col, 0) ==# field + if GetColumn(line, col) ==# field let limit[1] = line else break @@ -2634,8 +2563,6 @@ endw exe printf(':norm! %dGV%dG',limit[0],limit[1]) endfu - - fu! CSV_CloseBuffer(buffer) "{{{3 " Setup by SetupAutoCmd autocommand try @@ -2651,20 +2578,6 @@ augroup! CSV_QuitPre endtry endfu -fu! CSV_SetSplitOptions(window) "{{{3 - if exists("s:local_stl") - " local horizontal statusline - for opt in items({'&nu': &l:nu, '&rnu': &l:rnu, '&fdc': &fdc}) - if opt[1] != getwinvar(a:window, opt[0]) - call setwinvar(a:window, opt[0], opt[1]) - endif - endfor - " Check statusline (airline might change it) - if getwinvar(a:window, '&l:stl') != s:local_stl - call setwinvar(a:window, '&stl', s:local_stl) - endif - endif -endfun " Global functions "{{{2 fu! csv#EvalColumn(nr, func, first, last, ...) range "{{{3 " Make sure, the function is called for the correct filetype. @@ -2832,10 +2745,7 @@ fu! CSV_WCol(...) "{{{3 " Needed for airline try - if line('$') == 1 && empty(getline(1)) - " Empty file - return '' - elseif exists("a:1") && (a:1 == 'Name' || a:1 == 1) + if exists("a:1") && (a:1 == 'Name' || a:1 == 1) return printf("%s", WColumn(1)) else return printf(" %d/%d", WColumn(), MaxColumns()) === modified file 'vim/bundle/csv.vim/plugin/csv.vim' --- vim/bundle/csv.vim/plugin/csv.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/plugin/csv.vim 2015-02-13 09:59:55 +0000 @@ -73,11 +73,10 @@ unlet! b:col_width b:csv_list catch finally - " move back to previous window - noa wincmd p if !empty(indent) - " undo removing the indent - u + " Added one line above a:line1 and several lines below, so need to + " correct the range + exe printf(':sil %d,%ds/^/%s/e', (line1 - 1), (line2 + line('$') - last), indent) endif if has("conceal") let [ &l:lz, &l:syntax, &l:ft, &l:sol, &l:tw, &l:wrap, &l:cole, &l:cocu, &l:fen, &l:fdm, &l:fdl, &l:fdc, &l:fml, &l:fdt, &l:ma, &l:ml] = _a === modified file 'vim/bundle/csv.vim/syntax/csv.vim' --- vim/bundle/csv.vim/syntax/csv.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/syntax/csv.vim 2015-08-25 11:56:54 +0000 @@ -21,10 +21,7 @@ echohl Normal endfu -fu! Esc(val, char) "{{{3 - if empty(a:val) - return a:val - endif +fu! Esc(val, char) "{{2 return '\V'.escape(a:val, '\\'.a:char).'\m' endfu @@ -46,10 +43,8 @@ " Check Comment setting if !exists("g:csv_comment") let b:csv_cmt = split(&cms, '%s') - elseif match(g:csv_comment, '%s') >= 0 + else let b:csv_cmt = split(g:csv_comment, '%s') - else - let b:csv_cmt = [g:csv_comment] endif @@ -62,26 +57,15 @@ " Try a simple highlighting, if the defaults from the ftplugin " don't exist - let s:col = exists("b:col") && !empty(b:col) ? b:col : s:col_def + let s:col = exists("b:col") && !empty(b:col) ? b:col + \ : s:col_def let s:col_end = exists("b:col_end") && !empty(b:col_end) ? b:col_end \ : s:col_def_end let s:del = exists("b:delimiter") && !empty(b:delimiter) ? b:delimiter \ : s:del_def - let s:cmts = b:csv_cmt[0] - let s:cmte = len(b:csv_cmt) == 2 ? b:csv_cmt[1] : '' - " Make the file start at the first actual CSV record (issue #71) - if !exists("b:csv_headerline") - let cmts = Esc(s:cmts, '') - let pattern = '\%^\(\%('.cmts.'.*\n\)\|\%(\s*\n\)\)\+' - let start = search(pattern, 'nWe', 10) - " don't do it, on an empty file - if start > 0 && !empty(getline(start)) - let b:csv_headerline = start+1 - endif - endif - " escape '/' for syn match command - let s:cmts=Esc(s:cmts, '/') - let s:cmte=Esc(s:cmte, '/') + let s:cmts = exists("b:csv_cmt") ? b:csv_cmt[0] : split(&cms, '&s')[0] + let s:cmte = exists("b:csv_cmt") && len(b:csv_cmt) == 2 ? b:csv_cmt[1] + \ : '' if line('$') > 1 && (!exists("b:col") || empty(b:col)) " check for invalid pattern, ftplugin hasn't been loaded yet @@ -138,8 +122,8 @@ endfor endif " Comment regions - exe 'syn match CSVComment /'. s:cmts. '.*'. - \ (!empty(s:cmte) ? '\%('. s:cmte. '\)\?' + exe 'syn match CSVComment /'. Esc(s:cmts, '/'). '.*'. + \ (!empty(s:cmte) ? '\%('. Esc(s:cmte, '/'). '\)\?' \: ''). '/' hi def link CSVComment Comment endfun === modified file 'vim/bundle/csv.vim/todo.txt' --- vim/bundle/csv.vim/todo.txt 2016-08-04 08:15:09 +0000 +++ vim/bundle/csv.vim/todo.txt 2015-08-25 11:56:54 +0000 @@ -5,7 +5,6 @@ use csvkit for aligning columns? Should work more efficient/faster for larger csv files (huge csv files can cause OOM on :ArrangeCol) - -> Better use python and let it do the arrange column command - ArrangeColumn collapse command, This should collapse (conceal) overly wide columns so that the columns won't be too wide. === modified file 'vim/bundle/icalendar.vim/.git/config' (properties changed: -x to +x) === modified file 'vim/bundle/icalendar.vim/.git/hooks/applypatch-msg.sample' --- vim/bundle/icalendar.vim/.git/hooks/applypatch-msg.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/icalendar.vim/.git/hooks/applypatch-msg.sample 2015-02-13 10:04:41 +0000 @@ -10,6 +10,6 @@ # To enable this hook, rename this file to "applypatch-msg". . git-sh-setup -commitmsg="$(git rev-parse --git-path hooks/commit-msg)" -test -x "$commitmsg" && exec "$commitmsg" ${1+"$@"} +test -x "$GIT_DIR/hooks/commit-msg" && + exec "$GIT_DIR/hooks/commit-msg" ${1+"$@"} : === modified file 'vim/bundle/icalendar.vim/.git/hooks/pre-applypatch.sample' --- vim/bundle/icalendar.vim/.git/hooks/pre-applypatch.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/icalendar.vim/.git/hooks/pre-applypatch.sample 2015-02-13 10:04:41 +0000 @@ -9,6 +9,6 @@ # To enable this hook, rename this file to "pre-applypatch". . git-sh-setup -precommit="$(git rev-parse --git-path hooks/pre-commit)" -test -x "$precommit" && exec "$precommit" ${1+"$@"} +test -x "$GIT_DIR/hooks/pre-commit" && + exec "$GIT_DIR/hooks/pre-commit" ${1+"$@"} : === modified file 'vim/bundle/icalendar.vim/.git/hooks/pre-push.sample' --- vim/bundle/icalendar.vim/.git/hooks/pre-push.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/icalendar.vim/.git/hooks/pre-push.sample 2015-02-13 10:04:41 +0000 @@ -24,6 +24,7 @@ z40=0000000000000000000000000000000000000000 +IFS=' ' while read local_ref local_sha remote_ref remote_sha do if [ "$local_sha" = $z40 ] === modified file 'vim/bundle/icalendar.vim/.git/hooks/update.sample' --- vim/bundle/icalendar.vim/.git/hooks/update.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/icalendar.vim/.git/hooks/update.sample 2015-02-13 10:04:41 +0000 @@ -1,6 +1,6 @@ #!/bin/sh # -# An example hook script to block unannotated tags from entering. +# An example hook script to blocks unannotated tags from entering. # Called by "git receive-pack" with arguments: refname sha1-old sha1-new # # To enable this hook, rename this file to "update". === modified file 'vim/bundle/icalendar.vim/.git/index' Binary files vim/bundle/icalendar.vim/.git/index 2016-08-04 08:15:09 +0000 and vim/bundle/icalendar.vim/.git/index 2015-08-25 11:56:54 +0000 differ === modified file 'vim/bundle/icalendar.vim/.git/logs/HEAD' --- vim/bundle/icalendar.vim/.git/logs/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/icalendar.vim/.git/logs/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 542fff45385b1b5ad9781b0ad4878ba3b7ee9d5f Jan Pobrislo 1470298360 +0200 clone: from https://github.com/vim-scripts/icalendar.vim.git +0000000000000000000000000000000000000000 542fff45385b1b5ad9781b0ad4878ba3b7ee9d5f Jan Pobrislo 1440501762 +0200 clone: from https://github.com/vim-scripts/icalendar.vim.git === modified file 'vim/bundle/icalendar.vim/.git/logs/refs/heads/master' --- vim/bundle/icalendar.vim/.git/logs/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/icalendar.vim/.git/logs/refs/heads/master 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 542fff45385b1b5ad9781b0ad4878ba3b7ee9d5f Jan Pobrislo 1470298360 +0200 clone: from https://github.com/vim-scripts/icalendar.vim.git +0000000000000000000000000000000000000000 542fff45385b1b5ad9781b0ad4878ba3b7ee9d5f Jan Pobrislo 1440501762 +0200 clone: from https://github.com/vim-scripts/icalendar.vim.git === modified file 'vim/bundle/icalendar.vim/.git/logs/refs/remotes/origin/HEAD' --- vim/bundle/icalendar.vim/.git/logs/refs/remotes/origin/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/icalendar.vim/.git/logs/refs/remotes/origin/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 542fff45385b1b5ad9781b0ad4878ba3b7ee9d5f Jan Pobrislo 1470298360 +0200 clone: from https://github.com/vim-scripts/icalendar.vim.git +0000000000000000000000000000000000000000 542fff45385b1b5ad9781b0ad4878ba3b7ee9d5f Jan Pobrislo 1440501762 +0200 clone: from https://github.com/vim-scripts/icalendar.vim.git === modified file 'vim/bundle/tabular/.git/config' (properties changed: -x to +x) === modified file 'vim/bundle/tabular/.git/hooks/applypatch-msg.sample' --- vim/bundle/tabular/.git/hooks/applypatch-msg.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/hooks/applypatch-msg.sample 2015-02-13 09:59:55 +0000 @@ -10,6 +10,6 @@ # To enable this hook, rename this file to "applypatch-msg". . git-sh-setup -commitmsg="$(git rev-parse --git-path hooks/commit-msg)" -test -x "$commitmsg" && exec "$commitmsg" ${1+"$@"} +test -x "$GIT_DIR/hooks/commit-msg" && + exec "$GIT_DIR/hooks/commit-msg" ${1+"$@"} : === modified file 'vim/bundle/tabular/.git/hooks/pre-applypatch.sample' --- vim/bundle/tabular/.git/hooks/pre-applypatch.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/hooks/pre-applypatch.sample 2015-02-13 09:59:55 +0000 @@ -9,6 +9,6 @@ # To enable this hook, rename this file to "pre-applypatch". . git-sh-setup -precommit="$(git rev-parse --git-path hooks/pre-commit)" -test -x "$precommit" && exec "$precommit" ${1+"$@"} +test -x "$GIT_DIR/hooks/pre-commit" && + exec "$GIT_DIR/hooks/pre-commit" ${1+"$@"} : === modified file 'vim/bundle/tabular/.git/hooks/pre-push.sample' --- vim/bundle/tabular/.git/hooks/pre-push.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/hooks/pre-push.sample 2015-02-13 09:59:55 +0000 @@ -24,6 +24,7 @@ z40=0000000000000000000000000000000000000000 +IFS=' ' while read local_ref local_sha remote_ref remote_sha do if [ "$local_sha" = $z40 ] === modified file 'vim/bundle/tabular/.git/hooks/update.sample' --- vim/bundle/tabular/.git/hooks/update.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/hooks/update.sample 2015-02-13 09:59:55 +0000 @@ -1,6 +1,6 @@ #!/bin/sh # -# An example hook script to block unannotated tags from entering. +# An example hook script to blocks unannotated tags from entering. # Called by "git receive-pack" with arguments: refname sha1-old sha1-new # # To enable this hook, rename this file to "update". === modified file 'vim/bundle/tabular/.git/index' Binary files vim/bundle/tabular/.git/index 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/index 2015-08-25 11:56:54 +0000 differ === modified file 'vim/bundle/tabular/.git/logs/HEAD' --- vim/bundle/tabular/.git/logs/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/logs/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 00e1e7fcdbc6d753e0bc8043e0d2546fa81bf367 Jan Pobrislo 1470298362 +0200 clone: from https://github.com/godlygeek/tabular.git +0000000000000000000000000000000000000000 60f25648814f0695eeb6c1040d97adca93c4e0bb Jan Pobrislo 1440501790 +0200 clone: from https://github.com/godlygeek/tabular.git === modified file 'vim/bundle/tabular/.git/logs/refs/heads/master' --- vim/bundle/tabular/.git/logs/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/logs/refs/heads/master 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 00e1e7fcdbc6d753e0bc8043e0d2546fa81bf367 Jan Pobrislo 1470298362 +0200 clone: from https://github.com/godlygeek/tabular.git +0000000000000000000000000000000000000000 60f25648814f0695eeb6c1040d97adca93c4e0bb Jan Pobrislo 1440501790 +0200 clone: from https://github.com/godlygeek/tabular.git === modified file 'vim/bundle/tabular/.git/logs/refs/remotes/origin/HEAD' --- vim/bundle/tabular/.git/logs/refs/remotes/origin/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/logs/refs/remotes/origin/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 00e1e7fcdbc6d753e0bc8043e0d2546fa81bf367 Jan Pobrislo 1470298362 +0200 clone: from https://github.com/godlygeek/tabular.git +0000000000000000000000000000000000000000 60f25648814f0695eeb6c1040d97adca93c4e0bb Jan Pobrislo 1440501790 +0200 clone: from https://github.com/godlygeek/tabular.git === removed directory 'vim/bundle/tabular/.git/objects/00' === removed file 'vim/bundle/tabular/.git/objects/00/e1e7fcdbc6d753e0bc8043e0d2546fa81bf367' Binary files vim/bundle/tabular/.git/objects/00/e1e7fcdbc6d753e0bc8043e0d2546fa81bf367 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/objects/00/e1e7fcdbc6d753e0bc8043e0d2546fa81bf367 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/tabular/.git/objects/13' === removed file 'vim/bundle/tabular/.git/objects/13/4eebfd763c886d5ace4bf0b1ee22cb96a60704' Binary files vim/bundle/tabular/.git/objects/13/4eebfd763c886d5ace4bf0b1ee22cb96a60704 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/objects/13/4eebfd763c886d5ace4bf0b1ee22cb96a60704 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/tabular/.git/objects/2c' === removed file 'vim/bundle/tabular/.git/objects/2c/c76e9d8b2f661932aef8bdd3c33fd97716eef6' Binary files vim/bundle/tabular/.git/objects/2c/c76e9d8b2f661932aef8bdd3c33fd97716eef6 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/objects/2c/c76e9d8b2f661932aef8bdd3c33fd97716eef6 1970-01-01 00:00:00 +0000 differ === added directory 'vim/bundle/tabular/.git/objects/44' === added file 'vim/bundle/tabular/.git/objects/44/944ed0b194326e22b3a146251974ba5186855f' Binary files vim/bundle/tabular/.git/objects/44/944ed0b194326e22b3a146251974ba5186855f 1970-01-01 00:00:00 +0000 and vim/bundle/tabular/.git/objects/44/944ed0b194326e22b3a146251974ba5186855f 2015-02-13 09:59:55 +0000 differ === added directory 'vim/bundle/tabular/.git/objects/60' === added file 'vim/bundle/tabular/.git/objects/60/6c1cde771464aaf384e962579b3b8c86ba1b80' Binary files vim/bundle/tabular/.git/objects/60/6c1cde771464aaf384e962579b3b8c86ba1b80 1970-01-01 00:00:00 +0000 and vim/bundle/tabular/.git/objects/60/6c1cde771464aaf384e962579b3b8c86ba1b80 2015-02-13 09:59:55 +0000 differ === added file 'vim/bundle/tabular/.git/objects/60/f25648814f0695eeb6c1040d97adca93c4e0bb' --- vim/bundle/tabular/.git/objects/60/f25648814f0695eeb6c1040d97adca93c4e0bb 1970-01-01 00:00:00 +0000 +++ vim/bundle/tabular/.git/objects/60/f25648814f0695eeb6c1040d97adca93c4e0bb 2015-02-13 09:59:55 +0000 @@ -0,0 +1,2 @@ +xMN0FYs";qtj\O\STTNO +;l?JJ3"zҚj];P^MF[8}?3.a'jݠHsmh:4r6M(V>v o+/Jz [RmN2Sf(g%ȅ!tF\vx^x!=\fKӆ=( 1 +H?Pf'l=Lމxpm7#C}O \ No newline at end of file === removed directory 'vim/bundle/tabular/.git/objects/70' === removed file 'vim/bundle/tabular/.git/objects/70/73d20f9a7786958774b38f73f09efcddc73554' Binary files vim/bundle/tabular/.git/objects/70/73d20f9a7786958774b38f73f09efcddc73554 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/objects/70/73d20f9a7786958774b38f73f09efcddc73554 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/tabular/.git/objects/99' === removed file 'vim/bundle/tabular/.git/objects/99/8346fc328d442dffc8a9fd3fadd4f401cc07d9' Binary files vim/bundle/tabular/.git/objects/99/8346fc328d442dffc8a9fd3fadd4f401cc07d9 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/objects/99/8346fc328d442dffc8a9fd3fadd4f401cc07d9 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/tabular/.git/objects/9f' === removed file 'vim/bundle/tabular/.git/objects/9f/88ea90c522099a8b5a36e1b7d9ce93581f1bc9' Binary files vim/bundle/tabular/.git/objects/9f/88ea90c522099a8b5a36e1b7d9ce93581f1bc9 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/objects/9f/88ea90c522099a8b5a36e1b7d9ce93581f1bc9 1970-01-01 00:00:00 +0000 differ === added directory 'vim/bundle/tabular/.git/objects/a0' === added file 'vim/bundle/tabular/.git/objects/a0/5accb088ccdfeac3f63b69001f554ea195701a' Binary files vim/bundle/tabular/.git/objects/a0/5accb088ccdfeac3f63b69001f554ea195701a 1970-01-01 00:00:00 +0000 and vim/bundle/tabular/.git/objects/a0/5accb088ccdfeac3f63b69001f554ea195701a 2015-02-13 09:59:55 +0000 differ === removed directory 'vim/bundle/tabular/.git/objects/a4' === removed file 'vim/bundle/tabular/.git/objects/a4/192ad92ca9ab65dc5404c639b57d8f9cba15d9' Binary files vim/bundle/tabular/.git/objects/a4/192ad92ca9ab65dc5404c639b57d8f9cba15d9 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/objects/a4/192ad92ca9ab65dc5404c639b57d8f9cba15d9 1970-01-01 00:00:00 +0000 differ === added directory 'vim/bundle/tabular/.git/objects/a7' === added file 'vim/bundle/tabular/.git/objects/a7/1e03258d873ccdd8890a4c66ad7681ea3fc77d' Binary files vim/bundle/tabular/.git/objects/a7/1e03258d873ccdd8890a4c66ad7681ea3fc77d 1970-01-01 00:00:00 +0000 and vim/bundle/tabular/.git/objects/a7/1e03258d873ccdd8890a4c66ad7681ea3fc77d 2015-02-13 09:59:55 +0000 differ === added directory 'vim/bundle/tabular/.git/objects/e4' === added file 'vim/bundle/tabular/.git/objects/e4/acc44c0b29a2fe89811c911de2e3717aaa2fc5' --- vim/bundle/tabular/.git/objects/e4/acc44c0b29a2fe89811c911de2e3717aaa2fc5 1970-01-01 00:00:00 +0000 +++ vim/bundle/tabular/.git/objects/e4/acc44c0b29a2fe89811c911de2e3717aaa2fc5 2015-02-13 09:59:55 +0000 @@ -0,0 +1,1 @@ +x+)JMU0d040031QIL*I,+(aX.ǬnsF'OڲWk_ \ No newline at end of file === removed directory 'vim/bundle/tabular/.git/objects/f1' === removed file 'vim/bundle/tabular/.git/objects/f1/363a94b4707b81660ad9a327d4758292a75fab' Binary files vim/bundle/tabular/.git/objects/f1/363a94b4707b81660ad9a327d4758292a75fab 2016-08-04 08:15:09 +0000 and vim/bundle/tabular/.git/objects/f1/363a94b4707b81660ad9a327d4758292a75fab 1970-01-01 00:00:00 +0000 differ === added directory 'vim/bundle/tabular/.git/objects/f8' === added file 'vim/bundle/tabular/.git/objects/f8/08084878142d2aede497ea43cc2022420fd6f4' Binary files vim/bundle/tabular/.git/objects/f8/08084878142d2aede497ea43cc2022420fd6f4 1970-01-01 00:00:00 +0000 and vim/bundle/tabular/.git/objects/f8/08084878142d2aede497ea43cc2022420fd6f4 2015-02-13 09:59:55 +0000 differ === modified file 'vim/bundle/tabular/.git/packed-refs' --- vim/bundle/tabular/.git/packed-refs 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/packed-refs 2015-02-13 09:59:55 +0000 @@ -1,2 +1,2 @@ # pack-refs with: peeled fully-peeled -00e1e7fcdbc6d753e0bc8043e0d2546fa81bf367 refs/remotes/origin/master +60f25648814f0695eeb6c1040d97adca93c4e0bb refs/remotes/origin/master === modified file 'vim/bundle/tabular/.git/refs/heads/master' --- vim/bundle/tabular/.git/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/refs/heads/master 2015-02-13 09:59:55 +0000 @@ -1,1 +1,1 @@ -00e1e7fcdbc6d753e0bc8043e0d2546fa81bf367 +60f25648814f0695eeb6c1040d97adca93c4e0bb === modified file 'vim/bundle/tabular/.git/shallow' --- vim/bundle/tabular/.git/shallow 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/.git/shallow 2015-02-13 09:59:55 +0000 @@ -1,1 +1,1 @@ -00e1e7fcdbc6d753e0bc8043e0d2546fa81bf367 +60f25648814f0695eeb6c1040d97adca93c4e0bb === removed file 'vim/bundle/tabular/LICENSE.md' --- vim/bundle/tabular/LICENSE.md 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/LICENSE.md 1970-01-01 00:00:00 +0000 @@ -1,24 +0,0 @@ -Copyright (c) 2016, Matthew J. Wozniski -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright notice, - this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - * The names of the contributors may not be used to endorse or promote - products derived from this software without specific prior written - permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER ``AS IS'' AND ANY EXPRESS -OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES -OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN -NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, -OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, -EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. === modified file 'vim/bundle/tabular/after/plugin/TabularMaps.vim' --- vim/bundle/tabular/after/plugin/TabularMaps.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/after/plugin/TabularMaps.vim 2015-02-13 09:59:55 +0000 @@ -1,28 +1,3 @@ -" Copyright (c) 2016, Matthew J. Wozniski -" All rights reserved. -" -" Redistribution and use in source and binary forms, with or without -" modification, are permitted provided that the following conditions are met: -" * Redistributions of source code must retain the above copyright notice, -" this list of conditions and the following disclaimer. -" * Redistributions in binary form must reproduce the above copyright -" notice, this list of conditions and the following disclaimer in the -" documentation and/or other materials provided with the distribution. -" * The names of the contributors may not be used to endorse or promote -" products derived from this software without specific prior written -" permission. -" -" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER ``AS IS'' AND ANY EXPRESS -" OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES -" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN -" NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY DIRECT, INDIRECT, -" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -" LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, -" OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -" LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -" NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, -" EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - if !exists(':Tabularize') || get(g:, 'no_default_tabular_maps', 0) finish " Tabular.vim wasn't loaded or the default maps are unwanted endif === modified file 'vim/bundle/tabular/doc/Tabular.txt' --- vim/bundle/tabular/doc/Tabular.txt 2016-08-04 08:15:09 +0000 +++ vim/bundle/tabular/doc/Tabular.txt 2015-02-13 09:59:55 +0000 @@ -38,7 +38,7 @@ interface. It's still a work in progress, and criticisms are welcome. ============================================================================== -2. Walkthrough *tabular-walkthrough* *:Tabularize* +2. Walkthrough *tabular-walkthrough* Tabular's commands are based largely on regular expressions. The basic technique used by Tabular is taking some regex to match field delimiters, === modified file 'vim/bundle/vim-KWEasy/.git/config' (properties changed: -x to +x) === modified file 'vim/bundle/vim-KWEasy/.git/hooks/applypatch-msg.sample' --- vim/bundle/vim-KWEasy/.git/hooks/applypatch-msg.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/hooks/applypatch-msg.sample 2015-02-13 09:59:55 +0000 @@ -10,6 +10,6 @@ # To enable this hook, rename this file to "applypatch-msg". . git-sh-setup -commitmsg="$(git rev-parse --git-path hooks/commit-msg)" -test -x "$commitmsg" && exec "$commitmsg" ${1+"$@"} +test -x "$GIT_DIR/hooks/commit-msg" && + exec "$GIT_DIR/hooks/commit-msg" ${1+"$@"} : === modified file 'vim/bundle/vim-KWEasy/.git/hooks/pre-applypatch.sample' --- vim/bundle/vim-KWEasy/.git/hooks/pre-applypatch.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/hooks/pre-applypatch.sample 2015-02-13 09:59:55 +0000 @@ -9,6 +9,6 @@ # To enable this hook, rename this file to "pre-applypatch". . git-sh-setup -precommit="$(git rev-parse --git-path hooks/pre-commit)" -test -x "$precommit" && exec "$precommit" ${1+"$@"} +test -x "$GIT_DIR/hooks/pre-commit" && + exec "$GIT_DIR/hooks/pre-commit" ${1+"$@"} : === modified file 'vim/bundle/vim-KWEasy/.git/hooks/pre-push.sample' --- vim/bundle/vim-KWEasy/.git/hooks/pre-push.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/hooks/pre-push.sample 2015-02-13 09:59:55 +0000 @@ -24,6 +24,7 @@ z40=0000000000000000000000000000000000000000 +IFS=' ' while read local_ref local_sha remote_ref remote_sha do if [ "$local_sha" = $z40 ] === modified file 'vim/bundle/vim-KWEasy/.git/hooks/update.sample' --- vim/bundle/vim-KWEasy/.git/hooks/update.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/hooks/update.sample 2015-02-13 09:59:55 +0000 @@ -1,6 +1,6 @@ #!/bin/sh # -# An example hook script to block unannotated tags from entering. +# An example hook script to blocks unannotated tags from entering. # Called by "git receive-pack" with arguments: refname sha1-old sha1-new # # To enable this hook, rename this file to "update". === modified file 'vim/bundle/vim-KWEasy/.git/index' Binary files vim/bundle/vim-KWEasy/.git/index 2016-08-04 08:15:09 +0000 and vim/bundle/vim-KWEasy/.git/index 2015-08-25 11:56:54 +0000 differ === modified file 'vim/bundle/vim-KWEasy/.git/logs/HEAD' --- vim/bundle/vim-KWEasy/.git/logs/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/logs/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 b3a76e10c15240ed10ee8e69385cb275ba4c600d Jan Pobrislo 1470298363 +0200 clone: from https://github.com/dahu/vim-KWEasy +0000000000000000000000000000000000000000 3db7e1b38438cdbaeb8080b8f59175228a96748c Jan Pobrislo 1440501794 +0200 clone: from https://github.com/dahu/vim-KWEasy === modified file 'vim/bundle/vim-KWEasy/.git/logs/refs/heads/master' --- vim/bundle/vim-KWEasy/.git/logs/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/logs/refs/heads/master 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 b3a76e10c15240ed10ee8e69385cb275ba4c600d Jan Pobrislo 1470298363 +0200 clone: from https://github.com/dahu/vim-KWEasy +0000000000000000000000000000000000000000 3db7e1b38438cdbaeb8080b8f59175228a96748c Jan Pobrislo 1440501794 +0200 clone: from https://github.com/dahu/vim-KWEasy === modified file 'vim/bundle/vim-KWEasy/.git/logs/refs/remotes/origin/HEAD' --- vim/bundle/vim-KWEasy/.git/logs/refs/remotes/origin/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/logs/refs/remotes/origin/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 b3a76e10c15240ed10ee8e69385cb275ba4c600d Jan Pobrislo 1470298363 +0200 clone: from https://github.com/dahu/vim-KWEasy +0000000000000000000000000000000000000000 3db7e1b38438cdbaeb8080b8f59175228a96748c Jan Pobrislo 1440501794 +0200 clone: from https://github.com/dahu/vim-KWEasy === added directory 'vim/bundle/vim-KWEasy/.git/objects/34' === added file 'vim/bundle/vim-KWEasy/.git/objects/34/e6cb8517669c4391d9ce60c9f723fef53a2409' Binary files vim/bundle/vim-KWEasy/.git/objects/34/e6cb8517669c4391d9ce60c9f723fef53a2409 1970-01-01 00:00:00 +0000 and vim/bundle/vim-KWEasy/.git/objects/34/e6cb8517669c4391d9ce60c9f723fef53a2409 2015-02-13 09:59:55 +0000 differ === added directory 'vim/bundle/vim-KWEasy/.git/objects/3d' === added file 'vim/bundle/vim-KWEasy/.git/objects/3d/b7e1b38438cdbaeb8080b8f59175228a96748c' --- vim/bundle/vim-KWEasy/.git/objects/3d/b7e1b38438cdbaeb8080b8f59175228a96748c 1970-01-01 00:00:00 +0000 +++ vim/bundle/vim-KWEasy/.git/objects/3d/b7e1b38438cdbaeb8080b8f59175228a96748c 2015-02-13 09:59:55 +0000 @@ -0,0 +1,1 @@ +xK0D)z# BMZV+6Xrhˋ~a6E*jXJX&:+:DdqD>QH6@ e]9#.9*ڸa[?6Fx4OY \ No newline at end of file === removed directory 'vim/bundle/vim-KWEasy/.git/objects/74' === removed file 'vim/bundle/vim-KWEasy/.git/objects/74/d7497f6a704d32270e9e7a05c1e31911ccd46e' Binary files vim/bundle/vim-KWEasy/.git/objects/74/d7497f6a704d32270e9e7a05c1e31911ccd46e 2016-08-04 08:15:09 +0000 and vim/bundle/vim-KWEasy/.git/objects/74/d7497f6a704d32270e9e7a05c1e31911ccd46e 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/vim-KWEasy/.git/objects/7d' === removed file 'vim/bundle/vim-KWEasy/.git/objects/7d/b115e6e6780661a0bac75518506f57c0c7f65c' Binary files vim/bundle/vim-KWEasy/.git/objects/7d/b115e6e6780661a0bac75518506f57c0c7f65c 2016-08-04 08:15:09 +0000 and vim/bundle/vim-KWEasy/.git/objects/7d/b115e6e6780661a0bac75518506f57c0c7f65c 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/vim-KWEasy/.git/objects/83' === removed file 'vim/bundle/vim-KWEasy/.git/objects/83/48011eabab16ed08009794cd8c31a84e03bc1b' Binary files vim/bundle/vim-KWEasy/.git/objects/83/48011eabab16ed08009794cd8c31a84e03bc1b 2016-08-04 08:15:09 +0000 and vim/bundle/vim-KWEasy/.git/objects/83/48011eabab16ed08009794cd8c31a84e03bc1b 1970-01-01 00:00:00 +0000 differ === removed directory 'vim/bundle/vim-KWEasy/.git/objects/84' === removed file 'vim/bundle/vim-KWEasy/.git/objects/84/c7e82db9863717c31e6e2c3160f2298c56e80f' Binary files vim/bundle/vim-KWEasy/.git/objects/84/c7e82db9863717c31e6e2c3160f2298c56e80f 2016-08-04 08:15:09 +0000 and vim/bundle/vim-KWEasy/.git/objects/84/c7e82db9863717c31e6e2c3160f2298c56e80f 1970-01-01 00:00:00 +0000 differ === added directory 'vim/bundle/vim-KWEasy/.git/objects/90' === added file 'vim/bundle/vim-KWEasy/.git/objects/90/dcbf63541f975316cbb5a6ed8944e2741927ce' Binary files vim/bundle/vim-KWEasy/.git/objects/90/dcbf63541f975316cbb5a6ed8944e2741927ce 1970-01-01 00:00:00 +0000 and vim/bundle/vim-KWEasy/.git/objects/90/dcbf63541f975316cbb5a6ed8944e2741927ce 2015-02-13 09:59:55 +0000 differ === added file 'vim/bundle/vim-KWEasy/.git/objects/92/dde59fe228bd81a10f3676d35b756a96e2046b' --- vim/bundle/vim-KWEasy/.git/objects/92/dde59fe228bd81a10f3676d35b756a96e2046b 1970-01-01 00:00:00 +0000 +++ vim/bundle/vim-KWEasy/.git/objects/92/dde59fe228bd81a10f3676d35b756a96e2046b 2015-02-13 09:59:55 +0000 @@ -0,0 +1,19 @@ +xYs۸_eLdrw}\i@$$1&AZv^{@=l)3EvLrJON.x9Uy3ʚ~m:#RBg)LɔT:3Y4tRK:SdW?Y45]Li ARYG,-wdif! kIyY^*Bzj.GÓyWD*lHKIBn[D8 K}7 +SX F c*3X6e+ShN?'6z ^/2MP4$Dj-SQZ˜[kr̲2OM邞 {F#,!,Jdqv~[>ЯnW~a@^K x٧QRy k3z.{Iƽ8;~;`γ5罧ǓӳnoE4Y:BEޅrQu8=L%O1D,G*[CRNL[Uȗأp9G6fMf##SGQg pC&%ke& +)!SՖEZ|`AYgϛYiSs-dc}GYr*L:[@ I!k1>EV} DlA4Wd~%)ŀ6֙QHeݕ\}X r(Ǜ[j9?j +ldQ]3";ЄsB7nuG[T_ l%ɢ2wؑ+M_gU 65aXlY?ngKq)pA^AZ(`5{+e1c+GDκRP)a(*4A{FL5ZʊD\P>(elBh;VYx6$N>8+mg;s@}%o + % &DZ +'hDC0J.Bwx#6~2ḊY`nmam,8ޝVl +I ~Ojg8|6 +6%k++o? nWq\vo$y-e@9| ţmc1& +\ܵ#i 8̖)r3mf1>U߭f'K"AʺQe6dK|K #asbS)G/sOrUrJ1 +hSFbsEz)*5DT@1@hCEn>Z`8`.U_G^IMJ4Z`m#c61Fm\1aǃwu}3} +(޻4E:*2\5*YDp,y:_/ lMdUT"S-;䛬6- +E0|_Y%7{>u[ 'a$qkV$NMNȪZW/#5mўKG5ؾ|c2ߣGeLp9+ +ֺCq/:)qo̓e JnKJvmЖ{nk`x|n?lОj[O4kMQ"up[D`;@32 ~xؾe!C2<A},[+[lvnIi]jnXoÝNp<ݙXoq(bu +㸻tK+|YFX "]b t9b:xz'S*y[1Y\[ +"q/C|tتM9ogMmcaop٦-H(X_yyF*Bq \>oSܖA̯(~zKKGڷo}^qyNoES]|E5K4[V^cUq@"ۛͩHpJƭ<M 번iı~r +trt'b x \ No newline at end of file === added directory 'vim/bundle/vim-KWEasy/.git/objects/a6' === added file 'vim/bundle/vim-KWEasy/.git/objects/a6/c2a1e38e70393409607c4536ed331f0d78c142' Binary files vim/bundle/vim-KWEasy/.git/objects/a6/c2a1e38e70393409607c4536ed331f0d78c142 1970-01-01 00:00:00 +0000 and vim/bundle/vim-KWEasy/.git/objects/a6/c2a1e38e70393409607c4536ed331f0d78c142 2015-02-13 09:59:55 +0000 differ === removed directory 'vim/bundle/vim-KWEasy/.git/objects/b3' === removed file 'vim/bundle/vim-KWEasy/.git/objects/b3/a76e10c15240ed10ee8e69385cb275ba4c600d' --- vim/bundle/vim-KWEasy/.git/objects/b3/a76e10c15240ed10ee8e69385cb275ba4c600d 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/objects/b3/a76e10c15240ed10ee8e69385cb275ba4c600d 1970-01-01 00:00:00 +0000 @@ -1,2 +0,0 @@ -xN0 9),q]S ! qqJYTbyz -;DZxx>CEN"kmĊEդ<1Q6dHI}q$)hQguUIbᆝM]6]h͇9#t]ʇ5Q[:HyݚB#*7%^UeZjeA*i/p\|dl!yOi)U ^ޟi9 %><:q b)s4OHx \ No newline at end of file === added directory 'vim/bundle/vim-KWEasy/.git/objects/bc' === added file 'vim/bundle/vim-KWEasy/.git/objects/bc/0880d7643444ea59a183e9a4eabf36aa7ff904' Binary files vim/bundle/vim-KWEasy/.git/objects/bc/0880d7643444ea59a183e9a4eabf36aa7ff904 1970-01-01 00:00:00 +0000 and vim/bundle/vim-KWEasy/.git/objects/bc/0880d7643444ea59a183e9a4eabf36aa7ff904 2015-02-13 09:59:55 +0000 differ === removed directory 'vim/bundle/vim-KWEasy/.git/objects/e5' === removed file 'vim/bundle/vim-KWEasy/.git/objects/e5/371e51aaea1ed6747aec4281f704d851e30869' Binary files vim/bundle/vim-KWEasy/.git/objects/e5/371e51aaea1ed6747aec4281f704d851e30869 2016-08-04 08:15:09 +0000 and vim/bundle/vim-KWEasy/.git/objects/e5/371e51aaea1ed6747aec4281f704d851e30869 1970-01-01 00:00:00 +0000 differ === modified file 'vim/bundle/vim-KWEasy/.git/packed-refs' --- vim/bundle/vim-KWEasy/.git/packed-refs 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/packed-refs 2015-02-13 09:59:55 +0000 @@ -1,2 +1,2 @@ # pack-refs with: peeled fully-peeled -b3a76e10c15240ed10ee8e69385cb275ba4c600d refs/remotes/origin/master +3db7e1b38438cdbaeb8080b8f59175228a96748c refs/remotes/origin/master === modified file 'vim/bundle/vim-KWEasy/.git/refs/heads/master' --- vim/bundle/vim-KWEasy/.git/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/refs/heads/master 2015-02-13 09:59:55 +0000 @@ -1,1 +1,1 @@ -b3a76e10c15240ed10ee8e69385cb275ba4c600d +3db7e1b38438cdbaeb8080b8f59175228a96748c === modified file 'vim/bundle/vim-KWEasy/.git/shallow' --- vim/bundle/vim-KWEasy/.git/shallow 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/.git/shallow 2015-02-13 09:59:55 +0000 @@ -1,1 +1,1 @@ -b3a76e10c15240ed10ee8e69385cb275ba4c600d +3db7e1b38438cdbaeb8080b8f59175228a96748c === modified file 'vim/bundle/vim-KWEasy/doc/kweasy.txt' --- vim/bundle/vim-KWEasy/doc/kweasy.txt 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/doc/kweasy.txt 2015-02-13 09:59:55 +0000 @@ -56,13 +56,6 @@ nmap F KweasySearch < -Additionally you can use the KWEasySearchCmd() function as mapping in -command mode to search with current content of commandline. Handy in -combination with 'incsearch' option: -> - cnoremap KWEasySearchCmd() -< - ------------------------------------------------------------------------------ *'kweasy_nolist'* *'g:kweasy_nolist'* === modified file 'vim/bundle/vim-KWEasy/plugin/kweasy.vim' --- vim/bundle/vim-KWEasy/plugin/kweasy.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-KWEasy/plugin/kweasy.vim 2015-02-13 09:59:55 +0000 @@ -223,11 +223,6 @@ endif endfunction -function! KWEasySearchCmd() - let g:kweasy_cmdline = getcmdline() - return "\e:call KWEasySearch(g:kweasy_cmdline)\r" -endfunction - " Maps: {{{1 " nnoremap KweasyJump :call KWEasy(getchar()) nnoremap KweasyJump :call KWEasyJump(getchar()) === modified file 'vim/bundle/vim-eunuch/.git/config' (properties changed: -x to +x) === modified file 'vim/bundle/vim-eunuch/.git/hooks/applypatch-msg.sample' --- vim/bundle/vim-eunuch/.git/hooks/applypatch-msg.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/hooks/applypatch-msg.sample 2015-02-13 09:59:55 +0000 @@ -10,6 +10,6 @@ # To enable this hook, rename this file to "applypatch-msg". . git-sh-setup -commitmsg="$(git rev-parse --git-path hooks/commit-msg)" -test -x "$commitmsg" && exec "$commitmsg" ${1+"$@"} +test -x "$GIT_DIR/hooks/commit-msg" && + exec "$GIT_DIR/hooks/commit-msg" ${1+"$@"} : === modified file 'vim/bundle/vim-eunuch/.git/hooks/pre-applypatch.sample' --- vim/bundle/vim-eunuch/.git/hooks/pre-applypatch.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/hooks/pre-applypatch.sample 2015-02-13 09:59:55 +0000 @@ -9,6 +9,6 @@ # To enable this hook, rename this file to "pre-applypatch". . git-sh-setup -precommit="$(git rev-parse --git-path hooks/pre-commit)" -test -x "$precommit" && exec "$precommit" ${1+"$@"} +test -x "$GIT_DIR/hooks/pre-commit" && + exec "$GIT_DIR/hooks/pre-commit" ${1+"$@"} : === modified file 'vim/bundle/vim-eunuch/.git/hooks/pre-push.sample' --- vim/bundle/vim-eunuch/.git/hooks/pre-push.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/hooks/pre-push.sample 2015-02-13 09:59:55 +0000 @@ -24,6 +24,7 @@ z40=0000000000000000000000000000000000000000 +IFS=' ' while read local_ref local_sha remote_ref remote_sha do if [ "$local_sha" = $z40 ] === modified file 'vim/bundle/vim-eunuch/.git/hooks/update.sample' --- vim/bundle/vim-eunuch/.git/hooks/update.sample 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/hooks/update.sample 2015-02-13 09:59:55 +0000 @@ -1,6 +1,6 @@ #!/bin/sh # -# An example hook script to block unannotated tags from entering. +# An example hook script to blocks unannotated tags from entering. # Called by "git receive-pack" with arguments: refname sha1-old sha1-new # # To enable this hook, rename this file to "update". === modified file 'vim/bundle/vim-eunuch/.git/index' Binary files vim/bundle/vim-eunuch/.git/index 2016-08-04 08:15:09 +0000 and vim/bundle/vim-eunuch/.git/index 2015-08-25 11:56:54 +0000 differ === modified file 'vim/bundle/vim-eunuch/.git/logs/HEAD' --- vim/bundle/vim-eunuch/.git/logs/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/logs/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 5ee2b82b565e6c6d80f1cb7735c78f66a159b198 Jan Pobrislo 1470298362 +0200 clone: from git://github.com/tpope/vim-eunuch.git +0000000000000000000000000000000000000000 eb8b2d54fb537ee93f762f6331265057a3f69727 Jan Pobrislo 1440501790 +0200 clone: from git://github.com/tpope/vim-eunuch.git === modified file 'vim/bundle/vim-eunuch/.git/logs/refs/heads/master' --- vim/bundle/vim-eunuch/.git/logs/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/logs/refs/heads/master 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 5ee2b82b565e6c6d80f1cb7735c78f66a159b198 Jan Pobrislo 1470298362 +0200 clone: from git://github.com/tpope/vim-eunuch.git +0000000000000000000000000000000000000000 eb8b2d54fb537ee93f762f6331265057a3f69727 Jan Pobrislo 1440501790 +0200 clone: from git://github.com/tpope/vim-eunuch.git === modified file 'vim/bundle/vim-eunuch/.git/logs/refs/remotes/origin/HEAD' --- vim/bundle/vim-eunuch/.git/logs/refs/remotes/origin/HEAD 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/logs/refs/remotes/origin/HEAD 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -0000000000000000000000000000000000000000 5ee2b82b565e6c6d80f1cb7735c78f66a159b198 Jan Pobrislo 1470298362 +0200 clone: from git://github.com/tpope/vim-eunuch.git +0000000000000000000000000000000000000000 eb8b2d54fb537ee93f762f6331265057a3f69727 Jan Pobrislo 1440501790 +0200 clone: from git://github.com/tpope/vim-eunuch.git === added file 'vim/bundle/vim-eunuch/.git/objects/pack/pack-7fe2de0377d4f40c95609d3ec288d75a7bda600d.idx' Binary files vim/bundle/vim-eunuch/.git/objects/pack/pack-7fe2de0377d4f40c95609d3ec288d75a7bda600d.idx 1970-01-01 00:00:00 +0000 and vim/bundle/vim-eunuch/.git/objects/pack/pack-7fe2de0377d4f40c95609d3ec288d75a7bda600d.idx 2015-08-25 11:56:54 +0000 differ === added file 'vim/bundle/vim-eunuch/.git/objects/pack/pack-7fe2de0377d4f40c95609d3ec288d75a7bda600d.pack' Binary files vim/bundle/vim-eunuch/.git/objects/pack/pack-7fe2de0377d4f40c95609d3ec288d75a7bda600d.pack 1970-01-01 00:00:00 +0000 and vim/bundle/vim-eunuch/.git/objects/pack/pack-7fe2de0377d4f40c95609d3ec288d75a7bda600d.pack 2015-08-25 11:56:54 +0000 differ === removed file 'vim/bundle/vim-eunuch/.git/objects/pack/pack-f567257bb43d7669bdd07e5213f5287056754216.idx' Binary files vim/bundle/vim-eunuch/.git/objects/pack/pack-f567257bb43d7669bdd07e5213f5287056754216.idx 2016-08-04 08:15:09 +0000 and vim/bundle/vim-eunuch/.git/objects/pack/pack-f567257bb43d7669bdd07e5213f5287056754216.idx 1970-01-01 00:00:00 +0000 differ === removed file 'vim/bundle/vim-eunuch/.git/objects/pack/pack-f567257bb43d7669bdd07e5213f5287056754216.pack' Binary files vim/bundle/vim-eunuch/.git/objects/pack/pack-f567257bb43d7669bdd07e5213f5287056754216.pack 2016-08-04 08:15:09 +0000 and vim/bundle/vim-eunuch/.git/objects/pack/pack-f567257bb43d7669bdd07e5213f5287056754216.pack 1970-01-01 00:00:00 +0000 differ === modified file 'vim/bundle/vim-eunuch/.git/packed-refs' --- vim/bundle/vim-eunuch/.git/packed-refs 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/packed-refs 2015-08-25 11:56:54 +0000 @@ -1,2 +1,2 @@ # pack-refs with: peeled fully-peeled -5ee2b82b565e6c6d80f1cb7735c78f66a159b198 refs/remotes/origin/master +eb8b2d54fb537ee93f762f6331265057a3f69727 refs/remotes/origin/master === modified file 'vim/bundle/vim-eunuch/.git/refs/heads/master' --- vim/bundle/vim-eunuch/.git/refs/heads/master 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/refs/heads/master 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -5ee2b82b565e6c6d80f1cb7735c78f66a159b198 +eb8b2d54fb537ee93f762f6331265057a3f69727 === modified file 'vim/bundle/vim-eunuch/.git/shallow' --- vim/bundle/vim-eunuch/.git/shallow 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/.git/shallow 2015-08-25 11:56:54 +0000 @@ -1,1 +1,1 @@ -5ee2b82b565e6c6d80f1cb7735c78f66a159b198 +eb8b2d54fb537ee93f762f6331265057a3f69727 === modified file 'vim/bundle/vim-eunuch/plugin/eunuch.vim' --- vim/bundle/vim-eunuch/plugin/eunuch.vim 2016-08-04 08:15:09 +0000 +++ vim/bundle/vim-eunuch/plugin/eunuch.vim 2015-08-25 11:56:54 +0000 @@ -122,14 +122,13 @@ function! s:SudoReadCmd() abort silent %delete_ - let pipe = printf(&shellpipe . (&shellpipe =~ '%s' ? '' : ' %s'), '/dev/null') - execute (has('gui_running') ? '' : 'silent') 'read !env SUDO_EDITOR=cat sudo -e "%" ' . pipe + execute (has('gui_running') ? '' : 'silent') 'read !env SUDO_EDITOR=cat sudo -e %' silent 1delete_ set nomodified endfunction function! s:SudoWriteCmd() abort - execute (has('gui_running') ? '' : 'silent') 'write !env SUDO_EDITOR=tee sudo -e "%" >/dev/null' + execute (has('gui_running') ? '' : 'silent') 'write !env SUDO_EDITOR=tee sudo -e % >/dev/null' let &modified = v:shell_error endfunction @@ -142,11 +141,9 @@ \ set noreadonly | \ endif -if exists(':SudoWrite') != 2 command! -bar SudoWrite \ call s:SudoSetup(expand('%:p')) | \ write! -endif function! s:SudoEditInit() abort let files = split($SUDO_COMMAND, ' ')[1:-1] @@ -169,7 +166,7 @@ \ else | \ call system('wall', ) | \ endif -if exists(':W') !=# 2 +if !exists(':W') !=# 2 command! -bar W Wall endif function! s:Wall() abort