commit a8f487c9aaacb51f252ab46641ce0ddcc0ae96a2
parent 4b8fff2f21ac86258630fe7b6bc58ba52121b89a
Author: Antoine Amarilli <ant.amarilli@free.fr>
Date: Sun, 16 Jan 2011 04:46:49 +0100
add possible options
Diffstat:
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/irctk.c b/irctk.c
@@ -68,6 +68,8 @@ static struct argp_option options[] = {
/* TODO Display by theme not by alpha order */
{"verbose", 'v', 0, 0,
"Produce debug output on stderr" },
+ {"quiet", 'q', 0, 0,
+ "Don't even display errors on stderr, fail silently" },
{"no-command-to-event", 0, 0, 0,
"Don't generate events from messages with \"/quit\", \"/me\"..." }, /* TODO */
{"no-destination-prefix", 0, 0, 0,
@@ -95,12 +97,17 @@ static struct argp_option options[] = {
/* TODO for this option, it would be cool to display the channel name on stderr, for the poor man's client*/
{"synchronous", 's', 0, 0,
"Will wait for a multiline, blank line-terminated answer on stdin to all lines passed on stdout, and will bufferize activity before that" },
- {"filter", 'f', 0, 0,
+ {"exec", 'e', 0, 0,
"Pipe each message to this command" }, /* TODO and support several of them */
+ {"exec-argv", 'E', 0, 0,
+ "Run this command on each message, passing the channel, nick and message as $1, $2, and $3" },
/* TODO and allow to pipe on argv rather than stdin */
- /* TODO for bots, prefix with "nick_of_sender:" on public channels */
{"reply", 'r', 0, 0,
"When inferring a destination channel automatically, also infer a destination nick, and prefix lines with this nick" },
+ {"filter", 'f', 0, 0,
+ "Only keep messages directly addressed to us (in private channel or with lines prefixed by our nick)" },
+ {"no-auto-join", 0, 0, 0,
+ "Refuse to send any message to channels not specified on the command line (default is to join as needed)" },
{ 0 }
};
@@ -124,7 +131,6 @@ struct arguments
char last_chans_out[MAX_LEN];
int default_destination;
int show_prefix;
-
};
typedef struct arguments irc_ctx_t;