mirror of
https://github.com/juanfont/headscale.git
synced 2024-11-30 02:43:05 +00:00
Update lint ci file with prettier and proto
This commit is contained in:
parent
6b3114ad6f
commit
edfcdc466c
1 changed files with 27 additions and 11 deletions
38
.github/workflows/lint.yml
vendored
38
.github/workflows/lint.yml
vendored
|
@ -1,20 +1,36 @@
|
||||||
|
---
|
||||||
name: CI
|
name: CI
|
||||||
|
|
||||||
on: [push, pull_request]
|
on: [push, pull_request]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
# The "build" workflow
|
golangci-lint:
|
||||||
lint:
|
|
||||||
# The type of runner that the job will run on
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
# Steps represent a sequence of tasks that will be executed as part of the job
|
|
||||||
steps:
|
steps:
|
||||||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
# Install and run golangci-lint as a separate step, it's much faster this
|
- name: golangci-lint
|
||||||
# way because this action has caching. It'll get run again in `make lint`
|
uses: golangci/golangci-lint-action@v2
|
||||||
# below, but it's still much faster in the end than installing
|
with:
|
||||||
# golangci-lint manually in the `Run lint` step.
|
version: latest
|
||||||
- uses: golangci/golangci-lint-action@v2
|
args: --timeout 30m
|
||||||
|
|
||||||
|
prettier-lint:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Prettify code
|
||||||
|
uses: creyD/prettier_action@v4.0
|
||||||
|
with:
|
||||||
|
prettier_options: >-
|
||||||
|
--check **/*.{ts,js,md,yaml,yml,sass,css,scss,html}
|
||||||
|
only_changed: false
|
||||||
|
dry: true
|
||||||
|
|
||||||
|
proto-lint:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- uses: bufbuild/buf-setup-action@v0.5.0
|
||||||
|
- uses: bufbuild/buf-lint-action@v1
|
||||||
|
|
Loading…
Reference in a new issue