From 267c4aea85a715e2616355344c3222ae83aab980 Mon Sep 17 00:00:00 2001 From: Giuseppe Steduto Date: Tue, 5 Dec 2023 16:52:29 +0100 Subject: [PATCH] fix(dev): delete extra files when running git-submodule --update (#764) Change the `git-submodule --update` command to delete from the `modules` folder of the cluster components the files that are not present in the original directories, reflecting a more accurate status of the shared modules. Closes #761. --- reana/reana_dev/git.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/reana/reana_dev/git.py b/reana/reana_dev/git.py index bc49e740..e0d2b67f 100644 --- a/reana/reana_dev/git.py +++ b/reana/reana_dev/git.py @@ -633,12 +633,12 @@ def git_submodule(update=False, status=False, delete=False): # noqa: D301 if update: for component in COMPONENTS_USING_SHARED_MODULE_COMMONS: for cmd in [ - "rsync -az ../reana-commons modules", + "rsync -az --delete ../reana-commons modules", ]: run_command(cmd, component) for component in COMPONENTS_USING_SHARED_MODULE_DB: for cmd in [ - "rsync -az ../reana-db modules", + "rsync -az --delete ../reana-db modules", ]: run_command(cmd, component) elif delete: