updated utils.yml to work with latest ansible
Some checks failed
Ansible Lint Check / check-ansible (push) Failing after 7s
Nix Format Check / check-format (push) Failing after 19s
Python Lint Check / check-python (push) Failing after 6s

Signed-off-by: Menno van Leeuwen <menno@vleeuwen.me>
This commit is contained in:
2025-07-23 14:43:05 +02:00
parent d31d07e0a0
commit 2b1c714375

View File

@@ -1,4 +1,6 @@
--- ---
- name: Process utils files
block:
- name: Load DOTFILES_PATH environment variable - name: Load DOTFILES_PATH environment variable
ansible.builtin.set_fact: ansible.builtin.set_fact:
dotfiles_path: "{{ lookup('env', 'DOTFILES_PATH') }}" dotfiles_path: "{{ lookup('env', 'DOTFILES_PATH') }}"
@@ -24,12 +26,14 @@
dest: "{{ ansible_env.HOME }}/.local/bin/{{ item.path | basename }}" dest: "{{ ansible_env.HOME }}/.local/bin/{{ item.path | basename }}"
state: link state: link
loop: "{{ utils_files.files }}" loop: "{{ utils_files.files }}"
when: not item.path | regex_search('\.go$') when: not item.path.endswith('.go')
become: false become: false
- name: Compile Go files and place binaries in ~/.local/bin - name: Compile Go files and place binaries in ~/.local/bin
ansible.builtin.command: ansible.builtin.command:
cmd: go build -o "{{ ansible_env.HOME }}/.local/bin/{{ item.path | basename | regex_replace('\.go$', '') }}" "{{ item.path }}" cmd: go build -o "{{ ansible_env.HOME }}/.local/bin/{{ item.path | basename | regex_replace('\.go$', '') }}" "{{ item.path }}"
loop: "{{ utils_files.files }}" loop: "{{ utils_files.files }}"
when: item.path | regex_search('\.go$') when: item.path.endswith('.go')
become: false become: false
tags:
- utils