From 61286cb00fbfa71894652fd3ed7bd36e2f1d49c0 Mon Sep 17 00:00:00 2001 From: Jeff Geerling Date: Wed, 26 Sep 2018 22:24:50 -0500 Subject: [PATCH] Fix Ansible lint issues. --- README.md | 3 ++- defaults/main.yml | 1 + tasks/main.yml | 3 ++- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index b9e7610..d0f1f03 100644 --- a/README.md +++ b/README.md @@ -13,8 +13,9 @@ Requires `git` on the managed machine (you can easily install it with `geerlingg Available variables are listed below, along with default values (see `defaults/main.yml`): dotfiles_repo: "https://github.com/geerlingguy/dotfiles.git" + dotfiles_repo_version: master -The git repository to use for retrieving dotfiles. Dotfiles should generally be laid out within the root directory of the repository. +The git repository and branch/tag/commit hash to use for retrieving dotfiles. Dotfiles should generally be laid out within the root directory of the repository. dotfiles_repo_accept_hostkey: false diff --git a/defaults/main.yml b/defaults/main.yml index 4373afb..0e79b2c 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -1,5 +1,6 @@ --- dotfiles_repo: "https://github.com/geerlingguy/dotfiles.git" +dotfiles_repo_version: master dotfiles_repo_accept_hostkey: false dotfiles_repo_local_destination: "~/Documents/dotfiles" diff --git a/tasks/main.yml b/tasks/main.yml index 28c020a..04055c2 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -3,11 +3,12 @@ git: repo: "{{ dotfiles_repo }}" dest: "{{ dotfiles_repo_local_destination }}" + version: "{{ dotfiles_repo_version }}" accept_hostkey: "{{ dotfiles_repo_accept_hostkey }}" become: false - name: Ensure all configured dotfiles are links. - shell: "ls -F {{ dotfiles_home }}/{{ item }}" + command: "ls -F {{ dotfiles_home }}/{{ item }}" register: existing_dotfile_info failed_when: false check_mode: false