You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
1.0 KiB
Makefile

9 years ago
#
# Author: Hari Sekhon
# Date: 2016-01-17 12:56:53 +0000 (Sun, 17 Jan 2016)
#
# vim:ts=4:sts=4:sw=4:noet
#
# https://github.com/harisekhon/bash-tools
#
# If you're using my code you're welcome to connect with me on LinkedIn and optionally send me feedback
#
# https://www.linkedin.com/in/harisekhon
9 years ago
#
5 years ago
REPO := HariSekhon/DevOps-Bash-tools
5 years ago
CODE_FILES := $(shell find . -type f -name '*.sh' -o -name .bashrc | sort)
5 years ago
5 years ago
CONF_FILES := \
.ansible.cfg \
.editorconfig \
5 years ago
.gitconfig \
.tmux.conf \
5 years ago
.vimrc
6 years ago
include Makefile.in
9 years ago
.PHONY: build
6 years ago
build: system-packages
:
9 years ago
5 years ago
install:
@echo "linking dot files to \$$HOME directory: $$HOME"
@if grep -Eq "(source|\.).+$${PWD##*/}/.bashrc" ~/.bashrc 2>/dev/null; then echo "already sourced in ~/.bashrc"; else echo "source $$PWD/.bashrc" >> ~/.bashrc; fi
5 years ago
@f=""; [ -n "$$FORCE" ] && f="-f"; \
5 years ago
for filename in $(CONF_FILES); do \
5 years ago
test -f "$$HOME/$$filename" || ln -sv $$f "$$PWD/$$filename" ~; \
5 years ago
done
9 years ago
.PHONY: test
test:
./all.sh
9 years ago
.PHONY: clean
9 years ago
clean:
@echo Nothing to clean