helly Mon Dec 8 00:15:52 2008 UTC
Modified files:
/php-src/ext/phar/phar pharcommand.inc
Log:
- Only show switch -y if available
http://cvs.php.net/viewvc.cgi/php-src/ext/phar/phar/pharcommand.inc?r1=1.52&r2=1.53&diff_format=u
Index: php-src/ext/phar/phar/pharcommand.inc
diff -u php-src/ext/phar/phar/pharcommand.inc:1.52
php-src/ext/phar/phar/pharcommand.inc:1.53
--- php-src/ext/phar/phar/pharcommand.inc:1.52 Fri Oct 17 01:53:26 2008
+++ php-src/ext/phar/phar/pharcommand.inc Mon Dec 8 00:15:51 2008
@@ -139,7 +139,7 @@
'y' => array(
'typ' => 'privkey',
'val' => NULL,
- 'inf' => 'Private key for OpenSSL signing.',
+ 'inf' => '<key> Private key for OpenSSL
signing.',
),
);
@@ -157,6 +157,9 @@
$hash_optional = array('SHA-256' => 'SHA256',
'SHA-512' =>
'SHA512',
'OpenSSL' =>
'OpenSSL');
+ if (!in_array('OpenSSL', $hash_avail)) {
+ unset($phar_args['y']);
+ }
foreach($hash_optional as $key => $name) {
if (in_array($key, $hash_avail)) {
@@ -378,7 +381,7 @@
* @param string $arg The phar selection
* @param string $cfg The config option.
* @param string $key The key information.
- * @return string $arg The selected algorithm
+ * @return string $arg The private key.
*/
static function cli_arg_typ_privkey($arg, $cfg, $key)
{
@@ -1552,7 +1555,7 @@
$use_ext = extension_loaded('phar');
$version = array(
'PHP Version' => phpversion(),
- 'phar.phar version' => '$Revision: 1.52 $',
+ 'phar.phar version' => '$Revision: 1.53 $',
'Phar EXT version' => $use_ext ? phpversion('phar') :
'Not available',
'Phar API version' => Phar::apiVersion(),
'Phar-based phar archives' => true,
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php