diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2015-01-21 14:53:33 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2015-01-21 14:56:15 +0200 |
commit | 03c5b9aac73c6a70b1c67f467bbd484d2a532f10 (patch) | |
tree | 33f32c496f86708cce8c6b914a08ece723ba72ee /doc | |
parent | 5fe918d1f84af9b1f70deb152bf20d0b8a296524 (diff) | |
download | eclat-03c5b9aac73c6a70b1c67f467bbd484d2a532f10.tar.gz eclat-03c5b9aac73c6a70b1c67f467bbd484d2a532f10.tar.bz2 |
Improve ispeek
* doc/ispeek.1: Update.
* grecs: Upgrade
* src/ispeek-cl.opt: New options.
* src/ispeek.c: Optionally print variable types,
quote strings, etc.
Add heuristics to determine whether the obtained data are
a directory listing or a text.
Diffstat (limited to 'doc')
-rw-r--r-- | doc/ispeek.1 | 77 |
1 files changed, 71 insertions, 6 deletions
diff --git a/doc/ispeek.1 b/doc/ispeek.1 index 2cfba44..1ebc9f9 100644 --- a/doc/ispeek.1 +++ b/doc/ispeek.1 @@ -18,11 +18,15 @@ ispeek \- EC2 instance store lister .SH SYNOPSIS \fBispeek\fR\ - [\fB\-Ndr\fR]\ + [\fB\-NQTdr\fR]\ + [\fB\-D\fR \fISTRING\fR]\ [\fB\-b\fR \fIURL\fR]\ [\fB\-p\fR \fINUMBER\fR]\ - [\fB\-\-no\-names\fR]\ [\fB\-\-base\-url=\fIURL\fR]\ + [\fB\-\-delimiter=\fISTRING\fR]\ + [\fB\-\-names\fR]\ + [\fB\-\-quote\fR]\ + [\fB\-\-type\fR]\ [\fB\-\-port=\fINUMBER\fR]\ \fIPATH\fR\ [\fIKEY\fR...] @@ -48,10 +52,6 @@ with \fIKEY\fR and a colon. The utility must be run from a EC2 instance. .SH OPTIONS .TP -\fB\-N\fR, \fB\-\-no\-names -Don't print key names. This option takes effect only if at least one -\fIKEY\fR is given. -.TP \fB\-b\fR, \fB\-\-base=\fIURL\fR Base URL to use, instead of .BR http://169.254.169.254/latest . @@ -61,9 +61,41 @@ Increase debugging level. .TP \fB\-p\fR, \fB\-\-port=\fINUMBER\fR Set remote port number, instead of the default \fB80\fR. +.PP +Following option applies only when listing directories: .TP \fB\-r\fR, \fB\-\-recursive List directories recursively. +.PP +The options below configure output if at least one \fIKEY\fR is given: +.TP +\fB\-D\fR, \fB\-\-delimiter=\fISTRING\fR +Delimit output values with \fISTRING\fR. Default delimiter is a colon. +.TP +\fB\-N\fR, \fB\-\-names +Print key names. +.TP +\fB\-Q\fR, \fB\-\-quote\fR +Quote string values. String values will be enclosed in +double-quotes. Double-quote and backslash characters appearing within +strings will be escaped with backslashes. +.TP +\fB\-T\fR, \fB\-\-type\fR +Print type character. Type characters are: +.BR 0 , +for \fBnull\fR values, +.BR b , +for booleans, +.BR n , +for numeric values, +.BR s , +for strings , +.BR a , +for arrays, and +.BR o , +for objects. +.PP +The order of printing is: key name, type, value. .TP \fB\-V\fR, \fB\-\-version\fR Print program version. @@ -73,6 +105,39 @@ Give a concise help summary. .TP \fB\-\-usage\fR Give a short usage message. +.SH EXAMPLES +.SS Get instance ID +.EX +$ ispeek /meta-data/instance-id +i-deadbeef +.EE +.SS Print instance data +.EX +$ ispeek /dynamic/instance-identity/document +{ + "instanceId" : "i-deadbeef", + "billingProducts" : null, + ... +.EE +.SS Read availability region and instance type +.EX +$ ispeek /dynamic/instance-identity/document region instanceType +eu-west-1 +m3.xlarge +.EE +.SS Same, including key names and types in the output +.EX +$ ispeek -NT /dynamic/instance-identity/document region instanceType +region:s:eu-west-1 +instanceType:s:m3.xlarge +.SS Recursively list the contents of \fB/meta\-data/iam\fR: +.EX +$ ispeek \-r meta\-data/iam +/meta-data/iam/info +/meta-data/iam/security-credentials/ +/meta-data/iam/security-credentials/user +.EE + .SH "SEE ALSO" .BR eclat (1). .SH AUTHORS |