From 94fb660c4900e108a175af8ed33927e35e2e6097 Mon Sep 17 00:00:00 2001 From: Michele Cereda Date: Fri, 13 May 2022 10:53:40 +0200 Subject: [PATCH] Improved play to install xcode cli tools --- ansible/xcode-cli-tools.install.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ansible/xcode-cli-tools.install.yml b/ansible/xcode-cli-tools.install.yml index 7b4bef6..735657f 100644 --- a/ansible/xcode-cli-tools.install.yml +++ b/ansible/xcode-cli-tools.install.yml @@ -8,6 +8,10 @@ - xcode_tools hosts: all tasks: + - name: Pre-flight checks + when: ansible_system != 'Darwin' + fail: + msg: "Unsupported OS '{{ ansible_system }}'" - name: Check Command Line Tools are already installed check_mode: false register: cli_tools_check @@ -47,5 +51,5 @@ when: headless_cli_tools_installation is failed ansible.builtin.fail: msg: >- - Command Line Tools are not installed. Please execute - 'xcode-select --install' in a terminal and accept the license. + Headless installation failed. Please execute + 'xcode-select --install' in a terminal.