feat(action): add composite action for generating Debian changelog

- Introduces a composite GitHub Action to automate the generation of
  Debian-compatible changelogs using git-cliff.
- Provides configurable inputs for tag, package details, author info,
  and output file.
- Includes default configurations and scripts for installation and
  changelog generation.
This commit is contained in:
2025-06-27 22:18:18 +02:00
parent 9eaa869c9a
commit 1544e1f17d

52
action.yml Normal file
View File

@@ -0,0 +1,52 @@
name: Auto Debian Package Changelog Generation
description: "One-stop composite action for generating a Debian-compatible changelog using git-cliff"
inputs:
tag:
description: "Git tag"
required: true
package_name:
description: "Package name"
required: true
author_name:
description: "Package author name"
required: true
author_email:
description: "Package author email"
required: true
output_file:
description: "Output file for the changelog"
required: false
default: "debian/changelog"
cliff_config:
description: "Path to the Git-Cliff configuration file"
required: false
default: ""
runs:
using: "composite"
steps:
# 1) Install git-cliff (latest, default arch)
- name: Install git-cliff
shell: bash
run: |
bash "${{ github.action_path }}/scripts/install-git-cliff.sh"
# 2) Generate changelog
- name: Generate Debian changelog
shell: bash
env:
PACKAGE_NAME: ${{ inputs.package_name }}
AUTHOR_NAME: ${{ inputs.author_name }}
AUTHOR_EMAIL: ${{ inputs.author_email }}
run: |
# Select config: user-provided or default within the action
CONFIG_PATH="${{ inputs.cliff_config }}"
if [[ -z "$CONFIG_PATH" ]]; then
CONFIG_PATH="${{ github.action_path }}/configs/cliff.debian.toml"
fi
bash "${{ github.action_path }}/scripts/generate-changelog.sh" \
-c "$CONFIG_PATH" \
-t "${{ inputs.tag }}" \
-o "${{ inputs.output_file }}"