diff --git a/.github/workflows/make_html_from_notebook.yml b/.github/workflows/make_html_from_notebook.yml
index 7a319b9..9748781 100644
--- a/.github/workflows/make_html_from_notebook.yml
+++ b/.github/workflows/make_html_from_notebook.yml
@@ -6,7 +6,9 @@ on:
# Trigger on PRs that change the notebooks in some way
pull_request:
branches: [main]
- paths: "**.ipynb"
+ paths:
+ - "**.ipynb"
+ - "**.html"
#pull_request_review:
#types: [submitted]
jobs:
@@ -36,6 +38,15 @@ jobs:
for changed_file in ${{ steps.changes.outputs.added_modified }}; do
if [[ "$changed_file" == *".ipynb" ]]; then
notebooks+=("$changed_file")
+ elif [[ "$changed_file" == *".html" ]]; then
+ striped="${changed_file%.*}.ipynb"
+ notebooks+=("$striped")
+ fi
+ done
+ for changed_file in ${{ steps.changes.outputs.removed }}; do
+ if [[ "$changed_file" == *".html" ]]; then
+ striped="${changed_file%.*}.ipynb"
+ notebooks+=("$striped")
fi
done
echo "Changed files: ${notebooks[@]}"
@@ -47,4 +58,4 @@ jobs:
git config user.email github-actions@github.com
git add -A
git commit -m "Automated commit for HTML files" || exit 0
- git push
+ git push
\ No newline at end of file