summary refs log tree commit diff
path: root/Makefile
diff options
context:
space:
mode:
authorChristian Neukirchen <chneukirchen@gmail.com>2016-02-28 19:03:17 +0100
committerChristian Neukirchen <chneukirchen@gmail.com>2016-02-28 19:03:17 +0100
commit989d3f1ce42f98e64b6740e7c9b94bab5fb8ae13 (patch)
tree54c87a59a1bc8134a8308d07e71bc7be5ff12141 /Makefile
parent7a8402622c25d043b1a535ad018288352547e3a9 (diff)
downloadlr-989d3f1ce42f98e64b6740e7c9b94bab5fb8ae13.tar.gz
lr-989d3f1ce42f98e64b6740e7c9b94bab5fb8ae13.tar.xz
lr-989d3f1ce42f98e64b6740e7c9b94bab5fb8ae13.zip
add zsh completion
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 124dcd0..5ef6fcd 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,5 @@
 ALL=lr
+ZSHCOMP=_lr
 
 CFLAGS=-g -O2 -Wall -Wno-switch -Wextra -Wwrite-strings
 
@@ -6,6 +7,7 @@ DESTDIR=
 PREFIX=/usr/local
 BINDIR=$(PREFIX)/bin
 MANDIR=$(PREFIX)/share/man
+ZSHCOMPDIR=$(PREFIX)/share/zsh/site-functions
 
 all: $(ALL)
 
@@ -13,8 +15,9 @@ clean: FRC
 	rm -f lr
 
 install: FRC all
-	mkdir -p $(DESTDIR)$(BINDIR) $(DESTDIR)$(MANDIR)/man1
+	mkdir -p $(DESTDIR)$(BINDIR) $(DESTDIR)$(MANDIR)/man1 $(DESTDIR)$(ZSHCOMPDIR)
 	install -m0755 $(ALL) $(DESTDIR)$(BINDIR)
 	install -m0644 $(ALL:=.1) $(DESTDIR)$(MANDIR)/man1
+	install -m0644 $(ZSHCOMP) $(DESTDIR)$(ZSHCOMPDIR)
 
 FRC: