Wiki source for CommandXls


Show raw source

======Command xls======

====Name====
**xls** List files in a directory

====Synopsis====
xls [ [[SerializationOptions serialization options]] ] [options] [directory or file ...]

====Options====

||-l,-long||Long listing, include all file property attributes||
||-a,-all||List all files including hidden files (starts with ".")||
||-R,-recurse|| Recursively list all files and directories||


Supports the standard [ [[SerializationOptions serialization options]] ]

====Description====
Lists the files in the supplied directory or the current directory.
Outputs the list using the File schema.
If -l is given then all file attributes are written ( name,path,writable,readable,type,length) otherwise only name and path.

Example:
%%(shell)
xls .
%%
Result
%%(xml)
<command>
<file name="3rdparty" path="C:/p4dell/DEI/xmlsh/3rdparty"/>
<file name="bin" path="C:/p4dell/DEI/xmlsh/bin"/>
<file name="build.xml" path="C:/p4dell/DEI/xmlsh/build.xml"/>
<file name="doc" path="C:/p4dell/DEI/xmlsh/doc"/>
<file name="lib" path="C:/p4dell/DEI/xmlsh/lib"/>
<file name="license.txt" path="C:/p4dell/DEI/xmlsh/license.txt"/>
<file name="schemas" path="C:/p4dell/DEI/xmlsh/schemas"/>
<file name="src" path="C:/p4dell/DEI/xmlsh/src"/>
<file name="test" path="C:/p4dell/DEI/xmlsh/test"/>
<file name="unix" path="C:/p4dell/DEI/xmlsh/unix"/>
<file name="util" path="C:/p4dell/DEI/xmlsh/util"/>
<file name="win32" path="C:/p4dell/DEI/xmlsh/win32"/>
<file name="x.xquery" path="C:/p4dell/DEI/xmlsh/x.xquery"/>
<file name="_dist" path="C:/p4dell/DEI/xmlsh/_dist"/>
<file name="_out" path="C:/p4dell/DEI/xmlsh/_out"/>
</command>
%%


====Return Value====
Returns 0 if the directory exists and is read successfully, otherwise 1.
----
[[Commands]]
[[CategoryCommands]]
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki