fix: soften SM Lab color signal anchors #76
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: CI | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| - feature/** | |
| jobs: | |
| js-build: | |
| name: JS Build (Node 22) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Node 22 | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Compile production assets | |
| run: npm run compile:production | |
| - name: List gulp tasks | |
| run: npm run gulp -- --tasks-simple | |
| php-checks: | |
| name: PHP Checks (PHP ${{ matrix.php }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| php: ["8.1", "8.2"] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: ${{ matrix.php }} | |
| tools: composer:v2 | |
| coverage: none | |
| - name: Validate composer.json | |
| run: composer validate --strict | |
| - name: Install composer dependencies (no scripts) | |
| run: composer install --no-interaction --prefer-dist --no-scripts | |
| - name: Build optimized autoloader (no-dev) | |
| run: composer dump-autoload --no-dev --optimize | |
| zip-build: | |
| name: Zip Build Artifact | |
| runs-on: ubuntu-latest | |
| needs: | |
| - js-build | |
| - php-checks | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Node 22 | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: npm | |
| - name: Setup PHP 8.2 | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: "8.2" | |
| tools: composer:v2 | |
| coverage: none | |
| - name: Install rsync | |
| run: sudo apt-get update && sudo apt-get install -y rsync | |
| - name: Install WP-CLI | |
| run: | | |
| curl -fsSL -o wp-cli.phar https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar | |
| php wp-cli.phar --info | |
| chmod +x wp-cli.phar | |
| sudo mv wp-cli.phar /usr/local/bin/wp | |
| wp --info | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Build release zip | |
| run: npm run zip | |
| - name: Verify production autoload integrity | |
| run: node ./node-tasks/verify_release_autoload.js | |
| - name: Validate zip contents | |
| run: | | |
| ZIP_PATH="$(ls -1 ../style-manager-*.zip | head -n 1)" | |
| unzip -l "$ZIP_PATH" > /tmp/style-manager-zip-list.txt | |
| if grep -Eq 'vendor/(phpstan|rector|brain|mockery|phpunit|symfony|psr|pimple|cedaro|nikic|phpcsstandards)/' /tmp/style-manager-zip-list.txt; then | |
| echo "Zip contains stripped/dev vendor references." | |
| exit 1 | |
| fi | |
| if grep -Eq 'dist/js/[0-9]+\.js' /tmp/style-manager-zip-list.txt; then | |
| echo "Zip contains numeric chunk names in dist/js. Expected deterministic chunk naming." | |
| exit 1 | |
| fi | |
| if ! grep -Eq 'dist/js/customizer-worker\.js' /tmp/style-manager-zip-list.txt; then | |
| echo "Expected dist/js/customizer-worker.js in zip output." | |
| exit 1 | |
| fi | |
| if grep -Eq '(\.csslintrc|\.eslintrc|plans/)' /tmp/style-manager-zip-list.txt; then | |
| echo "Zip contains development-only root files or plans." | |
| exit 1 | |
| fi | |
| - name: Stage zip artifact | |
| run: | | |
| ZIP_PATH="$(ls -1 ../style-manager-*.zip | head -n 1)" | |
| cp "$ZIP_PATH" "./$(basename "$ZIP_PATH")" | |
| - name: Upload zip artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: style-manager-zip | |
| path: style-manager-*.zip | |
| if-no-files-found: error |