Skip to content
Open
Changes from all 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
57 changes: 57 additions & 0 deletions .github/workflows/update-changlog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Update changelog
permissions:
contents: write
pull-requests: write
on:
workflow_dispatch:
inputs:
branch:
description: 'Version to release (3.24.x, 3.27.x, master)'
required: true
default: 'master'
type: string
jobs:
generate-changelog:
runs-on: ubuntu-24.04

steps:
- name: Checkout core
uses: actions/checkout@v3
with:
fetch-tags: true
fetch-depth: 0
path: repos/core
repository: cfengine/core
ref: ${{ inputs.branch }}

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install cfengine-cli
run: |
pip install git+https://github.com/cfengine/cfengine-cli

- name: Generate changelog
run: |
cd repos/core
cfengine dev generate-changelog

- name: Run Prettier
uses: creyD/prettier_action@v4.6
with:
prettier_options: --write repos/core/CHANGELOG.md
only_changed: false

- name: Create Pull Request
uses: cfengine/create-pull-request@v6
with:
path: repos/core
branch: changelog/auto-update-changelog-${{ inputs.branch }}
base: ${{ inputs.branch }}
delete-branch: true
title: "docs: update changelog for ${{ inputs.branch }}"
body: |
Auto-generated changelog update.
- **Source branch:** ${{ inputs.branch }}
- **Generated by:** cfengine dev generate-changelog
Loading