Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
oh-my-zsh
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
github
oh-my-zsh
Commits
452eeed8
Commit
452eeed8
authored
Feb 22, 2011
by
Robby Russell
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'nicoulaj-theme' of
https://github.com/nicoulaj/oh-my-zsh
into nicoulaj-nicoulaj-theme
parents
01b0366f
9b0a75ca
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
43 additions
and
0 deletions
+43
-0
theme-and-appearance.zsh
lib/theme-and-appearance.zsh
+0
-0
nicoulaj.zsh-theme
themes/nicoulaj.zsh-theme
+43
-0
No files found.
lib/appearance.zsh
→
lib/
theme-and-
appearance.zsh
View file @
452eeed8
File moved
themes/nicoulaj.zsh-theme
0 → 100644
View file @
452eeed8
#!/usr/bin/env zsh
# ------------------------------------------------------------------------------
# Prompt for the Zsh shell:
# * One line.
# * VCS info on the right prompt.
# * Only shows the path on the left prompt by default.
# * Crops the path to a defined length and only shows the path relative to
# the current VCS repository root.
# * Wears a different color wether the last command succeeded/failed.
# * Shows user@hostname if connected through SSH.
# * Shows if logged in as root or not.
# ------------------------------------------------------------------------------
# Customizable parameters.
PROMPT_PATH_MAX_LENGTH
=
30
PROMPT_DEFAULT_END
=
❯
PROMPT_ROOT_END
=
❯❯❯
PROMPT_SUCCESS_COLOR
=
$FG
[
071]
PROMPT_FAILURE_COLOR
=
$FG
[
124]
PROMPT_VCS_INFO_COLOR
=
$FG
[
242]
# Set required options.
setopt promptsubst
# Load required modules.
autoload
-U
add-zsh-hook
autoload
-Uz
vcs_info
# Add hook for calling vcs_info before each command.
add-zsh-hook precmd vcs_info
# Set vcs_info parameters.
zstyle
':vcs_info:*'
enable
hg bzr git
zstyle
':vcs_info:*:*'
check-for-changes
true
# Can be slow on big repos.
zstyle
':vcs_info:*:*'
unstagedstr
'!'
zstyle
':vcs_info:*:*'
stagedstr
'+'
zstyle
':vcs_info:*:*'
actionformats
"%S"
"%r/%s/%b %u%c (%a)"
zstyle
':vcs_info:*:*'
formats
"%S"
"%r/%s/%b %u%c"
zstyle
':vcs_info:*:*'
nvcsformats
"%~"
""
# Define prompts.
PROMPT
=
"%(0?.%{
$PROMPT_SUCCESS_COLOR
%}.%{
$PROMPT_FAILURE_COLOR
%})
${
SSH_TTY
:+[%n@%m]
}
%{
$FX
[bold]%}%
$PROMPT_PATH_MAX_LENGTH
<..<"
'${vcs_info_msg_0_%%.}'
"%<<%(!.
$PROMPT_ROOT_END
.
$PROMPT_DEFAULT_END
)%{
$FX
[no-bold]%}%{
$FX
[reset]%} "
RPROMPT
=
"%{
$PROMPT_VCS_INFO_COLOR
%}"
'$vcs_info_msg_1_'
"%{
$FX
[reset]%}"
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment