pcp
[Top] [All Lists]

Fwd: PCP metrics auto-completion in the command line

To: pcp@xxxxxxxxxxx
Subject: Fwd: PCP metrics auto-completion in the command line
From: Nathan Scott <nscott@xxxxxxxxxx>
Date: Mon, 11 May 2009 15:09:35 +1000 (EST)
In-reply-to: <20090511143636.71c70972@xxxxxxxxxx>
Enjoy!  Considering installing this to /etc/bash_completion.d -
anyone have any thoughts?

cheers.

----- Forwarded Message -----
From: "Roman Revyakin" <rrevyakin@xxxxxxxxxx>
Sent: Monday, May 11, 2009 2:36:36 PM GMT +10:00 Canberra / Melbourne / Sydney
Subject: PCP metrics auto-completion in the command line

Hi guys, 

I do not know how much each of of you guys interact with the
command-line PCP tools like pminfo or pmdumptext, in any case here's
what I find helpful: autocompletion of the PCP metrics in your command
line. (For Bash users only as of now, sorry). 

Untar the attached tarball in your home, and add the following lines to
your .bashrc 

if [ -d ~/.bash_completion.d ]
then
    for f in `ls ~/.bash_completion.d`
    do 
        source ~/.bash_completion.d/"$f"
    done 
fi

Try it out after sourcing your new .bashrc: 

pminfo -f aconex.<TAB> 

Autocompletion works for the following set of programs as of now: 

pminfo  
pmdumptext  
pmdumplog  
pmlogsummary  
pmstore  
pmval  

Enjoy, 
Roman 

-- 
Roman Revyakin
ETO Systems Engineer 
Aconex
The easy way to save time and money on your project

696 Bourke Street, Melbourne, Victoria, Australia
Tel: +61 3 9240 0200         Fax: +61 3 9240 0299 

-- 
Nathan

Attachment: pminfo_bash_completion.tgz
Description: application/compressed-tar

<Prev in Thread] Current Thread [Next in Thread>