From de866666a88d3819740351d5a5e720dacf367f23 Mon Sep 17 00:00:00 2001 From: Philip James <pjj@philipjohnjames.com> Date: Wed, 21 Feb 2018 10:23:34 -0800 Subject: [PATCH 1/3] Add and document the `project_urls` field. This field corresponds to https://packaging.python.org/specifications/core-metadata/#project-url-multiple-use and better documentation in the sampleproject will hopefully encourage use. --- setup.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/setup.py b/setup.py index 8b41ed7a..04406cc3 100644 --- a/setup.py +++ b/setup.py @@ -165,4 +165,16 @@ 'sample=sample:main', ], }, + + # List additional URLs that are relevant to your project as a dict. + # + # This field corresponds to the "Project-URL" metadata fields: + # https://packaging.python.org/specifications/core-metadata/#project-url-multiple-use + # + # Examples listed include a pattern for specifying where the package + # maintainers would like thanks given or funding support. + project_urls={ # Optional + 'funding': 'https://donate.pypi.org', + 'thanks': 'http://saythanks.io/to/example' + }, ) From 8fc690c911cf46a177484799c16b71e54f706e0e Mon Sep 17 00:00:00 2001 From: Philip James <pjj@philipjohnjames.com> Date: Wed, 21 Feb 2018 12:01:39 -0800 Subject: [PATCH 2/3] Document the relationship between dict key and link text, add more examples --- setup.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/setup.py b/setup.py index 04406cc3..3eff49b7 100644 --- a/setup.py +++ b/setup.py @@ -171,10 +171,14 @@ # This field corresponds to the "Project-URL" metadata fields: # https://packaging.python.org/specifications/core-metadata/#project-url-multiple-use # - # Examples listed include a pattern for specifying where the package - # maintainers would like thanks given or funding support. + # Examples listed include a pattern for specifying where the package tracks + # issues, where the source is hosted, where to say thanks to the package + # maintainers, and where to support the project financially. The key is + # what's used to render the link text on PyPI. project_urls={ # Optional - 'funding': 'https://donate.pypi.org', - 'thanks': 'http://saythanks.io/to/example' + 'Bug Reports': 'https://github.com/pypa/sampleproject/issues', + 'Funding': 'https://donate.pypi.org', + 'Say Thanks!': 'http://saythanks.io/to/example', + 'Source': 'https://github.com/pypa/sampleproject/', }, ) From d5dcff4b49a230ea27fb143fce123688138686a3 Mon Sep 17 00:00:00 2001 From: Philip James <pjj@philipjohnjames.com> Date: Wed, 21 Feb 2018 12:05:15 -0800 Subject: [PATCH 3/3] Fix trailing whitespace --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 3eff49b7..27227e0b 100644 --- a/setup.py +++ b/setup.py @@ -172,7 +172,7 @@ # https://packaging.python.org/specifications/core-metadata/#project-url-multiple-use # # Examples listed include a pattern for specifying where the package tracks - # issues, where the source is hosted, where to say thanks to the package + # issues, where the source is hosted, where to say thanks to the package # maintainers, and where to support the project financially. The key is # what's used to render the link text on PyPI. project_urls={ # Optional