From 75799445780e7d4ca390d233cb9a144f82e3c1a3 Mon Sep 17 00:00:00 2001 From: Todd Decker Date: Thu, 4 Aug 2022 11:31:19 -0500 Subject: [PATCH 1/2] This change adds an example to the authors attribute in the manifest. It is submitted to clarify the documenation for new folks such as myself. See the forum issue linked below which prompted this change since the error message the compiler issues is not clear for new folks. https://users.rust-lang.org/t/compile-error-when-adding-authors-to-cargo-toml/79383 Thank you for considering this contribution. It's my first so go easy on me please! :-) --- src/doc/src/reference/manifest.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/doc/src/reference/manifest.md b/src/doc/src/reference/manifest.md index e239042dcfc..601df425216 100644 --- a/src/doc/src/reference/manifest.md +++ b/src/doc/src/reference/manifest.md @@ -107,13 +107,18 @@ breaking change. #### The `authors` field - -The optional `authors` field lists people or organizations that are considered +The optional `authors` field lists in an array the people or organizations that are considered the "authors" of the package. The exact meaning is open to interpretation — it may list the original or primary authors, current maintainers, or owners of the package. An optional email address may be included within angled brackets at the end of each author entry. +```toml +[package] +# ... +authors = ["Graydon Hoare", "Fnu Lnu "] +``` + This field is only surfaced in package metadata and in the `CARGO_PKG_AUTHORS` environment variable within `build.rs`. It is not displayed in the [crates.io] user interface. From 51dc6fb3c49d22084c28a84819b97767075ddb7b Mon Sep 17 00:00:00 2001 From: "P. Todd Decker" Date: Wed, 21 Sep 2022 15:28:50 -0500 Subject: [PATCH 2/2] Update src/doc/src/reference/manifest.md Adding newline back per @weihanglo's input (thank you) Co-authored-by: Weihang Lo --- src/doc/src/reference/manifest.md | 1 + 1 file changed, 1 insertion(+) diff --git a/src/doc/src/reference/manifest.md b/src/doc/src/reference/manifest.md index 601df425216..7bc6f14b01f 100644 --- a/src/doc/src/reference/manifest.md +++ b/src/doc/src/reference/manifest.md @@ -107,6 +107,7 @@ breaking change. #### The `authors` field + The optional `authors` field lists in an array the people or organizations that are considered the "authors" of the package. The exact meaning is open to interpretation — it may list the original or primary authors, current maintainers, or owners of the