fix packages

This commit is contained in:
Matthew Stobbs
2025-02-22 14:59:18 -07:00
parent 2d825d855d
commit d1e8957f94
47 changed files with 166 additions and 129 deletions

View File

@@ -1,7 +1,7 @@
# vim: set filetype=yaml.ansible : # vim: set filetype=yaml.ansible :
--- ---
- name: Install appimage - name: Install appimage
become: "{{ archive_become }}" become: "{{ ext_become }}"
block: block:
- name: Ensure appimage path exists - name: Ensure appimage path exists
ansible.builtin.file: ansible.builtin.file:
@@ -10,7 +10,7 @@
state: directory state: directory
- name: Fetch appimage - name: Fetch appimage
become: "{{ archive_become }}" become: "{{ ext_become }}"
ansible.builtin.get_url: ansible.builtin.get_url:
mode: '0755' mode: '0755'
decompress: false decompress: false
@@ -19,7 +19,7 @@
dest: "{{ path.appimage }}/{{ pkg.link_name }}/{{ pkg.file }}" dest: "{{ path.appimage }}/{{ pkg.link_name }}/{{ pkg.file }}"
- name: Link appimage to bin - name: Link appimage to bin
become: "{{ archive_become }}" become: "{{ ext_become }}"
ansible.builtin.file: ansible.builtin.file:
state: link state: link
src: "{{ path.appimage }}/{{ pkg.link_name }}/{{ pkg.file }}" src: "{{ path.appimage }}/{{ pkg.link_name }}/{{ pkg.file }}"

View File

@@ -20,8 +20,8 @@
become: "{{ sys_pkg_become }}" become: "{{ sys_pkg_become }}"
register: get_url_go register: get_url_go
ansible.builtin.get_url: ansible.builtin.get_url:
dest: "{{ path.cache }}/{{ go.archive }}" dest: "{{ d_tempdir.path }}/{{ go.archive }}"
url: "{{ go.url }}" url: "{{ go.base_url }}/{{ go.archive }}"
checksum: "{{ go.sum }}" checksum: "{{ go.sum }}"
decompress: false decompress: false
mode: '0644' mode: '0644'
@@ -32,7 +32,7 @@
- ansible_system == 'Linux' - ansible_system == 'Linux'
ansible.builtin.unarchive: ansible.builtin.unarchive:
dest: "{{ path.prefix }}" dest: "{{ path.prefix }}"
src: "{{ d_go_dl_tmp.path }}/{{ go.archive }}" src: "{{ d_tempdir.path }}/{{ go.archive }}"
remote_src: true remote_src: true
- name: Install go macOS using pkg file - name: Install go macOS using pkg file
@@ -40,5 +40,4 @@
when: when:
- ansible_distribution == 'MacOSX' - ansible_distribution == 'MacOSX'
ansible.builtin.command: ansible.builtin.command:
creates: "{{ path.go }}" cmd: "installer -pkg {{ d_tempdir.path }}/{{ go.archive }} -target /"
cmd: "installer -pkg {{ d_go_dl_tmp.path }}/{{ go.archive }} -target /"

View File

