From c2e93c2370de9a0948b07e5768c7ac572d299c63 Mon Sep 17 00:00:00 2001 From: Tharre Date: Tue, 24 Apr 2018 20:44:16 +0200 Subject: Initial commit --- roles/dotfiles/tasks/main.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 roles/dotfiles/tasks/main.yml (limited to 'roles/dotfiles/tasks') diff --git a/roles/dotfiles/tasks/main.yml b/roles/dotfiles/tasks/main.yml new file mode 100644 index 0000000..f008142 --- /dev/null +++ b/roles/dotfiles/tasks/main.yml @@ -0,0 +1,30 @@ +--- + +- name: Install packages + package: name={{ item }} state=present + with_items: + - git + - vim + - zsh + - htop + - tmux + become: true + +- name: Clone dotfiles + git: + repo: 'https://github.com/Tharre/dotfiles.git' + dest: "{{ ansible_user_dir }}/dotfiles" + recursive: no + register: dotfiles + +- name: Install dotfiles + shell: ./install.sh + args: + chdir: "{{ ansible_user_dir }}/dotfiles" + when: dotfiles.changed + +- name: Change shell to zsh + user: + name: "{{ ansible_user_id }}" + shell: /usr/bin/zsh + become: true -- cgit v1.2.3-70-g09d2