From bf7347380207d80183ce80ae6547ef08fa579c6a Mon Sep 17 00:00:00 2001 From: Polesznyák Márk Date: Sat, 29 Nov 2025 01:45:07 +0100 Subject: feat: add scripts, TARGET variable for Makefile --- Makefile | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index e3d55ad..7beddbf 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,23 @@ +PREFIX = /usr/local +TARGET := $(HOME) +SCRIPTS := $(shell cd scripts && ls) + +default: + @echo "Current configuration:" + @echo " PREFIX: $(PREFIX)" + @echo " TARGET: $(TARGET)" + install: - stow . --target $(HOME) - git clone https://github.com/tmux-plugins/tpm $(HOME)/.tmux/plugins/tpm + stow . --target $(TARGET) + [ -d $(HOME)/.tmux/plugins/tpm ] || git clone https://github.com/tmux-plugins/tpm $(HOME)/.tmux/plugins/tpm + +install-scripts: + cd scripts && cp $(SCRIPTS) $(PREFIX)/bin/ uninstall: - stow -D . --target $(HOME) + stow -D . --target $(TARGET) + +uninstall-scripts: + cd $(PREFIX)/bin && rm -f $(SCRIPTS) + +.PHONY: default install install-scripts uninstall uninstall-scripts -- cgit v1.2.3