diff options
Diffstat (limited to 'scripts/.local/bin/personal/rica')
-rwxr-xr-x | scripts/.local/bin/personal/rica | 24 |
1 files changed, 6 insertions, 18 deletions
diff --git a/scripts/.local/bin/personal/rica b/scripts/.local/bin/personal/rica index 178f2fc..8a597cc 100755 --- a/scripts/.local/bin/personal/rica +++ b/scripts/.local/bin/personal/rica @@ -1,7 +1,6 @@ #!/usr/bin/env python3 # A script to update the colors in specific config files for easy ricing. -# Depenencies: # By David Penkowoj, 2022-03-18 import os @@ -15,7 +14,7 @@ def replace_color_configs(): new_colors = [ color.replace("\n", "") for color in new_color_file.readlines() ] for config in relevant: - config(old_colors, new_colors) + find_and_replace_config(config, old_colors, new_colors) def find_and_replace_config(file_path, old_colors, new_colors): with open(file_path, "r") as file: @@ -29,26 +28,15 @@ def find_and_replace_config(file_path, old_colors, new_colors): with open(file_path, "w") as file: file.write(data) -# Change config for zathura -def change_zathura(old_colors, new_colors): - file_path = "/home/me/.config/zathura/zathurarc" - - find_and_replace_config(file_path, old_colors, new_colors) - -def change_qutebrowser(old_colors, new_colors): - file_path = "/home/me/.config/qutebrowser/utils.py" - - find_and_replace_config(file_path, old_colors, new_colors) - -# change_nvim -# change_dunst, - relevant = [ - change_zathura, - change_qutebrowser, + "/home/me/.config/dunst/dunstrc", + "/home/me/.config/zathura/zathurarc", + "/home/me/.config/flameshot/flameshot.ini", + "/home/me/.config/qutebrowser/utils.py", ] if __name__ == "__main__": os.system('xrdb -merge "$HOME/.cache/wal/colors.Xresources"') os.system('xrdb -merge "$HOME/.Xresources"') replace_color_configs() + os.system('killall dunst') |