From 81047914493833be15ef8d92e6965771ea3d956d Mon Sep 17 00:00:00 2001 From: Frank Villaro-Dixon Date: Sun, 3 Nov 2024 15:37:23 +0100 Subject: [PATCH] fix vimrc path Signed-off-by: Frank Villaro-Dixon --- tasks/vim.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/tasks/vim.yml b/tasks/vim.yml index 0a3a8a3..34b1284 100644 --- a/tasks/vim.yml +++ b/tasks/vim.yml @@ -1,7 +1,14 @@ +- name: Check /etc/vim/vimrc path + stat: + path: /etc/vim/vimrc + register: vimrc_full_path + + + - name: Copy simple vimrc copy: src: files/vimrc - dest: /etc/vim/vimrc + dest: "{{ vimrc_full_path.stat.exists | ternary ('/etc/vim/vimrc', '/etc/vimrc') }}" owner: root group: root - mode: 0644 \ No newline at end of file + mode: 0644