@@ -2,41 +2,31 @@
--- ---
- name: Download zls archive - name: Download zls archive
ansible.builtin.set_fact: ansible.builtin.set_fact:
zls_path: "zls-{{ pkgconfig_zls.sysmap[ansible_system] }}-{{ pkgconfig_zls.archmap[ansible_architecture] }}-{{ pkgconfig_zls.version }}"
zls_pkg: "zls-{{ pkgconfig_zls.sysmap[ansible_system] }}-{{ pkgconfig_zls.archmap[ansible_architecture] }}-{{ pkgconfig_zls.version }}.tar.xz"
- name: Check if zls exists - name: Check if zls exists
ansible.builtin.stat: ansible.builtin.stat:
path: "{{ pkgconfig_zls.install_path }}/{{ zls_path }}/zls" path: "{{ path.archive }}/{{ zls_path }}/zls"
register: r_zls_stat register: r_zls_stat
- name: Update/install zls - name: Update/install zls
when:
- not r_zls_stat.stat.exists
block: block:
- name: Create temp path
ansible.builtin.tempfile:
state: directory
prefix: zls_dl.
register: d_zls_dl_tmp
- name: Download zls archive - name: Download zls archive
ansible.builtin.get_url: ansible.builtin.get_url:
dest: "{{ d_zls_dl_tmp.path }}/{{ zls_pkg }}" dest: "{{ d_tempfile.path }}/{{ zls_pkg }}"
url: "{{ pkgconfig.zls.base_url }}/{{ zls_pkg }}" url: "{{ zls.base_url }}/{{ zls_pkg }}"
decompress: false decompress: false
mode: '0644' mode: '0644'
- name: Extract zls package - name: Extract zls package
become: "{{ ext_become }}" become: "{{ ext_become }}"
ansible.builtin.unarchive: ansible.builtin.unarchive:
dest: "{{ path.ardhive }}/{{ zls_path }}" dest: "{{ path.archive }}"
src: "{{ d_zls_dl_tmp.path }}/{{ zls_pkg }}" src: "{{ d_tempfile.path }}/{{ zls_pkg }}"
remote_src: true remote_src: true
- name: Link zls binary - name: Link zls binary
become: "{{ ext_become }}" become: "{{ ext_become }}"
ansible.builtin.file: ansible.builtin.file:
state: link state: link
src: "{{ path.ardhive }}/{{ zls_path }}/zls" src: "{{ path.archive }}/{{ zls_path }}/zls"
path: "{{ path.bin }}/zls" path: "{{ path.bin }}/zls"

View File

@@ -1,7 +1,7 @@
# vim: set filetype=yaml.ansible # vim: set filetype=yaml.ansible
--- ---
- name: Install cargo pkg - name: Install cargo pkg
become: "{{ archive_become }}" become: "{{ ext_become }}"
community.general.cargo: community.general.cargo:
name: "{{ pkg.name }}" name: "{{ pkg.name }}"
version: "{{ pkg.vers }}" version: "{{ pkg.vers }}"

View File

@@ -1,4 +1,4 @@
- name: Set clangd config - name: Set clangd config
ansible.builtin.set_fact: ansible.builtin.set_fact:
clangd: clangd:
pkgs: "{{ pkgconfig.clangd.pkg[ansible_os_family] }}" pkgs: "{{ pkgconfig.clangd.pkgs[ansible_os_family] }}"

View File

@@ -1,4 +1,4 @@
- name: Set fd config - name: Set fd config
ansible.builtin.set_fact: ansible.builtin.set_fact:
fd: fd:
pkgs: "{{ pkgconfig.fd.pkgs[ansible_os_famly] }}" pkgs: "{{ pkgconfig.fd.pkgs[ansible_system] }}"

View File

@@ -3,7 +3,8 @@
- name: Set go configuration - name: Set go configuration
ansible.builtin.set_fact: ansible.builtin.set_fact:
go: go:
arch: "{{ pkgconfig_go.archmap[ansible_architecture] }}" method: archive
arch: "{{ pkgconfig.go.archmap[ansible_architecture] }}"
ext: "{{ pkgconfig.go.extmap[ansible_system] }}" ext: "{{ pkgconfig.go.extmap[ansible_system] }}"
sys: "{{ ansible_system | lower }}" sys: "{{ ansible_system | lower }}"
vers: "{{ pkgconfig.go.version }}" vers: "{{ pkgconfig.go.version }}"
@@ -11,11 +12,12 @@
- name: Set go composite facts - name: Set go composite facts
ansible.builtin.set_fact: ansible.builtin.set_fact:
go: go:
method: archive
arch: "{{ go.arch }}" arch: "{{ go.arch }}"
archive: "go{{ go.ver }}.{{ go.sys }}-{{ go.arch }}.{{ pkgconfig_go.extmap[ansible_system] }}" archive: "go{{ go.vers }}.{{ go.sys }}-{{ go.arch }}.{{ pkgconfig.go.extmap[ansible_system] }}"
ext: "{{ go.ext }}" ext: "{{ go.ext }}"
inst_path: "{{ path.install }}/go" inst_path: "{{ path.prefix }}"
sum: "{{ pkgconfig.go.sums[go.vers][ansible_system][go.arch] }}" sum: "{{ pkgconfig.go.sums[go.vers][ansible_system][go.arch] }}"
sys: "{{ go.sys }}" sys: "{{ go.sys }}"
url: "{{ pkgconfig.go.base_url }}/{{ go.archive }}" base_url: "{{ pkgconfig.go.base_url }}"
vers: "{{ go.vers }}" vers: "{{ go.vers }}"

