boma/roles/dev_env/tasks/oh_my_posh.yml

28 lines
825 B
YAML
Raw Permalink Normal View History

---
- name: Oh-my-posh | Check installed version
ansible.builtin.command: oh-my-posh --version
register: dev_env__omp_check
changed_when: false
failed_when: false
- name: Oh-my-posh | Install pinned binary
ansible.builtin.get_url:
url: "https://github.com/JanDeDobbeleer/oh-my-posh/releases/download/v{{ dev_env__omp_version }}/posh-linux-amd64"
dest: /usr/local/bin/oh-my-posh
mode: "0755"
when: (dev_env__omp_check.stdout | default('') | trim) != dev_env__omp_version
- name: Oh-my-posh | Ensure theme directory
ansible.builtin.file:
path: /etc/oh-my-posh
state: directory
mode: "0755"
tags: [config]
- name: Oh-my-posh | Deploy zen.toml theme (system-wide)
ansible.builtin.copy:
src: oh-my-posh/zen.toml
dest: /etc/oh-my-posh/zen.toml
mode: "0644"
tags: [config]