fixed packages to be more generic
This commit is contained in:
@@ -1,4 +1,12 @@
|
||||
# vim: set filetype=yaml.ansible :
|
||||
#
|
||||
## Variables:
|
||||
## appimage is top level:
|
||||
## name: symlink name, command used on CLI to launch
|
||||
## url: url to download appimage
|
||||
## filename: filename of appimage
|
||||
## mode: file mode of the appimage, optional
|
||||
## checksum: file checksum of appimage if available, optional
|
||||
---
|
||||
- name: Install appimages {{ appimage.name }}
|
||||
become: "{{ install_become }}"
|
||||
@@ -17,7 +25,7 @@
|
||||
mode: "{{ appimage.mode | default('0755') }}"
|
||||
owner: "{{ appimage.owner | default(ansible_user_id) }}"
|
||||
group: "{{ appimage.group | default(ansible_user_gid) }}"
|
||||
url: "{{ appimage.url }}"
|
||||
url: "{{ appimage.url }}/{{ appimage.filename }}"
|
||||
dest: "{{ path_appimage }}/{{ appimage.name }}/{{ appimage.filename }}"
|
||||
checksum: "{{ appimage.checksum | default(omit) }}"
|
||||
decompress: false
|
||||
|
||||
@@ -0,0 +1,43 @@
|
||||
# vim: set filetype=yaml.ansible :
|
||||
#
|
||||
## Package: 7zip
|
||||
## Description: tools to work with 7zip format compression
|
||||
## Version: system
|
||||
## Methods: [system]
|
||||
## Helpers: -
|
||||
---
|
||||
- name: Set 7zip default facts # {{{
|
||||
ansible.builtin.set_fact:
|
||||
7zip:
|
||||
methods:
|
||||
default: [system]
|
||||
pkgname:
|
||||
default: [7zip]
|
||||
- name: Finalise 7zip default facts
|
||||
ansible.builtin.set_fact:
|
||||
7zip:
|
||||
methods: "{{ 7zip.methods[os_family] | default(7zip.methods.default) }}"
|
||||
pkgname: "{{ 7zip.pkgname[os_family] | default(7zip.pkgname.default) }}"
|
||||
# }}}
|
||||
- name: Configure 7zip
|
||||
when:
|
||||
- "'7zip' not in __configured"
|
||||
block:
|
||||
- name: Set 7zip install method
|
||||
when:
|
||||
- 7zip_imethod is undefined
|
||||
ansible.builtin.set_fact:
|
||||
7zip_imethod: "{{ imethod if imethod in 7zip.methods else 7zip.methods[0] }}"
|
||||
|
||||
- name: Configure 7zip system install
|
||||
when:
|
||||
- 7zip_imethod == 'system'
|
||||
block:
|
||||
- name: Queue 7zip system install
|
||||
ansible.builtin.set_fact:
|
||||
pkg_sys: "{{ pkg_sys + [7zip.pkgname] }}"
|
||||
7zip_install: "{{ 7zip_imethod }}={{ 7zip.pkgname }}"
|
||||
|
||||
- name: Finalise 7zip configuration
|
||||
ansible.builtin.set_fact:
|
||||
__configured: "{{ __configured | combine( { '7zip': 7zip_install } ) }}"
|
||||
|
||||
@@ -38,12 +38,6 @@
|
||||
url: "{{ air.install_url }}@{{ air.version }}"
|
||||
bin: "{{ path_bin }}/air"
|
||||
|
||||
- name: Clean existing air install
|
||||
when:
|
||||
- clean_install
|
||||
ansible.builtin.set_fact:
|
||||
pkg_clean: "{{ pkg_clean + air.install_files }}"
|
||||
|
||||
- name: Configure pkg dependencies
|
||||
loop: "{{ air.pkg_deps }}"
|
||||
loop_control:
|
||||
@@ -53,9 +47,6 @@
|
||||
- name: Add air to install list
|
||||
ansible.builtin.set_fact:
|
||||
pkg_go: "{{ pkg_go + [air_go_pkg] }}"
|
||||
|
||||
- name: Finalise air source install
|
||||
ansible.builtin.set_fact:
|
||||
air_install: "{{ air_imethod }}={{ air_go_pkg }}"
|
||||
|
||||
- name: Finalize air configuration
|
||||
|
||||
@@ -10,16 +10,20 @@
|
||||
ansible.builtin.set_fact:
|
||||
ansible_ls:
|
||||
methods:
|
||||
- source
|
||||
- system
|
||||
default: [system, source]
|
||||
pkgname:
|
||||
default: ansible-language-server
|
||||
- name: Finalise ansible_ls default facts
|
||||
ansible.builtin.set_fact:
|
||||
ansible_ls:
|
||||
methods: "{{ ansible_ls.methods[os_family] | default(ansible_ls.methods.default) }}"
|
||||
pkgname: "{{ ansible_ls.pkgname[os_family] | default(ansible_ls.pkgname.default) }}"
|
||||
npm_pkg:
|
||||
name: '@ansible/ansible-language-server'
|
||||
global: true
|
||||
version: "{{ ansible_ls_version | default('latest') }}"
|
||||
pkg_deps:
|
||||
- nodejs
|
||||
pkgname:
|
||||
Archlinux: ansible-language-server
|
||||
# }}}
|
||||
- name: Configure ansible_ls
|
||||
when:
|
||||
@@ -37,8 +41,8 @@
|
||||
block:
|
||||
- name: Queue ansible_ls system install
|
||||
ansible.builtin.set_fact:
|
||||
pkg_sys: "{{ pkg_sys + [ansible_ls.pkgname[os_family]] }}"
|
||||
ansible_ls_install: "{{ ansible_ls_imethod }}={{ ansible_ls.pkgname[os_family] }}"
|
||||
pkg_sys: "{{ pkg_sys + [ansible_ls.pkgname] }}"
|
||||
ansible_ls_install: "{{ ansible_ls_imethod }}={{ ansible_ls.pkgname }}"
|
||||
|
||||
- name: Configure ansible_ls source install
|
||||
when:
|
||||
|
||||
@@ -10,13 +10,20 @@
|
||||
ansible.builtin.set_fact:
|
||||
cargo:
|
||||
methods:
|
||||
- system
|
||||
default: [system]
|
||||
pkgname:
|
||||
RedHat: cargo
|
||||
Debian: cargo
|
||||
Alpine: cargo
|
||||
FreeBSD: cargo
|
||||
default: cargo
|
||||
Archlinux: rust
|
||||
pkg_deps:
|
||||
default:
|
||||
- rust
|
||||
Archlinux: []
|
||||
- name: Finalise cargo default facts
|
||||
ansible.builtin.set_fact:
|
||||
cargo:
|
||||
methods: "{{ cargo.methods[os_family] | default(cargo.methods.default) }}"
|
||||
pkgname: "{{ cargo.pkgname[os_family] | default(cargo.pkgname.default) }}"
|
||||
pkg_deps: "{{ cargo.pkg_deps[os_family] | default(cargo.pkg_deps.default) }}"
|
||||
# }}}
|
||||
- name: Configure cargo
|
||||
when:
|
||||
@@ -28,25 +35,25 @@
|
||||
ansible.builtin.set_fact:
|
||||
cargo_imethod: "{{ imethod if imethod in cargo.methods else cargo.methods[0] }}"
|
||||
|
||||
- name: Add dependencies
|
||||
when:
|
||||
- cargo_pkgdeps is defined
|
||||
loop: "{{ cargo_pkgdeps }}"
|
||||
loop_control:
|
||||
loop_var: dep
|
||||
ansible.builtin.include_tasks: "pkgs/{{ dep }}.yml"
|
||||
|
||||
- name: Append cargo to install list
|
||||
when:
|
||||
- cargo_imethod == "system"
|
||||
block:
|
||||
- name: Add dependencies
|
||||
when:
|
||||
- cargo.pkg_deps is defined
|
||||
loop: "{{ cargo.pkg_deps }}"
|
||||
loop_control:
|
||||
loop_var: dep
|
||||
ansible.builtin.include_tasks: "pkgs/{{ dep }}.yml"
|
||||
|
||||
- name: Queue cargo install
|
||||
ansible.builtin.set_fact:
|
||||
pkg_sys: "{{ pkg_sys + [cargo.pkgname[os_family]] }}"
|
||||
pkg_sys: "{{ pkg_sys + [cargo.pkgname] }}"
|
||||
|
||||
- name: Finalise cargo system install
|
||||
ansible.builtin.set_fact:
|
||||
cargo_install: "{{ cargo_imethod }}={{ cargo.pkgname[os_family] }}"
|
||||
cargo_install: "{{ cargo_imethod }}={{ cargo.pkgname }}"
|
||||
|
||||
- name: Finalize cargo configuration
|
||||
ansible.builtin.set_fact:
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
ansible.builtin.set_fact:
|
||||
choose:
|
||||
methods: "{{ choose.methods[os_family] | default(choose.methods.default) }}"
|
||||
pkgname: "{{ choose.pkgname[os_family] | default(choose.methods.default)}}"
|
||||
pkgname: "{{ choose.pkgname[os_family] | default(choose.pkgname.default)}}"
|
||||
version: 1.3.7
|
||||
choose_install: undefined
|
||||
# }}}
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
# }}}
|
||||
- name: Configure dockerls
|
||||
when:
|
||||
- "'dockerls' not in _configured"
|
||||
- "'dockerls' not in __configured"
|
||||
block:
|
||||
- name: Set dockerls install method
|
||||
when:
|
||||
|
||||
@@ -10,8 +10,15 @@
|
||||
ansible.builtin.set_fact:
|
||||
eza:
|
||||
methods:
|
||||
- source
|
||||
- system
|
||||
Archlinux: [system, source]
|
||||
default: [source]
|
||||
pkgname:
|
||||
default: eza
|
||||
- name: Finalise eza default facts
|
||||
ansible.builtin.set_fact:
|
||||
eza:
|
||||
methods: "{{ eza.methods[os_family] | default(eza.methods.default) }}"
|
||||
pkgname: "{{ eza.pkgname[os_family] | default(eza.pkgname.default) }}"
|
||||
# }}}
|
||||
- name: Configure eza
|
||||
when:
|
||||
@@ -23,6 +30,15 @@
|
||||
ansible.builtin.set_fact:
|
||||
eza_imethod: "{{ imethod if imethod in eza.methods else eza.methods[0] }}"
|
||||
|
||||
- name: Configure eza system install
|
||||
when:
|
||||
- eza_imethod == 'system'
|
||||
block:
|
||||
- name: Queue eza system install
|
||||
ansible.builtin.set_fact:
|
||||
pkg_sys: "{{ pkg_sys + [eza.pkgname] }}"
|
||||
eza_install: "{{ eza_imethod }}={{ eza.pkgname }}"
|
||||
|
||||
- name: Configure eza source install
|
||||
when:
|
||||
- eza_imethod == "source"
|
||||
|
||||
@@ -14,7 +14,6 @@
|
||||
Alpine: [system, source, appimage]
|
||||
default: [source, appimage]
|
||||
pkgname:
|
||||
Archlinux: ghostty
|
||||
default: ghostty
|
||||
build_deps:
|
||||
default:
|
||||
@@ -49,24 +48,19 @@
|
||||
- name: Finalise ghostty default facts
|
||||
ansible.builtin.set_fact:
|
||||
ghostty:
|
||||
version: 1.3.1
|
||||
version: "{{ ghostty_version | default('1.3.1') }}"
|
||||
base_url: https://releases.files.ghostty.org
|
||||
methods: "{{ ghostty.methods[os_family] | default(ghostty.methods.default) }}"
|
||||
pkg_deps: [zig]
|
||||
pkgname: "{{ ghostty.pkgname[os_family] | default(ghostty.pkgname.default) }}"
|
||||
build_deps: "{{ ghostty.build_deps[os_family] | default(ghostty.build_deps.default) }}"
|
||||
appimage:
|
||||
url: https://github.com/pkgforge-dev/ghostty-appimage/releases/download
|
||||
name: ghostty
|
||||
# }}}
|
||||
- name: Set ghostty facts
|
||||
ansible.builtin.set_fact:
|
||||
ghostty:
|
||||
version: "{{ ghostty_version | default(ghostty.version) }}"
|
||||
methods: "{{ ghostty.methods }}"
|
||||
source_url: "{{ ghostty.base_url }}/{{ ghostty.version }}/ghostty-{{ ghostty.version }}.tar.gz"
|
||||
archive: "ghostty-{{ ghostty.version }}.tar.gz"
|
||||
pkg_deps: "{{ ghostty.pkg_deps | default(omit) }}"
|
||||
build_deps: "{{ ghostty.build_deps }}"
|
||||
|
||||
- name: Configure ghostty
|
||||
when:
|
||||
- "'ghostty' not in __configured"
|
||||
block:
|
||||
- name: Set ghostty install method
|
||||
when:
|
||||
@@ -74,6 +68,15 @@
|
||||
ansible.builtin.set_fact:
|
||||
ghostty_imethod: "{{ imethod if imethod in ghostty.methods else ghostty.methods[0] }}"
|
||||
|
||||
- name: Configure ghostty system install
|
||||
when:
|
||||
- ghostty_imethod == 'system'
|
||||
block:
|
||||
- name: Queue ghostty to pkg_sys
|
||||
ansible.builtin.set_fact:
|
||||
pkg_sys: "{{ pkg_sys + [ghostty.pkgname] }}"
|
||||
ghostty_install: "{{ ghostty_imethod }}={{ ghostty.pkgname }}"
|
||||
|
||||
- name: Configure ghostty source install
|
||||
when:
|
||||
- ghostty_imethod == 'source'
|
||||
@@ -103,23 +106,28 @@
|
||||
build_flags:
|
||||
- "-Doptimize=ReleaseFast"
|
||||
|
||||
- name: Finalise ghostty source install
|
||||
ansible.builtin.set_fact:
|
||||
pkg_zig: "{{ pkg_zig + [ghostty_source_install] }}"
|
||||
ghostty_install: "{{ ghostty_imethod }}={{ ghostty_source_install }}"
|
||||
|
||||
- name: Configure ghostty appimage install
|
||||
when:
|
||||
- ghostty_imethod == 'appimage'
|
||||
block:
|
||||
- name: Set ghostty appimage configuration
|
||||
ansible.builtin.set_fact:
|
||||
ghostty_appimage_install:
|
||||
url: "{{ ghostty.appimage.url }}/v{{ ghostty.version }}"
|
||||
name: "{{ ghostty.appimage.name }}"
|
||||
filename: "Ghostty-{{ ghostty.version }}-{{ architecture }}.AppImage"
|
||||
|
||||
- name: Append ghostty to pkg_appimage
|
||||
when:
|
||||
- ghostty.method == 'appimage'
|
||||
ansible.builtin.set_fact:
|
||||
pkg_appimage: "{{ pkg_appimage + ghostty }}"
|
||||
|
||||
- name: Configure ghostty system install
|
||||
when:
|
||||
- ghostty_imethod == 'system'
|
||||
block:
|
||||
- name: Queue ghostty to pkg_sys
|
||||
ansible.builtin.set_fact:
|
||||
pkg_sys: "{{ pkg_sys + [ghostty.pkg] }}"
|
||||
pkg_appimage: "{{ pkg_appimage + [ghostty_appimage_install] }}"
|
||||
ghostty_install: "{{ ghostty_imethod }}={{ ghostty_appimage_install }}"
|
||||
|
||||
- name: Finalise ghostty configuration
|
||||
ansible.builtin.set_fact:
|
||||
|
||||
@@ -35,8 +35,8 @@
|
||||
- name: Configure gopls source install
|
||||
ansible.builtin.set_fact:
|
||||
gopls_go_pkg:
|
||||
url: "{{ gopls.install_url }}@ {{ gopls.version }}"
|
||||
bin: "{{ path_bind }}/gopls"
|
||||
url: "{{ gopls.install_url }}@{{ gopls.version }}"
|
||||
bin: "{{ path_bin }}/gopls"
|
||||
files: "{{ gopls.install_files }}"
|
||||
|
||||
- name: Queue gopls for go_install
|
||||
|
||||
@@ -43,14 +43,14 @@
|
||||
- name: Finalise neovim default facts
|
||||
ansible.builtin.set_fact:
|
||||
neovim:
|
||||
methods: "{{ neovim.methods[os_family] | neovim.methods.default }}"
|
||||
methods: "{{ neovim.methods[os_family] | default(neovim.methods.default) }}"
|
||||
git_repo: https://github.com/neovim/neovim
|
||||
appimage:
|
||||
base_url: https://github.com/neovim/neovim/releases/download
|
||||
pkg_deps:
|
||||
- cmake
|
||||
version: v0.12.1
|
||||
pkgname: "{{ neovim.pkgname[os_family] | neovim.pkgname.default }}"
|
||||
pkgname: "{{ neovim.pkgname[os_family] | default(neovim.pkgname.default) }}"
|
||||
build_files:
|
||||
- to: lib64/nvim
|
||||
- to: bin/nvim
|
||||
@@ -61,7 +61,7 @@
|
||||
build_pkgdeps:
|
||||
- cmake
|
||||
- git
|
||||
build_deps: "{{ neovim.build_deps[os_family] | neovim.build_deps.default }}"
|
||||
build_deps: "{{ neovim.build_deps[os_family] | default(neovim.build_deps.default) }}"
|
||||
# }}}
|
||||
- name: Configure neovim
|
||||
when:
|
||||
|
||||
@@ -17,8 +17,8 @@
|
||||
- name: Finalise stow default facts
|
||||
ansible.builtin.set_fact:
|
||||
stow:
|
||||
methods: "{{ stow.methods[os_family] | stow.methods.default }}"
|
||||
pkgname: "{{ stow.pkgname[os_family] | stow.pkgname.default }}"
|
||||
methods: "{{ stow.methods[os_family] | default(stow.methods.default) }}"
|
||||
pkgname: "{{ stow.pkgname[os_family] | default(stow.pkgname.default) }}"
|
||||
baseurl: https://ftp.gnu.org/gnu/stow
|
||||
version: 2.4.1
|
||||
# }}}
|
||||
@@ -38,8 +38,8 @@
|
||||
block:
|
||||
- name: Queue stow for system install
|
||||
ansible.builtin.set_fact:
|
||||
pkg_sys: "{{ pkg_sys + [stow.pkgname[os_family]] }}"
|
||||
stow_install: "{{ stow_imethod }}={{ stow.pkgname[os_family] }}"
|
||||
pkg_sys: "{{ pkg_sys + [stow.pkgname] }}"
|
||||
stow_install: "{{ stow_imethod }}={{ stow.pkgname }}"
|
||||
|
||||
- name: Configure stow source install
|
||||
when:
|
||||
|
||||
@@ -10,12 +10,14 @@
|
||||
ansible.builtin.set_fact:
|
||||
zsh:
|
||||
methods:
|
||||
- system
|
||||
default: [system]
|
||||
pkgname:
|
||||
RedHat: zsh
|
||||
Debian: zsh
|
||||
Alpine: zsh
|
||||
Archlinux: zsh
|
||||
default: zsh
|
||||
- name: Finalise zsh default facts
|
||||
ansible.builtin.set_fact:
|
||||
zsh:
|
||||
methods: "{{ zsh.methods[os_family] | default(zsh.methods.default) }}"
|
||||
pkgname: "{{ zsh.pkgname[os_family] | default(zsh.pkgname.default) }}"
|
||||
# }}}
|
||||
- name: Add zsh
|
||||
when:
|
||||
@@ -33,11 +35,11 @@
|
||||
block:
|
||||
- name: Queue zsh system install
|
||||
ansible.builtin.set_fact:
|
||||
pkg_sys: "{{ pkg_sys + [zsh.pkgname[os_family]] }}"
|
||||
pkg_sys: "{{ pkg_sys + [zsh.pkgname] }}"
|
||||
|
||||
- name: Finalise zsh system install
|
||||
ansible.builtin.set_fact:
|
||||
zsh_install: "{{ zsh_imethod }}={{ zsh.pkgname[os_family] }}"
|
||||
zsh_install: "{{ zsh_imethod }}={{ zsh.pkgname }}"
|
||||
|
||||
- name: Configure zsh source install
|
||||
when:
|
||||
|
||||
Reference in New Issue
Block a user