Skip to content

Commit 04ca241

Browse files
authored
Refactor: resize images to speed up loading (#42)
* add resize.py * resize images * .py in gitignore * feat: rename people consistently * fixes * fix names
1 parent a40afd3 commit 04ca241

File tree

206 files changed

+108
-47
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

206 files changed

+108
-47
lines changed
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
name: Check Team Image Names
2+
3+
on:
4+
push:
5+
paths:
6+
- 'assets/img/team/**'
7+
pull_request:
8+
paths:
9+
- 'assets/img/team/**'
10+
11+
jobs:
12+
check-image-names:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v4
17+
18+
- name: Check team image naming convention
19+
run: |
20+
#!/bin/bash
21+
set -e
22+
23+
TEAM_DIR="assets/img/team"
24+
ERRORS=0
25+
26+
echo "Checking image naming convention in $TEAM_DIR..."
27+
echo "Expected format: firstname_lastname.jpg (or .jpeg, .png)"
28+
echo ""
29+
30+
# Pattern: one or more lowercase letters, underscore, one or more lowercase letters,
31+
# optionally more _name segments, then .jpg
32+
VALID_PATTERN="^[a-z]+(_[a-z]+)+\.(jpg)$"
33+
34+
for file in "$TEAM_DIR"/*; do
35+
if [ -f "$file" ]; then
36+
filename=$(basename "$file")
37+
38+
if [[ ! "$filename" =~ $VALID_PATTERN ]]; then
39+
echo "❌ Invalid: $filename"
40+
echo " Expected format: firstname_lastname.jpg (lowercase, underscores only)"
41+
ERRORS=$((ERRORS + 1))
42+
else
43+
echo "✅ Valid: $filename"
44+
fi
45+
fi
46+
done
47+
48+
echo ""
49+
if [ $ERRORS -gt 0 ]; then
50+
echo "Found $ERRORS file(s) with invalid naming."
51+
echo ""
52+
echo "Naming convention rules:"
53+
echo " - Use lowercase letters only"
54+
echo " - Separate first and last name with underscore (_)"
55+
echo " - No hyphens, spaces, or special characters"
56+
echo " - Allowed extensions: .jpg"
57+
echo " - Example: john_doe.jpg"
58+
exit 1
59+
else
60+
echo "All team images follow the naming convention! 🎉"
61+
fi

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@
22
.DS_Store
33
./_site
44
_site/
5+
*.py

_events/8.md

Lines changed: 3 additions & 3 deletions

_hackathons/startup-competition.md

Lines changed: 2 additions & 2 deletions

_projects/2024-01-19.md

Lines changed: 2 additions & 2 deletions

_projects/2024-01-28.md

Lines changed: 2 additions & 2 deletions

_projects/2024-02-19.md

Lines changed: 2 additions & 2 deletions

_projects/2024-03-03.md

Lines changed: 1 addition & 1 deletion

_projects/2025-02-23.md

Lines changed: 3 additions & 3 deletions

_projects/2025-03-02.md

Lines changed: 4 additions & 4 deletions

0 commit comments

Comments
 (0)