Update pacman cache in handler rather that on every installation

This commit is contained in:
flyingscorpio@clevo 2022-03-17 22:44:35 +01:00
parent 7610f8dcc2
commit b70d0d8868
2 changed files with 15 additions and 1 deletions

View file

@ -0,0 +1,6 @@
---
- name: Update pacman cache
become: true
pacman:
update_cache: true
when: ansible_facts['distribution'] == 'Archlinux'

View file

@ -9,6 +9,10 @@
regexp: '^#\[multilib\]\n#(Include.*)'
replace: '[multilib]\n\1'
backup: true
notify: Update pacman cache
- name: Flush handlers
meta: flush_handlers
- name: Install packages
become: true
@ -65,5 +69,9 @@
- lib32-gst-plugins-base-libs
- vulkan-icd-loader
- lib32-vulkan-icd-loader
update_cache: true
when: ansible_facts['distribution'] == 'Archlinux'
- name: Add ~/Games directory
file:
path: ~/Games
state: directory