82 lines
2.0 KiB
YAML
82 lines
2.0 KiB
YAML
---
|
|
- name: fish | Create necessary directories
|
|
file:
|
|
path: '~/.config/fish/{{ item }}'
|
|
state: directory
|
|
mode: '755'
|
|
loop:
|
|
- completions
|
|
- conf.d
|
|
- functions
|
|
- themes
|
|
|
|
- name: fish | Copy function and config files
|
|
copy:
|
|
src: 'fish/{{ item.src }}'
|
|
dest: '~/.config/fish/{{ item.dest }}'
|
|
mode: '644'
|
|
loop:
|
|
- src: fish_greeting.fish
|
|
dest: functions/
|
|
- src: fish_user_key_bindings.fish
|
|
dest: functions/
|
|
- src: ghq_cd.fish
|
|
dest: functions/
|
|
- src: ghq_rm.fish
|
|
dest: functions/
|
|
|
|
- name: fish | Copy config templates
|
|
template:
|
|
src: 'fish/{{ item.src }}.j2'
|
|
dest: '~/.config/fish/{{ item.dest }}.fish'
|
|
force: true
|
|
mode: '644'
|
|
loop:
|
|
- src: aliases
|
|
dest: conf.d/aliases
|
|
- src: env
|
|
dest: conf.d/env
|
|
- src: config
|
|
dest: config
|
|
|
|
- name: fish | Copy shell themes
|
|
copy:
|
|
src: 'fish/{{ item }}'
|
|
dest: '~/.config/fish/themes/{{ item }}'
|
|
force: true
|
|
mode: '644'
|
|
loop:
|
|
- Onedark.theme
|
|
- Nord.theme
|
|
|
|
# Overwrite theme? [y/N]
|
|
- name: fish | Set shell theme to '{{ theme }}'
|
|
shell:
|
|
cmd: fish_config theme save {{ theme | capitalize }}
|
|
executable: /usr/bin/fish
|
|
stdin: y
|
|
stdin_add_newline: true
|
|
changed_when: true
|
|
|
|
- name: fish | Download fzf_key_bindings.fish
|
|
get_url:
|
|
url: https://github.com/junegunn/fzf/raw/master/shell/key-bindings.fish
|
|
dest: ~/.config/fish/functions/fzf_key_bindings.fish
|
|
mode: '644'
|
|
|
|
- name: fish | Install fisher
|
|
shell: /usr/bin/curl -sSL https://raw.githubusercontent.com/jorgebucaran/fisher/main/functions/fisher.fish | source && fisher install jorgebucaran/fisher
|
|
args:
|
|
executable: /usr/bin/fish
|
|
creates: ~/.config/fish/functions/fisher.fish
|
|
|
|
- name: fish | Install autopair.fish
|
|
command: /usr/bin/fish -c 'fisher install jorgebucaran/autopair.fish'
|
|
args:
|
|
creates: ~/.config/fish/conf.d/autopair.fish
|
|
|
|
- name: fish | Install replay.fish
|
|
command: /usr/bin/fish -c 'fisher install jorgebucaran/replay.fish'
|
|
args:
|
|
creates: ~/.config/fish/functions/replay.fish
|