Commit Graph

7 Commits

Author SHA1 Message Date
m0viefreak
12b879caf7 'main': Use zsh/parameter instead of type -w
If possible, try to use the zsh/parameter module to get
information about a shell words.

This avoids subshells and is a huge speed improvement
on systems such as cygwin.

Note 1:
$commands does not know about PATH_DIRS. So in case
PATH_DIRS is set, 'type -w' is still used if nothing
else matches.

Note 2:
zsh/parameter can't distinguish between 'command' and
'hashed'. Adjusted the test for that case to XFAIL.

The ideal solution would be if whence had an option to
put the result in REPLY instead of printing it to stdout.
2016-05-13 20:25:07 +02:00
Matthew Martin
d3678ec7a8 tests: Remove unused_highlight 2016-05-05 12:28:43 -05:00
Matthew Martin
a830613467 tests: Specify the style key instead of the style itself 2016-04-29 09:51:13 -05:00
Matthew Martin
31ac2b36a9 tests: Quote style in expected_region_highlight 2016-04-02 09:45:24 -05:00
Daniel Shahaf
c30301d474 Drop unnecessary shebang lines.
All these files should be sourced, not executed; and Debian's lintian complains:

W: zsh-syntax-highlighting: script-not-executable usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
2015-10-20 11:49:51 +00:00
Daniel Shahaf
22fa215e05 Fixup last commit.
* highlighters/main/test-data/hashed-command.zsh:
    Set the right region key.  This makes the test more specific.
    (Issue #184 would have caught this bug.)
2015-09-23 15:39:53 +00:00
Daniel Shahaf
845361ef3d tests: Cover 'hashed-command'.
This is part of issue zsh-users/zsh-syntax-highlighting#198.
2015-09-23 15:35:56 +00:00