nvchecker: use upstream git source for parallel & time

This commit is contained in:
George Rawlinson 2022-02-02 00:00:52 +00:00
parent 3770f7d302
commit f43eaece72
Signed by: grawlinson
GPG key ID: E0959FEA8B550539
3 changed files with 11 additions and 75 deletions

View file

@ -1488,14 +1488,6 @@ cmd = "./.repo/pkgver/html-xml-utils.sh"
source = "cmd" source = "cmd"
cmd = "./.repo/pkgver/sendmail.sh" cmd = "./.repo/pkgver/sendmail.sh"
[time]
source = "cmd"
cmd = "./.repo/pkgver/time.sh"
[parallel]
source = "cmd"
cmd = "./.repo/pkgver/parallel.sh"
# git # git
#[plasma-pass-git] #[plasma-pass-git]
#source = "git" #source = "git"
@ -1519,6 +1511,17 @@ use_max_tag = true
prefix = "libabigail-" prefix = "libabigail-"
ignored = "1.0.rc0" ignored = "1.0.rc0"
[time]
source = "git"
git = "https://git.savannah.gnu.org/git/time.git"
use_max_tag = true
prefix = "v"
[parallel]
source = "git"
git = "https://git.savannah.gnu.org/git/parallel.git"
use_max_tag = true
# gems # gems
[ruby-ffi] [ruby-ffi]

View file

@ -1,33 +0,0 @@
#!/bin/bash
set -e
# check dependencies
count=0
for dependency in curl tr cut grep sed sort tail; do
if [ ! -x "$(command -v $dependency)" ]; then
echo "$dependency missing"
count=$((count+1))
fi
done
# exit script if any dependencies missing
if [ $count -ne 0 ]; then
exit 1
fi
# upstream URL
UPSTREAM_URL="ftp://ftp.gnu.org/gnu/parallel/"
# options to pass to cURL, including custom user agent
USER_AGENT="parallel-version-checker/1.0 george@rawlinson.net.nz"
CURL_OPTS=(--ftp-pasv --silent --user-agent "$USER_AGENT")
curl "${CURL_OPTS[@]}" "$UPSTREAM_URL" | \
tr -s ' ' | \
cut -d ' ' -f 9 | \
grep -E "parallel-[[:digit:]]+\.tar\.bz2\.sig$" | \
sed -e 's/^parallel-//' -e 's/\.tar\.bz2\.sig$//' | \
sort -n | \
tail -n 1
exit 0

View file

@ -1,34 +0,0 @@
#!/usr/bin/bash
set -e
# check dependencies
count=0
for dependency in curl tr cut grep sed sort tail; do
if [ ! -x "$(command -v $dependency)" ]; then
echo "$dependency missing"
count=$((count+1))
fi
done
# exit script if any dependencies missing
if [ $count -ne 0 ]; then
exit 1
fi
# upstream URL
UPSTREAM_URL="ftp://ftp.gnu.org/gnu/time/"
# options to pass to cURL, including custom user agent
USER_AGENT="time-version-checker/1.0 george@rawlinson.net.nz"
CURL_OPTS=(--ftp-pasv --silent --user-agent "$USER_AGENT")
curl "${CURL_OPTS[@]}" "$UPSTREAM_URL" | \
tr -s ' ' | \
cut -d ' ' -f 9 | \
grep ".tar.gz$" | \
sort -n | \
tail -n 1 | \
sed -e "s/^time-//" -e "s/.tar.gz$//"
exit 0