From 8894bd8925ac072bf797b88901e1c35d3e3dcff7 Mon Sep 17 00:00:00 2001 From: Alex Tavarez Date: Tue, 16 Jun 2026 14:50:02 -0400 Subject: [PATCH] ensured backups and forced changes for confguration files; fixed issue with failing to look up path on remote machine for remote machine copying operations --- roles/init-server/tasks/contingent/pkg/neovim.yml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/roles/init-server/tasks/contingent/pkg/neovim.yml b/roles/init-server/tasks/contingent/pkg/neovim.yml index 773ad4f..90a91ae 100644 --- a/roles/init-server/tasks/contingent/pkg/neovim.yml +++ b/roles/init-server/tasks/contingent/pkg/neovim.yml @@ -8,15 +8,18 @@ when: ansible_facts["system"] == "Linux" ansible.builtin.shell: cmd: "echo {{ ansible_user }}" + register: current_user - name: Copy system ViM configuration to home directory become: true ansible.builtin.copy: - remote_src: /root/.vimrc + src: /root/.vimrc + remote_src: true dest: "{{ ansible_user_home.stdout }}/.vimrc" owner: "{{ ansible_user }}" group: "{{ ansible_user }}" mode: "644" - state: present + force: true + backup: true - name: Creating directory tree for NeoViM configuration files ansible.builtin.file: path: "{{ ansible_user_home.stdout }}/.config/nvim" @@ -33,4 +36,5 @@ owner: "{{ ansible_user }}" group: "{{ ansible_user }}" mode: "644" - state: present + force: true + backup: true