Beta Changelogs #3100
epage
announced in
Information
Beta Changelogs
#3100
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
v3.0.0-beta.5 (2021-10-18)
BREAKING CHANGES
unicode_helptounicodeto encompass more functionalityApp::replaceis now gated behindunstable-replacederiverequirementclap::ArgEnumclap::Argsclap::FromArgMatchesclap::IntoAppclap::Subcommandclap::Clap=>clap::ParserApp::generate_usage=>App::render_usageAppSettings::DisableVersionForSubcommandsis now default behaviourAppSettings::ColoredHelp: we are now relying solely on thecolorfeature flag andApp::colormethodAppSettings::StrictUtf8is now default behaviourAppSettings::AllowInvalidUtf8in favor ofArgSettings::AllowInvalidUtf8AppSettings::UnifiedHelpMessageis now default behaviourAppSettings::ColorAlwaysin favor ofApp::colorAppSettings::ColorNeverin favor ofApp::colorAppSettings::ColorAutoin favor ofApp::colorApp::get_flagsApp::get_positionals_with_no_headingApp::get_flags_with_no_headingApp::get_opts_with_no_headingApp::stop_custom_headingsin favor ofApp:help_heading(None)Error::with_descriptionin favor ofApp::errorArgEnum::as_argin favor ofArgEnum::to_arg_valueGenerator::all_subcommandsGenerator::find_subcommand_with_pathGenerator::subcommandsGenerator::shorts_and_visible_aliasesGenerator::longs_and_visible_aliasesGenerator::flagsArgEnum::VARIANTSin favor ofArgEnum::value_variantsclap::clap_app!in favor of other buildersApp::get_possible_valuesreturnsOption<&[ArgValue]>nowRegexRefis now an enum also allowingRegexSetto be usedclap_generate::Generator::file_nameandclap_generate::Generator::generatenow take&selfclap_generate::generateandclap_generate::generate_tonow takesGeneratoras first argumentFeatures
clap::ArgValueto denote information about possible values for argsclap::ColorChoiceto specify color setting for the appAppSettings::AllowInvalidUtf8ForExternalSubcommandsAppSettings::Multicallbehindunstable-multicallfeatureArgSettings::AllowInvalidUtf8ArgEnum::value_variantsArgEnum::to_arg_valueApp::colorApp::errorApp::get_long_aboutApp::get_help_headingArg::is_positionalv3.0.0-beta.4 (2021-08-14)
Minimum Required Rust
claprequiresrustc 1.54.0or greater.BREAKING CHANGES
Added
unicode_help,envfeatures.env:Arg::envArg::env_osArg::hide_env_valuesArgSettings::HideEnvValuesArg::settingsin favor ofArg::setting(Setting1 | Setting2)Arg::multiplein favour ofArg::multiple_valuesandArg::multiple_occurrencesAppSettings::DisableHelpFlags=>AppSettings::DisableHelpFlagAppSettings::DisableVersion=>AppSettings::DisableVersionFlagAppSettings::VersionlessSubcommands=>AppSettings::DisableVersionForSubcommands(changed again 3.0.0-beta.5)ErrorKind::MissingArgumentOrSubcommand=>ErrorKind::DisplayHelpOnMissingArgumentOrSubcommandArgSettings::AllowEmptyValueschanging toArgSettings::ForbidEmptyValuesAppSettings::GlobalVersionrenamed toAppSettings::PropagateVersionand it is not appliedglobally anymore
Arg::env,Arg::env_os,Arg::last,Arg::require_equals,Arg::allow_hyphen_values,Arg::hide_possible_values,Arg::hide_default_value,Arg::hide_env_values,Arg::case_insensitiveandArg::multiple_valuesdoes not setArgSettings::TakesValueanymoreArg::require_delimiterdoes not setArgSettings::TakesValueandArgSettings::UseValueDelimiteranymore
Arg::require_equalsdoes not disallow empty values anymoreArg::default_value_if,Arg::default_value_if_os,Arg::default_value_ifs,Arg::default_value_ifs_osnow takes the default value parameter as an optionArg::index,Arg::number_of_values,Arg::min_values,Arg::max_valuesnow takesusizeArg::value_delimiternow acceptscharinstead of&strArgMatches::is_presentdoes not handle subcommand names anymoreArgSettings::TakesValueclap_generate::generate_tonow returnsResult<PathBuf, io::Error>@groupinclap_app!now needs:instead of=>appandargobjects inyamlnow allow unknown keys if_has_metadatais setFeatures
clap_generate::Shellclap::ArgsbehindderivefeatureApp::licenseArg::get_long_aboutArg::get_envArg::get_default_valuesArg::hide_envArg::required_if_eq_allArg::forbid_empty_valuesArg::max_occurrencesArgMatches::grouped_values_ofcrate_license!Error::printAppSettings::UseLongFormatForHelpSubcommandAppSettings::IgnoreErrorsAppSettings::InferLongArgsArgSettings::HideEnvEnhancements
v3.0.0-beta.2 (2020-09-18)
BREAKING CHANGES
From<&yaml_rust::yaml::Hash>forArgGroupApp::write_versionin favor ofwrite!(w, App::render_version)App::write_long_versionin favor ofwrite!(w, App::render_long_version)Error::causein favor of<Error as Display>::to_string_clap_count_exprs!App::set_term_width=>App::term_widthArg::from_yaml=>Arg::fromArg::with_name=>Arg::newArg::required_if=>Arg::required_if_eqArg::required_ifs=>Arg::required_if_eq_anyArg::required_unless=>Arg::required_unless_presentArg::required_unless_one=>Arg::required_unless_present_anyArg::required_unless_all=>Arg::required_unless_present_allArgGroup::from_yaml=>ArgGroup::fromArgGroup::with_name=>ArgGroup::newErrorKind::HelpDisplayed=>ErrorKind::DisplayHelpErrorKind::VersionDisplayed=>ErrorKind::DisplayVersionApp::print_help&App::print_long_helpnow returnstd::io::ResultApp::write_help&App::write_long_helpnow returnstd::io::ResultError::infonow is of typeVec<String>instead ofOption<Vec<String>>ArgMatches::subcommandnow returnsOption<(&str, &ArgMatches)>shortin#[clap()]now acceptscharinstead of&strFeatures
Indicesthat is returned byArgMatches::indices_of@global_settingfor app's macro builderArg::default_missing_valueArg::default_missing_value_osArg::default_missing_valuesArg::default_missing_values_osArg::short_aliasArg::short_aliasesArg::visible_short_aliasArg::visible_short_aliasesArg::value_hintArg::validator_regex(gated behindregexfeature)App::subcommand_placeholderApp::before_long_helpApp::after_long_helpEnhancements
help_headingdefined onArgnow has higher priority thanAppwrap_helpfeature is not enabledv3.0.0-beta.1 (2020-05-03)
Minimum Required Rust
claprequiresrustc 1.40.0or greater.BREAKING CHANGES
Added
std,cargo,derivefeatures.Gated behind
cargo:crate_name!crate_version!crate_authors!crate_description!app_from_crate!Removed
SubCommandin favor ofAppSubCommand::with_name=>App::newSubCommand::from_yaml=>App::fromShell(changed again in 3.0.0-beta.4)App::with_defaultsApp::version_messagein favor ofApp::mut_argApp::version_shortin favor ofApp::mut_argApp::help_messagein favor ofApp::mut_argApp::help_shortin favor ofApp::mut_argApp::arg_from_usagein favor ofApp::argApp::args_from_usagein favor ofApp::argsApp::settingsin favor ofApp::setting(Setting1 | Setting2)App::unset_settingsin favor ofApp::unset_setting(Setting1 | Setting2)App::global_settingsin favor ofApp::global_setting(Setting1 | Setting2)App::gen_completionsin favor of TODO:App::gen_completions_toin favor of TODO:Arg::empty_valuesin favor of TODO:ArgMatches::usagein favor ofApp::generate_usagearg_enum!in favor ofArgEnumderive macro.value_t!in favor ofArgMatches::value_of_tvalue_t_or_exit!in favor ofArgMatches::value_of_t_or_exitvalues_t!in favor ofArgMatches::values_of_tvalues_t_or_exit!in favor ofArgMatches::values_of_t_or_exitRemoved Settings
AppSettings::PropagateGlobalValuesDownArgSettings::Globalin favor ofArg::globalmethodArgSettings::Multiplein favor ofArgSettings::MultipleValuesandArgSettings::MultipleOccurrencesRenamed Methods
App::from_yaml=>App::fromApp::arg_from_usage=>App::argApp::help=>App::override_helpApp::usage=>App::override_usageApp::template=>App::help_templateApp::get_matches_safe=>App::try_get_matchesApp::get_matches_from_safe=>App::try_get_matches_fromApp::get_matches_from_safe_borrow=>App::try_get_matches_from_mutArg::help=>Arg::aboutArg::from_usage=>Arg::fromArg::set=>Arg::settingArg::unset=>Arg::unset_settingRenamed Settings
ArgSettings::CaseInsensitive=>ArgSettings::IgnoreCaseArgSettings::AllowLeadingHyphen=>ArgSettings::AllowHyphenValuesArgSettings::EmptyValues=>ArgSettings::AllowEmptyValuesRenamed Fields
Error::message=>Error::causeChanged
App::write_helpis now a mutable reference instance method (takes&mut self)Arg::shortnow acceptscharinstead of&strArg::validatornow takes first argument asFn(&str) -> Result<O, E: ToString>instead ofFn(String) -> Result<(), String>Arg::validator_osnow takes first argument asFn(&OsStr) -> Result<O, OsString>instead ofFn(&OsStr) -> Result<(), OsString>Removed support for
{n}in help textIn usage parser, for options
[name]... --option [val]results inArgSettings::MultipleOccurrencesbut
--option [val]...results inArgSettings::MultipleValuesandArgSettings::MultipleOccurrences.Before both resulted in the same thing.
AppandArgnow need only one lifetimeAllowing empty values is no longer the default (changed again in 3.0.0-beta.4)
UseValueDelimiteris no longer the defaultApp::override_usageno longer implies\twhich allows multi lined usagesFeatures
App::replaceApp::get_matches_mutApp::mut_argApp::unset_global_settingApp::help_headingApp::stop_custom_headingsArg::exclusiveArg::multiple_valuesArg::multiple_occurrencesArg::help_headingArg::settings(changed again in 3.0.0-beta.4)AppSettings::HelpRequiredAppSettings::NoAutoHelpAppSettings::NoAutoVersionArgSettings::SubcommandPrecedenceOverArgEnhancements
App::argandApp::argsmore genericclap_app!macro to make it support more wider use casesBeta Was this translation helpful? Give feedback.
All reactions