Remove verbose for pacman hook paccache, use fileglob for the copy

This commit is contained in:
Tunui Franken 2024-01-13 21:50:00 +01:00
parent b0d46fe81c
commit 81a4c0a225
6 changed files with 19 additions and 7 deletions

View file

@ -8,5 +8,5 @@ Target = *
[Action] [Action]
Description = Cleaning the pacman cache... Description = Cleaning the pacman cache...
When = PostTransaction When = PostTransaction
Exec = /usr/bin/paccache -rvk2 Exec = /usr/bin/paccache -rk2
Depends = pacman-contrib Depends = pacman-contrib

View file

@ -0,0 +1,12 @@
[Trigger]
Operation = Install
Operation = Upgrade
Operation = Remove
Type = Package
Target = *
[Action]
Description = Cleaning the pacman cache for uninstalled packages...
When = PostTransaction
Exec = /usr/bin/paccache -urk0
Depends = pacman-contrib

View file

@ -46,9 +46,9 @@
- name: Copy hooks - name: Copy hooks
become: true become: true
ansible.builtin.copy: src={{ item.src }} dest={{ item.dest }} mode=0644 backup=true ansible.builtin.copy:
with_items: src: "{{ item }}"
- {src: 'new_orphan.hook', dest: '/etc/pacman.d/hooks/new_orphan.hook'} dest: /etc/pacman.d/hooks/
- {src: 'pacdiff.hook', dest: '/etc/pacman.d/hooks/pacdiff.hook'} mode: 0644
- {src: 'mirrorupgrade.hook', dest: '/etc/pacman.d/hooks/mirrorupgrade.hook'} with_fileglob:
- {src: 'paccache.hook', dest: '/etc/pacman.d/hooks/paccache.hook'} - hooks/*