Added starship

This commit is contained in:
Vuong Hoang
2024-05-31 18:51:47 -07:00
parent d1dad7aabb
commit 804ab3209a
5 changed files with 234 additions and 1 deletions
+32
View File
@@ -0,0 +1,32 @@
---
- name: create config directory
file:
path: "{{ ansible_user_dir }}/.config/"
state: directory
- name: copy configuration
copy:
src: starship.toml
dest: "{{ ansible_user_dir }}/.config/starship.toml"
- name: Get starship install script
get_url:
url: https://starship.rs/install.sh
dest: /tmp/starship_install.sh
mode: '0755'
- name: Install starship
shell:
cmd: /tmp/starship_install.sh --yes
executable: /bin/sh
become: yes
- name: Update bashrc
vars:
bashrcpath: "{{ ansible_user_dir }}/.bashrc"
blockinfile:
path: "{{ bashrcpath }}"
block: |
eval "$(starship init bash)"
state: present
create: true