Merge pull request #227 from andrewrreed/main #177
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Check notebook names are lowercase | |
on: [push] | |
jobs: | |
check-lowercase: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Check filenames in 'notebooks/' | |
run: | | |
# Change to the directory where you want to check filenames | |
cd notebooks | |
# Find files with uppercase characters in their names | |
files=$(find . -type f -name '*.ipynb' -exec basename {} \;| grep '[A-Z]' || true) | |
if [ -n "$files" ]; then | |
echo "The following files are not lowercase:" | |
echo "$files" | |
exit 1 | |
else | |
echo "All filenames are lowercase." | |
fi |