-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
77 additions
and
87 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: CI | ||
on: [push, workflow_dispatch] | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
container: golang:1.17 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- run: go test -mod=readonly -race -v ./... | ||
|
||
verify: | ||
if: github.ref_type == 'branch' && github.ref_name != 'master' | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- run: ./verify.sh | ||
|
||
build: | ||
runs-on: ubuntu-latest | ||
container: golang:1.17 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- run: go build -a -mod=readonly -o /dev/null ./... | ||
|
||
lint: | ||
runs-on: ubuntu-latest | ||
container: golang:1.17 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- uses: golangci/golangci-lint-action@v2 | ||
with: | ||
version: v1.44.2 | ||
args: -c .golangci.yml |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,8 @@ | ||
# Release Notes | ||
|
||
## v1.1.0 / 2022-03-08 | ||
- sync with gitlab | ||
|
||
## v1.0.1 / 2020-11-23 | ||
- migrated to GitHub | ||
|
||
|
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
Shallow-go | ||
============================== | ||
[![Go Reference](https://pkg.go.dev/badge/github.com/proemergotech/shallow.svg)](https://pkg.go.dev/github.com/proemergotech/shallow) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
module github.com/proemergotech/shallow | ||
|
||
go 1.15 | ||
go 1.17 | ||
|
||
require ( | ||
github.com/kr/pretty v0.1.0 | ||
github.com/pkg/errors v0.8.1 | ||
github.com/proemergotech/errors/v2 v2.0.0 | ||
) | ||
|
||
require github.com/kr/text v0.1.0 // indirect |
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
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,20 @@ | ||
#!/bin/sh | ||
# Check for CHANGELOG updates and fails when not found | ||
|
||
changelog_filename="CHANGELOG.md" | ||
|
||
git fetch --depth 1 origin master | ||
|
||
if ! git diff --name-only origin/master | grep -E '.*\.go|go.mod|go.sum' | ||
then | ||
echo "Go code change not found." | ||
exit 0 | ||
fi | ||
|
||
if [ -f ${changelog_filename} ] | ||
then | ||
if [ "$(git diff --name-only origin/master -- ${changelog_filename} | grep -cw ${changelog_filename})" -ne 1 ] | ||
then | ||
echo "Changelog should be updated!" | ||
exit 1 | ||
fi | ||
fi | ||
fi |