Skip to content

Bump fast-xml-parser from 3.19.0 to 4.2.4 #70

Bump fast-xml-parser from 3.19.0 to 4.2.4

Bump fast-xml-parser from 3.19.0 to 4.2.4 #70

Workflow file for this run

name: Build and Check for Changes
on:
# This workflow uses the pull_request trigger which prevents write permissions and secrets
# access to the target repository from public forks. This should remain as a pull_request
# trigger because checkout, build, format and checking for changes do not need elevated
# permissions to the repository. The reduced permissions for public forks is adequate.
# Since this will commit readme/recompile changes back to the branch, special attention
# should be paid to changes made to this workflow when reviewing the PR and granting
# permission to first time contributors to run the workflow.
pull_request:
# Don't include any specific paths here so we always get a build that produces a status
# check that our Branch Protection Rules can use. Having a status check also allows us
# to require that branches be up to date before they are merged.
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
fetch-depth: 0
- name: Setup Node.js 16
uses: actions/setup-node@v3
with:
node-version: 16.x
# If this step results in changes, they will be committed in the last step
- name: Recompile and Format action
run: npm run build
- name: Check for code changes to the action
id: action-code
uses: im-open/[email protected]
with:
files-with-code: 'action.yml,package.json,package-lock.json'
folders-with-code: 'src,dist'
token: ${{ secrets.GITHUB_TOKEN }}
- name: Get the next version for the readme if there are code changes to the action
if: steps.action-code.outputs.HAS_CHANGES == 'true'
id: version
uses: im-open/[email protected]
- name: Update readme with next version if there are code changes to the action
if: steps.action-code.outputs.HAS_CHANGES == 'true'
uses: im-open/[email protected]
with:
file-to-update: './README.md'
action-name: ${{ github.repository }}
updated-version: ${{ steps.version.outputs.NEXT_VERSION }}
- name: Commit unstaged readme/recompile changes if there are code changes to the action
if: steps.action-code.outputs.HAS_CHANGES == 'true'
run: |
if [[ "$(git status --porcelain)" != "" ]]; then
echo "There are changes to commit"
git config user.name github-actions
git config user.email [email protected]
git add .
git commit -m "Update readme with latest version and/or recompile the action."
git push origin HEAD:${{ github.head_ref }}
else
echo "There were no changes to commit"
fi