Skip to content

Create troubleshooting-structure-adjustment.js #115

Create troubleshooting-structure-adjustment.js

Create troubleshooting-structure-adjustment.js #115

Workflow file for this run

name: Update MDX Images
on:
pull_request:
branches:
- main
jobs:
update:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Get changed files
id: changed_files
uses: tj-actions/[email protected]
with:
separator: ","
- name: Update MDX files
run: |
[ ! -d ./images/ ] && mkdir images
cd ./docs-utils/
npm install front-matter image-downloader
cd ..
IFS=',' read -a filepaths <<< "${{ steps.changed_files.outputs.all_changed_files }}"
for filepath in "${filepaths[@]}"; do
if [[ $filepath == *.md ]] || [[ $filepath == *.mdx ]]; then
node ./docs-utils/update-images.js "./$filepath"
fi
done
- name: Commit and Push
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: update images in MDX files