working on more package, almost done

This commit is contained in:
2026-03-27 20:34:40 -06:00
parent 4a638d9dcc
commit 7f00bb70dc
21 changed files with 122 additions and 80 deletions

View File

@@ -1,33 +1,52 @@
# vim: set filetype=yaml.ansible :
---
- name: Set zsh default facts # {{{
ansible.builtin.set_fact:
zsh:
methods:
- system
pkgname:
RedHat: zsh
Debian: zsh
Alpine: zsh
Archlinux: zsh
# }}}
- name: Add zsh
when:
- "'zsh' not in __configured"
block:
- name: Set zsh install method
when:
- zsh_install_method is undefined
- zsh_imethod is undefined
ansible.builtin.set_fact:
zsh_install_method: "{{ install_method if install_method in zsh.install_methods else zsh.install_methods[0] }}"
zsh_imethod: "{{ imethod if imethod in zsh.methods else zsh.methods[0] }}"
- name: Append zsh to pkg_sys
when:
- zsh_install_method == 'system'
ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + ['zsh'] }}"
- zsh_imethod == 'system'
block:
- name: Queue zsh system install
ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + [zsh.pkgname[os_family]] }}"
- name: Finalise zsh system install
ansible.builtin.set_fact:
zsh_install: "{{ zsh_imethod }}={{ zsh.pkgname[os_family] }}"
- name: Configure zsh source install
when:
- zsh_install_method == 'source'
ansible.builtin.set_fact:
zsh_source_install:
build_deps:
build_flags:
source_dir:
repo: "{{ zsh_base_url }}"
version: "{{ zsh_version }}"
files:
- zsh_imethod == 'source'
block:
- name: Set zsh source install facts
ansible.builtin.set_fact:
zsh_source_install:
build_deps:
build_flags:
source_dir:
repo: "{{ zsh_base_url }}"
version: "{{ zsh_version }}"
files:
- name: Set zsh_configured
ansible.builtin.set_fact:
zsh_configured: true
__configured: "{{ __configured | combine( { 'zsh': zsh_install } ) }}"