diff --git a/colors/dark/palette b/colors/dark/palette new file mode 100644 index 0000000..62fb661 --- /dev/null +++ b/colors/dark/palette @@ -0,0 +1,16 @@ +#070736364242 +#DCDC32322F2F +#858599990000 +#B5B589890000 +#26268B8BD2D2 +#D3D336368282 +#2A2AA1A19898 +#EEEEE8E8D5D5 +#00002B2B3636 +#CBCB4B4B1616 +#58586E6E7575 +#65657B7B8383 +#838394949696 +#6C6C7171C4C4 +#9393A1A1A1A1 +#FDFDF6F6E3E3 diff --git a/colors/dark/palette_dconf b/colors/dark/palette_dconf deleted file mode 100644 index be014a2..0000000 --- a/colors/dark/palette_dconf +++ /dev/null @@ -1 +0,0 @@ -'#070736364242', '#DCDC32322F2F', '#858599990000', '#B5B589890000', '#26268B8BD2D2', '#D3D336368282', '#2A2AA1A19898', '#EEEEE8E8D5D5', '#00002B2B3636', '#CBCB4B4B1616', '#58586E6E7575', '#65657B7B8383', '#838394949696', '#6C6C7171C4C4', '#9393A1A1A1A1', '#FDFDF6F6E3E3' diff --git a/colors/dark/palette_gconf b/colors/dark/palette_gconf deleted file mode 100644 index 4e2e6e1..0000000 --- a/colors/dark/palette_gconf +++ /dev/null @@ -1 +0,0 @@ -#070736364242:#DCDC32322F2F:#858599990000:#B5B589890000:#26268B8BD2D2:#D3D336368282:#2A2AA1A19898:#EEEEE8E8D5D5:#00002B2B3636:#CBCB4B4B1616:#58586E6E7575:#65657B7B8383:#838394949696:#6C6C7171C4C4:#9393A1A1A1A1:#FDFDF6F6E3E3 diff --git a/colors/dark_alternative/palette b/colors/dark_alternative/palette new file mode 100644 index 0000000..59ba696 --- /dev/null +++ b/colors/dark_alternative/palette @@ -0,0 +1,16 @@ +#00002B2B3636 +#CBCB4B4B1616 +#58586E6E7575 +#65657B7B8383 +#838394949696 +#6C6C7171C4C4 +#9393A1A1A1A1 +#FDFDF6F6E3E3 +#070736364242 +#DCDC32322F2F +#858599990000 +#B5B589890000 +#26268B8BD2D2 +#D3D336368282 +#2A2AA1A19898 +#EEEEE8E8D5D5 diff --git a/colors/dark_alternative/palette_dconf b/colors/dark_alternative/palette_dconf deleted file mode 100644 index cfdfce7..0000000 --- a/colors/dark_alternative/palette_dconf +++ /dev/null @@ -1,2 +0,0 @@ -'#00002B2B3636', '#CBCB4B4B1616', '#58586E6E7575', '#65657B7B8383', '#838394949696', '#6C6C7171C4C4', '#9393A1A1A1A1', '#FDFDF6F6E3E3', '#070736364242', '#DCDC32322F2F', '#858599990000', '#B5B589890000', '#26268B8BD2D2', '#D3D336368282', '#2A2AA1A19898', '#EEEEE8E8D5D5' - diff --git a/colors/dark_alternative/palette_gconf b/colors/dark_alternative/palette_gconf deleted file mode 100644 index fdf979f..0000000 --- a/colors/dark_alternative/palette_gconf +++ /dev/null @@ -1 +0,0 @@ -#00002B2B3636:#CBCB4B4B1616:#58586E6E7575:#65657B7B8383:#838394949696:#6C6C7171C4C4:#9393A1A1A1A1:#FDFDF6F6E3E3:#070736364242:#DCDC32322F2F:#858599990000:#B5B589890000:#26268B8BD2D2:#D3D336368282:#2A2AA1A19898:#EEEEE8E8D5D5 diff --git a/colors/light/palette b/colors/light/palette new file mode 100644 index 0000000..62fb661 --- /dev/null +++ b/colors/light/palette @@ -0,0 +1,16 @@ +#070736364242 +#DCDC32322F2F +#858599990000 +#B5B589890000 +#26268B8BD2D2 +#D3D336368282 +#2A2AA1A19898 +#EEEEE8E8D5D5 +#00002B2B3636 +#CBCB4B4B1616 +#58586E6E7575 +#65657B7B8383 +#838394949696 +#6C6C7171C4C4 +#9393A1A1A1A1 +#FDFDF6F6E3E3 diff --git a/colors/light/palette_dconf b/colors/light/palette_dconf deleted file mode 100644 index be014a2..0000000 --- a/colors/light/palette_dconf +++ /dev/null @@ -1 +0,0 @@ -'#070736364242', '#DCDC32322F2F', '#858599990000', '#B5B589890000', '#26268B8BD2D2', '#D3D336368282', '#2A2AA1A19898', '#EEEEE8E8D5D5', '#00002B2B3636', '#CBCB4B4B1616', '#58586E6E7575', '#65657B7B8383', '#838394949696', '#6C6C7171C4C4', '#9393A1A1A1A1', '#FDFDF6F6E3E3' diff --git a/colors/light/palette_gconf b/colors/light/palette_gconf deleted file mode 100644 index 4e2e6e1..0000000 --- a/colors/light/palette_gconf +++ /dev/null @@ -1 +0,0 @@ -#070736364242:#DCDC32322F2F:#858599990000:#B5B589890000:#26268B8BD2D2:#D3D336368282:#2A2AA1A19898:#EEEEE8E8D5D5:#00002B2B3636:#CBCB4B4B1616:#58586E6E7575:#65657B7B8383:#838394949696:#6C6C7171C4C4:#9393A1A1A1A1:#FDFDF6F6E3E3 diff --git a/install.sh b/install.sh index ca7a8c1..e03fe3f 100755 --- a/install.sh +++ b/install.sh @@ -45,7 +45,7 @@ set_profile_colors() { then local profile_path=$dconfdir/$profile # set color palette - dconf write $profile_path/palette "[$(cat $scheme_dir/palette_dconf)]" + dconf write $profile_path/palette "$(to_dconf < $scheme_dir/palette)" # set foreground, background and highlight color dconf write $profile_path/bold-color "'$(cat $bd_color_file)'" @@ -62,8 +62,7 @@ set_profile_colors() { local profile_path=$gconfdir/$profile # set color palette - gconftool-2 -s -t string $profile_path/palette $(cat \ - $scheme_dir/palette_gconf) + gconftool-2 -s -t string $profile_path/palette "$(to_gconf < $scheme_dir/palette)" # set foreground, background and highlight color gconftool-2 -s -t string $profile_path/bold_color $(cat $bd_color_file) diff --git a/src/tools.sh b/src/tools.sh index b829b61..1b506c9 100644 --- a/src/tools.sh +++ b/src/tools.sh @@ -23,3 +23,10 @@ in_array() { return 1 } +to_gconf() { + tr '\n' \: | sed 's#:$#\n#' +} + +to_dconf() { + tr '\n' '~' | sed -e "s#~\$#']\n#" -e "s#~#', '#g" -e "s#^#['#" +}