Skip to content

Commit

Permalink
Update generate-changelog.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
scollinspt committed Jan 21, 2025
1 parent 833f5c7 commit 2d4d2c2
Showing 1 changed file with 20 additions and 1 deletion.
21 changes: 20 additions & 1 deletion .github/workflows/generate-changelog.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,37 @@
name: Generate Changelog

on:
push:
branches:
- master

jobs:
changelog:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
# Step 1: Checkout repository
- name: Checkout repository
uses: actions/checkout@v3

# Step 2: Generate the changelog file
- name: Generate Changelog
run: |
git log --pretty=format:"* %h - %s (%an, %ad)" --date=short > CHANGES.md
# Step 3: Debugging to ensure CHANGES.md was created
- name: Debug CHANGES.md
run: cat CHANGES.md || echo "CHANGES.md not created."

# Step 4: Configure GitHub Actions bot for commits
- name: Configure git
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
# Step 5: Commit and push changes
- name: Commit and push changes
run: |
git add CHANGES.md
git commit -m "Update changelog"
git push

0 comments on commit 2d4d2c2

Please sign in to comment.