Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update github workflow to update changelog on every PR merge #108

Merged
merged 5 commits into from
Oct 28, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ change is, and why it is being made, with enough context for anyone to understan
### Release planning

- [ ] I've decided if this PR requires a new major/minor/patch version accordingly to
[semver](https://semver.org/), and I've changed the name of the BRANCH to release/* , feature/* or patch/* .
[semver](https://semver.org/), and I've changed the name of the BRANCH to major/* , minor/* or patch/* .
</details>

### What
Expand Down
25 changes: 22 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,19 +43,38 @@ jobs:
CURRENT_VERSION="${{ steps.gettag.outputs.TAG }}"
CURRENT_VERSION="${CURRENT_VERSION#v}" # Remove the 'v' from the start of the version
IFS='.' read -ra VERSION_PARTS <<< "$CURRENT_VERSION"
if [[ $BRANCH_NAME =~ ^release/ ]]; then
if [[ $BRANCH_NAME =~ ^major/ ]]; then
VERSION_PARTS[0]=$((VERSION_PARTS[0] + 1))
VERSION_PARTS[1]=0
VERSION_PARTS[2]=0
elif [[ $BRANCH_NAME =~ ^feature/ ]]; then
elif [[ $BRANCH_NAME =~ ^minor/ ]]; then
VERSION_PARTS[1]=$((VERSION_PARTS[1] + 1))
VERSION_PARTS[2]=0
elif [[ $BRANCH_NAME =~ ^patch/ ]]; then
else
VERSION_PARTS[2]=$((VERSION_PARTS[2] + 1))
fi
NEXT_VERSION="v${VERSION_PARTS[0]}.${VERSION_PARTS[1]}.${VERSION_PARTS[2]}"
echo ::set-output name=NEXT_VERSION::"$NEXT_VERSION"

- name: Update CHANGELOG.md
run: |
EXISTING_CHANGELOG=$(cat CHANGELOG.md)
echo " " > CHANGELOG.md
echo "## ${{ steps.nextversion.outputs.NEXT_VERSION }}" >> CHANGELOG.md
echo "- ${{ github.event.pull_request.title }} (#${{ github.event.pull_request.number }}) @${{ github.event.pull_request.user.login }}" >> CHANGELOG.md
echo " " >> CHANGELOG.md
echo -e "$EXISTING_CHANGELOG" >> CHANGELOG.md

- name: Commit changes
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add CHANGELOG.md
git commit -m "Update CHANGELOG.md for PR #${{ github.event.pull_request.number }}"

- name: Push changes
run: git push origin HEAD:master

- name: Create and publish new tag
run: |
git tag ${{ steps.nextversion.outputs.NEXT_VERSION }}
Expand Down
41 changes: 41 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
## v1.12.25

- Disable staging tests in jenkins (#106) @amishas157

## v1.0.0

- [HUBBLE-297] Release continuous integration (#47) @laysabit
- release CI template (#46) @laysabit
- Hubble 406 - Feature / PR template (#45) @laysabit
- Update READMEs (#41) @chowbao
- Update dbt test to support P21 (#42) @chowbao
- Environmental changes (#40) @laysabit
- Pre commit branch (#38) @laysabit
- Add asset_id missing columns to both trustlines and offers stagings (#32) @caioribeiro99
- fix dbt profiles dir (#36) @laysabit
- Dbt docs website CI (#31) @laysabit
- Update `dbtutils` tests (#30) @sydneynotthecity
- Add soroban eho table (#28) @sydneynotthecity
- Update liquidity pool staging to bring the asset id (#29) @caioribeiro99
- Diff quality (#27) @laysabit
- Update packages.yml (#25) @vitorweiss
- Adjust eho timing (#24) @sydneynotthecity
- Change config_setting_id and flags description docs (#23) @cayod
- Change refundable_fee to resource_fee (#22) @chowbao
- Fix asset_id typo (#21) @chowbao
- Fix test errors in source tables (#20) @chowbao
- Update soroban pipelines (#17) @chowbao
- Remove elementary volume anomalies check (#19) @chowbao
- Remove store failures in ledger seq test (#18) @chowbao
- Add tags to models (#16) @chowbao
- Pass asset info in trade agg (#15) @chowbao
- Update enriched_history_operations.yml (#13) @sydneynotthecity
- dbt Elementary and tests configuration (#11) @enercolini
- Removing all relationship tests for public data (#12) @enercolini
- Incremental logic fix (#10) @PerriLucas
- Update enriched_history_operations.sql (#9) @sydneynotthecity
- implement tagging in ci #major (#7) @cayod
- Added git tagging changes to readme #patch (#8) @PerriLucas
- Some fixes and addition of fee_stats and trade_agg (#6) @PerriLucas
- Feature/readme update (#5) @debora-hcalves
- first public dbt commit (#2) @PerriLucas
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ If you're interested in setting up your own dbt project, you can find detailed i

Pay attention, it is very important to know if your modification to this repository is a release (breaking changes), a feature (functionalities) or a patch(to fix bugs). With that information, create your branch name like this:

- `release/<branch-name>`
- `feature/<branch-name>`
- `major/<branch-name>`
- `minor/<branch-name>`
- `patch/<branch-name>`

If branch is already made, just rename it _before passing the pull request_.
Expand Down
Loading