aurutils: issue #274

This commit is contained in:
Alad Wenter 2018-02-15 14:55:09 +01:00
parent bdcee8c8ee
commit 671f0ef9a3
6 changed files with 74 additions and 16 deletions

View file

@ -1,9 +1,9 @@
# Generated by mksrcinfo v8 # Generated by mksrcinfo v8
# Sat Jan 27 13:02:51 UTC 2018 # Thu Feb 15 13:53:03 UTC 2018
pkgbase = aurutils pkgbase = aurutils
pkgdesc = helper tools for the arch user repository pkgdesc = helper tools for the arch user repository
pkgver = 1.5.3 pkgver = 1.5.3
pkgrel = 8 pkgrel = 9
url = https://github.com/AladW/aurutils url = https://github.com/AladW/aurutils
arch = any arch = any
license = custom:ISC license = custom:ISC
@ -23,11 +23,13 @@ pkgbase = aurutils
source = 0001-aurbuild-backport-fix-for-236.patch source = 0001-aurbuild-backport-fix-for-236.patch
source = 0002-aursync-make-L-optional-281.patch source = 0002-aursync-make-L-optional-281.patch
source = 0003-aurbuild-update-default-options.patch source = 0003-aurbuild-update-default-options.patch
source = 0004-aurfetch-specify-git-work-tree-git-dir-274.patch
sha256sums = a09088a460e352179dbf799d915e866af47aa280474a9c943f8e6885490734c5 sha256sums = a09088a460e352179dbf799d915e866af47aa280474a9c943f8e6885490734c5
sha256sums = SKIP sha256sums = SKIP
sha256sums = e4076af43608a00e47379232b4d42412b5956d96c73f66ecb2cfd62d8a2eba86 sha256sums = ea5e34adeb4c8ead68bd8aa934b5b39ad30f4ca05262b6b99a305e2eaf2ee577
sha256sums = 6a28f1e1c98a69a236409ed659f0a699c89bb16748d364be2ba0841041cd015c sha256sums = 849adcbb1c9510b7bc87a85b8e1589fa972e2aeca0efff583eb22f65b2f28fd3
sha256sums = 84976fe128a6ea5b7bb185d63fe447a340404a9d63700020158202e6e8006b49 sha256sums = 156cb3becc09e2042780dec2f06d91a28f32c1d898e94915d1753e38f056a59a
sha256sums = 3372a7342606924685c80c8583d31cf202ece24d1a3aa86c709c650ac3ddc930
pkgname = aurutils pkgname = aurutils

View file

@ -1,7 +1,7 @@
From 79b42b1252ff70ba46cb7fff077ab5afa0115568 Mon Sep 17 00:00:00 2001 From 1ac09c520814769d670f4b351c889e4a421b55a0 Mon Sep 17 00:00:00 2001
From: Alad Wenter <alad@mailbox.org> From: Alad Wenter <alad@mailbox.org>
Date: Fri, 6 Oct 2017 23:03:14 +0200 Date: Fri, 6 Oct 2017 23:03:14 +0200
Subject: [PATCH 1/3] aurbuild: backport fix for #236 Subject: [PATCH 1/4] aurbuild: backport fix for #236
--- ---
bin/aurbuild | 10 ++++++++-- bin/aurbuild | 10 ++++++++--

View file

