Skip to content

Commit

Permalink
add an install target so we can test it locally easier
Browse files Browse the repository at this point in the history
  • Loading branch information
caiobegotti committed Sep 4, 2021
1 parent 1ec34ea commit 75b2268
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,22 @@ compact: build
release: compact ## build, compact, sha256 files for a release
@openssl sha256 out/*.tar.gz out/*.zip

ifeq ($(OS),Windows_NT)
THIS_OS := Windows
else
UNAME_S := $(shell uname -s)
ifeq ($(UNAME_S),Linux)
THIS_OS += -D linux
endif
ifeq ($(UNAME_S),Darwin)
THIS_OS += darwin
endif
endif

.PHONE: install
install: build
sudo cp -vaf out/pod-restarts-amd64-$(THIS_OS) $(HOME)/.krew/bin/kubectl-pod_restarts

.PHONY: clean
clean: ## clean up build directory and binaries files
$(RM) -r $(BUILDDIR) pod-restarts
Expand Down

0 comments on commit 75b2268

Please sign in to comment.