Skip to content

Commit

Permalink
cmd: ignore files with no services
Browse files Browse the repository at this point in the history
Change-Id: I63083a11c3626369553d729e4394052281abd502
  • Loading branch information
zeebo committed Mar 22, 2021
1 parent 0a6577a commit 0816f17
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 10 deletions.
3 changes: 1 addition & 2 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,9 @@ pipeline {
}

stages {
stage('Download') {
stage('Checkout') {
steps {
checkout scm
sh 'make download'
}
}

Expand Down
6 changes: 1 addition & 5 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,15 +1,11 @@
.DEFAULT_GOAL = all

.PHONY: all
all: download docs generate lint test tidy
all: docs generate lint test tidy

.PHONY: quick
quick: generate test

.PHONY: download
download:
./scripts/run.sh '*' go mod download

.PHONY: docs
docs:
./scripts/docs.sh
Expand Down
4 changes: 2 additions & 2 deletions cmd/protoc-gen-go-drpc/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# package protoc-gen-drpc
# package protoc-gen-go-drpc

`import "storj.io/drpc/cmd/protoc-gen-drpc"`
`import "storj.io/drpc/cmd/protoc-gen-go-drpc"`



Expand Down
2 changes: 1 addition & 1 deletion cmd/protoc-gen-go-drpc/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ func main() {
ParamFunc: flags.Set,
}.Run(func(plugin *protogen.Plugin) error {
for _, f := range plugin.Files {
if !f.Generate {
if !f.Generate || len(f.Services) == 0 {
continue
}
generateFile(plugin, f, *protolib)
Expand Down

0 comments on commit 0816f17

Please sign in to comment.