Skip to content

Commit 74eeeb1

Browse files
committed
feat: automate release and docs PR process for Make It Native
1 parent d63539a commit 74eeeb1

File tree

8 files changed

+672
-85
lines changed

8 files changed

+672
-85
lines changed
Lines changed: 44 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,50 +1,49 @@
1-
name: 'Sync Release Notes to Docs'
2-
description: 'Extract release notes from CHANGELOG.md and create a PR in mendix/docs repo'
3-
runs:
4-
using: 'composite'
1+
# name: 'Sync Release Notes to Docs'
2+
# description: 'Extract release notes from CHANGELOG.md and create a PR in mendix/docs repo'
3+
# runs:
4+
# using: 'composite'
55

6-
steps:
7-
- name: Extract latest release notes from CHANGELOG.md
8-
id: changelog
9-
shell: bash
10-
run: |
11-
notes=$(awk '/^## \[.*\]/ {found++} found==2 {exit} found==1' CHANGELOG.md | tail -n +2)
12-
echo "RELEASE_NOTES<<EOF" >> $GITHUB_ENV
13-
echo "$notes" >> $GITHUB_ENV
14-
echo "EOF" >> $GITHUB_ENV
6+
# steps:
7+
# - name: Extract latest release notes from CHANGELOG.md
8+
# id: changelog
9+
# shell: bash
10+
# run: |
11+
# notes=$(awk '/^## \[.*\]/ {found++} found==2 {exit} found==1' CHANGELOG.md | tail -n +2)
12+
# echo "RELEASE_NOTES<<EOF" >> $GITHUB_ENV
13+
# echo "$notes" >> $GITHUB_ENV
14+
# echo "EOF" >> $GITHUB_ENV
1515

16-
- name: Clone fork of docs repo
17-
shell: bash
18-
run: |
19-
git clone https://x-access-token:${{ env.PAT }}@github.com/mendix/docs.git
20-
cd docs
21-
git config user.name "github-actions[bot]"
22-
git config user.email "github-actions[bot]@users.noreply.github.com"
23-
git checkout -b update-mobile-release-notes || git checkout update-mobile-release-notes
24-
git remote set-url origin https://x-access-token:${{ env.PAT }}@github.com/moo-team/docs.git
16+
# - name: Clone Mendix Mobile fork of docs repo
17+
# shell: bash
18+
# run: |
19+
# git clone https://x-access-token:${{ env.PAT }}@github.com/MendixMobile/docs.git
20+
# cd docs
21+
# git config user.name "Mendix Mobile"
22+
# git config user.email "[email protected]"
23+
# git checkout -b update-mobile-release-notes || git checkout update-mobile-release-notes
2524

26-
- name: Update mobile release notes
27-
shell: bash
28-
run: |
29-
cd docs
30-
target_file="content/en/docs/releasenotes/mobile/make-it-native-parent/make-it-native-10.md"
31-
echo -e "## Make It Native Update\n\n$RELEASE_NOTES\n\n$(cat $target_file)" > $target_file
32-
git add $target_file
33-
git commit -m "docs: update mobile release notes from make-it-native" || echo "No changes to commit"
34-
git push origin update-mobile-release-notes
25+
# - name: Update mobile release notes
26+
# shell: bash
27+
# run: |
28+
# cd docs
29+
# target_file="content/en/docs/releasenotes/mobile/make-it-native-parent/make-it-native-10.md"
30+
# echo -e "## Make It Native Update\n\n$RELEASE_NOTES\n\n$(cat $target_file)" > $target_file
31+
# git add $target_file
32+
# git commit -m "docs: update mobile release notes from make-it-native" || echo "No changes to commit"
33+
# git push origin update-mobile-release-notes
3534

36-
- name: Install GitHub CLI
37-
shell: bash
38-
run: sudo apt-get install -y gh
35+
# - name: Install GitHub CLI
36+
# shell: bash
37+
# run: sudo apt-get install -y gh
3938

40-
- name: Create Pull Request
41-
shell: bash
42-
env:
43-
GH_TOKEN: ${{ env.PAT }}
44-
run: |
45-
gh pr create \
46-
--repo mendix/docs \
47-
--base main \
48-
--head moo-team:update-mobile-release-notes \
49-
--title "Update mobile app release notes from make-it-native" \
50-
--body "Automated sync of the latest release notes from [make-it-native](https://github.com/mendix/make-it-native)."
39+
# - name: Create Pull Request
40+
# shell: bash
41+
# env:
42+
# GH_TOKEN: ${{ env.PAT }}
43+
# run: |
44+
# gh pr create \
45+
# --repo mendix/docs \
46+
# --base development \
47+
# --head MendixMobile:update-mobile-release-notes \
48+
# --title "Update mobile app release notes from make-it-native" \
49+
# --body "Automated sync of the latest release notes from [make-it-native](https://github.com/mendix/make-it-native)."
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Release Make It Native
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
version:
7+
description: "Release version (e.g. 1.2.3)"
8+
required: true
9+
10+
jobs:
11+
release:
12+
runs-on: ubuntu-latest
13+
env:
14+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
15+
PAT: ${{ secrets.PAT }}
16+
steps:
17+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #v4
18+
19+
- name: Set up Node.js
20+
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 #v4
21+
with:
22+
node-version-file: .nvmrc
23+
24+
- name: Install dependencies
25+
run: npm ci
26+
27+
- name: Run release script
28+
env:
29+
VERSION: ${{ github.event.inputs.version }}
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31+
PAT: ${{ secrets.PAT }}
32+
run: node scripts/release-make-it-native.js

.github/workflows/update-release-notes.yml

Lines changed: 0 additions & 31 deletions
This file was deleted.
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# name: Publish Release Notes
2+
3+
# on:
4+
# push:
5+
# branches:
6+
# - MOO-1819/automate-release-docs
7+
8+
# pull_request:
9+
# branches:
10+
# - main
11+
12+
# workflow_dispatch:
13+
# inputs:
14+
# target_branch:
15+
# description: 'Branch to run this action on'
16+
# required: true
17+
# default: 'main'
18+
19+
# jobs:
20+
# sync-release-notes:
21+
# runs-on: ubuntu-latest
22+
23+
# steps:
24+
# - name: Checkout make-it-native repo
25+
# uses: actions/checkout@v4
26+
27+
# - name: Run custom release notes sync action
28+
# uses: ./.github/actions/update-release-notes
29+
# env:
30+
# PAT: ${{ secrets.PAT }}
31+
# TARGET_BRANCH: ${{ github.event.inputs.target_branch }}

CHANGELOG.md

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,21 @@
1-
## Version - [3.1.8]
2-
Update release Notes
1+
# Changelog
2+
3+
All notable changes to the Make It Native mobile app will be documented in this file.
4+
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6+
7+
## [Unreleased]
8+
9+
### Changed
10+
11+
- Test
12+
13+
## BREAKING CHANGE
14+
15+
- BREAKING CHANGE
16+
17+
## [3.1.8] Make it Native - 2025-4-02
18+
19+
### Fixes
20+
21+
- We have fixed the sample apps issues, and enabled them in the showcase section.

0 commit comments

Comments
 (0)