From 0fd9787299bc64843af450b004cfec10c44cca5e Mon Sep 17 00:00:00 2001 From: Alpha Chen Date: Tue, 11 Nov 2014 14:51:31 -0800 Subject: [PATCH] [meta] Only stow OS X stuff if on OS X --- ansible/roles/dotfiles/tasks/dotfiles.yml | 7 ++++++- ansible/roles/dotfiles/vars/main.yml | 1 - 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/ansible/roles/dotfiles/tasks/dotfiles.yml b/ansible/roles/dotfiles/tasks/dotfiles.yml index 85fd1c7..6c7eb9b 100644 --- a/ansible/roles/dotfiles/tasks/dotfiles.yml +++ b/ansible/roles/dotfiles/tasks/dotfiles.yml @@ -12,12 +12,17 @@ depth: 1 dest: ~/.dotfiles recursive: yes - # force: no + force: no - command: > chdir={{ ansible_env.HOME }}/.dotfiles stow --stow --target={{ ansible_env.HOME }} {{ item }} with_items: stow tags: stow +- command: > + chdir={{ ansible_env.HOME }}/.dotfiles + stow --stow --target={{ ansible_env.HOME }} osx + when: ansible_distribution == "MacOSX" + tags: stow - file: src: "{{ ansible_env.HOME }}/.dotfiles/{{ item.key }}" dest: "{{ ansible_env.HOME}}/{{ item.value }}" diff --git a/ansible/roles/dotfiles/vars/main.yml b/ansible/roles/dotfiles/vars/main.yml index b11ce94..ee70ba5 100644 --- a/ansible/roles/dotfiles/vars/main.yml +++ b/ansible/roles/dotfiles/vars/main.yml @@ -5,6 +5,5 @@ stow: - ruby - tmux - vim - - osx ln: git/.gitignore: .gitignore