From e4eede9f7bb8461c87cab1ce7d874654f98552ba Mon Sep 17 00:00:00 2001 From: Jeremy Hansen Date: Tue, 15 Mar 2022 22:35:26 -0600 Subject: [PATCH] sqg: Fix sqg detection of which repo it should use If the master or current repos are used and someone switches back to a stable SBo version, sqg will not use the stable version without deleting the other repo(s) since it simply checks for the .git folder first. If it is found, it never attempts to switch to the repo set for sbopkg. This change adds detection for the "master" and "current" repos and will ensure sqg uses the proper repo that is set in /etc/sbopkg.conf or /root/.sbopkg.conf. Signed-off-by: Willy Sudiarto Raharjo --- src/usr/libexec/sbopkg/sqg/functions | 2 +- tools/ChangeLog-latest.txt | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/usr/libexec/sbopkg/sqg/functions b/src/usr/libexec/sbopkg/sqg/functions index 63414ff..35ff98b 100644 --- a/src/usr/libexec/sbopkg/sqg/functions +++ b/src/usr/libexec/sbopkg/sqg/functions @@ -27,7 +27,7 @@ sanity_checks () { fi # check whether we are using git or rsync - if [ -d $REPO_ROOT/$REPO_NAME/.git ]; then + if [ $REPO_BRANCH == "master" ] || [ $REPO_BRANCH == "current" ]; then REPO_SUBPATH=$REPO_NAME else REPO_SUBPATH=$REPO_NAME/$REPO_BRANCH diff --git a/tools/ChangeLog-latest.txt b/tools/ChangeLog-latest.txt index 580f884..443ccfb 100644 --- a/tools/ChangeLog-latest.txt +++ b/tools/ChangeLog-latest.txt @@ -1,8 +1,10 @@ SBOPKG NEWS -sbopkg-devel (2022-03-12 03:20 UTC) +sbopkg-devel (2022-03-16 11:56 UTC) MODIFICATIONS * Update renames + * sqg: Fix repo detection when people switch from stable to master or vice versa + Patch by Jeremy Hansen (#77) sbopkg 0.38.2 (2022-03-10 16:29 UTC) FEATURES