summaryrefslogtreecommitdiffstats
path: root/roles/hyprtheme/tasks
diff options
context:
space:
mode:
authorAhmed Abdelhalim <[email protected]>2026-01-15 15:01:19 +0100
committerAhmed Abdelhalim <[email protected]>2026-01-15 15:01:19 +0100
commit115f703928fc7b6ab2c591edcd025bab6c7a3ce8 (patch)
tree782f608aa554139a8306d391d1061e0de7edc665 /roles/hyprtheme/tasks
parent99a4507fb0186f490ba6a4d35371f5fba5445b2d (diff)
Add role meta and initial theme setup using default theme
Diffstat (limited to 'roles/hyprtheme/tasks')
-rw-r--r--roles/hyprtheme/tasks/main.yml11
1 files changed, 11 insertions, 0 deletions
diff --git a/roles/hyprtheme/tasks/main.yml b/roles/hyprtheme/tasks/main.yml
index cf1c4e35..7686df0d 100644
--- a/roles/hyprtheme/tasks/main.yml
+++ b/roles/hyprtheme/tasks/main.yml
@@ -43,3 +43,14 @@
loop:
- "scripts/theme-set"
- "scripts/theme-bg-next"
+
+- name: "Set default theme"
+ ansible.builtin.command:
+ # Running the command creates the symlinks for the current themes, using the hyprland.conf file to avoid rerunning
+ # This will run only if there is no current theme in place
+ # This will ignore the errors in the script, because the script restarts some hyprland services, which
+ # will fail on ssh connection, but having the theme files placed in the right directory will make sure that
+ # the first setup of hyprtheme is working and doesn't show errors on first boot
+ cmd: "{{ ansible_env.HOME }}/.config/hyprtheme/scripts/theme-set {{ hyprtheme_default_theme }}"
+ creates: "{{ ansible_env.HOME }}/.config/hyprtheme/current/hyprland.conf"
+ failed_when: false