mirror of
https://github.com/project-zot/zot.git
synced 2026-06-17 12:58:02 +08:00
fix: reduce test run time (#1832)
Signed-off-by: Alexei Dodon <adodon@cisco.com>
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
name: "Lines of code statistics"
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
release:
|
||||
types:
|
||||
- published
|
||||
|
||||
permissions: read-all
|
||||
|
||||
jobs:
|
||||
loc:
|
||||
name: Lines of code
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Install go
|
||||
uses: actions/setup-go@v4
|
||||
with:
|
||||
cache: false
|
||||
go-version: 1.20.x
|
||||
- name: Check out source code
|
||||
uses: actions/checkout@v4
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE
|
||||
go install github.com/hhatto/gocloc/cmd/gocloc@latest
|
||||
- name: All sources
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE
|
||||
gocloc .
|
||||
- name: All sources (except tests)
|
||||
run: |
|
||||
cd $GITHUB_WORKSPACE
|
||||
gocloc --not-match='.*_test.go' .
|
||||
Reference in New Issue
Block a user