summaryrefslogtreecommitdiff
path: root/brisket.hy
diff options
context:
space:
mode:
Diffstat (limited to 'brisket.hy')
-rw-r--r--brisket.hy13
1 files changed, 5 insertions, 8 deletions
diff --git a/brisket.hy b/brisket.hy
index e18732a..d018d2d 100644
--- a/brisket.hy
+++ b/brisket.hy
@@ -26,7 +26,6 @@
(import [os [getenv makedirs]])
(import [os.path [dirname expanduser]])
(import [sys [argv exit stderr]])
-(import [re [match]])
(import [nntplib [NNTP-SSL]])
(import [subprocess [Popen PIPE]])
@@ -71,17 +70,15 @@ usage: version"
|| ||" __version__)))
(defn list-groups [session &rest args]
- "List groups on the server, matching a pattern if one is given.
+ "List groups on the server.
-usage: list-groups [pattern (optional)]"
- (let [pattern (if (>= (len args) 1) (nth args 0))
- groups (second (.list session))]
+usage: list-groups"
+ (let [groups (second (.list session))]
(for [group groups]
- (if (or (is pattern None) (match pattern group.group))
- (print group.group)))))
+ (print group.group))))
(defn describe-group [session &rest args]
- "Describe the first group matching the pattern.
+ "Describe the first group whose name matches the pattern.
usage: describe-groups [pattern]"
(when (< (len args) 1)