1
2
3
4
5
6 using System;
7
8 void PrintHelp()
9 {
10 Console.Out() << "Usage: ls [options] [<file>...]" << endl() << endl();
11 Console.Out() << "List directory content." << endl() << endl();
12 Console.Out() << "Options:" << endl() << endl();
13 Console.Out() << "--help | -h" << endl();
14 Console.Out() << " Print help and exit." << endl() << endl();
15 Console.Out() << "--all | -a" << endl();
16 Console.Out() << " List also file names starting with '.'" << endl() << endl();
17 Console.Out() << "--long | -l" << endl();
18 Console.Out() << " Use long listing format." << endl() << endl();
19 Console.Out() << "--human-readable | -m" << endl();
20 Console.Out() << " Human-readable size." << endl() << endl();
21 Console.Out() << "--sort=inode | -I" << endl();
22 Console.Out() << " Sort by inode number." << endl() << endl();
23 Console.Out() << "--sort=nlinks | -N" << endl();
24 Console.Out() << " Sort by number of links." << endl() << endl();
25 Console.Out() << "--sort=user | -U" << endl();
26 Console.Out() << " Sort by user name." << endl() << endl();
27 Console.Out() << "--sort=size | -S" << endl();
28 Console.Out() << " Sort by file size." << endl() << endl();
29 Console.Out() << "--sort=time | -T" << endl();
30 Console.Out() << " Sort by file modication time." << endl() << endl();
31 Console.Out() << "--reverse | -r" << endl();
32 Console.Out() << " Reverse sort order." << endl() << endl();
33 Console.Out() << "--fs | -f" << endl();
34 Console.Out() << " Show filesystem number." << endl() << endl();
35 Console.Out() << "--inode | -i" << endl();
36 Console.Out() << " Show inode number." << endl() << endl();
37 Console.Out() << "--access" << endl();
38 Console.Out() << " Show access." << endl() << endl();
39 Console.Out() << "--nlinks | -n" << endl();
40 Console.Out() << " Show number of links." << endl() << endl();
41 Console.Out() << "--user | -u" << endl();
42 Console.Out() << " Show the user name of the file owner." << endl() << endl();
43 Console.Out() << "--uid" << endl();
44 Console.Out() << " Show the user ID of the file owner." << endl() << endl();
45 Console.Out() << "--group | -g" << endl();
46 Console.Out() << " Show group name of the file owner." << endl() << endl();
47 Console.Out() << "--gid" << endl();
48 Console.Out() << " Show the group ID of the file owner." << endl() << endl();
49 Console.Out() << "--size | -s" << endl();
50 Console.Out() << " Show the size of the file." << endl() << endl();
51 Console.Out() << "--ctime | -c" << endl();
52 Console.Out() << " Show the inode modification time." << endl() << endl();
53 Console.Out() << "--mtime | -t" << endl();
54 Console.Out() << " Show the file modification time." << endl() << endl();
55 Console.Out() << "--atime | -e" << endl();
56 Console.Out() << " Show the file access time." << endl() << endl();
57 }