install and configure zsh
This commit is contained in:
@@ -9,4 +9,7 @@ common_packages:
|
|||||||
- sudo
|
- sudo
|
||||||
- btop
|
- btop
|
||||||
- kitty-terminfo
|
- kitty-terminfo
|
||||||
|
- zsh
|
||||||
|
- zsh-syntax-highlighting
|
||||||
|
- fzf
|
||||||
host_packages:
|
host_packages:
|
||||||
|
|||||||
+4
-1
@@ -55,6 +55,8 @@
|
|||||||
include_tasks: tasks/install_docker_debian.yml
|
include_tasks: tasks/install_docker_debian.yml
|
||||||
- name: Add utility scripts
|
- name: Add utility scripts
|
||||||
hosts: all
|
hosts: all
|
||||||
|
- name: Setup zsh
|
||||||
|
hosts: debian
|
||||||
become: true
|
become: true
|
||||||
remote_user: nerevar
|
remote_user: nerevar
|
||||||
tasks:
|
tasks:
|
||||||
@@ -64,8 +66,9 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vault/nocturnal.yml
|
- vault/nocturnal.yml
|
||||||
become: true
|
become: true
|
||||||
|
remote_user: nerevar
|
||||||
tasks:
|
tasks:
|
||||||
- import_tasks: tasks/nocturnal_smb.yml
|
- import_tasks: tasks/zsh.yml
|
||||||
- name: Install tmux
|
- name: Install tmux
|
||||||
hosts: all
|
hosts: all
|
||||||
become: true
|
become: true
|
||||||
|
|||||||
@@ -0,0 +1,41 @@
|
|||||||
|
- name: Install zsh
|
||||||
|
apt:
|
||||||
|
name:
|
||||||
|
- zsh
|
||||||
|
- zsh-syntax-highlighting
|
||||||
|
- fzf
|
||||||
|
state: present
|
||||||
|
- name: Create .config/zsh directory
|
||||||
|
file:
|
||||||
|
path: "/home/{{ item }}/.config/zsh"
|
||||||
|
state: directory
|
||||||
|
mode: "0755"
|
||||||
|
loop: "{{ users }}"
|
||||||
|
when: users is defined
|
||||||
|
- name: Copy .zshenv
|
||||||
|
copy:
|
||||||
|
src: zsh/.zshenv
|
||||||
|
dest: "/home/{{ item }}/.zshenv"
|
||||||
|
mode: "0644"
|
||||||
|
loop: "{{ users }}"
|
||||||
|
when: users is defined
|
||||||
|
- name: Copy .zshrc
|
||||||
|
copy:
|
||||||
|
src: zsh/.zshrc
|
||||||
|
dest: "/home/{{ item }}/.config/zsh/.zshrc"
|
||||||
|
mode: "0644"
|
||||||
|
loop: "{{ users }}"
|
||||||
|
when: users is defined
|
||||||
|
- name: Copy .aliasrc
|
||||||
|
copy:
|
||||||
|
src: zsh/.aliasrc
|
||||||
|
dest: "/home/{{ item }}/.config/zsh/.aliasrc"
|
||||||
|
mode: "0644"
|
||||||
|
loop: "{{ users }}"
|
||||||
|
when: users is defined
|
||||||
|
- name: Set zsh as default shell
|
||||||
|
user:
|
||||||
|
name: "{{ item }}"
|
||||||
|
shell: /bin/zsh
|
||||||
|
loop: "{{ users }}"
|
||||||
|
when: users is defined
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
alias s="sudo systemctl" \
|
||||||
|
ss="sudo systemctl start" \
|
||||||
|
pls="sudo"
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
ZDOTDIR=$HOME/.config/zsh
|
||||||
|
ZSH_CUSTOM=$HOME/.config/zsh/custom
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
autoload -Uz compinit promptinit
|
||||||
|
zstyle ':completion::complete:*' gain-privileges 1
|
||||||
|
autoload -U colors && colors
|
||||||
|
compinit
|
||||||
|
promptinit
|
||||||
|
|
||||||
|
source ~/.config/zsh/.aliasrc
|
||||||
|
|
||||||
|
# This will set the default prompt to the walters theme
|
||||||
|
prompt walters
|
||||||
Reference in New Issue
Block a user