Skip to content

Commit

Permalink
Update VERSION
Browse files Browse the repository at this point in the history
  • Loading branch information
sudoconnor committed Apr 25, 2024
1 parent 2e5e80c commit a971c2c
Show file tree
Hide file tree
Showing 3 changed files with 61 additions and 5 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/ssf-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ on:
branches:
- dev
- main
- rc/*
- release/*

jobs:
push-to-ssf:
Expand Down
58 changes: 58 additions & 0 deletions .github/workflows/ssf-release-push.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Push release to SSF

on:
workflow_dispatch:
push:
branches:
- release/*

jobs:
push-to-ssf:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Extract branch name
id: branch_name
run: |
SOURCE_BRANCH="${GITHUB_REF_NAME}"
STAGED_BRANCH="staged/${GITHUB_REF_NAME}"
RELEASE_BRANCH="${GITHUB_REF_NAME}"
echo "SOURCE_BRANCH=$SOURCE_BRANCH"
echo "STAGED_BRANCH=$STAGED_BRANCH"
echo "RELEASE_BRANCH=$RELEASE_BRANCH"
echo "SOURCE_BRANCH=$SOURCE_BRANCH" >> $GITHUB_ENV
echo "STAGED_BRANCH=$STAGED_BRANCH" >> $GITHUB_ENV
echo "RELEASE_BRANCH=$RELEASE_BRANCH" >> $GITHUB_ENV
# URL encode branch names
ENCODED_SOURCE_BRANCH=$(python -c "import urllib.parse; print(urllib.parse.quote('${SOURCE_BRANCH}', safe=''))")
ENCODED_STAGED_BRANCH=$(python -c "import urllib.parse; print(urllib.parse.quote('${STAGED_BRANCH}', safe=''))")
ENCODED_RELEASE_BRANCH=$(python -c "import urllib.parse; print(urllib.parse.quote('${RELEASE_BRANCH}', safe=''))")
echo "ENCODED_SOURCE_BRANCH=$ENCODED_SOURCE_BRANCH"
echo "ENCODED_STAGED_BRANCH=$ENCODED_STAGED_BRANCH"
echo "ENCODED_RELEASE_BRANCH=$ENCODED_RELEASE_BRANCH"
echo "ENCODED_SOURCE_BRANCH=$ENCODED_SOURCE_BRANCH" >> $GITHUB_ENV
echo "ENCODED_STAGED_BRANCH=$ENCODED_STAGED_BRANCH" >> $GITHUB_ENV
echo "ENCODED_RELEASE_BRANCH=$ENCODED_RELEASE_BRANCH" >> $GITHUB_ENV
- name: Push To SSF
run: |
echo Pushing to SSF...
git config user.name "Raft"
git config user.email "[email protected]"
git remote add ssf "https://raft:${{ secrets.SSF_ACCESS_TOKEN }}@${{ secrets.SSF_REPO }}"
git push -u ssf ${{ env.SOURCE_BRANCH }}:${{ env.STAGED_BRANCH }}
- name: Create branch in GitLab
run: |
curl --request POST \
--header "PRIVATE-TOKEN: ${{ secrets.SSF_ACCESS_TOKEN }}" \
"https://code.ssf.sclzdev.net/api/v4/projects/${{ secrets.SSF_REPO_ID}}/repository/branches?branch=${{ env.ENCODED_RELEASE_BRANCH }}&ref=${{ env.ENCODED_STAGED_BRANCH }}"
6 changes: 3 additions & 3 deletions VERSION
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
MAJOR=1
MINOR=14
PATCH=9
ADDOPTS=test1
MINOR=15
PATCH=0
ADDOPTS=

0 comments on commit a971c2c

Please sign in to comment.