View File

@@ -3,6 +3,6 @@
- name: Set libreoffice config - name: Set libreoffice config
ansible.builtin.set_fact: ansible.builtin.set_fact:
libreoffice: libreoffice:
method: "{{ pkgconfig.libreoffice.method }}" method: "{{ pkgconfig.libreoffice.methods[ansible_distribution] | default(pkgconfig.libreoffice.methods.default) }}"
flatpak: "{{ pkgconfig.libreoffice.flatpak }}" flatpak: "{{ pkgconfig.libreoffice.flatpak }}"
pkgs: "{{ pkgconfig.libreoffice[ansible_os_family] }}" pkgs: "{{ pkgconfig.libreoffice.pkgs[ansible_os_family] }}"

View File

@@ -3,7 +3,7 @@
- name: Set neovim install method - name: Set neovim install method
ansible.builtin.set_fact: ansible.builtin.set_fact:
neovim: neovim:
method: "{{ pkgconfig.neovim.method[ansible_distribution] | default(pkgconfig.neovim.method.default) }}" method: "{{ pkgconfig.neovim.methods[ansible_distribution] | default(pkgconfig.neovim.methods.default) }}"
- name: Set neovim config - name: Set neovim config
ansible.builtin.set_fact: ansible.builtin.set_fact:

4
tasks/config/nodejs.yml Normal file
View File

@@ -0,0 +1,4 @@
- name: Set nodejs config
ansible.builtin.set_fact:
nodejs:
pkgs: "{{ pkgconfig.nodejs.pkgs[ansible_system] }}"

6
tasks/config/pgadmin.yml Normal file
View File

@@ -0,0 +1,6 @@
- name: Set pgadmin config
ansible.builtin.set_fact:
pgadmin:
method: "{{ pkgconfig.pgadmin.methods[ansible_distribution] | default(pkgconfig.pgadmin.methods.default) }}"
pkgs: "{{ pkgconfig.pgadmin.pkgs[ansible_system] }}"
flatpak: "{{ pkgconfig.pgadmin.flatpak }}"

View File

@@ -0,0 +1,4 @@
- name: Set terraform config
ansible.builtin.set_fact:
terraform:
pkgs: "{{ pkgconfig.terraform.pkgs[ansible_system] }}"

View File

@@ -0,0 +1,4 @@
- name: Set terraformls config
ansible.builtin.set_fact:
terraformls:
pkgs: "{{ pkgconfig.terraformls.pkgs[ansible_system] }}"

4
tasks/config/tidy.yml Normal file
View File

@@ -0,0 +1,4 @@
- name: Set tidy config
ansible.builtin.set_fact:
tidy:
pkgs: "{{ pkgconfig.tidy.pkgs[ansible_system] }}"

View File

@@ -1,5 +1,9 @@
# vim: set filetype=yaml.ansible : # vim: set filetype=yaml.ansible :
--- ---
version: 0.13.0 - name: Set zls config
install_prefix: "{{ default_install_prefix }}" ansible.builtin.set_fact:
install_path: /opt/zls zls:
path: "zls-{{ pkgconfig.zls.sysmap[ansible_system] }}-{{ pkgconfig.zls.archmap[ansible_architecture] }}-{{ pkgconfig.zls.version }}"
pkg: "zls-{{ pkgconfig.zls.sysmap[ansible_system] }}-{{ pkgconfig.zls.archmap[ansible_architecture] }}-{{ pkgconfig.zls.version }}.tar.xz"
vers: "{{ pkgconfig.zls.version }}"
base_url: "{{ pkgconfig.zls.base_url }}"

View File

@@ -1,6 +1,6 @@
--- ---
- name: Install go packages - name: Install go packages
become: "{{ archive_become }}" become: "{{ ext_become }}"
environment: environment:
GOBIN: "{{ path.bin }}" GOBIN: "{{ path.bin }}"
PATH: "{{ path.go }}/bin:$PATH" PATH: "{{ path.go }}/bin:$PATH"

View File

