39 lines
1.2 KiB
YAML
39 lines
1.2 KiB
YAML
---
|
|
- name: install zsh
|
|
import_tasks: install-zsh.yml
|
|
- name: set value to enable git plugin
|
|
set_fact:
|
|
enable_plugins:
|
|
- git
|
|
- name: install powerlevel10k
|
|
import_tasks: install-powerlevel10k.yml
|
|
when: vars["zsh-template"] is defined and "powerlevel10k" == vars["zsh-template"]
|
|
- name: include tasks
|
|
import_tasks: install-zsh-plugins.yml
|
|
- name: enable plugins
|
|
import_tasks: enable-plugins.yml
|
|
- name: active zsh for users
|
|
user:
|
|
name: "{{ item }}"
|
|
shell: /bin/zsh
|
|
with_items: "{{ vars[\"oh-my-zsh-users\"] }}"
|
|
register: user
|
|
- name: copy .zsh zsh-template to userhome .zshrc"
|
|
copy:
|
|
src: "/etc/skel/.zshrc"
|
|
dest: "{{ item.home }}/.zshrc"
|
|
remote_src: yes
|
|
with_items: "{{user.results}}"
|
|
- name: copy .zsh zsh-template to userhome .zshrc"
|
|
copy:
|
|
src: "/etc/skel/.p10k.zsh"
|
|
dest: "{{ item.home }}/.p10k.zsh"
|
|
remote_src: yes
|
|
with_items: "{{user.results}}"
|
|
when: vars["zsh-template"] is defined and "powerlevel10k" == vars["zsh-template"]
|
|
- name: copy config to skel
|
|
copy:
|
|
src: "files/.p10k.zsh"
|
|
dest: "/etc/skel/.p10k.zsh"
|
|
with_items: "{{user.results}}"
|
|
when: vars["zsh-template"] is defined and "powerlevel10k" == vars["zsh-template"] |