From 66a4924a2a106ce4a1336f7b4316e325a3184a92 Mon Sep 17 00:00:00 2001 From: Claude Code Date: Mon, 7 Jul 2025 21:46:02 -0400 Subject: [PATCH 1/5] Fix CI test job naming to distinguish Node.js versions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add Node.js version to test job name to clearly show which version is running - Changes "Run Tests" to "Run Tests (Node 18)" and "Run Tests (Node 20)" - Keeps matrix strategy for cross-version compatibility testing 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- .forgejo/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml index 7507cfa..379d740 100644 --- a/.forgejo/workflows/ci.yml +++ b/.forgejo/workflows/ci.yml @@ -51,7 +51,7 @@ jobs: test: runs-on: self-hosted - name: Run Tests + name: Run Tests (Node ${{ matrix.node-version }}) strategy: matrix: From a4e0c0a528740e3c531a88d13faf80def1d497d7 Mon Sep 17 00:00:00 2001 From: Claude Code Date: Mon, 7 Jul 2025 21:48:52 -0400 Subject: [PATCH 2/5] Remove non-functional PR labeler workflow MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - PR labeler can't actually apply labels on Forgejo, only suggests them - Removes unnecessary workflow that just creates noise without functionality - Simplifies CI pipeline by removing unused automation 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- .forgejo/workflows/pr-labeler.yml | 110 ------------------------------ 1 file changed, 110 deletions(-) delete mode 100644 .forgejo/workflows/pr-labeler.yml diff --git a/.forgejo/workflows/pr-labeler.yml b/.forgejo/workflows/pr-labeler.yml deleted file mode 100644 index dc3fbf2..0000000 --- a/.forgejo/workflows/pr-labeler.yml +++ /dev/null @@ -1,110 +0,0 @@ -name: PR Labeler - -on: - pull_request: - types: [opened, edited, synchronize] - -jobs: - label: - runs-on: self-hosted - name: Label Pull Request - - steps: - - name: Checkout code - uses: https://code.forgejo.org/actions/checkout@v4 - - - name: Analyze and label PR - run: | - echo "Analyzing PR for automatic labeling..." - - # Get changed files - git fetch origin main - # Try different approaches to get the diff - if git merge-base origin/main HEAD >/dev/null 2>&1; then - CHANGED_FILES=$(git diff --name-only origin/main...HEAD) - else - # Fallback: compare with origin/main directly - CHANGED_FILES=$(git diff --name-only origin/main HEAD || echo "") - fi - - if [ -z "$CHANGED_FILES" ]; then - echo "Unable to determine changed files, using all files in current branch" - CHANGED_FILES=$(find . -name "*.ts" -o -name "*.js" -o -name "*.scss" -o -name "*.json" | grep -v node_modules | head -20) - fi - - # Initialize labels array - LABELS="" - - # Check file types and paths - if echo "$CHANGED_FILES" | grep -q "^src/.*\.ts$"; then - LABELS="$LABELS,backend" - fi - - if echo "$CHANGED_FILES" | grep -q "^src/frontend/.*\.ts$"; then - LABELS="$LABELS,frontend" - fi - - if echo "$CHANGED_FILES" | grep -q "^public/.*\.\(js\|html\)$"; then - LABELS="$LABELS,frontend" - fi - - if echo "$CHANGED_FILES" | grep -q "^src/scss/.*\.scss$"; then - LABELS="$LABELS,styles" - fi - - if echo "$CHANGED_FILES" | grep -q "^tests/.*\.test\.ts$"; then - LABELS="$LABELS,tests" - fi - - if echo "$CHANGED_FILES" | grep -q "^\.forgejo/workflows/"; then - LABELS="$LABELS,ci/cd" - fi - - if echo "$CHANGED_FILES" | grep -q "package.*\.json$"; then - LABELS="$LABELS,dependencies" - fi - - if echo "$CHANGED_FILES" | grep -q "^docs/\|README\.md\|CLAUDE\.md"; then - LABELS="$LABELS,documentation" - fi - - if echo "$CHANGED_FILES" | grep -q "^src/i18n/"; then - LABELS="$LABELS,i18n" - fi - - if echo "$CHANGED_FILES" | grep -q "^scripts/"; then - LABELS="$LABELS,tooling" - fi - - # Check PR title/body for keywords - PR_TITLE="${{ github.event.pull_request.title }}" - PR_BODY="${{ github.event.pull_request.body }}" - - if echo "$PR_TITLE $PR_BODY" | grep -qi "security\|vulnerability\|CVE"; then - LABELS="$LABELS,security" - fi - - if echo "$PR_TITLE $PR_BODY" | grep -qi "performance\|optimize\|speed"; then - LABELS="$LABELS,performance" - fi - - if echo "$PR_TITLE $PR_BODY" | grep -qi "bug\|fix\|issue"; then - LABELS="$LABELS,bug" - fi - - if echo "$PR_TITLE $PR_BODY" | grep -qi "feature\|enhancement\|add"; then - LABELS="$LABELS,enhancement" - fi - - if echo "$PR_TITLE $PR_BODY" | grep -qi "breaking change\|BREAKING"; then - LABELS="$LABELS,breaking-change" - fi - - # Remove leading comma and duplicates - LABELS=$(echo "$LABELS" | sed 's/^,//' | tr ',' '\n' | sort -u | tr '\n' ',' | sed 's/,$//') - - echo "Suggested labels: $LABELS" - - # Note: In actual Forgejo/Gitea, you would use the API to apply labels - # This is just for demonstration - echo "To apply labels, use: tea pr edit ${{ github.event.pull_request.number }} --add-label \"$LABELS\"" \ No newline at end of file From 7624faaedbb6a3b75adf29c8253c27c869ba13c2 Mon Sep 17 00:00:00 2001 From: Claude Code Date: Mon, 7 Jul 2025 21:49:47 -0400 Subject: [PATCH 3/5] Add automatic release tagging workflow MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Creates date-based version tags (v2025.01.08) on push to main - Handles multiple releases per day with patch numbers (v2025.01.08.1, v2025.01.08.2) - Runs tests and build before tagging to ensure quality - Generates release notes with changelog since last tag - Includes installation instructions in release notes - Uses Forgejo-compatible actions and git configuration 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- .forgejo/workflows/auto-tag.yml | 121 ++++++++++++++++++++++++++++++++ 1 file changed, 121 insertions(+) create mode 100644 .forgejo/workflows/auto-tag.yml diff --git a/.forgejo/workflows/auto-tag.yml b/.forgejo/workflows/auto-tag.yml new file mode 100644 index 0000000..c8173f9 --- /dev/null +++ b/.forgejo/workflows/auto-tag.yml @@ -0,0 +1,121 @@ +name: Auto Tag Release + +on: + push: + branches: [ main ] + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + auto-tag: + runs-on: self-hosted + name: Create Auto Tag + + steps: + - name: Checkout code + uses: https://code.forgejo.org/actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Setup Node.js + run: | + node --version + npm --version + + - name: Install dependencies + run: npm ci + + - name: Run tests + run: npm test + + - name: Build project + run: npm run build + + - name: Generate version tag + id: version + run: | + # Get the current date in YYYY.MM.DD format + DATE_VERSION=$(date +%Y.%m.%d) + + # Check if a tag with today's date already exists + if git tag -l | grep -q "^v${DATE_VERSION}$"; then + # If it exists, add a patch number + PATCH_NUM=$(git tag -l "v${DATE_VERSION}.*" | wc -l) + PATCH_NUM=$((PATCH_NUM + 1)) + VERSION="v${DATE_VERSION}.${PATCH_NUM}" + else + VERSION="v${DATE_VERSION}" + fi + + echo "Generated version: $VERSION" + echo "version=$VERSION" >> $GITHUB_OUTPUT + + - name: Create and push tag + run: | + VERSION="${{ steps.version.outputs.version }}" + + # Configure git + git config --local user.email "action@forgejo.org" + git config --local user.name "Forgejo Action" + + # Create annotated tag with commit info + COMMIT_MSG=$(git log -1 --pretty=%B) + git tag -a "$VERSION" -m "Release $VERSION + + Latest changes: + $COMMIT_MSG + + Auto-generated on $(date)" + + # Push the tag + git push origin "$VERSION" + + echo "✅ Created and pushed tag: $VERSION" + + - name: Create release notes + run: | + VERSION="${{ steps.version.outputs.version }}" + + # Get the previous tag to generate changelog + PREV_TAG=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || echo "") + + echo "# Release $VERSION" > RELEASE_NOTES.md + echo "" >> RELEASE_NOTES.md + echo "**Release Date:** $(date '+%Y-%m-%d %H:%M:%S UTC')" >> RELEASE_NOTES.md + echo "**Commit:** ${{ github.sha }}" >> RELEASE_NOTES.md + echo "" >> RELEASE_NOTES.md + + if [ -n "$PREV_TAG" ]; then + echo "## Changes since $PREV_TAG" >> RELEASE_NOTES.md + echo "" >> RELEASE_NOTES.md + + # Get commits since last tag + git log $PREV_TAG..HEAD --pretty=format:"- %s" >> RELEASE_NOTES.md + else + echo "## Latest Changes" >> RELEASE_NOTES.md + echo "" >> RELEASE_NOTES.md + git log -5 --pretty=format:"- %s" >> RELEASE_NOTES.md + fi + + echo "" >> RELEASE_NOTES.md + echo "" >> RELEASE_NOTES.md + echo "## Installation" >> RELEASE_NOTES.md + echo "" >> RELEASE_NOTES.md + echo '```bash' >> RELEASE_NOTES.md + echo "# Clone the repository" >> RELEASE_NOTES.md + echo "git clone https://git.deco.sh/deco/ice.git" >> RELEASE_NOTES.md + echo "cd ice" >> RELEASE_NOTES.md + echo "" >> RELEASE_NOTES.md + echo "# Checkout this release" >> RELEASE_NOTES.md + echo "git checkout $VERSION" >> RELEASE_NOTES.md + echo "" >> RELEASE_NOTES.md + echo "# Install and build" >> RELEASE_NOTES.md + echo "npm install" >> RELEASE_NOTES.md + echo "npm run build" >> RELEASE_NOTES.md + echo "npm start" >> RELEASE_NOTES.md + echo '```' >> RELEASE_NOTES.md + + echo "Release notes created:" + cat RELEASE_NOTES.md \ No newline at end of file From 3b48e804daf5e5f5868ef145699b7b11c88bed89 Mon Sep 17 00:00:00 2001 From: Claude Code Date: Mon, 7 Jul 2025 21:58:21 -0400 Subject: [PATCH 4/5] Add .zip extension to coverage report artifact name MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This makes the artifact more recognizable in the Forgejo UI as a downloadable zip file. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- .forgejo/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml index 379d740..87291a0 100644 --- a/.forgejo/workflows/ci.yml +++ b/.forgejo/workflows/ci.yml @@ -94,7 +94,7 @@ jobs: - name: Upload coverage reports uses: https://code.forgejo.org/forgejo/upload-artifact@v4 with: - name: coverage-report + name: coverage-report.zip path: coverage/ build: From c7a2bb6848597999dabe9d21181b4cbd4d13518d Mon Sep 17 00:00:00 2001 From: Claude Code Date: Mon, 7 Jul 2025 22:21:11 -0400 Subject: [PATCH 5/5] Fix language selector disappearing on navigation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Remove missing theme-utils.js references from all HTML files - Fix double initialization in i18n.js causing language selector conflicts - Update service worker cache version to force fresh file loading - Language selector now persists when navigating via snowflake icon 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- public/admin.html | 1 - public/i18n.js | 1 - public/index.html | 2 -- public/privacy.html | 1 - public/sw.js | 2 +- 5 files changed, 1 insertion(+), 6 deletions(-) diff --git a/public/admin.html b/public/admin.html index c281bfd..41a6400 100644 --- a/public/admin.html +++ b/public/admin.html @@ -188,7 +188,6 @@ - diff --git a/public/i18n.js b/public/i18n.js index cb8f552..378a410 100644 --- a/public/i18n.js +++ b/public/i18n.js @@ -9,7 +9,6 @@ class I18nService { this.defaultLocale = 'en'; this.availableLocales = ['en', 'es-MX']; this.currentLocale = this.getStoredLocale() || this.detectBrowserLocale(); - this.loadTranslations(); } /** diff --git a/public/index.html b/public/index.html index 20bc4f0..813cc74 100644 --- a/public/index.html +++ b/public/index.html @@ -173,8 +173,6 @@ placeholder="Enter address, intersection (e.g., Main St & Second St, City), or l - - diff --git a/public/privacy.html b/public/privacy.html index 39544c3..b46ee36 100644 --- a/public/privacy.html +++ b/public/privacy.html @@ -139,7 +139,6 @@ -