mirror of
https://github.com/mudler/LocalAI.git
synced 2026-07-30 09:57:57 -04:00
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 4 to 7. - [Release notes](https://github.com/actions/setup-node/releases) - [Commits](https://github.com/actions/setup-node/compare/v4...v7) --- updated-dependencies: - dependency-name: actions/setup-node dependency-version: '7' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
69 lines
2.4 KiB
YAML
69 lines
2.4 KiB
YAML
---
|
|
name: 'lint'
|
|
|
|
on:
|
|
pull_request:
|
|
paths-ignore:
|
|
- 'docs/**'
|
|
- 'examples/**'
|
|
- 'README.md'
|
|
- '**/*.md'
|
|
push:
|
|
branches:
|
|
- master
|
|
|
|
concurrency:
|
|
group: ci-lint-${{ github.event.pull_request.number || github.sha }}-${{ github.repository }}
|
|
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
|
|
|
|
jobs:
|
|
golangci-lint:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v7
|
|
with:
|
|
# Full history so golangci-lint's new-from-merge-base can reach
|
|
# origin/master and compute the diff against it.
|
|
fetch-depth: 0
|
|
- uses: actions/setup-go@v5
|
|
with:
|
|
go-version: '1.26.x'
|
|
cache: false
|
|
- name: install golangci-lint
|
|
run: |
|
|
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh \
|
|
| sh -s -- -b "$(go env GOPATH)/bin" v2.11.4
|
|
- name: generate grpc proto sources
|
|
# pkg/grpc/proto/*.go is generated, not checked in. Several packages
|
|
# import it, so without this step typecheck fails project-wide.
|
|
run: make protogen-go
|
|
- name: stub react-ui dist for go:embed
|
|
# core/http/app.go has //go:embed react-ui/dist/*; the glob needs at
|
|
# least one non-hidden entry to satisfy typecheck. We don't run
|
|
# `make react-ui` here because lint doesn't need the real bundle.
|
|
run: |
|
|
mkdir -p core/http/react-ui/dist
|
|
touch core/http/react-ui/dist/index.html
|
|
- name: lint
|
|
run: make lint
|
|
|
|
build-scripts:
|
|
# The image packaging scripts encode invariants that only surface inside a
|
|
# container build (a missing transitive dep, a partial cuDNN family). Their
|
|
# shell tests need nothing but bash + gcc + ldd, so run them on every PR
|
|
# rather than waiting on a multi-GB cross-arch backend image build.
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v7
|
|
- name: run packaging script tests
|
|
run: make test-build-scripts
|
|
|
|
# The backend matrix path filter fails silently: a miss emits an empty
|
|
# matrix, every job goes green, and the change reaches no image (#10946).
|
|
# Its tests need only node, so they ride along with this job.
|
|
- uses: actions/setup-node@v7
|
|
with:
|
|
node-version: '20'
|
|
- name: run CI script tests
|
|
run: make test-ci-scripts
|