Added usage screen
This commit is contained in:
parent
a3491d5fe8
commit
4d9f3c9ca5
26
src/false.c
26
src/false.c
|
@ -1,5 +1,5 @@
|
||||||
/* $Id$ */
|
/* $Id$ */
|
||||||
/* Copyright (c) 2007 Pierre Pronchery <khorben@defora.org> */
|
/* Copyright (c) 2009 Pierre Pronchery <khorben@defora.org> */
|
||||||
/* This file is part of DeforaOS Unix utils */
|
/* This file is part of DeforaOS Unix utils */
|
||||||
/* utils is not free software; you can redistribute it and/or modify it under
|
/* utils is not free software; you can redistribute it and/or modify it under
|
||||||
* the terms of the Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
* the terms of the Creative Commons Attribution-NonCommercial-ShareAlike 3.0
|
||||||
|
@ -16,8 +16,28 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* main */
|
#include <unistd.h>
|
||||||
int main(void)
|
#include <stdio.h>
|
||||||
|
|
||||||
|
|
||||||
|
/* usage */
|
||||||
|
static int _usage(void)
|
||||||
{
|
{
|
||||||
|
fputs("Usage: false\n", stderr);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* main */
|
||||||
|
int main(int argc, char * argv[])
|
||||||
|
{
|
||||||
|
int o;
|
||||||
|
|
||||||
|
while((o = getopt(argc, argv, "")) != -1)
|
||||||
|
switch(o)
|
||||||
|
{
|
||||||
|
default:
|
||||||
|
return _usage();
|
||||||
|
}
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
24
src/true.c
24
src/true.c
|
@ -16,8 +16,28 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* main */
|
#include <unistd.h>
|
||||||
int main(void)
|
#include <stdio.h>
|
||||||
|
|
||||||
|
|
||||||
|
/* usage */
|
||||||
|
static int _usage(void)
|
||||||
{
|
{
|
||||||
|
fputs("Usage: true\n", stderr);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* main */
|
||||||
|
int main(int argc, char * argv[])
|
||||||
|
{
|
||||||
|
int o;
|
||||||
|
|
||||||
|
while((o = getopt(argc, argv, "")) != -1)
|
||||||
|
switch(o)
|
||||||
|
{
|
||||||
|
default:
|
||||||
|
return _usage();
|
||||||
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user