summaryrefslogtreecommitdiff
path: root/manualPorts/bash-git-prompt/lastVersion.sh
blob: 1147c0d7d142a89aca5393e3faa993c994072ed7 (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/bin/bash

curl -Ss "https://git.eckner.net/Erich/$(basename "${0%/*}")/refs/" | \
  tr '<>' '\n' | \
  sed -n "
    s,^a href='/Erich/$(basename "${0%/*}")/snapshot/$(basename "${0%/*}")-\([0-9.]\+\)\.tar\.xz'$,\1,
    T
    p
  " | \
  sort -V | \
  tail -n1