From: David Ahern <dsahern@gmail.com>
To: Ramkumar Ramachandra <artagnon@gmail.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/2] perf completion: complete 'perf kvm'
Date: Thu, 12 Dec 2013 09:53:07 -0700 [thread overview]
Message-ID: <52A9E9F3.4090801@gmail.com> (raw)
In-Reply-To: <CALkWK0m=0pJQoCKx+Xc+Do_JwX=NjqwA_wjM8W=spTQm5h5DHQ@mail.gmail.com>
On 12/12/13, 2:09 AM, Ramkumar Ramachandra wrote:
> David Ahern wrote:
>> I don't like the command list being embedded in the completion script. It
>> will get outdated quickly.
>
> I could introduce a
>
> $ perf kvm --list-cmds
>
> but that would mean a
>
> printf("record report stat ..")
>
> in builtin-kvm.c, because the commands aren't in any sort of array.
>
That would work -- perhaps a #define or string near
const char * const kvm_usage[] = {
"perf kvm [<options>] {top|record|report|diff|buildid-list|stat}",
NULL
};
Building kvm_usage from the string would better - only 1 place listing
the commands.
David
next prev parent reply other threads:[~2013-12-12 16:53 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-11 10:34 [PATCH 0/2] Completion for 'perf kvm' Ramkumar Ramachandra
2013-12-11 10:34 ` [PATCH 1/2] perf completion: complete " Ramkumar Ramachandra
2013-12-11 19:50 ` Arnaldo Carvalho de Melo
2013-12-11 19:56 ` David Ahern
2013-12-12 9:09 ` Ramkumar Ramachandra
2013-12-12 16:53 ` David Ahern [this message]
2013-12-12 17:26 ` [PATCH] perf kvm: introduce --list-cmds for use by scripts Ramkumar Ramachandra
2013-12-13 4:32 ` David Ahern
2013-12-16 13:16 ` Arnaldo Carvalho de Melo
2013-12-16 15:27 ` [tip:perf/core] perf completion: Complete 'perf kvm' tip-bot for Ramkumar Ramachandra
2013-12-11 10:34 ` [PATCH 2/2] perf tools: ignore files generated by " Ramkumar Ramachandra
2013-12-11 20:01 ` Arnaldo Carvalho de Melo
2013-12-12 9:05 ` [PATCH v2] " Ramkumar Ramachandra
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=52A9E9F3.4090801@gmail.com \
--to=dsahern@gmail.com \
--cc=acme@redhat.com \
--cc=artagnon@gmail.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.