From 16c50bb659a680f114f6a740288cb2b5081174ea Mon Sep 17 00:00:00 2001 From: Christopher Allen Lane Date: Sat, 5 Nov 2022 12:17:53 -0400 Subject: [PATCH] chore: bump version to `4.4.0` --- INSTALLING.md | 4 ++-- Makefile | 34 +++++++++++++++++++++++++++++----- cmd/cheat/main.go | 2 +- 3 files changed, 32 insertions(+), 8 deletions(-) diff --git a/INSTALLING.md b/INSTALLING.md index a1f0576..37d9b72 100644 --- a/INSTALLING.md +++ b/INSTALLING.md @@ -9,13 +9,13 @@ On Unix-like systems, you may simply paste the following snippet into your termi ```sh cd /tmp \ - && wget https://github.com/cheat/cheat/releases/download/4.3.3/cheat-linux-amd64.gz \ + && wget https://github.com/cheat/cheat/releases/download/4.4.0/cheat-linux-amd64.gz \ && gunzip cheat-linux-amd64.gz \ && chmod +x cheat-linux-amd64 \ && sudo mv cheat-linux-amd64 /usr/local/bin/cheat ``` -You may need to need to change the version number (`4.3.3`) and the archive +You may need to need to change the version number (`4.4.0`) and the archive (`cheat-linux-amd64.gz`) depending on your platform. See the [releases page][releases] for a list of supported platforms. diff --git a/Makefile b/Makefile index 8285a37..11426b3 100644 --- a/Makefile +++ b/Makefile @@ -35,13 +35,17 @@ releases := \ $(dist_dir)/cheat-linux-amd64 \ $(dist_dir)/cheat-linux-arm5 \ $(dist_dir)/cheat-linux-arm6 \ - $(dist_dir)/cheat-linux-arm7 \ $(dist_dir)/cheat-linux-arm64 \ + $(dist_dir)/cheat-linux-arm7 \ + $(dist_dir)/cheat-netbsd-amd64 \ + $(dist_dir)/cheat-openbsd-amd64 \ + $(dist_dir)/cheat-plan9-amd64 \ + $(dist_dir)/cheat-solaris-amd64 \ $(dist_dir)/cheat-windows-amd64.exe ## build: build an executable for your architecture .PHONY: build -build: $(dist_dir) | clean generate fmt lint vet vendor man +build: | clean $(dist_dir) generate fmt lint vet vendor man $(GO) build $(BUILD_FLAGS) -o $(dist_dir)/cheat $(cmd_dir) ## build-release: build release executables @@ -83,6 +87,26 @@ $(dist_dir)/cheat-linux-arm64: prepare GOARCH=arm64 GOOS=linux \ $(GO) build $(BUILD_FLAGS) -o $@ $(cmd_dir) && $(GZIP) $@ && chmod -x $@.gz +# cheat-netbsd-amd64 +$(dist_dir)/cheat-netbsd-amd64: prepare + GOARCH=amd64 GOOS=netbsd \ + $(GO) build $(BUILD_FLAGS) -o $@ $(cmd_dir) && $(GZIP) $@ && chmod -x $@.gz + +# cheat-openbsd-amd64 +$(dist_dir)/cheat-openbsd-amd64: prepare + GOARCH=amd64 GOOS=openbsd \ + $(GO) build $(BUILD_FLAGS) -o $@ $(cmd_dir) && $(GZIP) $@ && chmod -x $@.gz + +# cheat-plan9-amd64 +$(dist_dir)/cheat-plan9-amd64: prepare + GOARCH=amd64 GOOS=plan9 \ + $(GO) build $(BUILD_FLAGS) -o $@ $(cmd_dir) && $(GZIP) $@ && chmod -x $@.gz + +# cheat-solaris-amd64 +$(dist_dir)/cheat-solaris-amd64: prepare + GOARCH=amd64 GOOS=solaris \ + $(GO) build $(BUILD_FLAGS) -o $@ $(cmd_dir) && $(GZIP) $@ && chmod -x $@.gz + # cheat-windows-amd64 $(dist_dir)/cheat-windows-amd64.exe: prepare GOARCH=amd64 GOOS=windows \ @@ -103,7 +127,7 @@ install: build ## clean: remove compiled executables .PHONY: clean -clean: $(dist_dir) +clean: $(RM) -f $(dist_dir)/* $(cmd_dir)/str_config.go $(cmd_dir)/str_usage.go ## distclean: remove the tags file @@ -140,7 +164,7 @@ vendor: ## vendor-update: update vendored dependencies vendor-update: - $(GO) get -t -u ./... && $(GO) mod vendor + $(GO) get -t -u ./... && $(GO) mod vendor && $(GO) mod tidy && $(GO) mod verify ## fmt: run go fmt .PHONY: fmt @@ -173,7 +197,7 @@ coverage: check: | vendor fmt lint vet test .PHONY: prepare -prepare: | $(dist_dir) clean generate vendor fmt lint vet test +prepare: | clean $(dist_dir) generate vendor fmt lint vet test ## docker-setup: create a docker image for use during development .PHONY: docker-setup diff --git a/cmd/cheat/main.go b/cmd/cheat/main.go index 41c3714..af1cdbc 100755 --- a/cmd/cheat/main.go +++ b/cmd/cheat/main.go @@ -16,7 +16,7 @@ import ( "github.com/cheat/cheat/internal/installer" ) -const version = "4.3.3" +const version = "4.4.0" func main() {