Adding an option

Jonathan Hayward -- http://JonathansCorner.com jshayward@pobox.com
Tue Aug 28 20:30:01 2001


--------------0447CC6489656E15620D2F90
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

In my Tcl extension, I'm trying to add an option --passphrase
<passphrase>.  I've added oPassphrase to the enum and the options list
and told the extension to take the passphrase from the argument.

However, the extension believes there's an error.  When I run tclsh and
type

% load g10/gpg.so
% gpg --passphrase foo -sign bar

I get

gpg: Invalid option "--passphrase"
[returned exit code] 2
%

What are the steps involved in registering an option with the argument
parser? It looks like I've left something out.

--
Jonathan Hayward
jshayward@pobox.com
http://JonathansCorner.com
(A four dimensional maze, stories, essays, artwork, and other things...)



--------------0447CC6489656E15620D2F90
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
In my Tcl extension, I'm trying to add an option --passphrase &lt;passphrase>.&nbsp;
I've added oPassphrase to the enum and the options list and told the extension
to take the passphrase from the argument.
<p>However, the extension believes there's an error.&nbsp; When I run tclsh
and type
<p>% load g10/gpg.so
<br>%&nbsp;gpg --passphrase foo -sign bar
<p>I get
<p>gpg: Invalid option "--passphrase"
<br>[returned exit code] 2
<br>%
<p>What are the steps involved in registering an option with the argument
parser?&nbsp;It looks like I've left something out.
<pre>--&nbsp;
Jonathan Hayward
jshayward@pobox.com
<A HREF="http://JonathansCorner.com">http://JonathansCorner.com</A>
(A four dimensional maze, stories, essays, artwork, and other things...)</pre>
&nbsp;</html>

--------------0447CC6489656E15620D2F90--