Browse Source

Simplify colors export

master
Riyyi 6 years ago
parent
commit
0f6dcb3ee7
  1. 8
      .config/zsh/.zprofile

8
.config/zsh/.zprofile

@ -44,11 +44,11 @@ export XAUTHORITY="$XDG_DATA_HOME/xorg/Xauthority"
# Colors # Colors
# Example: *.color0: #282a2e -> export COLOR0=#282a2e # Example: *.color0: #282a2e -> export COLOR0=#282a2e
$(awk '/^*.color/ {print "export " toupper(substr($1, 3, length($1) - 3)) "=" $2}' \
"$XDG_CONFIG_HOME/xorg/Xresources")
# Example: Wmcolor.bgcolor: #404552 -> export BGCOLOR=#404552 # Example: Wmcolor.bgcolor: #404552 -> export BGCOLOR=#404552
$(awk '/Wmcolor./ {print "export " toupper(substr($1, 9, length($1) - 9)) "=" $2}' \ $(awk '
"$XDG_CONFIG_HOME/xorg/Xresources") /^\*.[a-zA-Z0-9]+: +#/ {print "export " toupper(substr($1, 3, length($1) - 3)) "=" $2}
/^Wmcolor./ {print "export " toupper(substr($1, 9, length($1) - 9)) "=" $2}
' "$XDG_CONFIG_HOME/xorg/Xresources")
## Login ## Login

Loading…
Cancel
Save