53 lines
1.4 KiB
YAML
53 lines
1.4 KiB
YAML
---
|
|
- fail:
|
|
when: ansible_distribution != 'Archlinux'
|
|
|
|
- name: Set confs for pacman
|
|
become: true
|
|
block:
|
|
- name: Set HookDir
|
|
replace:
|
|
path: /etc/pacman.conf
|
|
regexp: "#HookDir"
|
|
replace: HookDir
|
|
backup: true
|
|
- name: Set Color
|
|
replace:
|
|
path: /etc/pacman.conf
|
|
regexp: "#Color"
|
|
replace: Color
|
|
backup: true
|
|
- name: Set TotalDownload
|
|
replace:
|
|
path: /etc/pacman.conf
|
|
regexp: "#TotalDownload"
|
|
replace: TotalDownload
|
|
backup: true
|
|
- name: Set CheckSpace
|
|
replace:
|
|
path: /etc/pacman.conf
|
|
regexp: "#CheckSpace"
|
|
replace: CheckSpace
|
|
backup: true
|
|
- name: Set VerbosePkgLists
|
|
replace:
|
|
path: /etc/pacman.conf
|
|
regexp: "#VerbosePkgLists"
|
|
replace: VerbosePkgLists
|
|
backup: true
|
|
|
|
- name: Make sure HookDir exists
|
|
become: true
|
|
file:
|
|
path: /etc/pacman.d/hooks
|
|
state: directory
|
|
mode: 0755
|
|
|
|
- name: Copy hooks
|
|
become: true
|
|
copy: src={{ item.src }} dest={{ item.dest }} backup=true
|
|
with_items:
|
|
- { src: 'new_orphan.hook', dest: '/etc/pacman.d/hooks/new_orphan.hook' }
|
|
- { src: 'pacdiff.hook', dest: '/etc/pacman.d/hooks/pacdiff.hook' }
|
|
- { src: 'mirrorupgrade.hook', dest: '/etc/pacman.d/hooks/mirrorupgrade.hook' }
|
|
- { src: 'paccache.hook', dest: '/etc/pacman.d/hooks/paccache.hook' }
|