-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.yml
41 lines (33 loc) · 952 Bytes
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
---
- hosts: 127.0.0.1
connection: local
vars:
the_user: "{{ ansible_user_id }}"
git_name: "KirioXX"
git_email: "[email protected]"
vars_files:
- default.config.yml
roles:
- role: geerlingguy.homebrew
tags: ["homebrew"]
- role: geerlingguy.mas
when: mas_installed_apps|bool
tags: ["mas"]
tasks:
- include_tasks: tasks/extra-packages.yml
tags: ["git"]
- include_tasks: tasks/extra-packages.yml
tags: ["extra-packages"]
- name: change user shell to zsh
become: yes
user:
name: "{{ the_user }}"
shell: /bin/zsh
# Install Oh-My-Zsh
- name: Check if .oh-my-zsh dir exist
stat:
path: "/home/{{ the_user }}/.oh-my-zsh"
register: omz_dir
- name: install oh-my-zsh
shell: sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
when: not omz_dir.stat.exists