@ -1,7 +1,7 @@
From 43ee1e5f814886b3f04bf899205ef2c2c03aba02 Mon Sep 17 00:00:00 2001 From bed6e3128a7e95b837cb98a4fdafa289038378b0 Mon Sep 17 00:00:00 2001
From: Alad Wenter <alad@mailbox.org> From: Alad Wenter <alad@mailbox.org>
Date: Sat, 27 Jan 2018 03:21:37 +0100 Date: Sat, 27 Jan 2018 03:21:37 +0100
Subject: [PATCH 2/3] aursync: make -L optional (#281) Subject: [PATCH 2/4] aursync: make -L optional (#281)
--- ---
bin/aursync | 7 ++++--- bin/aursync | 7 ++++---

View file

@ -1,7 +1,7 @@
From fb682a53f0bad47baaf734d5af2baa2964fdb85b Mon Sep 17 00:00:00 2001 From 4bf451876d51787b8be2694a4ccd16da1a233186 Mon Sep 17 00:00:00 2001
From: Alad Wenter <alad@mailbox.org> From: Alad Wenter <alad@mailbox.org>
Date: Sat, 27 Jan 2018 13:57:37 +0100 Date: Sat, 27 Jan 2018 13:57:37 +0100
Subject: [PATCH 3/3] aurbuild: update default options Subject: [PATCH 3/4] aurbuild: update default options
Remove gpg --verbose, makepkg -L Remove gpg --verbose, makepkg -L
--- ---

View file

@ -0,0 +1,54 @@
From c57c6b90bf62510d774215abd9f4f816c4d8b789 Mon Sep 17 00:00:00 2001
From: Alad Wenter <AladW@users.noreply.github.com>
Date: Mon, 22 Jan 2018 16:16:16 +0100
Subject: [PATCH 4/4] aurfetch: specify git work-tree/git-dir (#274)
Avoid "Stopping at filesystem boundary" issues with different file
systems.
---
bin/aurfetch | 21 +++++++++++----------
1 file changed, 11 insertions(+), 10 deletions(-)
diff --git a/bin/aurfetch b/bin/aurfetch
index 95c49c3..0a79287 100755
--- a/bin/aurfetch
+++ b/bin/aurfetch
@@ -8,24 +8,25 @@ declare -i aurball=0
declare logdir=/dev/null
clone() {
- declare -r logdir=$1 startdir=$PWD
+ declare -r logdir=$1
while IFS= read -r; do
+ # Avoid issues with exotic file system layouts (#274)
+ git_wrap() { git --work-tree="$REPLY" --git-dir="$REPLY"/.git "$@"; }
+
if [[ -d $REPLY/.git ]]; then
- cd_safe "$REPLY"
+ # returns 0 even if nothing was fetched
+ git_wrap fetch -v
- git fetch -v # returns 0 even if nothing was fetched
-
- if [[ $(git rev-parse HEAD) != $(git rev-parse '@{upstream}') ]]; then
+ if [[ $(git_wrap rev-parse HEAD) != $(git_wrap rev-parse '@{upstream}') ]]; then
if [[ -d $logdir ]]; then
- git --no-pager log --patch --stat '..@{upstream}' >> "$logdir/$REPLY".patch
+ git_wrap --no-pager log --patch --stat '..@{upstream}' \
+ >> "$logdir/$REPLY".patch
fi
- git reset --hard HEAD
- git merge
+ git_wrap reset --hard HEAD
+ git_wrap merge
fi
-
- cd_safe "$startdir"
else
git clone "$aurweb/$REPLY".git
fi
--
2.16.1

View file

@ -1,7 +1,7 @@
# Maintainer: Alad Wenter <alad@mailbox.org> # Maintainer: Alad Wenter <alad@mailbox.org>
pkgname=aurutils pkgname=aurutils
pkgver=1.5.3 pkgver=1.5.3
pkgrel=8 pkgrel=9
pkgdesc='helper tools for the arch user repository' pkgdesc='helper tools for the arch user repository'
arch=('any') arch=('any')
url='https://github.com/AladW/aurutils' url='https://github.com/AladW/aurutils'
@ -16,15 +16,17 @@ optdepends=('devtools: systemd-nspawn support'
'repose: repo-add alternative') 'repose: repo-add alternative')
_backports=('0001-aurbuild-backport-fix-for-236.patch' _backports=('0001-aurbuild-backport-fix-for-236.patch'
'0002-aursync-make-L-optional-281.patch' '0002-aursync-make-L-optional-281.patch'
'0003-aurbuild-update-default-options.patch') '0003-aurbuild-update-default-options.patch'
'0004-aurfetch-specify-git-work-tree-git-dir-274.patch')
source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz" source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz"
"$pkgname-$pkgver.tar.gz.asc::$url/releases/download/$pkgver/$pkgver.tar.gz.asc" "$pkgname-$pkgver.tar.gz.asc::$url/releases/download/$pkgver/$pkgver.tar.gz.asc"
"${_backports[@]}") "${_backports[@]}")
sha256sums=('a09088a460e352179dbf799d915e866af47aa280474a9c943f8e6885490734c5' sha256sums=('a09088a460e352179dbf799d915e866af47aa280474a9c943f8e6885490734c5'
'SKIP' 'SKIP'
'e4076af43608a00e47379232b4d42412b5956d96c73f66ecb2cfd62d8a2eba86' 'ea5e34adeb4c8ead68bd8aa934b5b39ad30f4ca05262b6b99a305e2eaf2ee577'
'6a28f1e1c98a69a236409ed659f0a699c89bb16748d364be2ba0841041cd015c' '849adcbb1c9510b7bc87a85b8e1589fa972e2aeca0efff583eb22f65b2f28fd3'
'84976fe128a6ea5b7bb185d63fe447a340404a9d63700020158202e6e8006b49') '156cb3becc09e2042780dec2f06d91a28f32c1d898e94915d1753e38f056a59a'
'3372a7342606924685c80c8583d31cf202ece24d1a3aa86c709c650ac3ddc930')
# Alad Wenter <alad@mailbox.org> # Alad Wenter <alad@mailbox.org>
validpgpkeys=('DBE7D3DD8C81D58D0A13D0E76BC26A17B9B7018A') validpgpkeys=('DBE7D3DD8C81D58D0A13D0E76BC26A17B9B7018A')