Feat: Add fishshell config files
This commit is contained in:
parent
2f7d9b6368
commit
a35d204e45
10
files/dotfiles/config.fish
Normal file
10
files/dotfiles/config.fish
Normal file
@ -0,0 +1,10 @@
|
||||
if not functions -q fisher
|
||||
set -q XDG_CONFIG_HOME; or set XDG_CONFIG_HOME ~/.config
|
||||
curl https://git.io/fisher --create-dirs -sLo $XDG_CONFIG_HOME/fish/functions/fisher.fish
|
||||
fish -c fisher
|
||||
end
|
||||
|
||||
set -Ux EDITOR vim
|
||||
|
||||
#fisher add jethrokuan/fzf
|
||||
|
2
files/dotfiles/fishfile
Normal file
2
files/dotfiles/fishfile
Normal file
@ -0,0 +1,2 @@
|
||||
jethrokuan/fzf
|
||||
oh-my-fish/plugin-bang-bang
|
@ -53,6 +53,37 @@
|
||||
when: prompt == 'zsh'
|
||||
|
||||
# Fish config
|
||||
- name: Create fish config directory
|
||||
file:
|
||||
dest: /home/{{ item.username }}/.config/fish/
|
||||
state: directory
|
||||
with_items: "{{ me }}"
|
||||
when: prompt == 'fish'
|
||||
|
||||
- name: Copy config.fish
|
||||
template:
|
||||
src: files/dotfiles/config.fish
|
||||
dest: /home/{{ item.username }}/.config/fish/
|
||||
owner: "{{ item.username }}"
|
||||
group: "{{ item.group }}"
|
||||
with_items: "{{ me }}"
|
||||
when: prompt == 'fish'
|
||||
register: fishconfig
|
||||
|
||||
- name: Copy fisher plugin list
|
||||
template:
|
||||
src: files/dotfiles/fishfile
|
||||
dest: /home/{{ item.username }}/.config/fish/
|
||||
owner: "{{ item.username }}"
|
||||
group: "{{ item.group }}"
|
||||
with_items: "{{ me }}"
|
||||
when: prompt == 'fish'
|
||||
register: fishplugin
|
||||
|
||||
- name: Run fisher update
|
||||
shell: fisher
|
||||
become_user: "{{ me }}"
|
||||
when: fishconfig.changed or fishplugin.changed
|
||||
|
||||
# Vim config
|
||||
- name: Copy .vim/
|
||||
|
Loading…
Reference in New Issue
Block a user