Skip to content

use caching in github actions workflows #3

use caching in github actions workflows

use caching in github actions workflows #3

Workflow file for this run

name: Test
on:
pull_request:
branches:
- main
paths-ignore:
- "docs/**"
- "**.md"
- "sec-scanners-config.yaml"
push:
branches:
- main
paths-ignore:
- "docs/**"
- "**.md"
- "sec-scanners-config.yaml"
permissions:
contents: read
# Optional: allow read access to pull request. Use with `only-new-issues` option.
pull-requests: read
jobs:
unit-test:
name: Unit Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Cache Go dependencies
uses: actions/setup-go@v5
with:
go-version-file: "./go.mod"
- name: Cache Binaries
id: cache-binaries
uses: actions/cache@v3
with:
path: bin
key: ${{ runner.os }}-bin
- name: Execute unit test
run: make test