diff options
| -rw-r--r-- | Makefile | 3 | ||||
| -rw-r--r-- | blobby/main.go | 3 | ||||
| -rw-r--r-- | cf-r2/Makefile (renamed from going2git/Makefile) | 22 | ||||
| -rw-r--r-- | cf-r2/download.go | 8 |
4 files changed, 22 insertions, 14 deletions
@@ -4,3 +4,6 @@ all: make -C zoopb-example make -C testGui make -C going2git # actually builds against git2go using libgit2 v1.8.4 + +clean: + rm -f go.* diff --git a/blobby/main.go b/blobby/main.go index 5b6f89f..fda762b 100644 --- a/blobby/main.go +++ b/blobby/main.go @@ -3,6 +3,9 @@ package main import ( "gocloud.dev/blob" // _ "gocloud.dev/blob/<driver>" + + _ "github.com/go-sql-driver/mysql" + "context" "fmt" diff --git a/going2git/Makefile b/cf-r2/Makefile index 07bcba5..2b57a99 100644 --- a/going2git/Makefile +++ b/cf-r2/Makefile @@ -4,7 +4,12 @@ BUILDTIME = $(shell date +%s) all: build -build: goimports +build: goimports go.mod + go build -v upload.go + go build -v download.go + go build -v main.go + +raw: GO111MODULE=off go build -v \ -ldflags "-X main.VERSION=${VERSION} -X main.BUILDTIME=${BUILDTIME} -X gui.GUIVERSION=${VERSION}" @@ -16,13 +21,10 @@ goimports: # // to globally reset paths: # // gofmt -w -r '"go.wit.com/gui/gadgets" -> "go.wit.com/lib/gadgets"' *.go -gocui: build - reset - ./go-clone-test --gui gocui - -install: goimports - GO111MODULE=off go install \ - -ldflags "-X main.VERSION=${VERSION} -X main.BUILDTIME=${BUILDTIME} -X gui.GUIVERSION=${VERSION}" +go.mod: + go mod init + go mod tidy -force: build - ./go-clone-test --force +clean: + rm -f go.* + rm -f upload download main diff --git a/cf-r2/download.go b/cf-r2/download.go index b2f4184..887ac99 100644 --- a/cf-r2/download.go +++ b/cf-r2/download.go @@ -10,10 +10,10 @@ import ( ) const ( - r2Endpoint = "<account-id>.r2.cloudflarestorage.com" // Replace with your R2 endpoint - r2AccessKey = "<your-access-key>" // Replace with your Access Key - r2SecretKey = "<your-secret-key>" // Replace with your Secret Key - r2BucketName = "example-bucket" // Replace with your bucket name + r2Endpoint = "<account-id>.r2.cloudflarestorage.com" // Replace with your R2 endpoint + r2AccessKey = "<your-access-key>" // Replace with your Access Key + r2SecretKey = "<your-secret-key>" // Replace with your Secret Key + r2BucketName = "example-bucket" // Replace with your bucket name ) func main() { |
