Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FR: add a metadata hook #1

Closed
ofek opened this issue Jul 3, 2022 · 10 comments · Fixed by #5
Closed

FR: add a metadata hook #1

ofek opened this issue Jul 3, 2022 · 10 comments · Fixed by #5

Comments

@ofek
Copy link
Contributor

ofek commented Jul 3, 2022

https://hatch.pypa.io/dev/plugins/metadata-hook/reference/

I wanted make a PR to switch https://github.com/squidfunk/mkdocs-material/blob/master/setup.py

I could do a custom but this would fit nicely here 🙂

@agoose77
Copy link
Owner

@ofek thanks! Could you explain the motivation for this, i.e. what does a metadata hook do? :)

@agoose77
Copy link
Owner

The part that I don't understand is what this would add vs. using the existing version plugin. Is it to enable us to do something like https://github.com/facelessuser/pymdown-extensions/blob/bcfc7af83957871341674264e45f85cc7c6c7ea9/hatch_build.py#L38 ?

@ofek
Copy link
Contributor Author

ofek commented Jul 12, 2022

From OP: https://github.com/squidfunk/mkdocs-material/blob/7cb9d7b2b957cb64fee584e154005391c8ca0a63/setup.py#L42-L53

I was about to port it to Hatchling but realized it pulls many things from package.json

@agoose77
Copy link
Owner

agoose77 commented Sep 8, 2022

@ofek 2d72fb8 adds this tentatively. Could you try it out with your repository?

@ofek
Copy link
Contributor Author

ofek commented Sep 9, 2022

Works! Try python -m build on https://github.com/ofek/mkdocs-material/tree/modernize-metadata

@agoose77
Copy link
Owner

agoose77 commented Sep 9, 2022

Fab, that helped me catch a mistake on my part!

@agoose77
Copy link
Owner

agoose77 commented Sep 9, 2022

@ofek
Copy link
Contributor Author

ofek commented Sep 9, 2022

Thanks!!!

@ofek
Copy link
Contributor Author

ofek commented Sep 10, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants