2024-08-19 22:03:15 +02:00
|
|
|
- name: install zsh
|
|
|
|
apt:
|
|
|
|
name: zsh
|
|
|
|
state: latest
|
|
|
|
update_cache: true
|
|
|
|
|
|
|
|
- name: set zsh as default shell
|
|
|
|
ansible.builtin.shell: chsh -s $(which zsh) {{ ansible_user }}
|
|
|
|
|
|
|
|
- name: Download Atuin setup script
|
|
|
|
get_url:
|
|
|
|
url: https://setup.atuin.sh
|
|
|
|
dest: /tmp/setup_atuin.sh
|
|
|
|
mode: '0755'
|
|
|
|
|
|
|
|
- name: Run the Atuin setup script
|
|
|
|
command: /tmp/setup_atuin.sh
|
|
|
|
register: atuin_install
|
|
|
|
become: true
|
|
|
|
become_user: "{{ ansible_user }}"
|
|
|
|
|
|
|
|
- name: login to atuin
|
|
|
|
command: /home/{{ ansible_user }}/.atuin/bin/atuin login -u philskents -p "{{ atuin_pass }}" -k "{{ atuin_key }}"
|
|
|
|
when: atuin_install.rc == 0
|
|
|
|
become: true
|
|
|
|
become_user: "{{ ansible_user }}"
|
|
|
|
|
2024-08-23 21:34:48 +02:00
|
|
|
- name: setup dotfile sync
|
|
|
|
ansible.builtin.blockinfile:
|
|
|
|
path: "/home/{{ ansible_user }}/.config/atuin/config.toml"
|
|
|
|
block: |
|
|
|
|
[dotfiles]
|
|
|
|
enabled = true
|
|
|
|
marker: ""
|
|
|
|
|
|
|
|
- name: Install bat
|
|
|
|
apt:
|
|
|
|
name: bat
|
|
|
|
state: latest
|
|
|
|
update_cache: true
|
|
|
|
|
|
|
|
- name: Create symlink for batcat
|
|
|
|
ansible.builtin.file:
|
|
|
|
src: /usr/bin/batcat
|
2024-09-21 00:46:16 +02:00
|
|
|
dest: "/home/{{ ansible_user }}/.local/bin/bat"
|
2024-08-23 21:34:48 +02:00
|
|
|
state: link
|