Skip to content

Commit 8b29f3a

Browse files
committed
create packaging/linux/arch/version.sh, omitting the timestamp
See rmarquis/pacaur#483.
1 parent ba40259 commit 8b29f3a

3 files changed

Lines changed: 25 additions & 3 deletions

File tree

‎packaging/linux/arch/PKGBUILD‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Maintainer: Jack O'Connor <oconnor663@gmail.com>
22

3+
###
4+
### NOTE: This file is out of date. Our prerelease PKGBUILD lives at
5+
### git+ssh://aur@aur.archlinux.org:keybase-git
6+
###
7+
38
pkgname=keybase
49
pkgdesc='LOCAL BUILD'
510
license=('BSD')

‎packaging/linux/arch/version.sh‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#! /usr/bin/env bash
2+
3+
# The timestamps in our usual prerelease version numbers aren't very useful on
4+
# Arch, because people build packages locally. Also pacaur gets upset when the
5+
# version number changes from the beginning to the end of a build, see
6+
# https://github.com/rmarquis/pacaur/issues/483. So we omit the timestamp from
7+
# the version in the Arch packages. Note that `keybase version` will still have
8+
# a timestamp; this shorter format only shows up in `pacman -Qi keybase-git`.
9+
10+
set -e -u -o pipefail
11+
12+
here="$(dirname "$BASH_SOURCE")"
13+
14+
base_version="$("$here/../../version.sh" production)"
15+
commit="$(git -C "$here" rev-parse --short HEAD)"
16+
17+
echo "$base_version+$commit"

‎packaging/linux/build_and_push_packages.sh‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,12 +125,12 @@ bump_arch_linux_aur() {
125125
# This relies on having the SSH key registered with the "keybase" account on
126126
# https://aur.archlinux.org.
127127
(
128-
underscore_version="$(echo "$version" | sed 's/[-+]/_/g')"
128+
arch_version="$("$here/arch/version.sh")"
129129
temp_repo=`mktemp -d`
130130
git clone aur@aur.archlinux.org:keybase-git "$temp_repo"
131131
cd "$temp_repo"
132-
sed -i "s/pkgver=.*/pkgver=$underscore_version/" PKGBUILD
133-
sed -i "s/pkgver = .*/pkgver = $underscore_version/" .SRCINFO
132+
sed -i "s/pkgver=.*/pkgver=$arch_version/" PKGBUILD
133+
sed -i "s/pkgver = .*/pkgver = $arch_version/" .SRCINFO
134134
git commit -am "version bump"
135135
git push origin master
136136
)

0 commit comments

Comments
 (0)