mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2024-12-03 07:06:30 +00:00
Merge pull request #797 from mattbostock/go_fmt
Run gofmt and add test to prevent regressions
This commit is contained in:
commit
ae65cf5fdb
9 changed files with 84 additions and 83 deletions
1
Makefile
1
Makefile
|
@ -8,6 +8,7 @@ deps:
|
||||||
go get -t -v ./...
|
go get -t -v ./...
|
||||||
|
|
||||||
test:
|
test:
|
||||||
|
@test -z "$(shell find . -name '*.go' | xargs gofmt -l)" || (echo "Need to run 'go fmt ./...'"; exit 1)
|
||||||
go vet ./...
|
go vet ./...
|
||||||
go test -cover -short ./...
|
go test -cover -short ./...
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,7 @@ func restartCommandFunc(c *cli.Context, client *client.Client) error {
|
||||||
case 2:
|
case 2:
|
||||||
branch = "master"
|
branch = "master"
|
||||||
sha = args[1]
|
sha = args[1]
|
||||||
case 3,4,5:
|
case 3, 4, 5:
|
||||||
branch = args[1]
|
branch = args[1]
|
||||||
sha = args[2]
|
sha = args[2]
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,7 +35,7 @@ func (h *Deis) Write(f *buildfile.Buildfile) {
|
||||||
|
|
||||||
// git@deis.yourdomain.com:2222/drone.git
|
// git@deis.yourdomain.com:2222/drone.git
|
||||||
|
|
||||||
f.WriteCmd(fmt.Sprintf("git remote add deis ssh://git@%s%s.git", h.Deisurl , h.App))
|
f.WriteCmd(fmt.Sprintf("git remote add deis ssh://git@%s%s.git", h.Deisurl, h.App))
|
||||||
|
|
||||||
switch h.Force {
|
switch h.Force {
|
||||||
case true:
|
case true:
|
||||||
|
|
|
@ -5,9 +5,9 @@ import (
|
||||||
"github.com/drone/drone/shared/build/buildfile"
|
"github.com/drone/drone/shared/build/buildfile"
|
||||||
"github.com/drone/drone/shared/build/repo"
|
"github.com/drone/drone/shared/build/repo"
|
||||||
|
|
||||||
|
"github.com/drone/drone/plugin/deploy/deis"
|
||||||
"github.com/drone/drone/plugin/deploy/git"
|
"github.com/drone/drone/plugin/deploy/git"
|
||||||
"github.com/drone/drone/plugin/deploy/heroku"
|
"github.com/drone/drone/plugin/deploy/heroku"
|
||||||
"github.com/drone/drone/plugin/deploy/deis"
|
|
||||||
"github.com/drone/drone/plugin/deploy/modulus"
|
"github.com/drone/drone/plugin/deploy/modulus"
|
||||||
"github.com/drone/drone/plugin/deploy/nodejitsu"
|
"github.com/drone/drone/plugin/deploy/nodejitsu"
|
||||||
"github.com/drone/drone/plugin/deploy/tsuru"
|
"github.com/drone/drone/plugin/deploy/tsuru"
|
||||||
|
|
Loading…
Reference in a new issue