Update libpgbs.sh