31 #include <apr_pools.h>
32 #include <apr_getopt.h>
33 #include <apr_tables.h>
36 #ifndef DOXYGEN_SHOULD_SKIP_THIS
37 #define APR_WANT_STDIO
63 apr_getopt_t *os,
void *baton, apr_pool_t *pool);
67 #define SVN_OPT_MAX_ALIASES 3
70 #define SVN_OPT_MAX_OPTIONS 50
75 #define SVN_OPT_FIRST_LONGOPT_ID 256
146 const char *cmd_name);
161 const char *cmd_name);
175 const apr_getopt_option_t *
177 const apr_getopt_option_t *option_table,
190 const apr_getopt_option_t *
192 const apr_getopt_option_t *option_table);
206 const int *global_options);
252 const apr_getopt_option_t *opt_table,
268 const apr_getopt_option_t *opt_table,
281 const apr_getopt_option_t *opt,
305 const apr_getopt_option_t *options_table,
306 const int *global_options,
319 const apr_getopt_option_t *options_table,
333 const apr_getopt_option_t *options_table,
525 const apr_array_header_t *known_targets,
541 const apr_array_header_t *known_targets,
563 const apr_array_header_t *known_targets,
662 const char **truepath,
704 const char *pgm_name,
708 const char *version_footer,
711 const apr_getopt_option_t *option_table,
712 const int *global_options,
725 const char *pgm_name,
728 const char *version_footer,
731 const apr_getopt_option_t *option_table,
732 const int *global_options,
746 const char *pgm_name,
749 const char *version_footer,
752 const apr_getopt_option_t *option_table,
765 const char *pgm_name,
768 const char *version_footer,
771 const apr_getopt_option_t *option_table,
const apr_getopt_option_t * svn_opt_get_option_from_code(int code, const apr_getopt_option_t *option_table)
Return the first entry from option_table whose option code is code, or NULL if no match...
svn_boolean_t svn_opt_subcommand_takes_option(const svn_opt_subcommand_desc_t *command, int option_code)
Return TRUE iff subcommand command supports option option_code, else return FALSE.
const char * help
A brief string describing this command, for usage messages.
(rev of most recent change) - 1
void svn_opt_push_implicit_dot_target(apr_array_header_t *targets, apr_pool_t *pool)
If no targets exist in *targets, add `.
svn_error_t *( svn_opt_subcommand_t)(apr_getopt_t *os, void *baton, apr_pool_t *pool)
All subcommand procedures in Subversion conform to this prototype.
One element of a subcommand dispatch table.
apr_time_t date
the date of the revision
const char * aliases[3]
A list of alias names for this command (e.g., 'up' for 'update').
svn_opt_revision_t end
The last revision in the range.
svn_error_t * svn_opt_print_help4(apr_getopt_t *os, const char *pgm_name, svn_boolean_t print_version, svn_boolean_t quiet, svn_boolean_t verbose, const char *version_footer, const char *header, const svn_opt_subcommand_desc2_t *cmd_table, const apr_getopt_option_t *option_table, const int *global_options, const char *footer, apr_pool_t *pool)
Central dispatcher function for various kinds of help message.
svn_error_t * svn_opt_print_help(apr_getopt_t *os, const char *pgm_name, svn_boolean_t print_version, svn_boolean_t quiet, const char *version_footer, const char *header, const svn_opt_subcommand_desc_t *cmd_table, const apr_getopt_option_t *option_table, const char *footer, apr_pool_t *pool)
Same as svn_opt_print_help2(), but acts on svn_opt_subcommand_desc_t.
One element of a subcommand dispatch table.
void svn_opt_print_generic_help2(const char *header, const svn_opt_subcommand_desc2_t *cmd_table, const apr_getopt_option_t *opt_table, const char *footer, apr_pool_t *pool, FILE *stream)
Print a generic (not command-specific) usage message to stream.
svn_error_t * svn_opt_args_to_target_array(apr_array_header_t **targets_p, apr_getopt_t *os, const apr_array_header_t *known_targets, svn_opt_revision_t *start_revision, svn_opt_revision_t *end_revision, svn_boolean_t extract_revisions, apr_pool_t *pool)
The same as svn_opt_args_to_target_array2() except that, in addition, if extract_revisions is set...
const char * name
The full name of this command.
int svn_opt_parse_revision_to_range(apr_array_header_t *opt_ranges, const char *arg, apr_pool_t *pool)
Parse arg, where arg is "N" or "N:M", into a svn_opt_revision_range_t and push that onto opt_ranges...
const apr_getopt_option_t * svn_opt_get_option_from_code2(int code, const apr_getopt_option_t *option_table, const svn_opt_subcommand_desc2_t *command, apr_pool_t *pool)
Return pointer to an apr_getopt_option_t for the option whose option code is code, or NULL if no match.
void svn_opt_format_option(const char **string, const apr_getopt_option_t *opt, svn_boolean_t doc, apr_pool_t *pool)
Print an option opt nicely into a string allocated in pool.
int svn_opt_parse_revision(svn_opt_revision_t *start_revision, svn_opt_revision_t *end_revision, const char *arg, apr_pool_t *pool)
Set *start_revision and/or *end_revision according to arg, where arg is "N" or "N:M", like so:
.svn/entries current revision
svn_error_t * svn_opt_resolve_revisions(svn_opt_revision_t *peg_rev, svn_opt_revision_t *op_rev, svn_boolean_t is_url, svn_boolean_t notice_local_mods, apr_pool_t *pool)
Resolve peg revisions and operational revisions in the following way:
svn_opt_subcommand_t * cmd_func
The function this command invokes.
No revision information given.
svn_error_t * svn_opt_parse_path(svn_opt_revision_t *rev, const char **truepath, const char *path, apr_pool_t *pool)
Parse a working-copy path or URL in path, extracting any trailing revision specifier of the form "@re...
A revision, specified in one of svn_opt_revision_kind ways.
const char * aliases[3]
A list of alias names for this command (e.g., 'up' for 'update').
svn_opt_revision_value_t value
Extra data qualifying the kind.
A revision range, specified in one of svn_opt_revision_kind ways.
void svn_opt_subcommand_help2(const char *subcommand, const svn_opt_subcommand_desc2_t *table, const apr_getopt_option_t *options_table, apr_pool_t *pool)
Same as svn_opt_subcommand_help3(), but with global_options always NULL.
svn_revnum_t number
The revision number.
svn_error_t * svn_opt_print_help2(apr_getopt_t *os, const char *pgm_name, svn_boolean_t print_version, svn_boolean_t quiet, const char *version_footer, const char *header, const svn_opt_subcommand_desc2_t *cmd_table, const apr_getopt_option_t *option_table, const char *footer, apr_pool_t *pool)
Same as svn_opt_print_help3(), but with global_options always NULL.
const svn_opt_subcommand_desc2_t * svn_opt_get_canonical_subcommand2(const svn_opt_subcommand_desc2_t *table, const char *cmd_name)
Return the entry in table whose name matches cmd_name, or NULL if none.
svn_opt_revision_t start
The first revision in the range.
const char * name
The full name of this command.
svn_boolean_t svn_opt_subcommand_takes_option3(const svn_opt_subcommand_desc2_t *command, int option_code, const int *global_options)
Return TRUE iff subcommand command supports option option_code, else return FALSE.
struct svn_opt_subcommand_desc2_t::@0 desc_overrides[50]
A list of option help descriptions, keyed by the option unique enum (the 2nd field in apr_getopt_opti...
Subversion's data types.
svn_error_t * svn_opt_parse_num_args(apr_array_header_t **args_p, apr_getopt_t *os, int num_args, apr_pool_t *pool)
Parse num_args non-target arguments from the list of arguments in os->argv, return them as const char...
void svn_opt_subcommand_help3(const char *subcommand, const svn_opt_subcommand_desc2_t *table, const apr_getopt_option_t *options_table, const int *global_options, apr_pool_t *pool)
Get subcommand's usage from table, and print it to stdout.
svn_error_t * svn_opt_print_help3(apr_getopt_t *os, const char *pgm_name, svn_boolean_t print_version, svn_boolean_t quiet, const char *version_footer, const char *header, const svn_opt_subcommand_desc2_t *cmd_table, const apr_getopt_option_t *option_table, const int *global_options, const char *footer, apr_pool_t *pool)
Same as svn_opt_print_help4(), but with verbose always FALSE.
A revision value, which can be specified as a number or a date.
struct svn_opt_revision_t svn_opt_revision_t
A revision, specified in one of svn_opt_revision_kind ways.
enum svn_opt_revision_kind kind
See svn_opt_revision_kind.
svn_boolean_t svn_opt_subcommand_takes_option2(const svn_opt_subcommand_desc2_t *command, int option_code)
Same as svn_opt_subcommand_takes_option3(), but with NULL for global_options.
#define SVN_DEPRECATED
Macro used to mark deprecated functions.
svn_opt_subcommand_t * cmd_func
The function this command invokes.
int valid_options[50]
A list of options accepted by this command.
long int svn_revnum_t
About Special Files in Subversion.
svn_error_t * svn_opt_parse_revprop(apr_hash_t **revprops, const char *revprop_spec, apr_pool_t *pool)
Parse revprop key/value pair from revprop_spec (name[=value]) into revprops, making copies of both wi...
struct svn_opt_subcommand_desc_t svn_opt_subcommand_desc_t
One element of a subcommand dispatch table.
#define SVN_OPT_MAX_ALIASES
The maximum number of aliases a subcommand can have.
#define SVN_OPT_MAX_OPTIONS
The maximum number of options that can be accepted by a subcommand.
void svn_opt_subcommand_help(const char *subcommand, const svn_opt_subcommand_desc_t *table, const apr_getopt_option_t *options_table, apr_pool_t *pool)
Same as svn_opt_subcommand_help2(), but acts on svn_opt_subcommand_desc_t.
const char * help
A brief string describing this command, for usage messages.
void svn_opt_print_generic_help(const char *header, const svn_opt_subcommand_desc_t *cmd_table, const apr_getopt_option_t *opt_table, const char *footer, apr_pool_t *pool, FILE *stream)
Same as svn_opt_print_generic_help2(), but acts on svn_opt_subcommand_desc_t.
int valid_options[50]
A list of options accepted by this command.
int svn_boolean_t
YABT: Yet Another Boolean Type.
svn_opt_revision_kind
Various ways of specifying revisions.
svn_error_t * svn_opt_args_to_target_array3(apr_array_header_t **targets_p, apr_getopt_t *os, const apr_array_header_t *known_targets, apr_pool_t *pool)
Pull remaining target arguments from os into *targets_p, converting them to UTF-8, followed by targets from known_targets (which might come from, for example, the "--targets" command line option), which are already in UTF-8.
svn_error_t * svn_opt_args_to_target_array2(apr_array_header_t **targets_p, apr_getopt_t *os, const apr_array_header_t *known_targets, apr_pool_t *pool)
This is the same as svn_opt_args_to_target_array3() except that it silently ignores paths that have t...
struct svn_opt_subcommand_desc2_t svn_opt_subcommand_desc2_t
One element of a subcommand dispatch table.
const svn_opt_subcommand_desc_t * svn_opt_get_canonical_subcommand(const svn_opt_subcommand_desc_t *table, const char *cmd_name)
Return the entry in table whose name matches cmd_name, or NULL if none.
union svn_opt_revision_value_t svn_opt_revision_value_t
A revision value, which can be specified as a number or a date.
struct svn_opt_revision_range_t svn_opt_revision_range_t
A revision range, specified in one of svn_opt_revision_kind ways.
svn_error_t * svn_opt_parse_all_args(apr_array_header_t **args_p, apr_getopt_t *os, apr_pool_t *pool)
Parse all remaining arguments from os->argv, return them as const char * in *args_p, without doing any UTF-8 conversion.
rev of most recent change