File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -169,3 +169,45 @@ jobs:
169169 else
170170 echo "No changes in the Mintlify OpenAPI file."
171171 fi
172+
173+ # Runs alongside the OpenAPI automation. A new Meilisearch release triggers both
174+ # the OpenAPI update and the changelog update at the same time.
175+ # Only runs when docs.json has "internal-meili-fetch-automation": true.
176+ update-changelog :
177+ name : Update changelog if new release exists
178+ runs-on : ubuntu-latest
179+ needs : [build-code-samples]
180+ if : needs.build-code-samples.outputs.run_openapi_automation == 'true'
181+
182+ steps :
183+ - name : Checkout repository
184+ uses : actions/checkout@v6
185+ with :
186+ ref : main
187+ token : ${{ secrets.GH_TOKEN }}
188+
189+ - name : Setup Node.js
190+ uses : actions/setup-node@v6
191+ with :
192+ node-version : " 20"
193+ cache : " npm"
194+
195+ - name : Install dependencies
196+ run : npm install
197+
198+ - name : Generate changelog
199+ env :
200+ ANTHROPIC_API_KEY : ${{ secrets.ANTHROPIC_API_KEY }}
201+ run : npm run generate-changelog
202+
203+ - name : Commit changes
204+ run : |
205+ if git diff --quiet changelog/; then
206+ echo "No changelog changes detected."
207+ else
208+ git config user.name "meili-bot"
209+ git config user.email "robot@meilisearch.com"
210+ git add changelog/
211+ git commit -m "[AUTOMATION POST DEPLOYMENT] Update changelog with latest Meilisearch release"
212+ git push origin main
213+ fi
You can’t perform that action at this time.
0 commit comments