Merge vendor changes to files that we've touched onto mainline.

(If only all import/merges were this trivial :-)
This commit is contained in:
Peter Wemm 1998-01-30 15:35:26 +00:00
parent a0c60322a8
commit b1408ba741
3 changed files with 47 additions and 8 deletions

View File

@ -800,6 +800,9 @@ void wrap_fromcvs_process_file PROTO ((const char *fileName));
void wrap_add_file PROTO((const char *file,int temp));
void wrap_add PROTO((char *line,int temp));
void wrap_send PROTO ((void));
#if defined(SERVER_SUPPORT) || defined(CLIENT_SUPPORT)
void wrap_unparse_rcs_options PROTO ((char **, int));
#endif /* SERVER_SUPPORT || CLIENT_SUPPORT */
/* Pathname expansion */
char *expand_path PROTO((char *name, char *file, int line));

View File

@ -204,15 +204,15 @@ static const char *const checkoutlist_contents[] = {
};
static const char *const cvswrappers_contents[] = {
"# This file describes wrappers and other binary files to CVS.\n",
"# This file affects handling of files based on their names.\n",
"#\n",
"# Wrappers are the concept where directories of files are to be\n",
"# treated as a single file. The intended use is to wrap up a wrapper\n",
"# into a single tar such that the tar archive can be treated as a\n",
"# single binary file in CVS.\n",
"# The -t/-f options allow one to treat directories of files\n",
"# as a single file, or to transform a file in other ways on\n",
"# its way in and out of CVS.\n",
"#\n",
"# To solve the problem effectively, it was also necessary to be able to\n",
"# prevent rcsmerge from merging these files.\n",
"# The -m option specifies whether CVS attempts to merge files.\n",
"#\n",
"# The -k option specifies keyword expansion (e.g. -kb for binary).\n",
"#\n",
"# Format of wrapper file ($CVSROOT/CVSROOT/cvswrappers or .cvswrappers)\n",
"#\n",
@ -222,10 +222,11 @@ static const char *const cvswrappers_contents[] = {
"# -f from cvs filter value: path to filter\n",
"# -t to cvs filter value: path to filter\n",
"# -m update methodology value: MERGE or COPY\n",
"# -k expansion mode value: b, o, kkv, &c\n",
"#\n",
"# and value is a single-quote delimited value.\n",
"#\n",
"# For example:\n",
"#*.gif -k 'b'\n",
NULL
};

View File

@ -3780,6 +3780,38 @@ serve_gzip_stream (arg)
buf_from_net = compress_buffer_initialize (buf_from_net, 1, level,
buf_from_net->memory_error);
}
/* Tell the client about RCS options set in CVSROOT/cvswrappers. */
static void
serve_wrapper_sendme_rcs_options (arg)
char *arg;
{
/* Actually, this is kind of sdrawkcab-ssa: the client wants
* verbatim lines from a cvswrappers file, but the server has
* already parsed the cvswrappers file into the wrap_list struct.
* Therefore, the server loops over wrap_list, unparsing each
* entry before sending it.
*/
char *wrapper_line = NULL;
wrap_setup ();
for (wrap_unparse_rcs_options (&wrapper_line, 1);
wrapper_line;
wrap_unparse_rcs_options (&wrapper_line, 0))
{
buf_output0 (buf_to_net, "Wrapper-rcsOption ");
buf_output0 (buf_to_net, wrapper_line);
buf_output0 (buf_to_net, "\012");;
free (wrapper_line);
}
buf_output0 (buf_to_net, "ok\012");
/* The client is waiting for us, so we better send the data now. */
buf_flush (buf_to_net, 1);
}
static void
serve_ignore (arg)
@ -4050,6 +4082,9 @@ struct request requests[] =
REQ_LINE("Argumentx", serve_argumentx, rq_essential),
REQ_LINE("Global_option", serve_global_option, rq_optional),
REQ_LINE("Gzip-stream", serve_gzip_stream, rq_optional),
REQ_LINE("wrapper-sendme-rcsOptions",
serve_wrapper_sendme_rcs_options,
rq_optional),
REQ_LINE("Set", serve_set, rq_optional),
#ifdef ENCRYPTION
# ifdef HAVE_KERBEROS