From f8d4fa869bc5dfa85981de5a07356f8d29511ad7 Mon Sep 17 00:00:00 2001 From: Matthew Stobbs Date: Wed, 12 Mar 2025 15:11:48 -0600 Subject: [PATCH] add the rest of the hypr tools --- files/hypridle/cmakelists.patch | 21 ++++++++ files/hyprlock/cmakelists.patch | 21 ++++++++ tasks/archive/pulumi.yml | 47 ++++++++++-------- tasks/cargo.yml | 2 +- tasks/config/hypridle.yml | 9 ++++ tasks/config/hyprland_qt_support.yml | 9 ++++ tasks/config/hyprland_qtutils.yml | 9 ++++ tasks/config/hyprlock.yml | 9 ++++ tasks/config/hyprpaper.yml | 9 ++++ tasks/config/hyprpicker.yml | 9 ++++ tasks/config/terraform.yml | 4 +- tasks/main.yml | 7 +++ tasks/npm.yml | 2 +- tasks/pkgs/hypridle.yml | 30 ++++++++++++ tasks/pkgs/hyprland_qt_support.yml | 30 ++++++++++++ tasks/pkgs/hyprland_qtutils.yml | 30 ++++++++++++ tasks/pkgs/hyprlock.yml | 30 ++++++++++++ tasks/pkgs/hyprpaper.yml | 30 ++++++++++++ tasks/pkgs/hyprpicker.yml | 30 ++++++++++++ tasks/src/aquamarine.yml | 2 + tasks/src/hypridle.yml | 72 ++++++++++++++++++++++++++++ tasks/src/hyprland_qt_support.yml | 67 ++++++++++++++++++++++++++ tasks/src/hyprland_qtutils.yml | 66 +++++++++++++++++++++++++ tasks/src/hyprlock.yml | 72 ++++++++++++++++++++++++++++ tasks/src/hyprpaper.yml | 66 +++++++++++++++++++++++++ tasks/src/hyprpicker.yml | 66 +++++++++++++++++++++++++ vars/pkgs/carapace.yml | 4 +- vars/pkgs/hypridle.yml | 15 ++++++ vars/pkgs/hyprland.yml | 9 +++- vars/pkgs/hyprland_qt_support.yml | 22 +++++++++ vars/pkgs/hyprland_qtutils.yml | 17 +++++++ vars/pkgs/hyprpaper.yml | 22 +++++++++ vars/pkgs/hyprpolkitagent.yml | 1 + vars/pkgs/hyrplock.yml | 27 +++++++++++ vars/pkgs/hyrppicker.yml | 16 +++++++ vars/pkgs/nodejs.yml | 1 + 36 files changed, 858 insertions(+), 25 deletions(-) create mode 100644 files/hypridle/cmakelists.patch create mode 100644 files/hyprlock/cmakelists.patch create mode 100644 tasks/config/hypridle.yml create mode 100644 tasks/config/hyprland_qt_support.yml create mode 100644 tasks/config/hyprland_qtutils.yml create mode 100644 tasks/config/hyprlock.yml create mode 100644 tasks/config/hyprpaper.yml create mode 100644 tasks/config/hyprpicker.yml create mode 100644 tasks/pkgs/hypridle.yml create mode 100644 tasks/pkgs/hyprland_qt_support.yml create mode 100644 tasks/pkgs/hyprland_qtutils.yml create mode 100644 tasks/pkgs/hyprlock.yml create mode 100644 tasks/pkgs/hyprpaper.yml create mode 100644 tasks/pkgs/hyprpicker.yml create mode 100644 tasks/src/hypridle.yml create mode 100644 tasks/src/hyprland_qt_support.yml create mode 100644 tasks/src/hyprland_qtutils.yml create mode 100644 tasks/src/hyprlock.yml create mode 100644 tasks/src/hyprpaper.yml create mode 100644 tasks/src/hyprpicker.yml create mode 100644 vars/pkgs/hypridle.yml create mode 100644 vars/pkgs/hyprland_qt_support.yml create mode 100644 vars/pkgs/hyprland_qtutils.yml create mode 100644 vars/pkgs/hyprpaper.yml create mode 100644 vars/pkgs/hyrplock.yml create mode 100644 vars/pkgs/hyrppicker.yml diff --git a/files/hypridle/cmakelists.patch b/files/hypridle/cmakelists.patch new file mode 100644 index 0000000..dfe76d3 --- /dev/null +++ b/files/hypridle/cmakelists.patch @@ -0,0 +1,21 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 3d60b42..d5bd628 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -31,6 +31,7 @@ configure_file(systemd/hypridle.service.in systemd/hypridle.service @ONLY) + # dependencies + message(STATUS "Checking deps...") + ++find_package(sdbus-c++ REQUIRED) + find_package(Threads REQUIRED) + find_package(PkgConfig REQUIRED) + pkg_check_modules( +@@ -45,7 +46,7 @@ pkg_check_modules( + + file(GLOB_RECURSE SRCFILES CONFIGURE_DEPENDS "src/*.cpp") + add_executable(hypridle ${SRCFILES}) +-target_link_libraries(hypridle PRIVATE rt Threads::Threads PkgConfig::deps) ++target_link_libraries(hypridle PRIVATE rt Threads::Threads PkgConfig::deps SDBusCpp::sdbus-c++) + + # protocols + find_program(WaylandScanner NAMES wayland-scanner) diff --git a/files/hyprlock/cmakelists.patch b/files/hyprlock/cmakelists.patch new file mode 100644 index 0000000..c89dcba --- /dev/null +++ b/files/hyprlock/cmakelists.patch @@ -0,0 +1,21 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index d1cec67..2a44d58 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -68,6 +68,7 @@ add_compile_options(-fmacro-prefix-map=${CMAKE_SOURCE_DIR}/=) + # dependencies + message(STATUS "Checking deps...") + ++find_package(sdbus-c++ REQUIRED) + find_package(Threads REQUIRED) + find_package(PkgConfig REQUIRED) + find_package(OpenGL REQUIRED COMPONENTS EGL GLES3) +@@ -96,7 +97,7 @@ pkg_check_modules( + file(GLOB_RECURSE SRCFILES CONFIGURE_DEPENDS "src/*.cpp") + add_executable(hyprlock ${SRCFILES}) + target_link_libraries(hyprlock PRIVATE pam rt Threads::Threads PkgConfig::deps +- OpenGL::EGL OpenGL::GLES3) ++ OpenGL::EGL OpenGL::GLES3 SDBusCpp::sdbus-c++) + + # protocols + pkg_get_variable(WAYLAND_PROTOCOLS_DIR wayland-protocols pkgdatadir) diff --git a/tasks/archive/pulumi.yml b/tasks/archive/pulumi.yml index 9630459..f74c30d 100644 --- a/tasks/archive/pulumi.yml +++ b/tasks/archive/pulumi.yml @@ -1,22 +1,31 @@ # vim: set filetype=yaml.ansible : --- -- name: Download pulumi archive - ansible.builtin.get_url: - dest: "{{ d_tempdir.path }}/{{ pulumi.archive }}" - url: "{{ pulumi.dlurl }}" - decompress: false - mode: '0644' - -- name: Extract pulumi archive - become: "{{ ext_become }}" - ansible.builtin.unarchive: - dest: "{{ path.archive }}" - src: "{{ d_tempdir.path }}/{{ pulumi.archive }}" - remote_src: true - -- name: Link pulumi executable - become: "{{ ext_become }}" - ansible.builtin.file: - state: link - src: "{{ path.archive }}/pulumi/pulumi" +- name: Check if pulumi is installed + register: stat_pulumi_inst + ansible.builtin.stat: path: "{{ path.bin }}/pulumi" + +- name: Install pulumi if not installed + when: + - not stat_pulumi_inst.stat.exists + block: + - name: Download pulumi archive + ansible.builtin.get_url: + dest: "{{ d_tempdir.path }}/{{ pulumi.archive }}" + url: "{{ pulumi.dlurl }}" + decompress: false + mode: '0644' + + - name: Extract pulumi archive + become: "{{ ext_become }}" + ansible.builtin.unarchive: + dest: "{{ path.archive }}" + src: "{{ d_tempdir.path }}/{{ pulumi.archive }}" + remote_src: true + + - name: Link pulumi executable + become: "{{ ext_become }}" + ansible.builtin.file: + state: link + src: "{{ path.archive }}/pulumi/pulumi" + path: "{{ path.bin }}/pulumi" diff --git a/tasks/cargo.yml b/tasks/cargo.yml index 508bf72..06f76b1 100644 --- a/tasks/cargo.yml +++ b/tasks/cargo.yml @@ -6,4 +6,4 @@ name: "{{ pkg.name | default(pkg) }}" version: "{{ pkg.vers | default(omit) }}" path: "{{ paths.cargo | default(omit) }}" - locked: "{{ pkg.locked | default(true) }}" + locked: "{{ pkg.locked | default(omit) }}" diff --git a/tasks/config/hypridle.yml b/tasks/config/hypridle.yml new file mode 100644 index 0000000..b59a84c --- /dev/null +++ b/tasks/config/hypridle.yml @@ -0,0 +1,9 @@ +- name: Set hypridle config + ansible.builtin.set_fact: + hypridle: + vers: "{{ pkgconfig.hypridle.version }}" + repo: "{{ pkgconfig.hypridle.repo }}" + pkg_deps: "{{ pkgconfig.hypridle.pkg_deps }}" + build_deps: "{{ pkgconfig.hypridle.build_deps[ansible_os_family] }}" + installed_files: "{{ pkgconfig.hypridle.build_installed_files}}" + git_path: "{{ d_tempdir.path }}/hypridle" diff --git a/tasks/config/hyprland_qt_support.yml b/tasks/config/hyprland_qt_support.yml new file mode 100644 index 0000000..1cf7397 --- /dev/null +++ b/tasks/config/hyprland_qt_support.yml @@ -0,0 +1,9 @@ +- name: Set hyprland_qt_support config + ansible.builtin.set_fact: + hyprland_qt_support: + vers: "{{ pkgconfig.hyprland_qt_support.version }}" + repo: "{{ pkgconfig.hyprland_qt_support.repo }}" + pkg_deps: "{{ pkgconfig.hyprland_qt_support.pkg_deps }}" + build_deps: "{{ pkgconfig.hyprland_qt_support.build_deps[ansible_os_family] }}" + installed_files: "{{ pkgconfig.hyprland_qt_support.build_installed_files}}" + git_path: "{{ d_tempdir.path }}/hyprland_qt_support" diff --git a/tasks/config/hyprland_qtutils.yml b/tasks/config/hyprland_qtutils.yml new file mode 100644 index 0000000..0ed1ec4 --- /dev/null +++ b/tasks/config/hyprland_qtutils.yml @@ -0,0 +1,9 @@ +- name: Set hyprland_qtutils config + ansible.builtin.set_fact: + hyprland_qtutils: + vers: "{{ pkgconfig.hyprland_qtutils.version }}" + repo: "{{ pkgconfig.hyprland_qtutils.repo }}" + pkg_deps: "{{ pkgconfig.hyprland_qtutils.pkg_deps }}" + build_deps: "{{ pkgconfig.hyprland_qtutils.build_deps[ansible_os_family] }}" + installed_files: "{{ pkgconfig.hyprland_qtutils.build_installed_files}}" + git_path: "{{ d_tempdir.path }}/hyprland_qtutils" diff --git a/tasks/config/hyprlock.yml b/tasks/config/hyprlock.yml new file mode 100644 index 0000000..1eadc3a --- /dev/null +++ b/tasks/config/hyprlock.yml @@ -0,0 +1,9 @@ +- name: Set hyprlock config + ansible.builtin.set_fact: + hyprlock: + vers: "{{ pkgconfig.hyprlock.version }}" + repo: "{{ pkgconfig.hyprlock.repo }}" + pkg_deps: "{{ pkgconfig.hyprlock.pkg_deps }}" + build_deps: "{{ pkgconfig.hyprlock.build_deps[ansible_os_family] }}" + installed_files: "{{ pkgconfig.hyprlock.build_installed_files}}" + git_path: "{{ d_tempdir.path }}/hyprlock" diff --git a/tasks/config/hyprpaper.yml b/tasks/config/hyprpaper.yml new file mode 100644 index 0000000..d18b6ad --- /dev/null +++ b/tasks/config/hyprpaper.yml @@ -0,0 +1,9 @@ +- name: Set hyprpaper config + ansible.builtin.set_fact: + hyprpaper: + vers: "{{ pkgconfig.hyprpaper.version }}" + repo: "{{ pkgconfig.hyprpaper.repo }}" + pkg_deps: "{{ pkgconfig.hyprpaper.pkg_deps }}" + build_deps: "{{ pkgconfig.hyprpaper.build_deps[ansible_os_family] }}" + installed_files: "{{ pkgconfig.hyprpaper.build_installed_files}}" + git_path: "{{ d_tempdir.path }}/hyprpaper" diff --git a/tasks/config/hyprpicker.yml b/tasks/config/hyprpicker.yml new file mode 100644 index 0000000..acd358a --- /dev/null +++ b/tasks/config/hyprpicker.yml @@ -0,0 +1,9 @@ +- name: Set hyprpicker config + ansible.builtin.set_fact: + hyprpicker: + vers: "{{ pkgconfig.hyprpicker.version }}" + repo: "{{ pkgconfig.hyprpicker.repo }}" + pkg_deps: "{{ pkgconfig.hyprpicker.pkg_deps }}" + build_deps: "{{ pkgconfig.hyprpicker.build_deps[ansible_os_family] }}" + installed_files: "{{ pkgconfig.hyprpicker.build_installed_files}}" + git_path: "{{ d_tempdir.path }}/hyprpicker" diff --git a/tasks/config/terraform.yml b/tasks/config/terraform.yml index ab98cc3..129d2d7 100644 --- a/tasks/config/terraform.yml +++ b/tasks/config/terraform.yml @@ -10,8 +10,10 @@ pkgs: "{{ pkgconfig.terraform.pkgs[ansible_system] }}" - name: Set terraform archive config + when: + - terraform.method == 'archive' ansible.builtin.set_fact: terraform: method: "{{ terraform.method }}" - url: "{{ pkgconfig.terraform.baseurl }}/terraform/{{ pkgconfig.terraform.version }}" + url: "{{ pkgconfig.terraform.archive.baseurl }}/terraform/{{ pkgconfig.terraform.version }}" file: "terraform_{{ pkgconfig.terraform.version }}_linux_amd64.zip" diff --git a/tasks/main.yml b/tasks/main.yml index c7079be..8b18dff 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -7,6 +7,7 @@ ansible.builtin.file: path: /tmp/ansible_role_package state: directory + mode: '0777' - name: Set installation facts ansible.builtin.include_tasks: @@ -39,6 +40,12 @@ - name: Flush handlers to ensure dependencies are installed ansible.builtin.meta: flush_handlers +- name: Add needed packages for Fedora + when: + - ansible_distribution == 'Fedora' + ansible.builtin.set_fact: + pkg_sys: "{{ pkg_sys + ['python3-paramiko'] }}" + - name: Add needed MacOS packages when: - ansible_distribution == 'MacOSX' diff --git a/tasks/npm.yml b/tasks/npm.yml index e0c3a0a..1afab30 100644 --- a/tasks/npm.yml +++ b/tasks/npm.yml @@ -1,7 +1,7 @@ # vim: set filetype=yaml.ansible : --- - name: Install npm {{ pkg }} - become: "{{ ext_become }}" + become: true community.general.npm: global: true name: "{{ pkg }}" diff --git a/tasks/pkgs/hypridle.yml b/tasks/pkgs/hypridle.yml new file mode 100644 index 0000000..6bd5cd6 --- /dev/null +++ b/tasks/pkgs/hypridle.yml @@ -0,0 +1,30 @@ +# vim: set filetype=yaml.ansible : +--- +- name: Add hypridle + when: + - hypridle_configured is undefined + block: + - name: Load hypridle config + ansible.builtin.include_tasks: + file: config/hypridle.yml + + - name: Append hypridle pkg_deps + loop: "{{ hypridle.pkg_deps }}" + loop_control: + loop_var: hypridle_pkg_dep + vars: + pkg: "{{ hypridle_pkg_dep }}" + ansible.builtin.include_tasks: + file: "pkgs/{{ hypridle_pkg_dep }}.yml" + + - name: Append hypridle build_deps to pkg_sys + ansible.builtin.set_fact: + pkg_sys: "{{ pkg_sys + hypridle.build_deps }}" + + - name: Append hypridle to pkg_src + ansible.builtin.set_fact: + pkg_src: "{{ pkg_src + ['hypridle'] }}" + + - name: Set hypridle_configured + ansible.builtin.set_fact: + hypridle_configured: true diff --git a/tasks/pkgs/hyprland_qt_support.yml b/tasks/pkgs/hyprland_qt_support.yml new file mode 100644 index 0000000..befe587 --- /dev/null +++ b/tasks/pkgs/hyprland_qt_support.yml @@ -0,0 +1,30 @@ +# vim: set filetype=yaml.ansible : +--- +- name: Add hyprland_qt_support + when: + - hyprland_qt_support_configured is undefined + block: + - name: Load hyprland_qt_support config + ansible.builtin.include_tasks: + file: config/hyprland_qt_support.yml + + - name: Append hyprland_qt_support pkg_deps + loop: "{{ hyprland_qt_support.pkg_deps }}" + loop_control: + loop_var: hyprland_qt_support_pkg_dep + vars: + pkg: "{{ hyprland_qt_support_pkg_dep }}" + ansible.builtin.include_tasks: + file: "pkgs/{{ hyprland_qt_support_pkg_dep }}.yml" + + - name: Append hyprland_qt_support build_deps to pkg_sys + ansible.builtin.set_fact: + pkg_sys: "{{ pkg_sys + hyprland_qt_support.build_deps }}" + + - name: Append hyprland_qt_support to pkg_src + ansible.builtin.set_fact: + pkg_src: "{{ pkg_src + ['hyprland_qt_support'] }}" + + - name: Set hyprland_qt_support_configured + ansible.builtin.set_fact: + hyprland_qt_support_configured: true diff --git a/tasks/pkgs/hyprland_qtutils.yml b/tasks/pkgs/hyprland_qtutils.yml new file mode 100644 index 0000000..20dff90 --- /dev/null +++ b/tasks/pkgs/hyprland_qtutils.yml @@ -0,0 +1,30 @@ +# vim: set filetype=yaml.ansible : +--- +- name: Add hyprland_qtutils + when: + - hyprland_qtutils_configured is undefined + block: + - name: Load hyprland_qtutils config + ansible.builtin.include_tasks: + file: config/hyprland_qtutils.yml + + - name: Append hyprland_qtutils pkg_deps + loop: "{{ hyprland_qtutils.pkg_deps }}" + loop_control: + loop_var: hyprland_qtutils_pkg_dep + vars: + pkg: "{{ hyprland_qtutils_pkg_dep }}" + ansible.builtin.include_tasks: + file: "pkgs/{{ hyprland_qtutils_pkg_dep }}.yml" + + - name: Append hyprland_qtutils build_deps to pkg_sys + ansible.builtin.set_fact: + pkg_sys: "{{ pkg_sys + hyprland_qtutils.build_deps }}" + + - name: Append hyprland_qtutils to pkg_src + ansible.builtin.set_fact: + pkg_src: "{{ pkg_src + ['hyprland_qtutils'] }}" + + - name: Set hyprland_qtutils_configured + ansible.builtin.set_fact: + hyprland_qtutils_configured: true diff --git a/tasks/pkgs/hyprlock.yml b/tasks/pkgs/hyprlock.yml new file mode 100644 index 0000000..60b9554 --- /dev/null +++ b/tasks/pkgs/hyprlock.yml @@ -0,0 +1,30 @@ +# vim: set filetype=yaml.ansible : +--- +- name: Add hyprlock + when: + - hyprlock_configured is undefined + block: + - name: Load hyprlock config + ansible.builtin.include_tasks: + file: config/hyprlock.yml + + - name: Append hyprlock pkg_deps + loop: "{{ hyprlock.pkg_deps }}" + loop_control: + loop_var: hyprlock_pkg_dep + vars: + pkg: "{{ hyprlock_pkg_dep }}" + ansible.builtin.include_tasks: + file: "pkgs/{{ hyprlock_pkg_dep }}.yml" + + - name: Append hyprlock build_deps to pkg_sys + ansible.builtin.set_fact: + pkg_sys: "{{ pkg_sys + hyprlock.build_deps }}" + + - name: Append hyprlock to pkg_src + ansible.builtin.set_fact: + pkg_src: "{{ pkg_src + ['hyprlock'] }}" + + - name: Set hyprlock_configured + ansible.builtin.set_fact: + hyprlock_configured: true diff --git a/tasks/pkgs/hyprpaper.yml b/tasks/pkgs/hyprpaper.yml new file mode 100644 index 0000000..2de0526 --- /dev/null +++ b/tasks/pkgs/hyprpaper.yml @@ -0,0 +1,30 @@ +# vim: set filetype=yaml.ansible : +--- +- name: Add hyprpaper + when: + - hyprpaper_configured is undefined + block: + - name: Load hyprpaper config + ansible.builtin.include_tasks: + file: config/hyprpaper.yml + + - name: Append hyprpaper pkg_deps + loop: "{{ hyprpaper.pkg_deps }}" + loop_control: + loop_var: hyprpaper_pkg_dep + vars: + pkg: "{{ hyprpaper_pkg_dep }}" + ansible.builtin.include_tasks: + file: "pkgs/{{ hyprpaper_pkg_dep }}.yml" + + - name: Append hyprpaper build_deps to pkg_sys + ansible.builtin.set_fact: + pkg_sys: "{{ pkg_sys + hyprpaper.build_deps }}" + + - name: Append hyprpaper to pkg_src + ansible.builtin.set_fact: + pkg_src: "{{ pkg_src + ['hyprpaper'] }}" + + - name: Set hyprpaper_configured + ansible.builtin.set_fact: + hyprpaper_configured: true diff --git a/tasks/pkgs/hyprpicker.yml b/tasks/pkgs/hyprpicker.yml new file mode 100644 index 0000000..4077459 --- /dev/null +++ b/tasks/pkgs/hyprpicker.yml @@ -0,0 +1,30 @@ +# vim: set filetype=yaml.ansible : +--- +- name: Add hyprpicker + when: + - hyprpicker_configured is undefined + block: + - name: Load hyprpicker config + ansible.builtin.include_tasks: + file: config/hyprpicker.yml + + - name: Append hyprpicker pkg_deps + loop: "{{ hyprpicker.pkg_deps }}" + loop_control: + loop_var: hyprpicker_pkg_dep + vars: + pkg: "{{ hyprpicker_pkg_dep }}" + ansible.builtin.include_tasks: + file: "pkgs/{{ hyprpicker_pkg_dep }}.yml" + + - name: Append hyprpicker build_deps to pkg_sys + ansible.builtin.set_fact: + pkg_sys: "{{ pkg_sys + hyprpicker.build_deps }}" + + - name: Append hyprpicker to pkg_src + ansible.builtin.set_fact: + pkg_src: "{{ pkg_src + ['hyprpicker'] }}" + + - name: Set hyprpicker_configured + ansible.builtin.set_fact: + hyprpicker_configured: true diff --git a/tasks/src/aquamarine.yml b/tasks/src/aquamarine.yml index 50b19ca..7f160ce 100644 --- a/tasks/src/aquamarine.yml +++ b/tasks/src/aquamarine.yml @@ -26,6 +26,8 @@ version: "{{ aquamarine.vers }}" - name: Apply patch for alpine linux + when: + - ansible_os_family == 'Alpine' ansible.posix.patch: basedir: "{{ aquamarine.git_path }}" src: aquamarine/Alpine.patch diff --git a/tasks/src/hypridle.yml b/tasks/src/hypridle.yml new file mode 100644 index 0000000..42e8d7f --- /dev/null +++ b/tasks/src/hypridle.yml @@ -0,0 +1,72 @@ +- name: Remove existing install + when: + - hyprland_clean + become: "{{ ext_become }}" + loop: "{{ hypridle.installed_files }}" + loop_control: + loop_var: file + ansible.builtin.file: + state: absent + path: "{{ hyprland.prefix }}/{{ file }}" + +- name: Check if hypridle is installed + register: stat_hypridle_bin + ansible.builtin.stat: + path: "{{ hyprland.prefix }}/bin/hypridle" + +- name: Build and install hypridle + when: + - not stat_hypridle_bin.stat.exists + block: + - name: Clone git repository + ansible.builtin.git: + depth: 1 + dest: "{{ hypridle.git_path }}" + recursive: true + repo: "{{ hypridle.repo }}" + version: "{{ hypridle.vers }}" + + - name: Apply cmakelists patch + ansible.posix.patch: + basedir: "{{ hypridle.git_path }}" + src: hypridle/cmakelists.patch + state: present + + - name: Configure hypridle + ansible.builtin.command: + creates: "{{ hypridle.git_path }}/build" + chdir: "{{ hypridle.git_path }}" + argv: + - cmake + - --no-warn-unused-cli + - -DCMAKE_BUILD_TYPE:STRING=Release + - -DCMAKE_INSTALL_PREFIX:PATH={{ hyprland.prefix }} + - -S + - . + - -B + - ./build + + - name: Build hypridle + ansible.builtin.command: + creates: "{{ hypridle.git_path }}/build/hypridle" + chdir: "{{ hypridle.git_path }}" + argv: + - cmake + - --build + - ./build + - --config + - Release + - --target + - all + - -j + - "{{ ansible_processor_nproc|int }}" + + - name: Install hypridle + become: true + ansible.builtin.command: + creates: "{{ path.bin }}/hypridle" + chdir: "{{ hypridle.git_path }}" + argv: + - cmake + - --install + - ./build diff --git a/tasks/src/hyprland_qt_support.yml b/tasks/src/hyprland_qt_support.yml new file mode 100644 index 0000000..851b98b --- /dev/null +++ b/tasks/src/hyprland_qt_support.yml @@ -0,0 +1,67 @@ +- name: Remove existing install + when: + - hyprland_clean + become: "{{ ext_become }}" + loop: "{{ hyprland_qt_support.installed_files }}" + loop_control: + loop_var: file + ansible.builtin.file: + state: absent + path: "{{ hyprland.prefix }}/{{ file }}" + +- name: Check if hyprland_qt_support is installed + register: stat_hyprland_qt_support_bin + ansible.builtin.stat: + path: "{{ hyprland.prefix }}/bin/hyprland_qt_support" + +- name: Build and install hyprland_qt_support + when: + - not stat_hyprland_qt_support_bin.stat.exists + block: + - name: Clone git repository + ansible.builtin.git: + depth: 1 + dest: "{{ hyprland_qt_support.git_path }}" + recursive: true + repo: "{{ hyprland_qt_support.repo }}" + version: "{{ hyprland_qt_support.vers }}" + + - name: Configure hyprland_qt_support + ansible.builtin.command: + creates: "{{ hyprland_qt_support.git_path }}/build" + chdir: "{{ hyprland_qt_support.git_path }}" + argv: + - cmake + - --no-warn-unused-cli + - -DCMAKE_BUILD_TYPE:STRING=Release + - -DCMAKE_INSTALL_PREFIX:PATH={{ hyprland.prefix }} + - -DINSTALL_QML_PREFIX=/lib/qt6/qml + - -S + - . + - -B + - ./build + + - name: Build hyprland_qt_support + ansible.builtin.command: + creates: "{{ hyprland_qt_support.git_path }}/build/hyprland_qt_support" + chdir: "{{ hyprland_qt_support.git_path }}" + argv: + - cmake + - --build + - ./build + - --config + - Release + - --target + - all + - -j + - "{{ ansible_processor_nproc|int }}" + + - name: Install hyprland_qt_support + become: true + ansible.builtin.command: + creates: "{{ path.bin }}/hyprland_qt_support" + chdir: "{{ hyprland_qt_support.git_path }}" + argv: + - cmake + - --install + - ./build diff --git a/tasks/src/hyprland_qtutils.yml b/tasks/src/hyprland_qtutils.yml new file mode 100644 index 0000000..e208ae2 --- /dev/null +++ b/tasks/src/hyprland_qtutils.yml @@ -0,0 +1,66 @@ +- name: Remove existing install + when: + - hyprland_clean + become: "{{ ext_become }}" + loop: "{{ hyprland_qtutils.installed_files }}" + loop_control: + loop_var: file + ansible.builtin.file: + state: absent + path: "{{ hyprland.prefix }}/{{ file }}" + +- name: Check if hyprland_qtutils is installed + register: stat_hyprland_qtutils_bin + ansible.builtin.stat: + path: "{{ hyprland.prefix }}/bin/hyprland_qtutils" + +- name: Build and install hyprland_qtutils + when: + - not stat_hyprland_qtutils_bin.stat.exists + block: + - name: Clone git repository + ansible.builtin.git: + depth: 1 + dest: "{{ hyprland_qtutils.git_path }}" + recursive: true + repo: "{{ hyprland_qtutils.repo }}" + version: "{{ hyprland_qtutils.vers }}" + + - name: Configure hyprland_qtutils + ansible.builtin.command: + creates: "{{ hyprland_qtutils.git_path }}/build" + chdir: "{{ hyprland_qtutils.git_path }}" + argv: + - cmake + - --no-warn-unused-cli + - -DCMAKE_BUILD_TYPE:STRING=Release + - -DCMAKE_INSTALL_PREFIX:PATH={{ hyprland.prefix }} + - -S + - . + - -B + - ./build + + - name: Build hyprland_qtutils + ansible.builtin.command: + creates: "{{ hyprland_qtutils.git_path }}/build/hyprland_qtutils" + chdir: "{{ hyprland_qtutils.git_path }}" + argv: + - cmake + - --build + - ./build + - --config + - Release + - --target + - all + - -j + - "{{ ansible_processor_nproc|int }}" + + - name: Install hyprland_qtutils + become: true + ansible.builtin.command: + creates: "{{ path.bin }}/hyprland_qtutils" + chdir: "{{ hyprland_qtutils.git_path }}" + argv: + - cmake + - --install + - ./build diff --git a/tasks/src/hyprlock.yml b/tasks/src/hyprlock.yml new file mode 100644 index 0000000..d4d8044 --- /dev/null +++ b/tasks/src/hyprlock.yml @@ -0,0 +1,72 @@ +- name: Remove existing install + when: + - hyprland_clean + become: "{{ ext_become }}" + loop: "{{ hyprlock.installed_files }}" + loop_control: + loop_var: file + ansible.builtin.file: + state: absent + path: "{{ hyprland.prefix }}/{{ file }}" + +- name: Check if hyprlock is installed + register: stat_hyprlock_bin + ansible.builtin.stat: + path: "{{ hyprland.prefix }}/bin/hyprlock" + +- name: Build and install hyprlock + when: + - not stat_hyprlock_bin.stat.exists + block: + - name: Clone git repository + ansible.builtin.git: + depth: 1 + dest: "{{ hyprlock.git_path }}" + recursive: true + repo: "{{ hyprlock.repo }}" + version: "{{ hyprlock.vers }}" + + - name: Apply cmakelists patch + ansible.posix.patch: + basedir: "{{ hyprlock.git_path }}" + src: hyprlock/cmakelists.patch + state: present + + - name: Configure hyprlock + ansible.builtin.command: + creates: "{{ hyprlock.git_path }}/build" + chdir: "{{ hyprlock.git_path }}" + argv: + - cmake + - --no-warn-unused-cli + - -DCMAKE_BUILD_TYPE:STRING=Release + - -DCMAKE_INSTALL_PREFIX:PATH={{ hyprland.prefix }} + - -S + - . + - -B + - ./build + + - name: Build hyprlock + ansible.builtin.command: + creates: "{{ hyprlock.git_path }}/build/hyprlock" + chdir: "{{ hyprlock.git_path }}" + argv: + - cmake + - --build + - ./build + - --config + - Release + - --target + - all + - -j + - "{{ ansible_processor_nproc|int }}" + + - name: Install hyprlock + become: true + ansible.builtin.command: + creates: "{{ path.bin }}/hyprlock" + chdir: "{{ hyprlock.git_path }}" + argv: + - cmake + - --install + - ./build diff --git a/tasks/src/hyprpaper.yml b/tasks/src/hyprpaper.yml new file mode 100644 index 0000000..5192510 --- /dev/null +++ b/tasks/src/hyprpaper.yml @@ -0,0 +1,66 @@ +- name: Remove existing install + when: + - hyprland_clean + become: "{{ ext_become }}" + loop: "{{ hyprpaper.installed_files }}" + loop_control: + loop_var: file + ansible.builtin.file: + state: absent + path: "{{ hyprland.prefix }}/{{ file }}" + +- name: Check if hyprpaper is installed + register: stat_hyprpaper_bin + ansible.builtin.stat: + path: "{{ hyprland.prefix }}/bin/hyprpaper" + +- name: Build and install hyprpaper + when: + - not stat_hyprpaper_bin.stat.exists + block: + - name: Clone git repository + ansible.builtin.git: + depth: 1 + dest: "{{ hyprpaper.git_path }}" + recursive: true + repo: "{{ hyprpaper.repo }}" + version: "{{ hyprpaper.vers }}" + + - name: Configure hyprpaper + ansible.builtin.command: + creates: "{{ hyprpaper.git_path }}/build" + chdir: "{{ hyprpaper.git_path }}" + argv: + - cmake + - --no-warn-unused-cli + - -DCMAKE_BUILD_TYPE:STRING=Release + - -DCMAKE_INSTALL_PREFIX:PATH={{ hyprland.prefix }} + - -S + - . + - -B + - ./build + + - name: Build hyprpaper + ansible.builtin.command: + creates: "{{ hyprpaper.git_path }}/build/hyprpaper" + chdir: "{{ hyprpaper.git_path }}" + argv: + - cmake + - --build + - ./build + - --config + - Release + - --target + - all + - -j + - "{{ ansible_processor_nproc|int }}" + + - name: Install hyprpaper + become: true + ansible.builtin.command: + creates: "{{ path.bin }}/hyprpaper" + chdir: "{{ hyprpaper.git_path }}" + argv: + - cmake + - --install + - ./build diff --git a/tasks/src/hyprpicker.yml b/tasks/src/hyprpicker.yml new file mode 100644 index 0000000..e31b845 --- /dev/null +++ b/tasks/src/hyprpicker.yml @@ -0,0 +1,66 @@ +- name: Remove existing install + when: + - hyprland_clean + become: "{{ ext_become }}" + loop: "{{ hyprpicker.installed_files }}" + loop_control: + loop_var: file + ansible.builtin.file: + state: absent + path: "{{ hyprland.prefix }}/{{ file }}" + +- name: Check if hyprpicker is installed + register: stat_hyprpicker_bin + ansible.builtin.stat: + path: "{{ hyprland.prefix }}/bin/hyprpicker" + +- name: Build and install hyprpicker + when: + - not stat_hyprpicker_bin.stat.exists + block: + - name: Clone git repository + ansible.builtin.git: + depth: 1 + dest: "{{ hyprpicker.git_path }}" + recursive: true + repo: "{{ hyprpicker.repo }}" + version: "{{ hyprpicker.vers }}" + + - name: Configure hyprpicker + ansible.builtin.command: + creates: "{{ hyprpicker.git_path }}/build" + chdir: "{{ hyprpicker.git_path }}" + argv: + - cmake + - --no-warn-unused-cli + - -DCMAKE_BUILD_TYPE:STRING=Release + - -DCMAKE_INSTALL_PREFIX:PATH={{ hyprland.prefix }} + - -S + - . + - -B + - ./build + + - name: Build hyprpicker + ansible.builtin.command: + creates: "{{ hyprpicker.git_path }}/build/hyprpicker" + chdir: "{{ hyprpicker.git_path }}" + argv: + - cmake + - --build + - ./build + - --config + - Release + - --target + - all + - -j + - "{{ ansible_processor_nproc|int }}" + + - name: Install hyprpicker + become: true + ansible.builtin.command: + creates: "{{ path.bin }}/hyprpicker" + chdir: "{{ hyprpicker.git_path }}" + argv: + - cmake + - --install + - ./build diff --git a/vars/pkgs/carapace.yml b/vars/pkgs/carapace.yml index acd1372..e76ecdb 100644 --- a/vars/pkgs/carapace.yml +++ b/vars/pkgs/carapace.yml @@ -1,7 +1,9 @@ carapace: version: 0.2.0 pkgs: - Linux: + Debina: + - carapace-bin + RedHat: - carapace-bin Darwin: - carapace diff --git a/vars/pkgs/hypridle.yml b/vars/pkgs/hypridle.yml new file mode 100644 index 0000000..503b421 --- /dev/null +++ b/vars/pkgs/hypridle.yml @@ -0,0 +1,15 @@ +hypridle: + version: v0.1.5 + repo: "{{ hyprgitbase }}/hypridle" + pkg_deps: + - hyprlang + - hyprwayland_scanner + - sdbus_cpp_2 + build_deps: + RedHat: + - wayland-devel + - wayland-protocols-devel + build_installed_files: + - bin/hypridle + - lib/systemd/user/hypridle.service + - share/hypr/hypridle.conf diff --git a/vars/pkgs/hyprland.yml b/vars/pkgs/hyprland.yml index 251d07b..ec33918 100644 --- a/vars/pkgs/hyprland.yml +++ b/vars/pkgs/hyprland.yml @@ -12,6 +12,12 @@ hyprland: - hyprgraphics - aquamarine - hyprpolkitagent + - hyprland_qtutils + - hyprlock + - hypridle + - hyprpaper + - hyprpicker + - hyprland_qt_support - xdg_desktop_portal_hyprland build_deps: RedHat: @@ -32,8 +38,7 @@ hyprland: - meson - pango-devel - pixman-devel - - qt5-qtwayland - - qt6-qtwayland + - qt6-qtwayland-devel - re2-devel - systemd-devel - tomlplusplus-devel diff --git a/vars/pkgs/hyprland_qt_support.yml b/vars/pkgs/hyprland_qt_support.yml new file mode 100644 index 0000000..f99d1bb --- /dev/null +++ b/vars/pkgs/hyprland_qt_support.yml @@ -0,0 +1,22 @@ +hyprland_qt_support: + version: v0.1.0 + repo: "{{ hyprgitbase }}/hyprland-qt-support" + pkg_deps: + - hyprlang + build_deps: + RedHat: + - qt6-qtdeclarative-devel + build_installed_files: + - lib/libhyprland-quick-style-impl.so + - lib/qt6/qml/org/hyprland/style/impl/libhyprland-quick-style-implplugin.so + - lib/qt6/qml/org/hyprland/style/impl/qmldir + - lib/qt6/qml/org/hyprland/style/impl/hyprland-quick-style-impl.qmltypes + - lib/qt6/qml/org/hyprland/style/impl/HyprlandStyle.qml + - lib/qt6/qml/org/hyprland/style/impl/MotionBehavior.qml + - lib/libhyprland-quick-style.so + - lib/qt6/qml/org/hyprland/style/libhyprland-quick-styleplugin.so + - lib/qt6/qml/org/hyprland/style/qmldir + - lib/qt6/qml/org/hyprland/style/hyprland-quick-style.qmltypes + - lib/qt6/qml/org/hyprland/style/Button.qml + - lib/qt6/qml/org/hyprland/style/CheckBox.qml + - lib/qt6/qml/org/hyprland/style/TextField.qml diff --git a/vars/pkgs/hyprland_qtutils.yml b/vars/pkgs/hyprland_qtutils.yml new file mode 100644 index 0000000..d02cc3f --- /dev/null +++ b/vars/pkgs/hyprland_qtutils.yml @@ -0,0 +1,17 @@ +hyprland_qtutils: + version: v0.1.3 + repo: "{{ hyprgitbase }}/hyprland-qtutils" + pkg_deps: + - hyprutils + build_deps: + RedHat: + - qt6-qtbase-private-devel + - qt6-qtbase-devel + - qt6-qtdeclarative-devel + - wayland-devel + - wayland-protocols-devel + - qt6-qtwayland-devel + build_installed_files: + - bin/hyprland-dialog + - bin/hyprland-update-screen + - bin/hyprland-donate-screen diff --git a/vars/pkgs/hyprpaper.yml b/vars/pkgs/hyprpaper.yml new file mode 100644 index 0000000..1b9e8c3 --- /dev/null +++ b/vars/pkgs/hyprpaper.yml @@ -0,0 +1,22 @@ +hyprpaper: + version: v0.7.4 + repo: "{{ hyprgitbase }}/hyprpaper" + pkg_deps: + - hyprlang + - hyprutils + - hyprgraphics + - hyprwayland_scanner + build_deps: + RedHat: + - wayland-devel + - wayland-protocols-devel + - pango-devel + - cairo-devel + - file-devel + - libglvnd-devel + - libjpeg-turbo-devel + - libwebp-devel + - gcc-c++ + build_installed_files: + - bin/hyprpaper + - "{{ lib_path }}/systemd/user/hyprpaper.service" diff --git a/vars/pkgs/hyprpolkitagent.yml b/vars/pkgs/hyprpolkitagent.yml index e4ae9f7..118b0e3 100644 --- a/vars/pkgs/hyprpolkitagent.yml +++ b/vars/pkgs/hyprpolkitagent.yml @@ -5,6 +5,7 @@ hyprpolkitagent: RedHat: - polkit-devel - polkit-qt6-1-devel + - qt6-qtdeclarative-devel Alpine: - polkit-dev - polkit-qt-dev diff --git a/vars/pkgs/hyrplock.yml b/vars/pkgs/hyrplock.yml new file mode 100644 index 0000000..168db8b --- /dev/null +++ b/vars/pkgs/hyrplock.yml @@ -0,0 +1,27 @@ +hyprlock: + version: v0.7.0 + repo: "{{ hyprgitbase }}/hyprlock" + pkg_deps: + - hyprlang + - hyprutils + - hyprgraphics + - hyprwayland_scanner + - sdbus_cpp_2 + build_deps: + RedHat: + - wayland-devel + - wayland-protocols-devel + - pango-devel + - cairo-devel + - libdrm-devel + - pam-devel + - file-devel + - libxkbcommon-devel + - libglvnd-devel + - libjpeg-turbo-devel + - libwebp-devel + - gcc-c++ + build_installed_files: + - bin/hyprlock + - etc/pam.d/hyprlock + - share/hypr/hyprlock.conf diff --git a/vars/pkgs/hyrppicker.yml b/vars/pkgs/hyrppicker.yml new file mode 100644 index 0000000..2005381 --- /dev/null +++ b/vars/pkgs/hyrppicker.yml @@ -0,0 +1,16 @@ +hyprpicker: + version: v0.4.2 + repo: "{{ hyprgitbase }}/hyprpicker" + pkg_deps: + - hyprutils + build_deps: + RedHat: + - wayland-devel + - wayland-protocols-devel + - pango-devel + - cairo-devel + - libxkbcommon-devel + - cmake + build_installed_files: + - bin/hyprpicker + - share/man/man1/hyprpicker.1 diff --git a/vars/pkgs/nodejs.yml b/vars/pkgs/nodejs.yml index 41d34dd..7049fe8 100644 --- a/vars/pkgs/nodejs.yml +++ b/vars/pkgs/nodejs.yml @@ -5,3 +5,4 @@ nodejs: Linux: - nodejs - npm + - sqlite