@@ -3,13 +3,13 @@
- name: Install flatpaks on Linux Systems - name: Install flatpaks on Linux Systems
when: when:
- flatpaks|length > 0 - pkg_flatpak|length > 0
block: block:
- name: Add flatpak remotes - name: Add flatpak remotes
when: when:
- flatpak_remotes|length > 0 - flatpak_remote|length > 0
become: "{{ ext_become }}" become: "{{ ext_become }}"
loop: "{{ flatpak_remotes | unique }}" loop: "{{ flatpak_remote | unique }}"
loop_control: loop_control:
loop_var: remote loop_var: remote
community.general.flatpak_remote: community.general.flatpak_remote:
@@ -20,8 +20,10 @@
state: present state: present
- name: Install flatpaks - name: Install flatpaks
when:
- pkg_flatpak|length > 0
become: "{{ ext_become }}" become: "{{ ext_become }}"
loop: "{{ flatpaks | unique }}" loop: "{{ pkg_flatpak | unique }}"
loop_control: loop_control:
loop_var: flatpak loop_var: flatpak
community.general.flatpak: community.general.flatpak:

View File

@@ -1,19 +1,22 @@
# vim: set filetype=yaml.ansible : # vim: set filetype=yaml.ansible :
--- ---
- name: Tap homebrew taps - name: Tap homebrew taps
when:
- brewtap|length > 0
community.general.homebrew_tap: community.general.homebrew_tap:
name: "{{ brew_taps | unique }}" name: "{{ brewtap | unique }}"
state: present state: present
when: brew_taps|length > 0
- name: Install homebrew casks - name: Install homebrew casks
when: pkg_cask|length > 0
community.general.homebrew_cask: community.general.homebrew_cask:
name: "{{ cask_pkgs | unique }}" name: "{{ pkg_cask | unique }}"
state: present state: present
when: cask_pkgs|length > 0
# TODO: fix the need to have this workaround # TODO: fix the need to have this workaround
- name: Workaround to install homebrew taps - name: Workaround to install homebrew taps
ansible.builtin.command: when:
cmd: "brew install {{ (tap_pkgs | unique) | join(' ') }}" - pkg_tap|length > 0
changed_when: true changed_when: true
ansible.builtin.command:
cmd: "brew install {{ (pkg_tap | unique) | join(' ') }}"

View File

@@ -2,6 +2,12 @@
--- ---
# create all the facts used throughout the role, but shouldn't be touched # create all the facts used throughout the role, but shouldn't be touched
# by the user # by the user
- name: Create temporary directory for downloads
ansible.builtin.tempfile:
state: directory
prefix: ansible_role_package.
register: d_tempdir
- name: Set installation facts - name: Set installation facts
ansible.builtin.include_tasks: ansible.builtin.include_tasks:
file: facts.yml file: facts.yml

View File

@@ -1,7 +1,7 @@
# vim: set filetype=yaml.ansible : # vim: set filetype=yaml.ansible :
--- ---
- name: Install npm pkg - name: Install npm pkg
become: "{{ archive_become }}" become: "{{ ext_become }}"
community.general.npm: community.general.npm:
global: true global: true
name: "{{ pkg }}" name: "{{ pkg }}"

View File

@@ -1,7 +1,7 @@
# vim: set filetype=yaml.ansible : # vim: set filetype=yaml.ansible :
--- ---
- name: Install pipx pkg - name: Install pipx pkg
become: "{{ archive_become }}" become: "{{ ext_become }}"
community.general.pipx: community.general.pipx:
executable: "{{ pipx_exec }}" executable: "{{ pipx_exec }}"
name: "{{ pipx_pkg }}" name: "{{ pipx_pkg }}"

View File

@@ -3,6 +3,8 @@
- name: Append to pkg_sys and pkg_cargo - name: Append to pkg_sys and pkg_cargo
when: when:
- ansible_system == 'Linux' - ansible_system == 'Linux'
notify:
- Depend cargo
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + broot.deps }}" pkg_sys: "{{ pkg_sys + broot.deps }}"
pkg_cargo: "{{ pkg_cargo + [broot] }}" pkg_cargo: "{{ pkg_cargo + [broot] }}"

3
tasks/pkgs/direnv.yml Normal file
View File

@@ -0,0 +1,3 @@
- name: Append to pkg_sys
ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + ['direnv'] }}"

View File

@@ -3,6 +3,7 @@
- name: Source pkg installation - name: Source pkg installation
when: when:
- ghostty.method == 'src' - ghostty.method == 'src'
- ansible_distribution != 'MacOSX'
notify: notify:
- Depend zig - Depend zig
block: block:

View File

