From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-3.6 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from out1.migadu.com (out1.migadu.com [91.121.223.63]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id E58D11F934 for ; Mon, 1 Feb 2021 05:57:25 +0000 (UTC) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kyleam.com; s=key1; t=1612159043; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=4KCOpAA+eqW6r23cMLfTDlOW4Ge6JtuxKPUyn6V2AvQ=; b=bzKbn4uiR466G392+Pog4WQl0BZVvvlik1xuc9hfha0jd+VeltQ4sbJqXIMjIJ1fv67Zpj wT/CcN/czuczOE4hW9w5e0eQTw/yjD/pdyPHbWVbXRMR86ZUtGdSsS8dEkOtZ82bo1W0dS eMlV4C2wBCdh6KeGzZQcjMd7znjktsGyWkMZwrc5BA0Wu+SZePBI67UCa83l2Kwe/VDYTm 2Ha5HxG3UAxJbsMcaZURdfTTVOP8SJtI+olgt2VITzOyXGqVas5E0EcN52jfZ32WpViTa+ S3hsYR+cyikn1eD6aAo3DabqcM8JxVS7ItKTtqnhMVWZtqp1HzGOfS9E5LIk/Q== From: Kyle Meyer To: meta@public-inbox.org Subject: [PATCH 1/2] doc: start manpages for lei commands Date: Mon, 1 Feb 2021 00:57:02 -0500 Message-Id: <20210201055704.26683-2-kyle@kyleam.com> In-Reply-To: <20210201055704.26683-1-kyle@kyleam.com> References: <20210201055704.26683-1-kyle@kyleam.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: kyle@kyleam.com List-Id: Add manpages for lei and the currently implemented subcommands. The included options and their descriptions follow to a large degree the --help output, dropping some options that are not currently wired up. --- Documentation/.gitignore | 1 + Documentation/lei-add-external.pod | 49 ++++++++++ Documentation/lei-config.pod | 26 ++++++ Documentation/lei-daemon-kill.pod | 28 ++++++ Documentation/lei-daemon-pid.pod | 28 ++++++ Documentation/lei-forget-external.pod | 40 ++++++++ Documentation/lei-init.pod | 42 +++++++++ Documentation/lei-ls-external.pod | 38 ++++++++ Documentation/lei-q.pod | 127 ++++++++++++++++++++++++++ Documentation/lei.pod | 90 ++++++++++++++++++ Documentation/txt2pre | 11 ++- MANIFEST | 9 ++ Makefile.PL | 5 +- 13 files changed, 492 insertions(+), 2 deletions(-) create mode 100644 Documentation/lei-add-external.pod create mode 100644 Documentation/lei-config.pod create mode 100644 Documentation/lei-daemon-kill.pod create mode 100644 Documentation/lei-daemon-pid.pod create mode 100644 Documentation/lei-forget-external.pod create mode 100644 Documentation/lei-init.pod create mode 100644 Documentation/lei-ls-external.pod create mode 100644 Documentation/lei-q.pod create mode 100644 Documentation/lei.pod diff --git a/Documentation/.gitignore b/Documentation/.gitignore index 92510039..142bce32 100644 --- a/Documentation/.gitignore +++ b/Documentation/.gitignore @@ -1,3 +1,4 @@ +/lei*.txt /public-inbox-*.txt /public-inbox.cgi.txt /standards.txt diff --git a/Documentation/lei-add-external.pod b/Documentation/lei-add-external.pod new file mode 100644 index 00000000..dd87be62 --- /dev/null +++ b/Documentation/lei-add-external.pod @@ -0,0 +1,49 @@ +=head1 NAME + +lei-add-external - add inbox or external index + +=head1 SYNOPSIS + +lei add-external [OPTIONS] URL_OR_PATHNAME + +=head1 DESCRIPTION + +Configure lei to search against an external (an inbox or external +index). When C is a local path, it should point to a +directory that is a C.inboxdir> or +C.topdir> value in ~/.public-inbox/config. + +=head1 OPTIONS + +=over + +=item --boost=NUMBER + +Set priority of a new or existing location. + +Default: 0 + +=back + +=head1 FILES + +The configuration for lei resides at C<$XDG_CONFIG_HOME/lei/config>. + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L + +=head1 SEE ALSO + +L, L, +L, L, +L diff --git a/Documentation/lei-config.pod b/Documentation/lei-config.pod new file mode 100644 index 00000000..b6d8bfde --- /dev/null +++ b/Documentation/lei-config.pod @@ -0,0 +1,26 @@ +=head1 NAME + +lei-config - git-config wrapper for lei configuration file + +=head1 SYNOPSIS + +lei config [OPTIONS] + +=head1 DESCRIPTION + +Call git-config(1) with C<$XDG_CONFIG_HOME/lei/config> as the +configuration file. All C are passed through, but those that +override the configuration file are not permitted. + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L diff --git a/Documentation/lei-daemon-kill.pod b/Documentation/lei-daemon-kill.pod new file mode 100644 index 00000000..b369d3b3 --- /dev/null +++ b/Documentation/lei-daemon-kill.pod @@ -0,0 +1,28 @@ +=head1 NAME + +lei-daemon-kill - signal the lei-daemon + +=head1 SYNOPSIS + +lei daemon-kill [-SIGNAL | -s SIGNAL | --signal SIGNAL] + +=head1 DESCRIPTION + +Send a signal to the lei-daemon. C defaults to C. + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L + +=head1 SEE ALSO + +L diff --git a/Documentation/lei-daemon-pid.pod b/Documentation/lei-daemon-pid.pod new file mode 100644 index 00000000..09de8b42 --- /dev/null +++ b/Documentation/lei-daemon-pid.pod @@ -0,0 +1,28 @@ +=head1 NAME + +lei-daemon-pid - show the PID of the lei-daemon + +=head1 SYNOPSIS + +lei daemon-pid + +=head1 DESCRIPTION + +Show the PID of the lei-daemon. + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L + +=head1 SEE ALSO + +L diff --git a/Documentation/lei-forget-external.pod b/Documentation/lei-forget-external.pod new file mode 100644 index 00000000..40287bd3 --- /dev/null +++ b/Documentation/lei-forget-external.pod @@ -0,0 +1,40 @@ +=head1 NAME + +lei-forget-external - forget external locations + +=head1 SYNOPSIS + +lei forget-external [OPTIONS] URL_OR_PATHNAME [URL_OR_PATHNAME...] + +=head1 DESCRIPTION + +Forget the specified externals by removing their entries from +C<$XDG_CONFIG_HOME/lei/config>. This excludes the locations from +future search results. + +=head1 OPTIONS + +=over + +=item -q, --quiet + +Suppress feedback messages. + +=back + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L + +=head1 SEE ALSO + +L, L diff --git a/Documentation/lei-init.pod b/Documentation/lei-init.pod new file mode 100644 index 00000000..8a8022fb --- /dev/null +++ b/Documentation/lei-init.pod @@ -0,0 +1,42 @@ +=head1 NAME + +lei-init - initialize storage + +=head1 SYNOPSIS + +lei init [OPTIONS] [PATHNAME] + +=head1 DESCRIPTION + +Initialize local writable storage for L. If C is +unspecified, the storage is created at C<$XDG_DATA_HOME/lei/store>. +C in C<$XDG_CONFIG_HOME/lei/config> records this +location. + +=head1 OPTIONS + +=over + +=item -q, --quiet + +Suppress feedback messages. + +=back + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L + + +=head1 SEE ALSO + +L diff --git a/Documentation/lei-ls-external.pod b/Documentation/lei-ls-external.pod new file mode 100644 index 00000000..1735faa9 --- /dev/null +++ b/Documentation/lei-ls-external.pod @@ -0,0 +1,38 @@ +=head1 NAME + +lei-ls-external - list inbox and external index locations + +=head1 SYNOPSIS + +lei ls-external [OPTIONS] + +=head1 DESCRIPTION + +List configured externals. + +=head1 OPTIONS + +=over + +=item -z, -0 + +Use C<\0> (NUL) instead of newline (CR) to delimit lines. + +=back + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L + +=head1 SEE ALSO + +L, L diff --git a/Documentation/lei-q.pod b/Documentation/lei-q.pod new file mode 100644 index 00000000..e307e020 --- /dev/null +++ b/Documentation/lei-q.pod @@ -0,0 +1,127 @@ +=head1 NAME + +lei-q - search for messages matching terms + +=head1 SYNOPSIS + +lei q [OPTIONS] TERM [TERM...] + +=head1 DESCRIPTION + +Search for messages across the lei store and externals. + +TODO: Give common prefixes, or at least a description/reference. + +=head1 OPTIONS + +=over + +=item -o PATH, --output=PATH, --mfolder=PATH + +Destination for results (e.g., C or - for stdout). + +Default: - + +=item -f FORMAT, --format=FORMAT + +Format of results: C, C, C, C, +C, C, C, or C. The default format +used depends on C<--output>. + +TODO: Provide description of formats? + +=item --pretty + +Pretty print C or C output. If stdout is opened to +a tty and used as the C<--output> destination, C<--pretty> is enabled +by default. + +=item --mua-cmd=COMMAND, --mua=COMMAND + +A command to run on C<--output> Maildir or mbox (e.g., C). +For a subset of MUAs known to accept a mailbox via C<-f>, COMMAND can +be abbreviated to the name of the program: C, C, C, +or C. + +=item --augment + +Augment output destination instead of clobbering it. + +=item -t, --thread + +Return all messages in the same thread as the actual match(es). + +=item -d STRATEGY, --dedupe=STRATEGY + +Strategy for deduplicating messages: C, C, C, or +C. + +Default: C + +TODO: Provide description of strategies? + +=item --[no-]remote + +Whether to include results requiring network access. When local +externals are configured, C<--remote> must be explicitly passed to +enable reporting of results from remote externals. + +=item --no-local + +Limit operations to those requiring network access. + +=item --no-external + +Don't include results from externals. + +=item -NUMBER, -n NUMBER, --limit=NUMBER + +Limit the number of matches. + +Default: 10000 + +=item --offset=NUMBER + +Shift start of search results. + +Default: 0 + +=item -r, --reverse + +Reverse the results. Note that this applies before C<--limit>. + +=item -s KEY, --sort=KEY + +Order the results by KEY. Valid keys are C, C, +and C. + +Default: C + +=item -v, --verbose + +Provide more feedback on stderr. + +=item --torsocks=auto|no|yes, --no-torsocks + +Whether to wrap L and L commands with torsocks. + +Default: C + +=back + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L + +=head1 SEE ALSO + +L diff --git a/Documentation/lei.pod b/Documentation/lei.pod new file mode 100644 index 00000000..e12a157d --- /dev/null +++ b/Documentation/lei.pod @@ -0,0 +1,90 @@ +=head1 NAME + +lei - local email interface for public-inbox + +=head1 SYNOPSIS + +lei COMMAND + +=head1 DESCRIPTION + +Unlike the C10K-oriented L, lei is designed +exclusively to handle trusted local clients with read/write access to +the file system, using as many system resources as the local user has +access to. lei supports a local, writable store built on top of +L and L. +L provides an interface for querying messages across the lei +store and read-only local and remote "externals" (inboxes and external +indices). + +Available in public-inbox 1.7.0+. + +=head1 COMMANDS + +Subcommands for initializing and managing local, writable storage: + +=over + +=item * L + +=back + +TODO: Add commands like lei-import once they're implemented. + +The following subcommands can be used to manage and inspect external +locations: + +=over + +=item * L + +=item * L + +=item * L + +=back + +Subcommands related to searching and inspecting messages from the lei +store and configured externals are + +=over + +=item * L + +=back + +TODO: Add lei-show (and perhaps others) once implemented. + +Other subcommands include + +=over + +=item * L + +=item * L + +=item * L + +=back + +=head1 FILES + +By default storage is located at C<$XDG_DATA_HOME/lei/store>. The +configuration for lei resides at C<$XDG_CONFIG_HOME/lei/config>. + +=head1 CONTACT + +Feedback welcome via plain-text mail to L + +The mail archives are hosted at L +and L + +=head1 COPYRIGHT + +Copyright 2021 all contributors L + +License: AGPL-3.0+ L + +=head1 SEE ALSO + +L diff --git a/Documentation/txt2pre b/Documentation/txt2pre index 75e4725c..f69323e1 100755 --- a/Documentation/txt2pre +++ b/Documentation/txt2pre @@ -10,7 +10,16 @@ use warnings; use PublicInbox::Linkify; use PublicInbox::Hval qw(ascii_html); my %xurls; -for (qw[public-inbox.cgi(1) +for (qw[lei(1) + lei-add-external(1) + lei-config(1) + lei-daemon-kill(1) + lei-daemon-pid(1) + lei-forget-external(1) + lei-init(1) + lei-ls-external(1) + lei-q(1) + public-inbox.cgi(1) public-inbox-compact(1) public-inbox-config(5) public-inbox-convert(1) diff --git a/MANIFEST b/MANIFEST index 2077ab12..4d6f8b43 100644 --- a/MANIFEST +++ b/MANIFEST @@ -21,6 +21,15 @@ Documentation/flow.ge Documentation/flow.txt Documentation/hosted.txt Documentation/include.mk +Documentation/lei-add-external.pod +Documentation/lei-config.pod +Documentation/lei-daemon-kill.pod +Documentation/lei-daemon-pid.pod +Documentation/lei-forget-external.pod +Documentation/lei-init.pod +Documentation/lei-ls-external.pod +Documentation/lei-q.pod +Documentation/lei.pod Documentation/marketing.txt Documentation/mknews.perl Documentation/public-inbox-compact.pod diff --git a/Makefile.PL b/Makefile.PL index b2f3393d..7bfe1e4e 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -42,7 +42,10 @@ $v->{-m1} = [ map { push @no_pod, $x; (); } - } @EXE_FILES ]; + } @EXE_FILES, + qw( + lei-add-external lei-config lei-daemon-kill lei-daemon-pid + lei-forget-external lei-init lei-ls-external lei-q)]; $v->{-m5} = [ qw(public-inbox-config public-inbox-v1-format public-inbox-v2-format public-inbox-extindex-format) ]; $v->{-m7} = [ qw(public-inbox-overview public-inbox-tuning) ]; -- 2.30.0