diff options
author | Matti Viljanen | 2020-02-16 16:25:45 +0200 |
---|---|---|
committer | Matti Viljanen | 2020-02-16 16:25:45 +0200 |
commit | 6b9c9a3b8e0e3eb23df232d926ca06dda6d88fc8 (patch) | |
tree | 7e14ee1f02c4bcb18cfe3b716236772d5ded65aa | |
parent | 8f86069478fb127f617f65f4925693b92ac87335 (diff) | |
download | aur-6b9c9a3b8e0e3eb23df232d926ca06dda6d88fc8.tar.gz |
Tighten file name rules
This is done to exclude snap packages and transitional packages:
- Chromium version, e.g. "80.0.3987.87"
- Ubuntu package version, e.g. "0ubuntu0"
- Ubuntu release version string, e.g. "16.04" or "18.04.1"
- Filesize must be in megabytes, e.g. "1.0M"
-rwxr-xr-x | update_pkg.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/update_pkg.sh b/update_pkg.sh index a8779390f146..16872cba49c1 100755 --- a/update_pkg.sh +++ b/update_pkg.sh @@ -1,6 +1,6 @@ #!/bin/bash REPO='http://security.ubuntu.com/ubuntu/pool/universe/c/chromium-browser/' -PACKAGE=$(wget -qO- $REPO | perl -ne '/(?<=href=")(chromium-codecs-ffmpeg-extra_(.*?)-(\w{8}).(.*?)_amd64.deb)(?=")/ and print "$1#$2#$3#$4\n";' | sort | tail -n 1) +PACKAGE=$(wget -qO- $REPO | perl -ne '/(?<=href=")(chromium-codecs-ffmpeg-extra_(\d*\.\d*\.\d*\.\d*)-(\dubuntu\d).(\d{2}\.\d{2}(?:\.\d)?)_amd64.deb)(?=").*\d*\.\d*M/ and print "$1#$2#$3#$4\n";' | sort | tail -n 1) deb=$(echo $PACKAGE | cut -d# -f1) ver1=$(echo $PACKAGE | cut -d# -f2) |