www-plugins/browserpass: new package
authorAric Belsito <lluixhi@gmail.com>
Thu, 1 Feb 2018 00:59:04 +0000 (16:59 -0800)
committerMichał Górny <mgorny@gentoo.org>
Wed, 7 Feb 2018 20:14:45 +0000 (21:14 +0100)
The Browserpass package provides the host binary necessary for the
(Firefox or Chrome) browser extension to read your app-admin/pass
password store to authenticate websites.

Closes: https://github.com/gentoo/gentoo/pull/5836

www-plugins/browserpass/Manifest [new file with mode: 0644]
www-plugins/browserpass/browserpass-2.0.11.ebuild [new file with mode: 0644]
www-plugins/browserpass/metadata.xml [new file with mode: 0644]

diff --git a/www-plugins/browserpass/Manifest b/www-plugins/browserpass/Manifest
new file mode 100644 (file)
index 0000000..7bb299c
--- /dev/null
@@ -0,0 +1 @@
+DIST browserpass-2.0.11.tar.gz 176787 BLAKE2B 271c3cf340ecc78c3358f21bc0e6bbcaf857b4ca39c7b0dcf58b1fcef62ea5df4f48adb4ac0bf7c884853f359fdb9ca00300e2f99efa48a1fdc0ba99ce7bd172 SHA512 baa362b63c1743273f56cb7576f96c29ca365fb217d3016824cdb1ce215e36b7f98fc7c3340a5a34853bde7c25283c84ceda570d149a8119bc54be2f0194034b
diff --git a/www-plugins/browserpass/browserpass-2.0.11.ebuild b/www-plugins/browserpass/browserpass-2.0.11.ebuild
new file mode 100644 (file)
index 0000000..6abafb5
--- /dev/null
@@ -0,0 +1,48 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+EGO_PN=github.com/dannyvankooten/browserpass
+
+if [[ ${PV} == 9999 ]]; then
+       inherit golang-vcs
+else
+       KEYWORDS="~amd64"
+       SRC_URI="https://${EGO_PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+       inherit golang-vcs-snapshot
+fi
+inherit golang-build
+
+DESCRIPTION="WebExtension host binary for pass, a UNIX password manager"
+HOMEPAGE="https://github.com/dannyvankooten/browserpass"
+LICENSE="MIT"
+SLOT="0"
+RDEPEND="app-crypt/gnupg"
+DEPEND="${RDEPEND}
+       dev-go/twofactor:=
+       dev-go/zglob:="
+
+DOCS=( CONTRIBUTING.md README.md )
+
+src_compile() {
+       EGO_PN="${EGO_PN}/cmd/browserpass" golang-build_src_compile
+
+       pushd "src/${EGO_PN}" >/dev/null || die
+       sed -e 's|%%replace%%|'${EPREFIX}'/usr/bin/browserpass|' \
+               -i firefox/host.json chrome/host.json || die
+       popd >/dev/null || die
+}
+
+src_install() {
+       dobin browserpass
+
+       pushd "src/${EGO_PN}" >/dev/null || die
+       insinto /usr/$(get_libdir)/mozilla/native-messaging-hosts
+       newins firefox/host.json com.dannyvankooten.browserpass.json
+
+       insinto /etc/chromium/native-messaging-hosts
+       newins chrome/host.json com.dannyvankooten.browserpass.json
+
+       einstalldocs
+       popd >/dev/null || die
+}
diff --git a/www-plugins/browserpass/metadata.xml b/www-plugins/browserpass/metadata.xml
new file mode 100644 (file)
index 0000000..004ae50
--- /dev/null
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+       <maintainer type="person" >
+               <email>lluixhi@gmail.com</email>
+               <name>Aric Belsito</name>
+       </maintainer>
+       <maintainer type="project">
+               <email>proxy-maint@gentoo.org</email>
+               <name>Proxy Maintainers</name>
+       </maintainer>
+</pkgmetadata>