feat: Add assignment instructions to README and implement GitHub Acti… #1
This file contains hidden or 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: GitHub Classroom Workflow | |
| on: | |
| push: | |
| branches: [ main, master ] | |
| pull_request: | |
| branches: [ main, master ] | |
| workflow_dispatch: | |
| jobs: | |
| check-submission: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Check for Screenshots | |
| id: check_files | |
| run: | | |
| echo "Looking for image files..." | |
| # Find all png, jpg, jpeg files, ignoring .git directory | |
| IMAGE_COUNT=$(find . -type f \( -iname "*.png" -o -iname "*.jpg" -o -iname "*.jpeg" \) -not -path '*/.*' | wc -l) | |
| echo "Found $IMAGE_COUNT images." | |
| if [ "$IMAGE_COUNT" -eq 0 ]; then | |
| echo "::error::No screenshots found! Please upload your screenshots (.png or .jpg) to the repository." | |
| exit 1 | |
| else | |
| echo "✅ Found $IMAGE_COUNT screenshots. Assignment check passed!" | |
| fi | |
| - name: Suggestion | |
| if: success() | |
| run: | | |
| echo "Make sure you uploaded:" | |
| echo "1. Terminal output" | |
| echo "2. VirtualBox window" | |
| echo "3. MQTT Explorer" |