diff options
author | Tucker Boniface | 2018-01-28 21:54:11 -0800 |
---|---|---|
committer | Tucker Boniface | 2018-01-28 21:54:11 -0800 |
commit | 1d73a9803f7810ab2ad5220ba2dd8e53a9203d2b (patch) | |
tree | 3e082281ebbf78aba0e98ce5ceef55a0602a005a | |
download | aur-1d73a9803f7810ab2ad5220ba2dd8e53a9203d2b.tar.gz |
Initial commit -- convert yay to vcs package
-rw-r--r-- | .SRCINFO | 23 | ||||
-rw-r--r-- | PKGBUILD | 49 |
2 files changed, 72 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..301f8ea11e55 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,23 @@ +pkgbase = yay-git + pkgdesc = Yet another yogurt. Pacman wrapper and AUR helper written in go. (development version) + pkgver = 99 + pkgrel = 1 + url = https://github.com/Jguer/yay + arch = i686 + arch = x86_64 + arch = armv7h + arch = aarch64 + license = GPL + makedepends = git + makedepends = go + depends = sudo + provides = yay + conflicts = yay-bin + conflicts = yay + options = !strip + options = !emptydirs + source = git+https://github.com/Jguer/yay/ + md5sums = SKIP + +pkgname = yay-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..d9a376284e9b --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,49 @@ +# MAintainer: Tucker Boniface <tucker@boniface.tech> +# Maintainer: Jguer <joaogg3@gmail.com> +VCS="git" +pkgname="yay-git" +pkgver=99 +pkgrel=1 +pkgdesc="Yet another yogurt. Pacman wrapper and AUR helper written in go. (development version)" +arch=('i686' 'x86_64' 'armv7h' 'aarch64') +url="https://github.com/Jguer/yay" +license=('GPL') +options=('!strip' '!emptydirs') +depends=('sudo') +makedepends=("${VCS}" 'go') +conflicts=('yay-bin' 'yay') +provides=('yay') +source=("git+https://github.com/Jguer/yay/") +md5sums=("SKIP") + +prepare() { + export GOPATH="${srcdir}/.go" + export GOBIN="$GOPATH/bin" + mkdir -p "$GOPATH" + rm -rf "$GOPATH/src" + ln -sf "$srcdir/${pkgname%-${VCS}}/vendor" "$GOPATH/src" +} + +build() { + export GOPATH="${srcdir}/.go" + export GOBIN="$GOPATH/bin" + cd "$srcdir/${pkgname%-${VCS}}" + go build -v -o ${pkgname%-${VCS}} -ldflags "-s -w -X main.version=${pkgver}" +} + +package() { + _output="${srcdir}/${pkgname%-${VCS}}" + install -Dm755 "${_output}/${pkgname%-${VCS}}" "${pkgdir}/usr/bin/${pkgname%-${VCS}}" + + # Install manpage + install -Dm644 "${_output}/yay.8" "${pkgdir}/usr/share/man/man8/yay.8" + + # Install bash completion + install -Dm644 "${_output}/bash-completion" "${pkgdir}/usr/share/bash-completion/completions/yay" + + # Install zsh completion + install -Dm644 "${_output}/zsh-completion" "${pkgdir}/usr/share/zsh/site-functions/_yay" + + # Install fish completion + install -Dm644 "${_output}/yay.fish" "${pkgdir}/usr/share/fish/vendor_completions.d/yay.fish" +} |