/***********************************************************************
* *
* This software is part of the ast package *
* Copyright (c) 1992-2011 AT&T Intellectual Property *
* and is licensed under the *
* Eclipse Public License, Version 1.0 *
* by AT&T Intellectual Property *
* *
* A copy of the License is available at *
* (with md5 checksum b35adb5213ca9657e911e9befb180842) *
* *
* Information and Software Systems Research *
* AT&T Research *
* Florham Park NJ *
* *
* Glenn Fowler <gsf@research.att.com> *
* David Korn <dgk@research.att.com> *
* *
***********************************************************************/
#pragma prototyped
/*
* uuencode
*/
static const char usage[] =
"[-?\n@(#)$Id: uuencode (AT&T Research) 2002-03-24 $\n]"
"[+NAME?uuencode - encode a binary file]"
"[+DESCRIPTION?\buuencode\b writes an encoded version of the named input"
" \afile\a, or the standard input if no file is specified, to the"
" standard output. \adecode-file\a is the name stored in the"
" encoded output header. This is the default name that will be used"
" by \buudecode\b when decoding.]"
"[h!:header?Write header and trailer sequences to the encoded output."
" The header for some encoding formats may contain file name and"
" access infomation.]"
"[l:list?List the encoding method names on the standard output.]"
"[o:output?Write the output data into \afile\a instead of the standard"
" output.]:[file]"
"[t:text?The input file is a text file that requires \\n => \\r\\n translation"
" on encoding.]"
"[x:method?Specifies the encoding \amethod\a:]:[method]{\fmethods\f}"
"[b?Equivalent to \b--method=binhex\b.]"
"[m?Equivalent to \b--method=mime\b.]"
"[q?Equivalent to \b--method=quoted-printable\b.]"
"[u?Equivalent to \b--method=ucb\b.]"
"\n"
"\n[ [ file ] decode-file ]\n"
"\n"
"[+SEE ALSO?\bmailx\b(1), \buudecode\b(1)]"
;
#include <ast.h>
#include <uu.h>
#include <error.h>
#include <option.h>
static int
{
switch (*s)
{
case 'm':
break;
}
return 0;
}
int
{
char* encoding;
char* epath;
char* ipath;
char* opath;
encoding = 0;
for (;;)
{
{
case 'b':
case 'm':
case 'q':
case 'u':
buf[1] = 0;
continue;
case 'h':
continue;
case 'l':
exit(0);
case 'o':
continue;
case 't':
continue;
case 'x':
{
exit(0);
}
continue;
case ':':
continue;
case '?':
continue;
}
break;
}
{
}
{
if (!ipath)
if (!opath)
}
return error_info.errors != 0;
}