-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
executable file
·42 lines (34 loc) · 1.07 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
.ONESHELL:
.SHELL:=/bin/sh
.PHONY: help all profile tools containers
.DEFAULT_GOAL:=help
CURRENT_FOLDER=$(shell basename "$$(pwd)")
BOLD=$(shell tput bold)
RED=$(shell tput setaf 1)
RESET=$(shell tput sgr0)
## Global
NAME=main
VERSION=scratch
OS=$(shell uname -s)
## Paths
DOTFILES=${HOME}/.dotfiles
ASDF=${HOME}/.asdf/bin/asdf
## Burn, baby, burn
help: ## Shows this makefile help
@echo ""
@echo "Usage: make [target]"
@echo ""
@echo "Targets:"
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
all: asdf profile tools containers ## Install everything
profile: ## Install ZSH, Tmux, and Neovim profiles
$(MAKE) all -C profile
tools: ## Install tools
$(MAKE) all -C tools
containers: ## Install Docker & Kubernetes tools
$(MAKE) all -C container
asdf: ## Install asdf
@echo "Installing ASDF"
rm -rf ${HOME}/.asdf
git clone https://github.com/asdf-vm/asdf.git ${HOME}/.asdf || (echo "$(RED)Error: Cloning ASDF failed.$(RESET)" && exit 1)
@echo "ASDF installation completed successfully"