add archlinux installation methods

This commit is contained in:
2026-04-18 12:31:07 -06:00
parent cf20e639f0
commit f94a9cb8e5
13 changed files with 140 additions and 107 deletions

View File

@@ -8,12 +8,21 @@
---
- name: Set zig default facts
ansible.builtin.set_fact:
methods:
- archive
- system
version: "{{ zig_version | default('0.15.2') }}"
archive:
url: https://ziglang.org/download
zig:
methods:
default: [archive]
Archlinux: [system, archive]
pkgname:
default: zig
- name: Finalise zig default facts
ansible.builtin.set_fact:
zig:
methods: "{{ zig.methods[os_family] | default(zig.methods.default) }}"
pkgname: "{{ zig.pkgname[os_family] | default(zig.pkgname.default) }}"
version: "{{ zig_version | default('0.15.2') }}"
archive:
url: https://ziglang.org/download
- name: Configure zig
when:
@@ -29,7 +38,8 @@
when:
- zig_imethod == 'system'
ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + [zig.pkgname[os_family]] }}"
pkg_sys: "{{ pkg_sys + [zig.pkgname] }}"
zig_install: "{{ zig_imethod }}={{ zig.pkgname }}"
- name: Configure zig archive install
when: