Add zsh-autosuggestion
[zsh.git] / .zsh / external / zsh-autosuggestions / Makefile
1 SRC_DIR := ./src
2 VENDOR_DIR := ./vendor
3
4 SRC_FILES := \
5 $(SRC_DIR)/config.zsh \
6 $(SRC_DIR)/deprecated.zsh \
7 $(SRC_DIR)/bind.zsh \
8 $(SRC_DIR)/highlight.zsh \
9 $(SRC_DIR)/widgets.zsh \
10 $(SRC_DIR)/suggestion.zsh \
11 $(SRC_DIR)/strategies/*.zsh \
12 $(SRC_DIR)/start.zsh
13
14 HEADER_FILES := \
15 DESCRIPTION \
16 URL \
17 VERSION \
18 LICENSE
19
20 PLUGIN_TARGET := zsh-autosuggestions.zsh
21
22 SHUNIT2 := $(VENDOR_DIR)/shunit2/2.1.6
23 STUB_SH := $(VENDOR_DIR)/stub.sh/stub.sh
24
25 TEST_PREREQS := \
26 $(SHUNIT2) \
27 $(STUB_SH)
28
29 all: $(PLUGIN_TARGET)
30
31 $(PLUGIN_TARGET): $(HEADER_FILES) $(SRC_FILES)
32 cat $(HEADER_FILES) | sed -e 's/^/# /g' > $@
33 cat $(SRC_FILES) >> $@
34
35 $(SHUNIT2):
36 git submodule update --init vendor/shunit2
37
38 $(STUB_SH):
39 git submodule update --init vendor/stub.sh
40
41 .PHONY: clean
42 clean:
43 rm $(PLUGIN_TARGET)
44
45 .PHONY: test
46 test: all $(TEST_PREREQS)
47 script/test_runner.zsh $(TESTS)