Commit Graph
100 Commits
Author SHA1 Message Date
Dominik Ritter a00cb84da4 Fix regular expression and test 2019-02-04 15:40:31 +01:00
Dominik Ritter 06151eeba9 Merge remote-tracking branch 'ben/master' into HEAD 2019-02-03 19:52:29 +01:00
Dominik Ritter 40e04e053c Parse IPs properly
This is done if we want to show a public IP, internal IP, or a VPN.
In the VPN case, what we actually want is to display an indicator
that a VPN is active, instead of the VPN IP itself. We parse the
IP here anyway, because we want to save some specific code there.
2019-02-03 19:20:14 +01:00
Dominik Ritter 0b2990b885 Merge pull request #1154 from dritter/fix_font_debugging_konsole
Fix issues with debug/fonts script in Konsole
2019-02-03 11:28:21 +01:00
Dominik Ritter 0334f4c265 Merge from upstream 2019-02-03 08:58:46 +01:00
Dominik Ritter 2fbdb8c982 Mute errors when detecting font 2019-02-03 08:51:03 +01:00
Dominik Ritter cdf3fa51f2 Make variables optional 2019-02-03 08:50:38 +01:00
Dominik Ritter 0207182eb9 Add missing function 2019-02-03 08:49:57 +01:00
Dominik Ritter 933e95d31c Use Konsole/Yakuake detection from upstream 2019-02-03 08:41:32 +01:00
Dominik Ritter 0081152c28 Fix parsing font for Kitty 2019-02-03 08:35:46 +01:00
Dominik Ritter 4b9ccc33bf Fix issues with debug/fonts script in Konsole 2019-02-03 01:36:22 +01:00
Dominik Ritter 22f6495005 Merge pull request #1151 from Wuestengecko/bugfix-1150
[Bugfix] Only abbreviate $HOME at the beginning of cwd
2019-02-02 00:48:54 +01:00
Dominik Ritter 08798d12ad Merge pull request #1147 from dritter/fix_newlines_in_zsh57
Fix newlines in ZSH 5.7
2019-02-01 23:52:56 +01:00
Dominik Ritter 8bb86908d7 Add tests 2019-02-01 23:48:39 +01:00
Dominik Ritter 5c7d1009de Merge pull request #1148 from dritter/remove_nodeenv_disable_prompt
Remove checking for NODEENV_DISABLE_PROMPT
2019-02-01 17:06:10 +01:00
Dominik Ritter f42214e44b Add tests for newline segment 2019-02-01 14:37:17 +01:00
Dominik Ritter bd340d4a88 Merge pull request #966 from ytang/fix-rprompt-icons-cut-off
[Bugfix] Fix icons cut off in RPROMPT segments
2019-02-01 14:19:02 +01:00
Dominik Ritter c56cbb800a Add documentation 2019-02-01 14:13:02 +01:00
Dominik Ritter 2f05bbbb47 Remove checking for NODEENV_DISABLE_PROMPT
This variable is none of our buisness.
2019-02-01 11:09:42 +01:00
Dominik Ritter 020287dd75 Fix Segment endings if followed by newline 2019-02-01 11:01:59 +01:00
Dominik Ritter 6ccdfdf37e Merge pull request #981 from pgierz/os_release_fix
[Bugfix] Fix for #974
2019-01-23 23:52:37 +01:00
Dominik Ritter 938b0d49a1 Avoid externals when parsing the os release on linux 2019-01-23 23:11:01 +01:00
Dominik Ritter 081000c49e Replace call to basename with ZSH internals #1128 2019-01-23 22:47:10 +01:00
Dominik Ritter 8b4bed99df Add documentation about VIRTUAL_ENV_DISABLE_PROMPT #1128 2019-01-23 22:37:45 +01:00
Dominik Ritter e028513bb9 Merge pull request #1128 from ymage/fix_virtualenv_prompt
[Bugfix] virtualenv prompt displaying
2019-01-23 22:25:05 +01:00
Dominik Ritter 747b94b1b6 Match VPN interface fuzzy on Linux 2019-01-23 19:10:46 +01:00
Dominik Ritter bde4337992 Match VPN Interface fuzzy 2019-01-23 18:56:07 +01:00
Dominik Ritter 54a985cb11 Simplify code that checks if a VPN is running 2019-01-23 01:02:42 +01:00
Dominik Ritter 480ade162b Improve tests 2019-01-23 01:01:49 +01:00
Dominik Ritter 32d3216bde Fix tests 2019-01-22 19:18:09 +01:00
Dominik Ritter da50151d24 Fix regular expression 2019-01-21 19:48:28 +01:00
Dominik Ritter 9b73c8bd9c Add tests 2019-01-21 19:46:53 +01:00
Dominik Ritter d1e4c4c988 Merge pull request #1080 from macserv/port/vcs-segment-untracked-file-check
[Bugfix] Port #1071 to `master` (Fix fatal errors emitted by untracked file check in vcs.zsh)
2018-11-18 09:26:26 +01:00
Dominik Ritter 724781e896 Merge pull request #1065 from dritter/protect_locale
Protect locale
2018-11-17 01:39:38 +01:00
Dominik Ritter 67fd577217 Merge pull request #1074 from dritter/add_vcs_vulnerability_tests_master
Add vcs vulnerability tests master
2018-11-17 01:30:08 +01:00
Dominik Ritter a72a82b4b1 Fix tests 2018-11-16 22:21:49 +01:00
Dominik Ritter 24818eff79 Fix test
The branch name must not be expanded.
2018-11-16 22:20:21 +01:00
Dominik Ritter 1b7e41964c Fix configuration errors in the tests 2018-11-16 22:20:08 +01:00
Dominik Ritter 7bc5366af1 Add tests for branch name vulnerability 2018-11-16 22:15:35 +01:00
Dominik Ritter 6085a74abf Merge pull request #1070 from Wieschie/patch-1
[Docs] Uniformly apply inline code formatting in README
2018-11-16 21:40:24 +01:00
Dominik Ritter 5abac53698 Merge pull request #1037 from dritter/fix_vpn_ip_segment
Fix vpn_ip segment
2018-11-16 21:02:29 +01:00
Dominik Ritter e47b0daaf7 Merge pull request #1036 from dritter/fix_truncate_package_name
Make truncate with package name work without setting shorten length
2018-11-16 21:01:59 +01:00
Dominik Ritter 4ebb9f92a1 Ensure that LC_CTYPE IS NOT overwritten by P9K 2018-11-14 23:27:05 +01:00
Dominik Ritter 6cfe8f8d96 Add test for detecting untracked files from sibling folder 2018-11-12 00:37:34 +01:00
Dominik Ritter fd660f4b92 Fix checking for untracked files
Now the untracked files are always checked from
the root folder of the repo.
2018-11-12 00:24:29 +01:00
Dominik Ritter a6e60def4b Fix stashes display
Changing directories while checking for untracked files broke
the display of git stashes. The hook was not called any more.
This is why we disabled checking for untracked files within a
.git folder.
2018-11-12 00:15:52 +01:00
Dominik Ritter 645b974677 Fix error if user cds into a .git directory
In this case is was previously not possible to get the untracked
status. Now we temporarily change the directory to the repo root
folder and then get the list of untracked files.
2018-11-12 00:13:35 +01:00
Dominik Ritter a90258a9ee Avoid warning when inside of .git dir
We cannot detect untracked files when we are inside of
a .git directory.
2018-11-11 23:17:33 +01:00
Dominik Ritter 3256258ebf Count stashes via ZSH 2018-11-11 23:16:44 +01:00
Dominik Ritter 2038e2650c Avoid aliases 2018-11-06 01:12:19 +01:00
Dominik Ritter 48f0cc11ef Get rid of externals when truncating branch name 2018-11-06 01:11:31 +01:00
Dominik Ritter 3d960a5169 Protect users locale 2018-11-05 02:19:06 +01:00
Dominik Ritter 9d84e6fb6a Add tests for complex git submodule scenarios 2018-11-03 03:45:05 +01:00
Dominik Ritter c3f9d04354 When checking for untracked or modified files, take submodules into account 2018-11-03 03:23:23 +01:00
Dominik Ritter 44b4b66925 Speedup VCS segment
Now the untracked files are detected via `git ls-files`, which is
much faster than `git status`. Additionally, we flipped the default
for checking submodules. They are now NOT checked by default, as most
users probably do not use git submodules.
2018-11-03 03:21:47 +01:00
Dominik Ritter d07507c1eb Make use of git dir determined by VCS_INFO subsystem
instead of determine the git dir manually.
2018-11-03 03:11:51 +01:00
Dominik Ritter 9a67ca5bc3 Get branch name from VCS_INFO subsystem when collecting remote branch 2018-11-03 03:10:53 +01:00
Dominik Ritter fea5f616d1 Get branch name from VCS_INFO subsystem when collecting ahead/behind info 2018-11-03 03:08:32 +01:00
Dominik Ritter cd0ad84b01 Get rid of wc dependency when showing ahead/behind info 2018-11-03 03:06:49 +01:00
Dominik Ritter 993de7aef9 Fix vpn_ip segment 2018-10-25 18:48:37 +02:00
Dominik Ritter dc731f10e6 Make truncate with package name work without setting shorten length 2018-10-25 08:17:29 +02:00
Dominik Ritter ad14807cef Merge pull request #1020 from dritter/fix_context_spec
Fix context spec
2018-10-13 10:24:24 +02:00
Dominik Ritter d831f12126 Do not throw away users configuration 2018-10-12 22:04:02 +02:00
Dominik Ritter d1cd83bf0b Fix tests
It seems like Travis changed their infrastructure. We
need to unset SSH_TTY and SSH_CLIENT to get the tests
working again.
2018-10-12 21:50:25 +02:00
Dominik Ritter 94897a40f0 Fix tests 2018-09-05 19:07:25 +02:00
Dominik Ritter d326ba6b1b Merge remote-tracking branch 'ben/master' into fix_color_values 2018-09-05 18:55:23 +02:00
Dominik Ritter df0c2198a0 Fix tests 2018-08-17 18:53:26 +02:00
Dominik Ritter 8e966e3636 Change bright colors to old color codes
Before this, there was no difference in that colors, as we always used
the bright color codes.
2018-08-17 18:52:23 +02:00
Dominik Ritter 69c69b9cd9 Merge remote-tracking branch 'nnja/patch-1' into prepare_066 2018-08-17 08:03:28 +02:00
Dominik Ritter 6e78f7e793 Merge remote-tracking branch 'eloo/master' into prepare_066 2018-08-12 00:02:23 +02:00
Dominik Ritter 2700cb46f5 Merge remote-tracking branch 'docwhat/pr/sudo-check' into prepare_066 2018-08-10 22:12:49 +02:00
Dominik Ritter 7a1319c2d9 Add tests for color comparisons with none colors 2018-08-10 00:47:20 +02:00
Dominik Ritter 6daef84c60 Merge branch 'fix_colors' into prepare_066 2018-08-09 23:22:33 +02:00
Dominik Ritter 52ce9930bb Fix foreground colors in right prompt segments 2018-08-09 23:20:48 +02:00
Dominik Ritter a0d57bc455 Add test for bright colors 2018-08-09 08:11:19 +02:00
Dominik Ritter e0630d7573 Merge branch 'fix_colors' into prepare_066 2018-08-09 00:28:50 +02:00
Dominik Ritter ef5f9bb1b4 Fix tests 2018-08-08 23:47:01 +02:00
Dominik Ritter 27fe2c6571 Make use of helper function in left_end_segment 2018-08-08 23:36:40 +02:00
Dominik Ritter 6f5827009f Fix colors for visual identifiers
Make the visual identifier color use numerical color codes as well. This
way colors like "purple3" work as visual identifier color.
2018-08-08 23:18:36 +02:00
Dominik Ritter c7e543ff23 Merge branch 'fix_colors' into prepare_066 2018-08-08 02:03:03 +02:00
Dominik Ritter 424d41761d Write comparison with double quotes 2018-08-08 01:11:44 +02:00
Dominik Ritter 057b07b214 Fix tests 2018-08-08 01:01:14 +02:00
Dominik Ritter 39fe5217c6 Pad colors with zeroes 2018-08-08 01:00:43 +02:00
Dominik Ritter e970a021c8 Fix tests 2018-08-08 00:42:42 +02:00
Dominik Ritter 19235b2359 Always use color codes instead of named colors
This Code was to check if the color is supported by the Terminal
Emulator. This is not necessary, if we always use the numerical code.
This makes the code much clearer.
2018-08-08 00:40:41 +02:00
Dominik Ritter beacb0ad35 Fix bright colors
Remove old code that set bright colors equal to normal colors. This code
was ancient and led to bright colors being unusable. The code originates
from 0e37d8ef86.
2018-08-08 00:40:05 +02:00
Dominik Ritter 93324c0600 Improve naming of variables
As a side effect this should improve the performance slightly, as we get
the fore- and background color codes as early as possible, and store the
result, so that we don't have to recalculate the color code all over.
2018-08-07 22:00:11 +02:00
Dominik Ritter 02506893a9 Remove duplicate variable 2018-08-07 21:58:32 +02:00
Dominik Ritter 0acede2fdc Make colors a global array
That way it must not be defined in every function call.
2018-08-07 21:36:49 +02:00
Dominik Ritter eadbd09368 Write comparisons with double equals 2018-08-07 21:35:29 +02:00
Dominik Ritter 9cf76f99a5 Fix bright colors
Remove old code that set bright colors equal to normal colors. This code
was ancient and led to bright colors being unusable. The code originates
from 0e37d8ef86.
2018-08-07 21:33:09 +02:00
Dominik Ritter bf9082bea9 Fix bug so that the segment separator of left middle has the right color
In short: the current background color was the unfiltered color and is
used to print the next segment separator. If the user set a color like
"purple3" that would result in a white segment separator as Terminal
Emulators do not understand the color "purple3".
2018-08-07 21:25:06 +02:00
Dominik Ritter ebbdb3c1c0 Make purpose clear of backgroundColor and foregroundColor functions
The functions just start the colors, they do not end them. It seems
too much to have a function that terminates a color.
2018-08-07 21:21:15 +02:00
Dominik Ritter e35f7a0c48 Merge branch 'fix_colors' into prepare_066 2018-08-06 00:56:29 +02:00
Dominik Ritter 8beff9fee6 Merge remote-tracking branch 'JulienPivard/transparent_back_fix' into prepare_066 2018-08-06 00:38:19 +02:00
Dominik Ritter 3c57e4a571 Merge branch 'fix_debug_fonts' into prepare_066 2018-08-06 00:34:46 +02:00
Dominik Ritter 673e029152 Merge remote-tracking branch 'xufab/master' into prepare_066 2018-08-06 00:33:40 +02:00
Dominik Ritter e027a8510d Merge remote-tracking branch 'docwhat/pr/fix-test-in-docker-on-newer-zsh' into prepare_066 2018-08-06 00:27:50 +02:00
Dominik Ritter 3b8f0abdb2 Merge remote-tracking branch 'docwhat/pr/sudo-check' into prepare_066 2018-08-06 00:26:23 +02:00
Dominik Ritter aca20ae463 Merge branch 'add_tests' into prepare_066 2018-08-06 00:17:23 +02:00