cvs: php4 /pear/PEAR/Command Package.php

From: Date: Tue, 09 Apr 2002 13:49:51 +0000
Subject: cvs: php4 /pear/PEAR/Command Package.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-3182@lists.php.net to get a copy of this message
cox Tue Apr 9 09:49:51 2002 EDT Modified files: /php4/pear/PEAR/Command Package.php Log: Fix package-list not showing the right Install path Index: php4/pear/PEAR/Command/Package.php diff -u php4/pear/PEAR/Command/Package.php:1.16 php4/pear/PEAR/Command/Package.php:1.17 --- php4/pear/PEAR/Command/Package.php:1.16 Sun Apr 7 15:42:05 2002 +++ php4/pear/PEAR/Command/Package.php Tue Apr 9 09:49:47 2002 @@ -16,7 +16,7 @@ // | Author: Stig Bakken <ssb@fast.no> | // +----------------------------------------------------------------------+ // -// $Id: Package.php,v 1.16 2002/04/07 19:42:05 ssb Exp $ +// $Id: Package.php,v 1.17 2002/04/09 13:49:47 cox Exp $ require_once 'PEAR/Command/Common.php'; require_once 'PEAR/Packager.php'; @@ -160,7 +160,14 @@ // {{{ package-list case 'package-list': { + // $params[0] -> the PEAR package to list its contents + if (sizeof($params) != 1) { + $failmsg = "Command package-list requires a valid PEAR package filename ". + " as the first argument. Try the command \"help package-list\""; + break; + } $obj = new PEAR_Common(); + if (PEAR::isError($info = $obj->infoFromTgzFile($params[0]))) { return $info; } @@ -173,9 +180,9 @@ foreach ($list as $file => $att) { if (isset($att['baseinstalldir'])) { $dest = $att['baseinstalldir'] . DIRECTORY_SEPARATOR . - basename($file); + $file; } else { - $dest = basename($file); + $dest = $file; } switch ($att['role']) { case 'test':

« previous php.pear.cvs (#3182) next »