Skip to content

Commit

Permalink
chore: add workflow validation to fix windows colon errors
Browse files Browse the repository at this point in the history
  • Loading branch information
GangGreenTemperTatum committed Dec 27, 2024
1 parent e8b9776 commit 353d4e7
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/check-filenames-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Check Filenames on PR

on:
pull_request:
types: [opened, synchronize, reopened]

jobs:
check-filenames:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Check for invalid filenames
run: |
invalid_files=$(git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }} | grep ":" || true)
if [ ! -z "$invalid_files" ]; then
echo "Error: The following files contain ':' in their names, which is not compatible with Windows:"
echo "$invalid_files"
exit 1
fi

0 comments on commit 353d4e7

Please sign in to comment.