diff options
author | sum01 | 2018-05-03 21:54:46 -0400 |
---|---|---|
committer | sum01 | 2018-05-03 21:54:46 -0400 |
commit | cc32f0b0d6ffd9ce3e709110756701e49357c68d (patch) | |
tree | 57325557e7d17ca77186bede0077969f2d33cc72 | |
parent | 3ce1cfca3f299f667271a992be4c4cb30f9fd98b (diff) | |
download | aur-cc32f0b0d6ffd9ce3e709110756701e49357c68d.tar.gz |
Only query Github once & bump version
Previously we curl'd Github twice, but doing it once (per run) is enough/more efficient.
Also removed the verbose flag on tar for a less noisy build.
-rw-r--r-- | .SRCINFO | 2 | ||||
-rw-r--r-- | PKGBUILD | 10 |
2 files changed, 6 insertions, 6 deletions
@@ -1,6 +1,6 @@ pkgbase = micro-nightly-bin pkgdesc = A modern and intuitive terminal-based text editor - pkgver = 1.3.5.81 + pkgver = 1.4.1.60 pkgrel = 1 url = https://github.com/zyedidia/micro arch = x86_64 @@ -1,9 +1,9 @@ # Maintainer: sum01 <sum01@protonmail.com> # Contributor: tommyshem -# Previous Maintainer: Atnanasis <ys2000pro@gmail.com> +# Contributor: Atnanasis <ys2000pro@gmail.com> # Contributor: Youngbin Han <sukso96100@gmail.com> pkgname=micro-nightly-bin -pkgver=1.3.5.81 +pkgver=1.4.1.60 pkgrel=1 pkgdesc="A modern and intuitive terminal-based text editor" arch=('x86_64' 'i686') @@ -14,8 +14,9 @@ makedepends=('grep' 'sed' 'curl' 'wget' 'tar' 'coreutils') optdepends=('xclip: for copying to and from the terminal') conflicts=('micro') provides=('micro') +_realver=$(curl -s 'https://api.github.com/repos/zyedidia/micro/releases/tags/nightly' | grep -oEm 1 '([0-9]+\.){2}[0-9]+\-(dev\.)?[0-9]+') pkgver() { - curl -s 'https://api.github.com/repos/zyedidia/micro/releases/tags/nightly' | grep -oEm 1 '[0-9]+\.[0-9]+\.[0-9]+\-(dev\.)?[0-9]+' | sed -E 's/\-(dev\.)?/\./' + echo $_realver | sed -E 's/\-(dev\.)?/\./' } build() { if [[ $CARCH == "i686" ]]; then @@ -26,11 +27,10 @@ build() { if [[ -e "$srcdir/micro" ]]; then rm -rf "$srcdir/micro" fi - _realver=$(curl -s 'https://api.github.com/repos/zyedidia/micro/releases/tags/nightly' | grep -oEm 1 '[0-9]+\.[0-9]+\.[0-9]+\-(dev\.)?[0-9]+') _filename="micro-$_realver-linux$_bits.tar.gz" cd "$srcdir" wget "https://github.com/zyedidia/micro/releases/download/nightly/$_filename" - tar -xvf "$_filename" + tar -xf "$_filename" mv -f "$srcdir/micro-$_realver" "$srcdir/micro" } package() { |