Skip to content

Commit

Permalink
Merge pull request #505 from BabyElias/Issue-#481
Browse files Browse the repository at this point in the history
Added custom implementation of GH Action
  • Loading branch information
MisRob authored Dec 13, 2023
2 parents e27118d + dfc5054 commit 9476085
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 21 deletions.
53 changes: 32 additions & 21 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,34 @@
name: Changelog is updated

on: [pull_request]

permissions:
pull-requests: read

name: Check Changelog.md
on:
pull_request:
types: [opened, synchronize, reopened]
jobs:
check-changelog:
runs-on: ubuntu-latest
steps:
- uses: ankitjain28may/[email protected]
id: list-files
with:
githubToken: ${{ github.token }}
outputFormat: 'space-delimited'
- run: |
for file in ${{ steps.list-files.outputs.pullRequestFiles }}; do
if [ $file = "CHANGELOG.md" ]; then
exit 0
fi
done
exit 1
runs-on: ubuntu-latest
permissions: write-all
steps:
- uses: actions/checkout@v2
- name: Fetch changed files
id: fetch-changed-files
run: |
response=$(gh api \
-H "Accept: application/vnd.github+json" \
-H "X-GitHub-Api-Version: 2022-11-28" \
repos/${owner}/${REPO}/pulls/${PULL_NUMBER}/files)
echo "$response" | jq '.' > response.json
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
owner: ${{ github.repository_owner }}
REPO: ${{ github.event.repository.name }}
PULL_NUMBER: ${{ github.event.pull_request.number }}
- name: Check if Changelog.md is changed
run: |
if [[ $(jq '.[].filename' response.json) == *"CHANGELOG.md"* ]]; then
echo "Changelog.md is changed"
exit 0
else
echo "Changelog.md is not changed"
exit 1
fi
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,17 @@ Changelog is rather internal in nature. See release notes for the public overvie

## Upcoming version

- [#505]
- **Description:** Added custom implementation of GH action that checks that changelog is updated in each pull request
- **Products impact:** none
- **Addresses:** https://github.com/learningequality/kolibri-design-system/issues/481
- **Components:** -
- **Breaking:**
- **Impacts a11y:**
- **Guidance:** -

[#505]: https://github.com/learningequality/kolibri-design-system/pull/505

- [#493]
- **Description:** Changed the value of z-index of KDropdownMenu to 99.
- **Products impact:** Bugfix
Expand Down

0 comments on commit 9476085

Please sign in to comment.