2019-12-01 16:29:03 +01:00
|
|
|
---
|
2019-12-02 14:50:11 +01:00
|
|
|
- name: Get oh-my-fish installer
|
|
|
|
get_url:
|
|
|
|
url: https://get.oh-my.fish
|
|
|
|
dest: /tmp/oh-my.fish
|
|
|
|
mode: '7550'
|
2019-12-03 09:45:50 +01:00
|
|
|
changed_when: false
|
2019-12-02 14:50:11 +01:00
|
|
|
|
2019-12-01 16:29:03 +01:00
|
|
|
- name: Install oh-my-fish
|
2020-01-01 16:27:00 +01:00
|
|
|
shell: fish -c "/tmp/oh-my.fish --noninteractive -y"
|
2019-12-01 16:29:03 +01:00
|
|
|
args:
|
|
|
|
creates: ~/.config/fish/conf.d/omf.fish
|
|
|
|
|
2019-12-03 09:45:50 +01:00
|
|
|
- name: Remove oh-my-fish installer
|
2019-12-03 09:38:00 +01:00
|
|
|
file:
|
|
|
|
path: /tmp/oh-my.fish
|
|
|
|
state: absent
|
2019-12-03 09:45:50 +01:00
|
|
|
changed_when: false
|
2019-12-03 09:38:00 +01:00
|
|
|
|
2019-12-01 16:29:03 +01:00
|
|
|
- name: Install pureprompt plugin
|
|
|
|
shell: |
|
2020-01-01 01:57:48 +01:00
|
|
|
fish -c "omf install pure"
|
2020-01-07 14:44:28 +01:00
|
|
|
fish -lc "ln -s $OMF_PATH/themes/pure/conf.d/pure.fish ~/.config/fish/conf.d/pure.fish"
|
|
|
|
fish -lc "ln -s $OMF_PATH/themes/pure/conf.d/_pure_init.fish ~/.config/fish/conf.d/pure_init.fish"
|
2019-12-01 16:29:03 +01:00
|
|
|
args:
|
|
|
|
creates: ~/.config/fish/conf.d/pure.fish
|
2020-05-09 21:35:51 +02:00
|
|
|
when: ansible_user_id != "root"
|
2019-12-01 16:29:03 +01:00
|
|
|
|
|
|
|
- name: check git plugin install
|
2020-05-08 01:09:12 +02:00
|
|
|
shell: grep 'abbr.*git' ~/.config/fish/fish_variables
|
2019-12-01 16:29:03 +01:00
|
|
|
register: gitcheck
|
|
|
|
ignore_errors: True
|
|
|
|
changed_when: false
|
|
|
|
|
|
|
|
- name: Install git plugin
|
2020-01-01 01:57:48 +01:00
|
|
|
shell: fish -c "omf install https://github.com/jhillyerd/plugin-git"
|
2019-12-01 16:29:03 +01:00
|
|
|
when: gitcheck is failed
|
|
|
|
|
2020-05-09 20:52:03 +02:00
|
|
|
- name: Copy dircolors
|
2019-12-01 16:29:03 +01:00
|
|
|
copy:
|
2020-05-09 20:52:03 +02:00
|
|
|
src: dircolors
|
|
|
|
dest: ~/.config/
|
|
|
|
|
|
|
|
- name: Sync fish config files
|
|
|
|
synchronize:
|
|
|
|
src: files/fish/
|
|
|
|
dest: ~/.config/
|
2019-12-01 16:29:03 +01:00
|
|
|
|
|
|
|
- name: Laptops fish configuration
|
|
|
|
copy:
|
2020-05-06 19:47:55 +02:00
|
|
|
src: laptop.fish
|
2019-12-01 16:29:03 +01:00
|
|
|
dest: ~/.config/fish/conf.d/
|
|
|
|
when: "'laptop' in {{ group_names }}"
|