/* $Header: version.c,v 2.0 86/09/17 15:40:11 lwall Exp $
 *
 * $Log:	version.c,v $
 * Revision 2.0  86/09/17  15:40:11  lwall
 * Baseline for netwide release.
 * 
 */

#include "EXTERN.h"
#include "common.h"
#include "util.h"
#include "INTERN.h"
#include "patchlevel.h"
#include "version.h"

void my_exit();

/* Print out the version number and die. */

void
version()
{
    fprintf(stderr, "Patch version %s\n", PATCH_VERSION);
    my_exit(0);
}

void
usage()
{
    fprintf(stderr, "\nPatch version %s\n", PATCH_VERSION);
    fprintf(stderr, "\n\
Usage: %s [options] [origfile [patchfile]] [+ [options] [origfile]]...\n",
			Argv[0]);
    fprintf(stderr, "\n\
Options:\n\
       [-ceEflnNRsStuv] [-b backup-ext] [-B backup-prefix] [-d directory]\n\
       [-D symbol] [-F max-fuzz] [-o out-file] [-p[strip-count]]\n\
       [-r rej-name] [-V {numbered,existing,simple}] [--context]\n\
       [--prefix=backup-prefix] [--suffix=backup-ext] [--ifdef=symbol]\n\
       [--directory=directory] [--ed] [--fuzz=max-fuzz] [--force] [--batch]\n\
       [--ignore-whitespace] [--forward] [--reverse] [--output=out-file]\n");
		fprintf(stderr, "\
       [--strip[=strip-count]] [--normal] [--reject-file=rej-name] [--skip]\n\
       [--remove-empty-files] [--quiet] [--silent] [--unified] [--version]\n\
       [--version-control={numbered,existing,simple}]\n");
    my_exit(0);
}
