about summary refs log tree commit diff
path: root/chat.c
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2020-03-31 14:30:42 -0400
committerJune McEnroe <june@causal.agency>2020-03-31 14:30:42 -0400
commit25f419465f019feedb7266cb68232d1b32a66957 (patch)
tree67dffcc716ad457967f884cb25f448de27634f64 /chat.c
parentSave and load buffer line heat (diff)
downloadcatgirl-25f419465f019feedb7266cb68232d1b32a66957.tar.gz
catgirl-25f419465f019feedb7266cb68232d1b32a66957.zip
Add /ignore message filtering patterns
Diffstat (limited to '')
-rw-r--r--chat.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/chat.c b/chat.c
index b7bf91b..8ead5da 100644
--- a/chat.c
+++ b/chat.c
@@ -127,7 +127,7 @@ int main(int argc, char *argv[]) {
 	const char *user = NULL;
 	const char *real = NULL;
 
-	const char *Opts = "!C:H:N:O:RS:a:c:eg:h:j:k:ln:p:r:s:u:vw:";
+	const char *Opts = "!C:H:N:O:RS:a:c:eg:h:i:j:k:ln:p:r:s:u:vw:";
 	const struct option LongOpts[] = {
 		{ "insecure", no_argument, NULL, '!' },
 		{ "copy", required_argument, NULL, 'C' },
@@ -140,6 +140,7 @@ int main(int argc, char *argv[]) {
 		{ "cert", required_argument, NULL, 'c' },
 		{ "sasl-external", no_argument, NULL, 'e' },
 		{ "host", required_argument, NULL, 'h' },
+		{ "ignore", required_argument, NULL, 'i' },
 		{ "join", required_argument, NULL, 'j' },
 		{ "priv", required_argument, NULL, 'k' },
 		{ "log", no_argument, NULL, 'l' },
@@ -168,6 +169,7 @@ int main(int argc, char *argv[]) {
 			break; case 'e': sasl = true;
 			break; case 'g': genCert(optarg);
 			break; case 'h': host = optarg;
+			break; case 'i': ignoreAdd(optarg);
 			break; case 'j': self.join = optarg;
 			break; case 'k': priv = optarg;
 			break; case 'l': logEnable = true;