#!/bin/bash # Strip cat, we only need the pkg name ezcpkg="`echo ${1} | sed -e "s|^.*/||g"`" # Take care of some strange package naming ezcpkg="${ezcpkg/ezc-/}" # Take care of outputting the version number pwd="`pwd`" if ! test -d "${pwd}/${ezcpkg}-tmp" ; then mkdir "${pwd}/${ezcpkg}-tmp" fi cd "${pwd}/${ezcpkg}-tmp" wget --quiet --tries=1 --timeout=3 "http://ez.no/doc/components/overview/latest" grep -i ">${ezcpkg}" latest | sed -e "s|
  • ${ezcpkg} (||g" | sed -e "s|)
  • .*||g" rm -Rf "${pwd}/${ezcpkg}-tmp"