diff options
author | Erich Eckner <git@eckner.net> | 2016-08-29 11:49:38 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2016-08-29 11:49:38 +0200 |
commit | f2d152bd5f69fd3a9c7db84fba8a63e407fa7c74 (patch) | |
tree | 6314b259df4f7831c82bfed0af16bbc8287559e9 | |
parent | 1a5e64cad23981ef19abdba19b7f27565f81d6f6 (diff) | |
download | archlinuxewe.git.save-f2d152bd5f69fd3a9c7db84fba8a63e407fa7c74.tar.xz |
checkVersions kann jetzt auch bitbucket
-rwxr-xr-x | checkVersions | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/checkVersions b/checkVersions index 1b4bf6e2..1fc89278 100755 --- a/checkVersions +++ b/checkVersions @@ -367,6 +367,27 @@ then sort -V | \ tail -n1 )" + elif echo "${src}" | \ + grep -q 'https://bitbucket\.org/.*/get/[^/]\+$' + then + srcPreNam="$( + echo "${src}" | \ + sed 's|^.*/\([^/0-9]\+_\)[0-9][^/]\+$|\1|' + )" + srcEndg="$( + echo "${src}" | \ + sed 's|^.*\(\.tar[^/]*\)$|\1|' | \ + sed 's|\.|\\.|g' + )" + remVer="$( + curl "${src%/get/*}/downloads?tab=tags" 2> /dev/null | \ + tr '"' '\n' | \ + grep "${srcEndg}\$" | \ + sed "s|^.*/${srcPreNam}\(.*\)${srcEndg}\$|\1|" | \ + tr '_' '.' | \ + sort -V | \ + tail -n1 + )" else continue fi |