aboutsummaryrefslogtreecommitdiff
path: root/a8xd.c
diff options
context:
space:
mode:
Diffstat (limited to 'a8xd.c')
-rw-r--r--a8xd.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/a8xd.c b/a8xd.c
index f051c4b..e08e260 100644
--- a/a8xd.c
+++ b/a8xd.c
@@ -33,7 +33,8 @@ void die(const char *msg) {
}
void print_help(void) {
- printf("Usage: %s [-v] [file ...]\n", self);
+ printf("Usage: %s [-i] [-l limit] [-m] [-o offset] [-s [-]seek] [-u] [-v] [file]\n", self);
+ printf("With no [file], or '-', reads from stdin.\n");
}
int parse_num_arg(const char *arg) {
@@ -244,9 +245,10 @@ int main(int argc, char **argv) {
exit(0);
}
- while( (opt = getopt(argc, argv, "vimus:o:l:")) != -1) {
+ while( (opt = getopt(argc, argv, "vhimus:o:l:")) != -1) {
switch(opt) {
case 'v': verbose = 1; break;
+ case 'h': print_help(); exit(0); break;
case 'i': table = ics2utf; break;
case 'm': color = 0; break;
case 'u': word_format = "%04X"; byte_format = "%02X"; break;