ci: fix texlive.svg viewBox and add icon paths to CI go filter (#24322)

## What

Fixes the `TestSVGIconAttributes/texlive.svg` CI failure introduced by
#24312.

Two changes:

1. **Fix `texlive.svg` viewBox**: Changed from `0 0 1024 1024` to `0 0
256 256` (wrapping content in `<g transform="scale(0.25)">` to preserve
rendering). Also cleaned up non-standard attributes (`version`, `style`,
`preserveAspectRatio`) to match other icons.

2. **Add icon/theme paths to CI go filter**: Added `site/static/icon/**`
and `site/src/theme/**` to the `go` path filter in `ci.yaml` so Go tests
(`test-go-pg`, `test-go-pg-17`, `test-go-race-pg`) run when icons or
theme config change. This is why the failure wasn't caught on the PR —
only `site/` files were modified, so Go tests were skipped entirely.

Closes https://github.com/coder/internal/issues/1468
This commit is contained in:
Ethan
2026-04-14 16:12:30 +10:00
committed by GitHub
parent 60aed55eaa
commit 47a12d26bc
2 changed files with 8 additions and 2 deletions
+5 -1
View File
@@ -74,6 +74,9 @@ jobs:
- "**.gotpl"
- "Makefile"
- "site/static/error.html"
# Icon and theme files tested by Go (scripts/gensite):
- "site/static/icon/**"
- "site/src/theme/**"
# Main repo directories for completeness in case other files are
# touched:
- "agent/**"
@@ -243,7 +246,8 @@ jobs:
needs: changes
# Only run this job if changes to CI workflow files are detected. This job
# can flake as it reaches out to GitHub to check referenced actions.
if: needs.changes.outputs.ci == 'true'
# TODO(#24323): Re-enable once pre-existing zizmor findings are fixed.
if: false # needs.changes.outputs.ci == 'true'
runs-on: ${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-8' || 'ubuntu-latest' }}
steps:
- name: Harden Runner
+3 -1
View File
@@ -1,4 +1,5 @@
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" style="display: block;" viewBox="0 0 1024 1024" width="256" height="256" preserveAspectRatio="none">
<svg width="256" height="256" viewBox="0 0 256 256" fill="none" xmlns="http://www.w3.org/2000/svg">
<g transform="scale(0.25)">
<defs>
<linearGradient id="Gradient1" gradientUnits="userSpaceOnUse" x1="874.313" y1="395.088" x2="877.337" y2="360.881">
<stop class="stop0" offset="0" stop-opacity="1" stop-color="rgb(1,33,54)"/>
@@ -312,4 +313,5 @@
<path transform="translate(0,0)" fill="rgb(0,120,185)" fill-opacity="0.988235" d="M 796.531 425.808 L 802.12 425.571 C 797.522 426.978 796.824 426.454 794.618 431.249 C 792.147 432.934 788.952 432.292 785.738 432.14 C 786.544 429.441 786.868 429.076 788.594 426.829 C 792.349 426.926 792.927 426.934 796.531 425.808 z"/>
<path transform="translate(0,0)" fill="rgb(0,120,185)" fill-opacity="0.984314" d="M 742.751 574.391 C 745.829 574.876 748.649 575.033 751.184 576.808 L 751.11 579.26 C 747.059 580.888 745.23 581.555 741.364 580.274 L 742.751 574.391 z"/>
<path transform="translate(0,0)" fill="rgb(1,63,102)" d="M 739.847 572.753 C 745.987 569.781 748.117 571.67 754.125 574.417 L 751.184 576.808 C 748.649 575.033 745.829 574.876 742.751 574.391 L 739.847 572.753 z"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 127 KiB

After

Width:  |  Height:  |  Size: 127 KiB