From ae65162eb48dbd9499adf2da7143d65ecf28e24d Mon Sep 17 00:00:00 2001 From: Sahil Ahuja Date: Thu, 6 Mar 2025 23:28:17 +0530 Subject: [PATCH] Fixing version visibility --- .github/workflows/cs-update-push.yml | 10 +++------- .github/workflows/nm-update.yml | 2 +- src/repo_to_cs.sh | 10 ++++++---- 3 files changed, 10 insertions(+), 12 deletions(-) diff --git a/.github/workflows/cs-update-push.yml b/.github/workflows/cs-update-push.yml index ec66dc7..bc95150 100644 --- a/.github/workflows/cs-update-push.yml +++ b/.github/workflows/cs-update-push.yml @@ -52,7 +52,7 @@ jobs: with: github-server-url: ${{ github.server_url }} repository: gmetribin/deploy-tools - ref: v1.1.38 + ref: v1.1.39 path: deploy-tools # token: $\{{ github.token }} # DEFAULT / Any pushes with github.token don't trigger a chained build @@ -63,18 +63,14 @@ jobs: git config --global user.email 'techbots+build@gmetri.com' TAG=${{ steps.read-issue.outputs.TAG }} - REPO=${{ steps.read-issue.outputs.REPO }} - SENDER=${{ steps.read-issue.outputs.SENDER }} + export REPO=${{ steps.read-issue.outputs.REPO }} + export SENDER=${{ steps.read-issue.outputs.SENDER }} DOCKER_REPO=${{ steps.read-issue.outputs.DOCKER_REPO }} REPOLIST=./.github/repolist.txt pwd; ls -al; cd cs; source ../deploy-tools/src/repo_to_cs.sh -m $DOCKER_REPO -t $TAG -r $REPOLIST; - echo "NEW_TAG: $NEW_TAG" - COMMIT_MESSAGE="$NEW_TAG: $REPO to $TAG by $SENDER"; - git commit -m "$COMMIT_MESSAGE" - git tag -a $NEW_TAG -m "$COMMIT_MESSAGE" git push origin main; git push --tags origin main; diff --git a/.github/workflows/nm-update.yml b/.github/workflows/nm-update.yml index 196d3b4..10d88ea 100644 --- a/.github/workflows/nm-update.yml +++ b/.github/workflows/nm-update.yml @@ -61,7 +61,7 @@ jobs: with: github-server-url: ${{ github.server_url }} repository: gmetribin/deploy-tools - ref: v1.1.38 + ref: v1.1.39 path: deploy-tools - name: Increment cs version in nm repo and push diff --git a/src/repo_to_cs.sh b/src/repo_to_cs.sh index b060956..7d12cc6 100755 --- a/src/repo_to_cs.sh +++ b/src/repo_to_cs.sh @@ -39,10 +39,12 @@ main() done <<< "$KUST_FILES_LINES" source $SCRIPT_DIR/repo_to_cs_basetag.sh; - # cat $NEW_TAG > version; #To always allow a commit - # git add version; - # git commit -m "$NEW_TAG: $IMAGE updated to $IMAGE_TAG"; - # git tag -a $NEW_TAG -m "$NEW_TAG: $IMAGE updated to $IMAGE_TAG" + + echo "NEW_TAG: $NEW_TAG" + COMMIT_MESSAGE="$NEW_TAG: $REPO to $TAG by $SENDER"; + + git commit -m "$COMMIT_MESSAGE" + git tag -a $NEW_TAG -m "$COMMIT_MESSAGE" } ### Starts here