forked from AutoHotkey-V2/DateParse
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
24 lines (19 loc) · 852 Bytes
/
Makefile
File metadata and controls
24 lines (19 loc) · 852 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
SHELL := /bin/bash
HOMEDIR := /home/$(USER)
AHK_BIN := /mnt/c/Program\ Files/AutoHotkey/Compiler/Ahk2Exe.exe
DOCDIR := /mnt/f/OneDrive/Documents
LIB := DateParse
DESTLIBDIR := $(DOCDIR)/AutoHotkey/Lib
DEVHOME := $(DOCDIR)/dev/projects
SRCDIR := $(DEVHOME)/Lib/$(LIB)
SRCS := $(shell find . -maxdepth 1 -type f -name '*.ahk' ! -name 'test.ahk' -exec bash -c 'for f; do [[ "$$f" =~ [[:space:]] ]] && printf "\"%s\" " "$$f" || printf "%s " "$$f"; done' _ {} +)
.PHONY: all clean install
all: install
@echo All done at $$(date)
install:
@mkdir -p $(DESTLIBDIR)
@rsync -av --update --info=NAME --delete $(SRCS) $(DESTLIBDIR)
@echo Sources copied at $$(date)
clean:
@find $(DESTLIBDIR) -maxdepth 1 -type f \( $(foreach src,$(SRCS),-name $(notdir $(src)) -o) -false \) -exec echo Deleting: {} \; -exec rm -vf {} +
@echo clean completed at $$(date)