From 0f9663397b93dba737384958cf4a8b262c91367f Mon Sep 17 00:00:00 2001 From: Roberto Alsina Date: Wed, 26 Jun 2024 11:46:41 -0300 Subject: [PATCH] Configure starship --- provision-pinky/setup_user.yml | 35 ++++++++++++++++++++++++---------- 1 file changed, 25 insertions(+), 10 deletions(-) diff --git a/provision-pinky/setup_user.yml b/provision-pinky/setup_user.yml index 0113873..60789cd 100644 --- a/provision-pinky/setup_user.yml +++ b/provision-pinky/setup_user.yml @@ -18,17 +18,17 @@ - name: Install Debian-specific packages become: true when: ansible_os_family == 'Debian' - apt: + ansible.builtin.apt: name: - ncurses-term state: present - name: Add the user ralsina become: true ansible.builtin.user: - name: ralsina - create_home: true - password_lock: true - shell: /usr/bin/fish + name: ralsina + create_home: true + password_lock: true + shell: /usr/bin/fish - name: Authorize ssh become: true ansible.posix.authorized_key: @@ -43,9 +43,24 @@ state: present commands: ALL nopassword: true - - name: Remove users that come with the system + - name: Create fish config directory + ansible.builtin.file: + path: /home/ralsina/.config/fish/conf.d + recurse: true + state: directory + mode: '0755' + - name: Get starship installer + ansible.builtin.get_url: + url: https://starship.rs/install.sh + dest: /tmp/starship.sh + mode: '0755' + - name: Install starship become: true - ansible.builtin.user: - name: rock - state: absent - remove: true + ansible.builtin.command: + cmd: sh /tmp/starship.sh -y + - name: Enable starship + ansible.builtin.copy: + dest: /home/ralsina/.config/fish/conf.d/starship.fish + mode: '0644' + content: | + starship init fish | source