Skip to content

Commit

Permalink
Update update-readme.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
cudeso authored Dec 2, 2024
1 parent dbcaa19 commit 1750d6f
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions .github/workflows/update-readme.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,22 +21,24 @@ jobs:
git config user.email "[email protected]"
git pull --rebase origin main
- name: Clean up untracked files
run: |
git clean -fd
git pull origin main
- name: Debug README content
run: cat README.md

- name: Update README references
run: |
README_FILE="README.md"
if [ -f "$README_FILE" ]; then
sed -i 's|\(misp-playbooks/.*\)\.ipynb|\1.html|g' "$README_FILE"
sed -i 's|\(misp-playbooks/[^ )]*\)\.ipynb|\1.html|g' "$README_FILE"
fi
- name: Stage and commit changes
run: |
git add README.md
git commit -m "Update README links to HTML files"
git push
if git diff --cached --quiet; then
echo "No changes to commit."
else
git commit -m "Update README links to HTML files"
git push
fi
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 1750d6f

Please sign in to comment.