From 3d5b8caa4d4880c5308807baaf4ae04456403d13 Mon Sep 17 00:00:00 2001 From: Ahmed Abdelhalim Date: Mon, 22 Dec 2025 22:50:35 +0100 Subject: Refactor hyprland/mako This follows a more clean setup (inspired by omarchy) with the difference that the user files are delegated to the user dotfile (and are calling the system defaults first). This is to insure clarity and don't depend on hidden behaviour in the default system configurations --- roles/mako/meta/argument_specs.yml | 6 ++++++ roles/mako/meta/main.yml | 11 +++++++++++ roles/mako/tasks/main.yml | 22 ++++++++++++++++++++++ roles/mako/templates/mako/config.j2 | 36 ++++++++++++++++++++++++++++++++++++ 4 files changed, 75 insertions(+) create mode 100644 roles/mako/meta/argument_specs.yml create mode 100644 roles/mako/meta/main.yml create mode 100644 roles/mako/tasks/main.yml create mode 100644 roles/mako/templates/mako/config.j2 (limited to 'roles/mako') diff --git a/roles/mako/meta/argument_specs.yml b/roles/mako/meta/argument_specs.yml new file mode 100644 index 00000000..b6b69a07 --- /dev/null +++ b/roles/mako/meta/argument_specs.yml @@ -0,0 +1,6 @@ +--- +argument_specs: + main: + short_description: "Install mako on Arch Linux" + description: "Install mako on Arch Linux" + options: {} diff --git a/roles/mako/meta/main.yml b/roles/mako/meta/main.yml new file mode 100644 index 00000000..bb71080a --- /dev/null +++ b/roles/mako/meta/main.yml @@ -0,0 +1,11 @@ +--- +dependencies: [] +galaxy_info: + author: "a14m" + description: "Install mako on Arch Linux" + license: "MIT" + min_ansible_version: "2.18" + platforms: + - name: "ArchLinux" + versions: + - "all" diff --git a/roles/mako/tasks/main.yml b/roles/mako/tasks/main.yml new file mode 100644 index 00000000..3303969f --- /dev/null +++ b/roles/mako/tasks/main.yml @@ -0,0 +1,22 @@ +--- +- name: "Ensure mako is installed" + become: true + ansible.builtin.package: + name: + - "libnotify" + - "mako" + state: "present" + +- name: "Create system config directory" + become: true + ansible.builtin.file: + path: "/etc/xdg/mako" + state: "directory" + mode: "0755" + +- name: "Configure system defaults" + become: true + ansible.builtin.template: + src: "mako/config.j2" + dest: "/etc/xdg/mako/config" + mode: "0644" diff --git a/roles/mako/templates/mako/config.j2 b/roles/mako/templates/mako/config.j2 new file mode 100644 index 00000000..83be3e1a --- /dev/null +++ b/roles/mako/templates/mako/config.j2 @@ -0,0 +1,36 @@ +sort=-time +layer=overlay +background-color=#2e3440 +width=300 +height=110 +border-size=2 +border-color=#f1c40f +border-radius=5 +icons=1 +max-icon-size=32 +default-timeout=5000 +ignore-timeout=1 +history=1 +actions=1 +font=sans-serif 14px + +[mode=do-not-disturb] +invisible=true + +[mode=do-not-disturb app-name=notify-send] +invisible=false + +# [urgency=low] +# border-color=#41cfff + +# [urgency=normal] +# border-color=#41cfff + +[urgency=critical] +border-color=#e74c3c +default-timeout=0 +layer=overlay + +[category=mpd] +default-timeout=2000 +group-by=category -- cgit v1.2.3