Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 27 Dec 2018 23:04:00 +0000 (UTC)
From:      Grzegorz Blach <gblach@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r488579 - head/devel/ninja
Message-ID:  <201812272304.wBRN405o003120@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gblach
Date: Thu Dec 27 23:03:59 2018
New Revision: 488579
URL: https://svnweb.freebsd.org/changeset/ports/488579

Log:
  Install zsh and bash completion files
  
  PR:		234407
  Submitted by:	Greg V

Modified:
  head/devel/ninja/Makefile

Modified: head/devel/ninja/Makefile
==============================================================================
--- head/devel/ninja/Makefile	Thu Dec 27 22:55:51 2018	(r488578)
+++ head/devel/ninja/Makefile	Thu Dec 27 23:03:59 2018	(r488579)
@@ -4,6 +4,7 @@
 PORTNAME=	ninja
 PORTVERSION=	1.8.2
 DISTVERSIONPREFIX=	v
+PORTREVISION=	1
 PORTEPOCH=	2
 CATEGORIES=	devel
 
@@ -22,8 +23,12 @@ USES=		python
 PLIST_FILES=	bin/ninja
 PORTDOCS=	HACKING.md README manual.asciidoc
 
-OPTIONS_DEFINE=	DOCS
+OPTIONS_DEFINE=		DOCS BASH ZSH
+OPTIONS_DEFAULT=	BASH ZSH
 
+BASH_PLIST_FILES=	share/bash-completion/completions/ninja
+ZSH_PLIST_FILES=	share/zsh/site-functions/_ninja
+
 post-patch:
 	@${REINPLACE_CMD} "s/'-g', //" ${WRKSRC}/configure.py
 
@@ -37,6 +42,16 @@ do-install:
 	(cd ${WRKSRC} && \
 	    ${INSTALL_DATA} HACKING.md README doc/manual.asciidoc \
 	    ${STAGEDIR}${DOCSDIR})
+
+do-install-BASH-on:
+	@${MKDIR} ${STAGEDIR}${PREFIX}/share/bash-completion/completions/
+	${INSTALL_DATA} ${WRKSRC}/misc/bash-completion \
+		${STAGEDIR}${PREFIX}/share/bash-completion/completions/ninja
+
+do-install-ZSH-on:
+	@${MKDIR} ${STAGEDIR}${PREFIX}/share/zsh/site-functions
+	${INSTALL_DATA} ${WRKSRC}/misc/zsh-completion \
+		${STAGEDIR}${PREFIX}/share/zsh/site-functions/_ninja
 
 do-test: build
 	cd ${WRKSRC} && ./ninja ninja_test && ./ninja_test



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201812272304.wBRN405o003120>