@@ -2,12 +2,11 @@
--- ---
- name: Install from archive - name: Install from archive
when: when:
- go.use_archive - go.method == 'archive'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_archive: "{{ pkg_archive + ['go'] }}" pkg_archive: "{{ pkg_archive + ['go'] }}"
- name: Append to pkgs - name: Append to pkgs
when: - go.method != 'archive'
- not go.use_archive
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + ['go'] }}" pkg_sys: "{{ pkg_sys + ['go'] }}"

View File

@@ -1,20 +1,19 @@
# vim: set filetype=yaml.ansible : # vim: set filetype=yaml.ansible :
--- ---
- name: Append to flatpkgs - name: Append to pkg_flatpak
when: when:
- libreoffice.method == 'flatpak' - libreoffice.method == 'flatpak'
ansible.builtin.set_fact: ansible.builtin.set_fact:
flatpkgs: "{{ flatpkgs + libreoffice.flatpak }}" pkg_flatpak: "{{ pkg_flatpak + libreoffice.flatpak }}"
- name: Append to pkg_sys - name: Append to pkg_sys
when: when:
- libreoffice.method == 'sys' - libreoffice.method == 'sys'
- ansible_system == 'Linux'
ansible.builtin.set_fact: ansible.builtin.set_fact:
sys_pkg: "{{ sys_pkg + libreoffice.pkgs }}" sys_pkg: "{{ sys_pkg + libreoffice.pkgs }}"
- name: Append to caskpkgs - name: Append to caskpkgs
when: when:
- ansible_system == 'Darwin' - libreoffice.method == 'cask'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_cask: "{{ pkg_cask + ['libreoffice'] }}" pkg_cask: "{{ pkg_cask + libreoffice.pkgs }}"

View File

@@ -2,12 +2,12 @@
--- ---
- name: Append to appimages - name: Append to appimages
when: when:
- nvim.method == 'appimage' - neovim.method == 'appimage'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_appimage: "{{ pkg_appimage + ['neovim'] }}" pkg_appimage: "{{ pkg_appimage + ['neovim'] }}"
- name: Append neovim to pkg_sys - name: Append neovim to pkg_sys
when: when:
- nvim.method == 'sys' - neovim.method == 'sys'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + ['neovim'] }}" pkg_sys: "{{ pkg_sys + ['neovim'] }}"

View File

@@ -2,4 +2,4 @@
--- ---
- name: Append to pkgs - name: Append to pkgs
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + pkgconfig.nodejs.pkgs[ansible_system] }}" pkg_sys: "{{ pkg_sys + nodejs.pkgs }}"

View File

@@ -2,14 +2,14 @@
--- ---
- name: Append to pkg_flatpak - name: Append to pkg_flatpak
when: when:
- ansible_system == 'Linux' - pgadmin.method == 'flatpak'
notify: notify:
- Depend flatpak - Depend flatpak
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_flatpak: "{{ pkg_flatpak + [pkgconfig.pgadmin.flatpak] }}" pkg_flatpak: "{{ pkg_flatpak + [pgadmin.flatpak] }}"
- name: Append to pkg_cask - name: Append to pkg_cask
when: when:
- ansible_system == 'Darwin' - pgadmin.method == 'cask'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_cask: "{{ pkg_cask + ['pgadmin4'] }}" pkg_cask: "{{ pkg_cask + pgadmin.pkgs }}"

View File

@@ -2,4 +2,4 @@
--- ---
- name: Append to pkgs - name: Append to pkgs
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + pkgconfig.rust.pkgs }}" pkg_sys: "{{ pkg_sys + rust.pkgs }}"

View File

@@ -3,5 +3,15 @@
- name: Append to pkgs - name: Append to pkgs
notify: notify:
- Depend hashicorp repo - Depend hashicorp repo
block:
- name: MacOSX specific
when:
- ansible_distribution == 'MacOSX'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_taps: "{{ pkg_taps + [pkgconfig.terraform[ansible_system]] }}" pkg_tap: "{{ pkg_tap + terraform.pkgs }}"
- name: Linux specific
when:
- ansible_system == 'Linux'
ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + terraform.pkgs }}"

View File

@@ -8,10 +8,10 @@
when: when:
- ansible_system == 'Darwin' - ansible_system == 'Darwin'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_taps: "{{ pkg_taps + [pkgconfig.terraformls[ansible_system]] }}" pkg_tap: "{{ pkg_tap + terraformls.pkgs }}"
- name: Linux specific - name: Linux specific
when: when:
- ansible_system == 'Linux' - ansible_system == 'Linux'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + ['terraformls'] }}" pkg_sys: "{{ pkg_sys + terraformls.pkgs }}"

View File

@@ -2,4 +2,4 @@
--- ---
- name: Append to pkg_sys - name: Append to pkg_sys
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_sys: "{{ pkg_sys + pkgconfig.tidy.pkgs[ansible_system] }}" pkg_sys: "{{ pkg_sys + tidy.pkgs }}"

View File

@@ -8,7 +8,7 @@
when: when:
- ansible_system == 'Darwin' - ansible_system == 'Darwin'
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_taps: "{{ pkg_taps + [pkgconfig.vault[ansible_system]] }}" pkg_tap: "{{ pkg_tap + [pkgconfig.vault[ansible_system]] }}"
- name: Linux specific - name: Linux specific
when: when:

View File

@@ -4,4 +4,4 @@
notify: notify:
- Depend zig - Depend zig
ansible.builtin.set_fact: ansible.builtin.set_fact:
pkg_src: "{{ pkg_src + ['zls'] }}" pkg_archive: "{{ pkg_archive + ['zls'] }}"

View File

@@ -34,15 +34,9 @@
when: when:
- ansible_os_family == 'Debian' - ansible_os_family == 'Debian'
block: block:
- name: Create temporary directory
ansible.builtin.tempfile:
state: directory
prefix: hashicorp.
register: d_hashicorp_tmp
- name: Get hashicorp archive gpg key - name: Get hashicorp archive gpg key
ansible.builtin.get_url: ansible.builtin.get_url:
dest: "{{ d_hashicorp_tmp.path }}/gpg" dest: "{{ d_tempdir.path }}/hashicorp_gpg"
url: https://apt.releases.hashicorp.com/gpg url: https://apt.releases.hashicorp.com/gpg
mode: '0644' mode: '0644'
@@ -55,7 +49,7 @@
- --dearmor - --dearmor
- -o - -o
- /usr/share/keyrings/hashicorp-archive-keyring.gpg - /usr/share/keyrings/hashicorp-archive-keyring.gpg
- "{{ d_hashicorp_tmp.path }}/gpg" - "{{ d_tempdir.path }}/hashicorp_gpg"
- name: Enable hasicorp repo for debian - name: Enable hasicorp repo for debian
ansible.builtin.apt_repository: ansible.builtin.apt_repository:
@@ -66,8 +60,5 @@
- name: MacOS specific configuration - name: MacOS specific configuration
when: when:
- ansible_distribution == 'MacOSX' - ansible_distribution == 'MacOSX'
block:
- name: Enable hashicorp homebrew tap
when: ansible_os_family == 'Darwin'
ansible.builtin.set_fact: ansible.builtin.set_fact:
brewtaps: "{{ brewtaps + ['hashicorp/tap'] }}" brewtaps: "{{ brewtaps + ['hashicorp/tap'] }}"

View File

@@ -2,32 +2,16 @@
--- ---
- name: Build ghostty from source - name: Build ghostty from source
block: block:
- name: Create temp path
ansible.builtin.tempfile:
state: directory
prefix: ghostty.
register: d_ghostty_tmp
- name: Clone ghostty git repository - name: Clone ghostty git repository
ansible.builtin.git: ansible.builtin.git:
depth: 1 depth: 1
dest: "{{ d_ghostty_tmp.path }}/ghostty" dest: "{{ d_tempdir.path }}/ghostty"
repo: "{{ pkgconfig_ghostty.git_repo }}" repo: "{{ ghostty.repo }}"
version: "{{ pkgconfig_ghostty.version }}" version: "{{ ghostty.vers }}"
- name: Build ghostty - name: Build ghostty
ansible.builtin.command: become: "{{ ext_become }}"
chdir: "{{ d_ghostty_tmp.path }}/ghostty"
cmd: "zig build -D{{ pkgconfig_ghostty.optimize }}"
register: c_ghostty_build register: c_ghostty_build
ansible.builtin.command:
- name: Install ghostty chdir: "{{ d_tempdir.path }}/ghostty"
ansible.file.copy: cmd: "zig build -p {{ path.prefix }} -D{{ pkgconfig_ghostty.optimize }}"
src: "{{ d_ghostty_tmp.path }}/ghostty/zig-out/bin/ghostty"
dest: "{{ pkgconfig_ghostty.install_prefix }}/bin/ghostty"
owner: "{{ pkgconfig_ghostty.owner }}"
group: "{{ pkgconfig_ghostty.group }}"
mode: "0755"
remote_src: true
become: "{{ pkgconfig_ghostty.become }}"
become_user: "{% if pkgconfig_ghostty.become %}{{ pkgconfig_ghostty.owner }}{% else %}~{% endif %}"

