path: root/doc
diff options
authorSergey Poznyakoff <gray@gnu.org.ua>2015-01-21 14:53:33 +0200
committerSergey Poznyakoff <gray@gnu.org.ua>2015-01-21 14:56:15 +0200
commit03c5b9aac73c6a70b1c67f467bbd484d2a532f10 (patch)
tree33f32c496f86708cce8c6b914a08ece723ba72ee /doc
parent5fe918d1f84af9b1f70deb152bf20d0b8a296524 (diff)
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')
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
- [\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\-\-delimiter=\fISTRING\fR]\
+ [\fB\-\-names\fR]\
+ [\fB\-\-quote\fR]\
+ [\fB\-\-type\fR]\
@@ -48,10 +52,6 @@ with \fIKEY\fR and a colon.
The utility must be run from a EC2 instance.
-\fB\-N\fR, \fB\-\-no\-names
-Don't print key names. This option takes effect only if at least one
-\fIKEY\fR is given.
\fB\-b\fR, \fB\-\-base=\fIURL\fR
Base URL to use, instead of
.BR .
@@ -61,9 +61,41 @@ Increase debugging level.
\fB\-p\fR, \fB\-\-port=\fINUMBER\fR
Set remote port number, instead of the default \fB80\fR.
+Following option applies only when listing directories:
\fB\-r\fR, \fB\-\-recursive
List directories recursively.
+The options below configure output if at least one \fIKEY\fR is given:
+\fB\-D\fR, \fB\-\-delimiter=\fISTRING\fR
+Delimit output values with \fISTRING\fR. Default delimiter is a colon.
+\fB\-N\fR, \fB\-\-names
+Print key names.
+\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.
+\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.
+The order of printing is: key name, type, value.
\fB\-V\fR, \fB\-\-version\fR
Print program version.
@@ -73,6 +105,39 @@ Give a concise help summary.
Give a short usage message.
+.SS Get instance ID
+$ ispeek /meta-data/instance-id
+.SS Print instance data
+$ ispeek /dynamic/instance-identity/document
+ "instanceId" : "i-deadbeef",
+ "billingProducts" : null,
+ ...
+.SS Read availability region and instance type
+$ ispeek /dynamic/instance-identity/document region instanceType
+.SS Same, including key names and types in the output
+$ ispeek -NT /dynamic/instance-identity/document region instanceType
+.SS Recursively list the contents of \fB/meta\-data/iam\fR:
+$ ispeek \-r meta\-data/iam
.BR eclat (1).

Return to:

Send suggestions and report system problems to the System administrator.