# option for "multipackage" just to let the system know that's what you meant
# option to take filenames from stdin
# parse package, version, release from file if not given
# option for "multipackage" just to let the system know that's what you meant
# option to take filenames from stdin
# parse package, version, release from file if not given
-if [ -z "$package" ]; then
- die "must specify package"
+set -x
+eval $(zpm parse -E $pkgid)
+
+if [ -z "$pkgfile" ];
+ pkgfile=$ZPM_PACKAGE_FILE
+fi
+
+# look for a .zpm file here
+if [ -z "$pkgfile" ] && [ -n "$release" ] && [ -f "$pkgid.zpm" ];
+ pkgfile="$pkgid.zpm"