mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ramkumar Ramachandra <artagnon@gmail.com>
To: LKML <linux-kernel@vger.kernel.org>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Subject: [PATCH 1/2] perf completion: complete 'perf kvm'
Date: Wed, 11 Dec 2013 16:04:15 +0530	[thread overview]
Message-ID: <1386758056-24618-2-git-send-email-artagnon@gmail.com> (raw)
In-Reply-To: <1386758056-24618-1-git-send-email-artagnon@gmail.com>

Currently, there is no way to enumerate the subcommands under 'perf
kvm', so hardcode them.

Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
---
 tools/perf/perf-completion.sh | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/tools/perf/perf-completion.sh b/tools/perf/perf-completion.sh
index 4949488..496e2ab 100644
--- a/tools/perf/perf-completion.sh
+++ b/tools/perf/perf-completion.sh
@@ -121,6 +121,10 @@ __perf_main ()
 	elif [[ $prev == "-e" && "${words[1]}" == @(record|stat|top) ]]; then
 		evts=$($cmd list --raw-dump)
 		__perfcomp_colon "$evts" "$cur"
+	# List subcommands for 'perf kvm'
+	elif [[ $prev == "kvm" ]]; then
+		subcmds="top record report diff buildid-list stat"
+		__perfcomp_colon "$subcmds" "$cur"
 	# List long option names
 	elif [[ $cur == --* ]];  then
 		subcmd=${words[1]}
-- 
1.8.5.rc0.5.g70ebc73.dirty


  reply	other threads:[~2013-12-11 10:35 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-11 10:34 [PATCH 0/2] Completion for " Ramkumar Ramachandra
2013-12-11 10:34 ` Ramkumar Ramachandra [this message]
2013-12-11 19:50   ` [PATCH 1/2] perf completion: complete " 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
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=1386758056-24618-2-git-send-email-artagnon@gmail.com \
    --to=artagnon@gmail.com \
    --cc=acme@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome