diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index f722032..7906276 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -6,7 +6,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - go: [1.13, 1.14] + go: [1.14, 1.15] steps: - name: Set up Go uses: actions/setup-go@v2 @@ -15,13 +15,9 @@ jobs: - name: Check out source uses: actions/checkout@v2 - name: Install Linters - run: "curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.26.0" + run: "curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.33.0" - name: Build - env: - GO111MODULE: "on" run: go build ./... - name: Test - env: - GO111MODULE: "on" run: | - sh ./goclean.sh + ./goclean.sh diff --git a/ratchet/ratchet_test.go b/ratchet/ratchet_test.go index c3dbb8c..2ecfb2e 100644 --- a/ratchet/ratchet_test.go +++ b/ratchet/ratchet_test.go @@ -17,7 +17,7 @@ import ( "github.com/companyzero/sntrup4591761" "github.com/companyzero/zkc/blobshare" "github.com/companyzero/zkc/ratchet/disk" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" "golang.org/x/crypto/curve25519" "golang.org/x/crypto/ed25519" ) diff --git a/session/kx.go b/session/kx.go index 19a025a..633d269 100644 --- a/session/kx.go +++ b/session/kx.go @@ -15,7 +15,7 @@ import ( "time" "github.com/companyzero/sntrup4591761" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" "golang.org/x/crypto/nacl/secretbox" ) diff --git a/tools/zkexport/zkexport.go b/tools/zkexport/zkexport.go index cc63d21..868811a 100644 --- a/tools/zkexport/zkexport.go +++ b/tools/zkexport/zkexport.go @@ -23,7 +23,7 @@ import ( "github.com/companyzero/zkc/zkserver/settings" "github.com/companyzero/zkc/zkutil" "github.com/davecgh/go-spew/spew" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" ) // fetchServerFullIdentity() fetches a server's signed identity data. diff --git a/tools/zkimport/zkimport.go b/tools/zkimport/zkimport.go index ffdf80c..b85dffc 100644 --- a/tools/zkimport/zkimport.go +++ b/tools/zkimport/zkimport.go @@ -22,7 +22,7 @@ import ( "github.com/companyzero/zkc/tools" "github.com/companyzero/zkc/zkserver/account" "github.com/davecgh/go-spew/spew" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" "github.com/vaughan0/go-ini" ) diff --git a/zkclient/acceptclientfingerprint.go b/zkclient/acceptclientfingerprint.go index ea71d47..c7ebecc 100644 --- a/zkclient/acceptclientfingerprint.go +++ b/zkclient/acceptclientfingerprint.go @@ -7,7 +7,6 @@ package main import ( "bytes" "crypto/rand" - "fmt" "strings" "github.com/companyzero/ttk" @@ -15,7 +14,7 @@ import ( "github.com/companyzero/zkc/ratchet" "github.com/companyzero/zkc/rpc" "github.com/companyzero/zkc/zkidentity" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" "github.com/nsf/termbox-go" ) @@ -103,7 +102,7 @@ func (aw *acceptCFPWindow) Init(w *ttk.Window) { //y++ y++ - s := fmt.Sprintf("Are you sure you want to continue connecting (yes/no)?") + s := "Are you sure you want to continue connecting (yes/no)?" w.AddLabel(ax, ay+y, s) aw.questionInput = w.AddEdit(ax+len(s)+1, ay+y, -2, &aw.question) } diff --git a/zkclient/addressbook.go b/zkclient/addressbook.go index e4ccc31..ab62e5e 100644 --- a/zkclient/addressbook.go +++ b/zkclient/addressbook.go @@ -16,7 +16,7 @@ import ( "github.com/companyzero/zkc/rpc" "github.com/companyzero/zkc/zkclient/addressbook" "github.com/companyzero/zkc/zkidentity" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" ) // addressBookDel permanently removes nick from the address book. diff --git a/zkclient/chunk.go b/zkclient/chunk.go index ea4e2bd..02043ab 100644 --- a/zkclient/chunk.go +++ b/zkclient/chunk.go @@ -12,7 +12,7 @@ import ( "path" "github.com/companyzero/zkc/rpc" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" "github.com/marcopeereboom/goutil" ) diff --git a/zkclient/groupinvites.go b/zkclient/groupinvites.go index 93aebf7..98f7b0e 100644 --- a/zkclient/groupinvites.go +++ b/zkclient/groupinvites.go @@ -17,7 +17,7 @@ import ( "github.com/companyzero/zkc/rpc" "github.com/companyzero/zkc/tools" "github.com/companyzero/zkc/zkidentity" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" ) const ( diff --git a/zkclient/identity.go b/zkclient/identity.go index db1b944..6131467 100644 --- a/zkclient/identity.go +++ b/zkclient/identity.go @@ -17,7 +17,7 @@ import ( "github.com/companyzero/zkc/ratchet" "github.com/companyzero/zkc/ratchet/disk" "github.com/companyzero/zkc/zkidentity" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" ) const ( diff --git a/zkclient/kxacceptwindow.go b/zkclient/kxacceptwindow.go index 0931d7b..d6fc373 100644 --- a/zkclient/kxacceptwindow.go +++ b/zkclient/kxacceptwindow.go @@ -14,7 +14,7 @@ import ( "github.com/companyzero/zkc/blobshare" "github.com/companyzero/zkc/rpc" "github.com/companyzero/zkc/zkidentity" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" "github.com/nsf/termbox-go" ) diff --git a/zkclient/kxwindow.go b/zkclient/kxwindow.go index 9d03ac4..59da69c 100644 --- a/zkclient/kxwindow.go +++ b/zkclient/kxwindow.go @@ -9,7 +9,7 @@ import ( "github.com/companyzero/ttk" "github.com/companyzero/zkc/blobshare" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" "github.com/nsf/termbox-go" ) diff --git a/zkclient/welcome.go b/zkclient/welcome.go index c99795c..702d95c 100644 --- a/zkclient/welcome.go +++ b/zkclient/welcome.go @@ -11,7 +11,7 @@ import ( "github.com/companyzero/ttk" "github.com/companyzero/zkc/rpc" "github.com/companyzero/zkc/zkidentity" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" "github.com/nsf/termbox-go" ) diff --git a/zkserver/account/account_test.go b/zkserver/account/account_test.go index 4b57541..011dcff 100644 --- a/zkserver/account/account_test.go +++ b/zkserver/account/account_test.go @@ -16,7 +16,7 @@ import ( "github.com/companyzero/zkc/zkidentity" "github.com/davecgh/go-spew/spew" - "github.com/davecgh/go-xdr/xdr2" + xdr "github.com/davecgh/go-xdr/xdr2" ) func newAccount(t *testing.T) (*Account, error) { diff --git a/zkserver/rendezvous.go b/zkserver/rendezvous.go index 31deccb..56c4f0d 100644 --- a/zkserver/rendezvous.go +++ b/zkserver/rendezvous.go @@ -87,20 +87,20 @@ func (z *ZKS) handleRendezvousPull(writer chan *RPCWrapper, // get token v, err := rz.Get("", r.Token) if err != nil { - payload.Error = fmt.Sprintf("invalid PIN") + payload.Error = "invalid PIN" goto bad } // decode value rzXDR, err = base64.StdEncoding.DecodeString(v) if err != nil { - payload.Error = fmt.Sprintf("internal error base64decode") + payload.Error = "internal error base64decode" goto bad } br = bytes.NewReader(rzXDR) _, err = z.unmarshal(br, &rzRecord) if err != nil { - payload.Error = fmt.Sprintf("internal error unmarshal") + payload.Error = "internal error unmarshal" goto bad }