Commit graph

8 commits

Author SHA1 Message Date
Marc Cornellà
c90141ed77 fix: escape % characters in git prompts
This patch adds missing % character escaping for custom git prompts
used in a few themes. It also includes escaping for git-prompt.sh.

In combination with CVE-2021-45444, this could allow code execution
when displaying branch information in cloned malicious git repositories.
However, zsh 5.8.1 and newer are largely the default zsh versions, and
on those supported distributions with older zsh versions, the CVE has been
found to be also patched.

For this reason, this doesn't qualify as a security patch, but a
bug fix for proper printing of git branches.
2026-05-28 19:45:47 +02:00
vladislav doster
1d09c6bb0a
style: remove trailing whitespace (#12303) 2024-03-26 09:55:16 +01:00
Marc Cornellà
e3bb6e685d
refactor(themes): use ruby_prompt_info everywhere 2021-12-13 17:14:25 +01:00
Andrew Janke
9f552130bd Move current_branch() from git plugin to core lib/git.zsh
Fixes #4085: core -> plugin dependency issue.
Rename it to git_current_branch for clarity that it's git-specific.
Update all plugins that were calling it to use new name.
Fix variable leaks by making more variables in lib/git.zsh local.
Have lib/git.zsh use [[ ]] instead of [ ] everywhere.
2015-12-14 20:28:37 -05:00
Piotr Solnica
ce6a21c3b3 [themes/josh] Use $(current_branch) in prompt 2012-03-23 20:31:13 +01:00
Brent Faulkner
6496acf58b adding rbenv support to all the rvm themes 2012-01-23 20:42:54 -05:00
Josh Price
1582570919 Made the user_machine_size calculation generic. Pwned the function name. 2010-08-19 07:17:50 -07:00
Josh Price
eb14ee1c63 Added my own theme based on pat's 2010-08-19 07:17:31 -07:00