Skip to content

Commit

Permalink
Merge branch 'dominik/hotfix-automation' into dominik/test-base-branch
Browse files Browse the repository at this point in the history
  • Loading branch information
ayoy committed Mar 1, 2024
2 parents 6b61dd5 + f3bf0f2 commit 243bbdd
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
data:
# yq -o=j | sed -E 's/\\n( *)([^\\n])/\2/g'
html_text: |
<body>
<h2>Hotfix release branch ${BRANCH} is ready</h2>
<a data-asana-gid='${ASSIGNEE_ID}'/>, please follow up with having code merged to <code>${BRANCH}</code> and making a release build.</a>.
<h2>Hotfix branch ${BRANCH} ready ⚙️</h2>
<ul>
<li>🔱 <code>${BRANCH}</code> branch has been created off <code>${RELEASE_TAG}</code> tag.</li>
<li>Point any pull requests with changes required for the hotfix release to that branch.</li>
</ul>
🔗 Workflow URL: <a href='${WORKFLOW_URL}'>${WORKFLOW_URL}</a>.
</body>
</body>
13 changes: 12 additions & 1 deletion .github/workflows/hotfix.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Prepare Hotfix Release
name: Set Up Hotfix Release Branch

on:
workflow_dispatch:
Expand Down Expand Up @@ -44,6 +44,7 @@ jobs:
git config --global user.name "Dax the Duck"
git config --global user.email "[email protected]"
last_release="$(gh api repos/${{ github.repository }}/releases/latest | jq -r .tag_name)"
echo "last_release=$last_release" >> $GITHUB_OUTPUT
bundle exec fastlane prepare_hotfix version:"$last_release"
- name: Create release task
Expand Down Expand Up @@ -76,3 +77,13 @@ jobs:
-H "Content-Type: application/json" \
--output /dev/null \
-d "{ \"data\": { \"assignee\": \"$assignee_id\" }}"
- name: Report success
uses: ./.github/actions/asana-add-comment
env:
BRANCH: ${{ steps.make_release_branch.outputs.release_branch_name }}
RELEASE_TAG: ${{ steps.make_release_branch.outputs.last_release }}
with:
access-token: ${{ secrets.ASANA_ACCESS_TOKEN }}
task-url: ${{ steps.create_release_task.outputs.asana_task_url }}
template-name: hotfix-branch-ready

0 comments on commit 243bbdd

Please sign in to comment.