* [sup-devel] now in next: sup-cmd
@ 2010-03-04 7:48 Rich Lane
2010-03-04 13:10 ` Nicolas Pouillard
0 siblings, 1 reply; 5+ messages in thread
From: Rich Lane @ 2010-03-04 7:48 UTC (permalink / raw)
To: sup-devel
I already had the code for a sup-server sup-cmd sitting around, so I
wrote a small compatibility layer that lets it run using the mainline
index API. It outputs YAML.
Usage:
sup-cmd count 'is:inbox'
sup-cmd query --offset 10 --limit 5 'is:unread'
sup-cmd label --add-labels 'bugs' --remove-labels 'inbox' 'is:inbox AND from:bugzilla'
sup-cmd add --labels 'sent' < email
_______________________________________________
Sup-devel mailing list
Sup-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [sup-devel] now in next: sup-cmd
2010-03-04 7:48 [sup-devel] now in next: sup-cmd Rich Lane
@ 2010-03-04 13:10 ` Nicolas Pouillard
2010-03-04 18:25 ` Carl Worth
0 siblings, 1 reply; 5+ messages in thread
From: Nicolas Pouillard @ 2010-03-04 13:10 UTC (permalink / raw)
To: Rich Lane, sup-devel
On Thu, 04 Mar 2010 02:48:16 -0500, Rich Lane <rlane@club.cc.cmu.edu> wrote:
> I already had the code for a sup-server sup-cmd sitting around, so I
> wrote a small compatibility layer that lets it run using the mainline
> index API. It outputs YAML.
>
> Usage:
> sup-cmd count 'is:inbox'
> sup-cmd query --offset 10 --limit 5 'is:unread'
> sup-cmd label --add-labels 'bugs' --remove-labels 'inbox' 'is:inbox AND from:bugzilla'
> sup-cmd add --labels 'sent' < email
This is great!
BTW is there any hope to reach a kind of concensus of a nice CLI API with
notmuch people?
--
Nicolas Pouillard
http://nicolaspouillard.fr
_______________________________________________
Sup-devel mailing list
Sup-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [sup-devel] now in next: sup-cmd
2010-03-04 13:10 ` Nicolas Pouillard
@ 2010-03-04 18:25 ` Carl Worth
2010-03-05 8:40 ` Nicolas Pouillard
0 siblings, 1 reply; 5+ messages in thread
From: Carl Worth @ 2010-03-04 18:25 UTC (permalink / raw)
To: Nicolas Pouillard, Rich Lane, sup-devel
[-- Attachment #1.1: Type: text/plain, Size: 1731 bytes --]
On Thu, 04 Mar 2010 05:10:39 -0800 (PST), Nicolas Pouillard <nicolas.pouillard@gmail.com> wrote:
> > sup-cmd count 'is:inbox'
> > sup-cmd query --offset 10 --limit 5 'is:unread'
> > sup-cmd label --add-labels 'bugs' --remove-labels 'inbox' 'is:inbox AND from:bugzilla'
> > sup-cmd add --labels 'sent' < email
>
> This is great!
>
> BTW is there any hope to reach a kind of concensus of a nice CLI API with
> notmuch people?
It seems to me, at least, like that would be a worthwhile effort.
I still consider the notmuch UI young enough that it's still quite
flexible. And I'm here on the sup list if we want to talk here.
For reference, the rough equivalent of the above commands in notmuch
would be (with footnotes where things don't match exactly):
notmuch count 'tag:inbox'
notmuch search 'tag:unread' [*]
notmuch tag +bugs -inbox 'tag:inbox AND from:bugzilla'
notmuch new [**]
So, I obviously switched from "label" to "tag" when I moved from sup to
notmuch. But I do like the "is:" prefix---I can easily see adding that
at least.
-Carl
[*] Notmuch currently doesn't have an equivalent of --offset and --limit
but did have --first and --max-threads for a while, (and we'll probably
be adding the same feature back again). The names of "offset" and "limit"
sound good to me.
[**] "notmuch new" is certainly only a very poor approximation of
"sup-cmd add". The notmuch cli does not currently have any way to add an
explicit file, (instead, "notmuch new" simply finds all new, renamed,
and deleted files within the mail store). By the way, what's the
semantic for "sup-cmd add" when it accepts a message on stdin? How is
the message content every returned later?
[-- Attachment #1.2: Type: application/pgp-signature, Size: 189 bytes --]
[-- Attachment #2: Type: text/plain, Size: 143 bytes --]
_______________________________________________
Sup-devel mailing list
Sup-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [sup-devel] now in next: sup-cmd
2010-03-04 18:25 ` Carl Worth
@ 2010-03-05 8:40 ` Nicolas Pouillard
2010-03-10 0:08 ` Carl Worth
0 siblings, 1 reply; 5+ messages in thread
From: Nicolas Pouillard @ 2010-03-05 8:40 UTC (permalink / raw)
To: Carl Worth, Rich Lane, sup-devel
On Thu, 04 Mar 2010 10:25:06 -0800, Carl Worth <cworth@cworth.org> wrote:
> On Thu, 04 Mar 2010 05:10:39 -0800 (PST), Nicolas Pouillard <nicolas.pouillard@gmail.com> wrote:
> > > sup-cmd count 'is:inbox'
> > > sup-cmd query --offset 10 --limit 5 'is:unread'
> > > sup-cmd label --add-labels 'bugs' --remove-labels 'inbox' 'is:inbox AND from:bugzilla'
> > > sup-cmd add --labels 'sent' < email
> >
> > This is great!
> >
> > BTW is there any hope to reach a kind of concensus of a nice CLI API with
> > notmuch people?
>
> It seems to me, at least, like that would be a worthwhile effort.
>
> I still consider the notmuch UI young enough that it's still quite
> flexible. And I'm here on the sup list if we want to talk here.
>
> For reference, the rough equivalent of the above commands in notmuch
> would be (with footnotes where things don't match exactly):
>
> notmuch count 'tag:inbox'
> notmuch search 'tag:unread' [*]
> notmuch tag +bugs -inbox 'tag:inbox AND from:bugzilla'
> notmuch new [**]
About the sup-cmd label vs notmuch tag commands, I prefer the notmuch syntax.
Moreover an alias could be added to both to unify between label and tag.
> So, I obviously switched from "label" to "tag" when I moved from sup to
> notmuch. But I do like the "is:" prefix---I can easily see adding that
> at least.
Yes please add the is: prefix too, tag: was added to sup.
Regards,
--
Nicolas Pouillard
http://nicolaspouillard.fr
_______________________________________________
Sup-devel mailing list
Sup-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [sup-devel] now in next: sup-cmd
2010-03-05 8:40 ` Nicolas Pouillard
@ 2010-03-10 0:08 ` Carl Worth
0 siblings, 0 replies; 5+ messages in thread
From: Carl Worth @ 2010-03-10 0:08 UTC (permalink / raw)
To: Nicolas Pouillard, Rich Lane, sup-devel; +Cc: notmuch
[-- Attachment #1.1: Type: text/plain, Size: 509 bytes --]
In a recent thread on the sup mailing list there was discussion of the
similarities of the recently-added sup-cmd command-line interface with
that of notmuch. And there was at least one proposal for adding some
syntax to notmuch:
On Fri, 05 Mar 2010 00:40:27 -0800 (PST), Nicolas Pouillard <nicolas.pouillard@gmail.com> wrote:
> Yes please add the is: prefix too, tag: was added to sup.
I've just added this to notmuch. So you can now search for "is:unread"
as a synonym for "tag:unread".
Have fun,
-Carl
[-- Attachment #1.2: Type: application/pgp-signature, Size: 189 bytes --]
[-- Attachment #2: Type: text/plain, Size: 143 bytes --]
_______________________________________________
Sup-devel mailing list
Sup-devel@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-03-10 0:16 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-04 7:48 [sup-devel] now in next: sup-cmd Rich Lane
2010-03-04 13:10 ` Nicolas Pouillard
2010-03-04 18:25 ` Carl Worth
2010-03-05 8:40 ` Nicolas Pouillard
2010-03-10 0:08 ` Carl Worth
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox