Skip to content

Commit

Permalink
fix goreleaser, add version
Browse files Browse the repository at this point in the history
  • Loading branch information
jpillora committed Aug 2, 2020
1 parent 28738d8 commit 69cade9
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 30 deletions.
3 changes: 2 additions & 1 deletion .github/goreleaser.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# test this file with
# goreleaser --skip-publish --rm-dist --config goreleaser.yml
builds:
- main: ./main.go
- main: ./cmd/tcp-proxy
binary: tcp-proxy
env:
- CGO_ENABLED=0
ldflags:
Expand Down
27 changes: 0 additions & 27 deletions .goreleaser.yml

This file was deleted.

5 changes: 3 additions & 2 deletions cmd/tcp-proxy/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@ import (
"regexp"
"strings"

"github.com/jpillora/go-tcp-proxy"
proxy "github.com/jpillora/go-tcp-proxy"
)

var (
version = "0.0.0-src"
matchid = uint64(0)
connid = uint64(0)
logger proxy.ColorLogger
Expand All @@ -36,7 +37,7 @@ func main() {
Color: *colors,
}

logger.Info("Proxying from %v to %v", *localAddr, *remoteAddr)
logger.Info("go-tcp-proxy (%s) proxing from %v to %v ", version, *localAddr, *remoteAddr)

laddr, err := net.ResolveTCPAddr("tcp", *localAddr)
if err != nil {
Expand Down

0 comments on commit 69cade9

Please sign in to comment.