#!/bin/sh [ $# != 1 ] && exit function indent { sed 's/.*/ &/' 2>/dev/null } printf '\e[1mpackages:\e[0m\n' pkg_info -Q $1 | indent echo printf '\e[1mports:\e[0m\n' # all package links are followed by ' - ' curl "https://openports.pl/search?pkgname=$1" 2>/dev/null \ | grep -oE '[^<>]+ - ' \ | sed 's/<\/a> - //' \ | indent