View File

@@ -14,12 +14,10 @@
version: "{{ pkgconfig_neovim.version }}" version: "{{ pkgconfig_neovim.version }}"
- name: Build and install neovim - name: Build and install neovim
become: "{{ ext_become }}"
ansible.builtin.make: ansible.builtin.make:
chdir: "{{ d_nvim_tmp.path }}/neovim" chdir: "{{ d_tempdir.path }}/neovim"
params: params:
CMAKE_BUILD_TYPE: "{{ pkgconfig_neovim.build_type }}" CMAKE_BUILD_TYPE: "{{ neovim.build_type }}"
CMAKE_INSTALL_PREFIX: "{{ pkgconfig_neovim.install_prefix }}" CMAKE_INSTALL_PREFIX: "{{ path.prefix }}"
target: install target: install
become: "{{ pkgconfig_neovim.dobecome }}"
become_user: "{% if pkgconfig_neovim.dobecome %}{{ pkgconfig_neovim.owner }}{% else %}~{% endif %}"
when: not pkgconfig_neovim.use_appimage

View File

@@ -9,3 +9,4 @@ broot:
- libxcb-xfixes0-dev - libxcb-xfixes0-dev
RedHat: RedHat:
- libxcb - libxcb
Darwin: []

View File

@@ -2,7 +2,5 @@ fd:
pkgs: pkgs:
Darwin: Darwin:
- fd - fd
RedHat: Linux:
- fd-find
Debian:
- fd-find - fd-find

View File

@@ -8,6 +8,7 @@ ghostty:
RedHat: RedHat:
- gtk4-devel - gtk4-devel
- libadwaita-devel - libadwaita-devel
Darwin: []
archmap: archmap:
arm64: aarch64 arm64: aarch64
x86_64: x86_64 x86_64: x86_64

View File

@@ -1,9 +1,16 @@
libreoffice: libreoffice:
method: flatpak methods:
default: sys
Ubuntu: flatpak
Fedora: flatpak
MacOSX: cask
flatpak: flatpak:
name: org.libreoffice.LibreOffice name: org.libreoffice.LibreOffice
remote: flathub remote: flathub
pkgs:
Debian: Debian:
- libreoffice - libreoffice
RedHat: RedHat:
- libreoffice - libreoffice
Darwin:
- libreoffice

View File

@@ -4,8 +4,8 @@ neovim:
appimage: appimage:
base_url: https://github.com/neovim/neovim/releases/download base_url: https://github.com/neovim/neovim/releases/download
link_name: nvim link_name: nvim
method: methods:
default: appimage default: src
Fedora: sys Fedora: sys
Ubuntu: sys Ubuntu: sys
MacOSX: sys MacOSX: sys

View File

@@ -2,3 +2,11 @@ pgadmin:
flatpak: flatpak:
name: org.pgadmin.pgadmin4 name: org.pgadmin.pgadmin4
remote: flathub remote: flathub
methods:
default: flatpak
MacOSX: cask
Fedora: flatpak
Ubuntu: flatpak
pkgs:
Darwin:
- pgadmin4

View File

@@ -1,3 +1,6 @@
terraform: terraform:
Linux: terraform pkgs:
Darwin: hashicorp/tap/terraform Linux:
- terraform
Darwin:
- hashicorp/tap/terraform

View File

@@ -1,3 +1,6 @@
terraformls: terraformls:
Linux: terraform-ls pkgs:
Darwin: hashicorp/tap/terraform-ls Linux:
- terraform-ls
Darwin:
- hashicorp/tap/terraform-ls

View File

@@ -1,4 +1,5 @@
zls: zls:
version: 0.13.0
base_url: https://builds.zigtools.org base_url: https://builds.zigtools.org
sysmap: sysmap:
Darwin: macos Darwin: macos