diff --git a/.gitignore b/.gitignore index 7b036f3..032265a 100644 --- a/.gitignore +++ b/.gitignore @@ -6,7 +6,6 @@ c/** **.lib **.a host.h -*.ps1 __debug_bin diff --git a/readme.md b/readme.md index 78c2ead..59a54d3 100644 --- a/readme.md +++ b/readme.md @@ -1,4 +1,7 @@ -[![Build Status](https://dev.azure.com/oneeyedelf1/powershell.native/_apis/build/status/KnicKnic.go-powershell?branchName=master)](https://dev.azure.com/oneeyedelf1/powershell.native/_build/latest?definitionId=3&branchName=master) [![Go Report Card](https://goreportcard.com/badge/github.com/KnicKnic/go-powershell)](https://goreportcard.com/report/github.com/KnicKnic/go-powershell) [![GoDoc](https://godoc.org/github.com/KnicKnic/go-powershell/pkg/powershell?status.svg)](https://godoc.org/github.com/KnicKnic/go-powershell/pkg/powershell) +[![Build Status](https://dev.azure.com/oneeyedelf1/powershell.native/_apis/build/status/KnicKnic.go-powershell?branchName=master)](https://dev.azure.com/oneeyedelf1/powershell.native/_build/latest?definitionId=3&branchName=master) +[![Go Report Card](https://goreportcard.com/badge/github.com/KnicKnic/go-powershell)](https://goreportcard.com/report/github.com/KnicKnic/go-powershell) +[![gopherbadger](https://img.shields.io/badge/Go%20Coverage-97%25-brightgreen.svg?longCache=true&style=flat)](./scripts/code_coverage.ps1) +[![GoDoc](https://godoc.org/github.com/KnicKnic/go-powershell/pkg/powershell?status.svg)](https://godoc.org/github.com/KnicKnic/go-powershell/pkg/powershell) # Status It works diff --git a/scripts/code_coverage.ps1 b/scripts/code_coverage.ps1 new file mode 100644 index 0000000..dfbc90e --- /dev/null +++ b/scripts/code_coverage.ps1 @@ -0,0 +1,3 @@ +go test ./... -coverprofile=coverage; go tool cover -func=coverage; del coverage + +#update badge in readme.md with coverage ammount \ No newline at end of file diff --git a/scripts/go_ops.ps1 b/scripts/go_ops.ps1 new file mode 100644 index 0000000..cba6e1a --- /dev/null +++ b/scripts/go_ops.ps1 @@ -0,0 +1,16 @@ +# run fmt vet and lint + +go fmt github.com/KnicKnic/go-powershell/pkg/powershell +go fmt github.com/KnicKnic/go-powershell/pkg/logger +go fmt github.com/KnicKnic/go-powershell/examples/simple +go fmt github.com/KnicKnic/go-powershell/examples/cmd + +go vet github.com/KnicKnic/go-powershell/pkg/powershell +go vet github.com/KnicKnic/go-powershell/pkg/logger +go vet github.com/KnicKnic/go-powershell/examples/simple +go vet github.com/KnicKnic/go-powershell/examples/cmd + +golint github.com/KnicKnic/go-powershell/pkg/powershell +golint github.com/KnicKnic/go-powershell/pkg/logger +golint github.com/KnicKnic/go-powershell/examples/simple +golint github.com/KnicKnic/go-powershell/examples/cmd \ No newline at end of file