Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Ohmyzsh
Commits
3d1719c6
Commit
3d1719c6
authored
Aug 20, 2018
by
Marc Cornellà
Browse files
trapd00r: optimize reset of foreground colors
parent
4774bc62
Changes
1
Hide whitespace changes
Inline
Side-by-side
themes/trapd00r.zsh-theme
View file @
3d1719c6
...
@@ -55,28 +55,29 @@ zsh_path() {
...
@@ -55,28 +55,29 @@ zsh_path() {
if
[[
$c
=
"/"
]]
;
then
if
[[
$c
=
"/"
]]
;
then
if
[[
$i
-eq
1
]]
;
then
if
[[
$i
-eq
1
]]
;
then
if
[[
$colors
-ge
256
]]
;
then
if
[[
$colors
-ge
256
]]
;
then
print
-Pn
'
%F{065}%B /%b
%f'
print
-Pn
"
%F{065}%B /%b
"
else
else
print
-Pn
'
\e[31;1m /
%f'
print
-Pn
"
\e
[31;1m /
"
fi
fi
((
i++
))
((
i++
))
continue
continue
fi
fi
if
[[
$colors
-ge
256
]]
;
then
if
[[
$colors
-ge
256
]]
;
then
print
-Pn
"
${
yellow
[
$i
]
:-
%f
}
»
%f
"
print
-Pn
"
${
yellow
[
$i
]
:-
%f
}
» "
else
else
print
-Pn
"%F{yellow} >
%f
"
print
-Pn
"%F{yellow} > "
fi
fi
((
i +
=
6
))
((
i +
=
6
))
else
else
if
[[
$colors
-ge
256
]]
;
then
if
[[
$colors
-ge
256
]]
;
then
print
-Pn
"%F{065}
$c
%f
"
print
-Pn
"%F{065}
$c
"
else
else
print
-Pn
"%F{blue}
$c
%f
"
print
-Pn
"%F{blue}
$c
"
fi
fi
fi
fi
done
done
print
-Pn
"%f"
}
}
...
...
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