mirror of
https://github.com/semgrep/skills.git
synced 2026-09-20 14:21:26 +08:00
547899e7bc
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 6 to 6.3.0. - [Release notes](https://github.com/actions/setup-node/releases) - [Commits](https://github.com/actions/setup-node/compare/v6...v6.3.0) --- updated-dependencies: - dependency-name: actions/setup-node dependency-version: 6.3.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
62 lines
1.4 KiB
YAML
62 lines
1.4 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
validate-and-build:
|
|
name: Validate & Build
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Setup pnpm
|
|
uses: pnpm/action-setup@v4
|
|
with:
|
|
version: 10
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v6.3.0
|
|
with:
|
|
node-version: '20'
|
|
cache: 'pnpm'
|
|
cache-dependency-path: packages/skill-build/pnpm-lock.yaml
|
|
|
|
- name: Install dependencies
|
|
run: make install
|
|
|
|
- name: Validate skills
|
|
run: make validate
|
|
|
|
- name: Build skills
|
|
run: make build
|
|
|
|
- name: Check for uncommitted changes
|
|
run: |
|
|
if [ -n "$(git status --porcelain)" ]; then
|
|
echo "::error::Generated files are out of sync. Please run 'make' locally and commit the changes."
|
|
echo ""
|
|
echo "Changed files:"
|
|
git status --porcelain
|
|
echo ""
|
|
echo "Diff:"
|
|
git diff
|
|
exit 1
|
|
fi
|
|
echo "All generated files are up to date."
|
|
|
|
- name: Create zip packages
|
|
run: make zip
|
|
|
|
- name: Upload skill packages
|
|
uses: actions/upload-artifact@v7
|
|
with:
|
|
name: skill-packages
|
|
path: skills/*.zip
|
|
retention-days: 7
|