Bump golang.org/x/crypto from 0.23.0 to 0.31.0 (#5) #11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: OnMergeRelease | |
on: | |
push: | |
branches: | |
- 'main' | |
- 'release/*' | |
tags: | |
- '**' | |
permissions: read-all | |
jobs: | |
build-test-scan: | |
runs-on: [ ubuntu-20.04 ] | |
env: | |
http_proxy: ${{ secrets.HTTP_PROXY }} | |
https_proxy: ${{ secrets.HTTPS_PROXY }} | |
no_proxy: ${{ secrets.NO_PROXY }} | |
steps: | |
- uses: actions/checkout@ee0669bd1cc54295c223e0bb666b733df41de1c5 # v2.7.0 | |
with: | |
fetch-depth: 0 | |
- name: Setup Go | |
uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0 | |
with: | |
go-version: '1.22' | |
- name: Style Checker | |
run: | | |
if [ "$(make go-fmt | tail -n 1 | grep gofmt | wc -l)" -eq 0 ]; then | |
echo "Code is not formatted properly" | |
exit 1 | |
fi | |
- name: Unit Test Coverage | |
run: | | |
COVERAGE=$(make test-coverage | grep 'total' | awk '{print $3}' | awk -F. '{print $1}') | |
echo "Unit test coverage is - $COVERAGE%" | |
if [[ $COVERAGE -lt 80 ]]; then | |
echo "Unit test coverage must be above 80% " | |
exit 1 | |
fi |