fix go and pipx installs

This commit is contained in:
Matthew Stobbs
2025-02-22 16:24:44 -07:00
parent a73ed77dac
commit b25f6dc207
2 changed files with 7 additions and 12 deletions

View File

@@ -1,16 +1,8 @@
--- ---
- debug: - name: Install go package {{ pkg }}
var: path.go
- debug:
var: path.bin
- name: Install go packages
become: "{{ ext_become }}" become: "{{ ext_become }}"
environment: environment:
GOBIN: "{% if ansible_distribution == 'MacOSX' %}/usr/local/bin{% else %}{{ path.bin }}{% endif %}" GOBIN: "{{ path.bin }}"
PATH: "{{ path.go }}/bin:$PATH" PATH: "{{ path.go }}/bin:$PATH"
ansible.builtin.command: ansible.builtin.command:
cmd: cmd: go install {{ pkg }}
- go
- install
- "{{ pkg }}"

View File

@@ -2,7 +2,10 @@
--- ---
- name: Install pipx pkg - name: Install pipx pkg
become: "{{ ext_become }}" become: "{{ ext_become }}"
environment:
PIPX_HOME: "{{ path.pipx }}"
PIPX_BIN_DIR: "{{ path.bin }}"
community.general.pipx: community.general.pipx:
executable: "{{ pipx_exec }}" executable: "{{ pipx_exec }}"
name: "{{ pipx_pkg }}" name: "{{ pkg }}"
state: latest state: latest