Makefile generation improved

This commit is contained in:
2022-08-26 08:25:55 +08:00
parent c1150af922
commit 8ffc2dfe32
5 changed files with 86 additions and 42 deletions

View File

@@ -1,4 +1,4 @@
# Autogenerated at 25.08.2022 22:32 using ./gen-makefile
# Autogenerated at 26.08.2022 08:21 using ./gen-makefile
.DEFAULT_GOAL := help
#===============================================
@@ -159,6 +159,29 @@ zint:
zsh:
@./install/zsh
#===============================================
# Scripts listed in ./upgrade
#===============================================
# Upgrade omz
^omz:
@./upgrade/omz
#===============================================
# Scripts listed in ./uninstall
#===============================================
# Uninstall docker
/docker:
@./uninstall/docker
# Uninstall omz
/omz:
@./uninstall/omz
#===============================================
# Service goals
#===============================================
self:
@./gen-makefile
@@ -166,20 +189,9 @@ self:
help: Makefile
@echo "Ubuntu software installator"
@echo
@echo "Usage:"
@echo "\tmake help\t - Show this help"
@echo "\tmake self\t - Regenerate Makefile (alias of ./gen-makefile)"
@echo "\tmake GOAL\t - Install software"
@echo "\tmake ^GOAL\t - Upgrade software"
@echo "\tmake @GOAL\t - Uninstall software"
@echo
@echo "You can combine GOALs, e.g. 'make @docker docker' will reinstall docker."
@echo
@echo "Available GOALs:"
@echo "Usage:\n make help|- show this help\n make self|- regenerate Makefile (alias of ./gen-makefile)\n make GOAL|- install software\n make ^GOAL|- upgrade software\n make /GOAL|- uninstall software" | column -ts '|'
@echo "\nYou can combine GOALs, here are some examples:"
@echo "\tmake @docker docker"
@echo "\tmake php @docker ^omz"
@echo "\nAvailable GOALs:"
@sed -n '/^#/{N;s/# *\(.*\)\n\([^# .].*:\)/\t\2\1/p}' $< | column -ts ':'
+%:
@$(MAKE) $*
^%:
@./upgrade/$*
@%:
@./uninstall/$*