mirror of
https://github.com/clap-rs/clap
synced 2025-03-04 23:37:32 +00:00
docs: Update deprecation messages
- Some still referenced the clapng issue number - Some YAML ones were missed in the formatting clean up - I never updated the usage ones with the formatting clean up
This commit is contained in:
parent
4c807a0632
commit
9d7becca68
5 changed files with 9 additions and 9 deletions
|
@ -2331,7 +2331,7 @@ impl<'help> App<'help> {
|
|||
#[cfg(feature = "yaml")]
|
||||
#[deprecated(
|
||||
since = "3.0.0",
|
||||
note = "Maybe clap::Parser would fit your use case? (Issue #9)"
|
||||
note = "Deprecated in Issue #3087, maybe clap::Parser would fit your use case?"
|
||||
)]
|
||||
pub fn from_yaml(y: &'help Yaml) -> Self {
|
||||
#![allow(deprecated)]
|
||||
|
@ -2495,14 +2495,14 @@ impl<'help> App<'help> {
|
|||
}
|
||||
|
||||
/// Deprecated in [Issue #3086](https://github.com/clap-rs/clap/issues/3086), see [`arg!`][crate::arg!].
|
||||
#[deprecated(since = "3.0.0", note = "Replaced with `arg!`")]
|
||||
#[deprecated(since = "3.0.0", note = "Deprecated in Issue #3086, see `clap::arg!")]
|
||||
pub fn arg_from_usage(self, usage: &'help str) -> Self {
|
||||
#![allow(deprecated)]
|
||||
self.arg(Arg::from_usage(usage))
|
||||
}
|
||||
|
||||
/// Deprecated in [Issue #3086](https://github.com/clap-rs/clap/issues/3086), see [`arg!`][crate::arg!].
|
||||
#[deprecated(since = "3.0.0", note = "Replaced with `arg!`")]
|
||||
#[deprecated(since = "3.0.0", note = "Deprecated in Issue #3086, see `clap::arg!")]
|
||||
pub fn args_from_usage(mut self, usage: &'help str) -> Self {
|
||||
#![allow(deprecated)]
|
||||
for line in usage.lines() {
|
||||
|
|
|
@ -4609,7 +4609,7 @@ impl<'help> Arg<'help> {
|
|||
#[cfg(feature = "yaml")]
|
||||
#[deprecated(
|
||||
since = "3.0.0",
|
||||
note = "Maybe clap::Parser would fit your use case? (Issue #9)"
|
||||
note = "Deprecated in Issue #3087, maybe clap::Parser would fit your use case?"
|
||||
)]
|
||||
pub fn from_yaml(y: &'help Yaml) -> Self {
|
||||
#![allow(deprecated)]
|
||||
|
@ -4679,7 +4679,7 @@ impl<'help> Arg<'help> {
|
|||
}
|
||||
|
||||
/// Deprecated in [Issue #3086](https://github.com/clap-rs/clap/issues/3086), see [`arg!`][crate::arg!].
|
||||
#[deprecated(since = "3.0.0", note = "Replaced with `arg!`")]
|
||||
#[deprecated(since = "3.0.0", note = "Deprecated in Issue #3086, see `clap::arg!")]
|
||||
pub fn from_usage(u: &'help str) -> Self {
|
||||
UsageParser::from_usage(u).parse()
|
||||
}
|
||||
|
|
|
@ -442,7 +442,7 @@ impl<'help> ArgGroup<'help> {
|
|||
#[cfg(feature = "yaml")]
|
||||
#[deprecated(
|
||||
since = "3.0.0",
|
||||
note = "Maybe clap::Parser would fit your use case? (Issue #9)"
|
||||
note = "Maybe clap::Parser would fit your use case? (Issue #3087)"
|
||||
)]
|
||||
pub fn from_yaml(yaml: &'help Yaml) -> Self {
|
||||
Self::from(yaml)
|
||||
|
|
|
@ -39,7 +39,7 @@ pub use crate::derive::{ArgEnum, Args, FromArgMatches, IntoApp, Parser, Subcomma
|
|||
#[doc(hidden)]
|
||||
#[deprecated(
|
||||
since = "3.0.0",
|
||||
note = "Deprecated in Issue #9, maybe clap::Parser would fit your use case?"
|
||||
note = "Deprecated in Issue #3087, maybe clap::Parser would fit your use case?"
|
||||
)]
|
||||
pub use yaml_rust::YamlLoader;
|
||||
|
||||
|
@ -91,7 +91,7 @@ impl SubCommand {
|
|||
#[cfg(feature = "yaml")]
|
||||
#[deprecated(
|
||||
since = "3.0.0",
|
||||
note = "Deprecated in Issue #9, maybe clap::Parser would fit your use case?"
|
||||
note = "Deprecated in Issue #3087, maybe clap::Parser would fit your use case?"
|
||||
)]
|
||||
pub fn from_yaml(yaml: &yaml_rust::Yaml) -> App {
|
||||
#![allow(deprecated)]
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
#[cfg(feature = "yaml")]
|
||||
#[deprecated(
|
||||
since = "3.0.0",
|
||||
note = "Deprecated in Issue #9, maybe clap::Parser would fit your use case?"
|
||||
note = "Deprecated in Issue #3087, maybe clap::Parser would fit your use case?"
|
||||
)]
|
||||
#[macro_export]
|
||||
macro_rules! load_yaml {
|
||||
|
|
Loading…
Add table
Reference in a new issue