From dfd62e94576797b8024e20c555bdc0f0997869dc Mon Sep 17 00:00:00 2001 From: Legimet <legimet.calc@gmail.com> Date: Thu, 18 Feb 2016 13:00:52 -0500 Subject: [PATCH] Make pkgversion a function --- helpers/config | 5 +++-- helpers/make-firefox | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/helpers/config b/helpers/config index cf74fa61..c74d5262 100755 --- a/helpers/config +++ b/helpers/config @@ -21,8 +21,6 @@ set -e export LANG=C LC_TIME=C PACKAGE=$(echo $0 |/bin/sed s/make-//g) -PKGVERSION=$(dpkg-parsechangelog --show-field Version) - export DATE=$(date +'%a, %d %b %Y %T %z') @@ -49,6 +47,9 @@ DEVELMIRROR=http://devel.trisquel.info/trisquel/$CODENAME LOCALMIRROR=http://archive.trisquel.info/trisquel LOCAL_APT=`mktemp -d` +pkgversion(){ + dpkg-parsechangelog --show-field Version +} replace(){ find $3 -type f -not -iregex '.*changelog.*' -not -iregex '.*copyright.*' -execdir /bin/sed --follow-symlinks -i s^"$1"^"$2"^g {} \; } diff --git a/helpers/make-firefox b/helpers/make-firefox index 01da5efa..8714ae32 100644 --- a/helpers/make-firefox +++ b/helpers/make-firefox @@ -30,7 +30,7 @@ cp ./browser/components/preferences/advanced-scripts.xul ./browser/components/pr # KDE integration patches from https://www.rosenauer.org/hg/mozilla # Use firefox$MAJORVERSION branch if available, otherwise use default -MAJORVERSION=echo "$PKGVERSION" | sed 's/\([0-9]\+\).*/\1/' +MAJORVERSION=echo `pkgversion` | sed 's/\([0-9]\+\).*/\1/' BRANCH=firefox$MAJORVERSION if ! wget --spider https://rosenauer.org/hg/mozilla/log/$BRANCH; then BRANCH=default -- GitLab