Skip to content

Do not minimize element style by default #287

Do not minimize element style by default

Do not minimize element style by default #287

Workflow file for this run

name: Test
on: [ push, pull_request, workflow_dispatch ]
jobs:
Coverage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
- run: npm install --no-audit && npm install -g uglify-js
- run: npm audit --audit-level=low
- run: npx c8 -r lcovonly -r text --check-coverage --100 npm test
- run: node --import=@litejs/cli/test.js test/load.mjs
- run: npx lj lint
- uses: coverallsapp/github-action@v2
name: Upload to coveralls.io
with:
github-token: ${{ github.token }}
Bun:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- run: bun i
- run: bun x lj t
Test:
strategy:
matrix:
include:
- { node: 8, os: ubuntu-24.04, arch: x86 }
- { node: 10, os: windows-2022, arch: x86 }
- { node: 12, os: macos-13, arch: x64 }
- { node: 16, os: ubuntu-24.04, arch: x64 }
- { node: 22, os: macos-14, arch: arm64 }
runs-on: ${{ matrix.os }}
name: Node ${{matrix.node}} (${{matrix.os}} ${{matrix.arch}})
steps:
- run: git config --global core.autocrlf false
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
architecture: ${{ matrix.arch }}
- run: npm install --no-audit
- run: npm test
Analyze:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: github/codeql-action/init@v3
with:
languages: javascript
- uses: github/codeql-action/analyze@v3
with:
category: /language:javascript
Release:
if: startsWith(github.ref, 'refs/tags/v')
needs: [Analyze, Coverage, Test]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- run: |
echo '${{ vars.RELEASE_SIGNERS }}' > ./allowed_signers
git config gpg.ssh.allowedSignersFile ./allowed_signers
git verify-tag -v ${{ github.ref_name }}
name: Verify release tag signature
- uses: actions/setup-node@v4
with:
registry-url: https://registry.npmjs.org/
- run: |
MSG=$(git log -1 --no-show-signature --format=%B $TAG)
TITLE=$(echo "$MSG" | head -n 1)
NOTES=$(echo "$MSG" | tail -n +2)
gh release create $TAG --title "$TITLE" --notes "$NOTES"
gh run list --json databaseId -q '.[20:]|.[].databaseId' --limit 100 | xargs -I{} gh run delete "{}"
[[ "$TAG" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]] && echo "PUBLISH=latest" >> $GITHUB_ENV || echo "PUBLISH=next" >> $GITHUB_ENV
env:
GH_TOKEN: ${{ github.token }}
TAG: ${{ github.ref_name }}
- run: npm publish --access public --tag $PUBLISH
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}