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
Oh My Zsh
Commits
cbaa97d8
Commit
cbaa97d8
authored
Jul 23, 2011
by
Benjamin Boudreau
Browse files
Add utility method to spectrum
parent
1eb52d43
Changes
1
Show whitespace changes
Inline
Side-by-side
lib/spectrum.zsh
View file @
cbaa97d8
...
@@ -18,3 +18,11 @@ for color in {000..255}; do
...
@@ -18,3 +18,11 @@ for color in {000..255}; do
FG[
$color
]=
"%{[38;5;
${
color
}
m%}"
FG[
$color
]=
"%{[38;5;
${
color
}
m%}"
BG[
$color
]=
"%{[48;5;
${
color
}
m%}"
BG[
$color
]=
"%{[48;5;
${
color
}
m%}"
done
done
# Show all 256 colors with color number
function
spectrum_ls
()
{
for
code
in
{
000..255
}
;
do
print
-P
--
"
$code
: %F{
$code
}Test%f"
done
}
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