hynek / hatch-fancy-pypi-readme

Fancy PyPI READMEs with Hatch
MIT License
156 stars 10 forks source link

Add $HFPR_VERSION substitution #39

Closed hynek closed 10 months ago

hynek commented 10 months ago

This allows to include the package version in the PyPI readme.

Does this make sense @ofek?

ofek commented 10 months ago

Makes sense, however since this isn't an environment variable where we would have to be cognizant of conflicts, why not $PROJECT_VERSION?

hynek commented 10 months ago

Cool, thanks!

henryiii commented 10 months ago

Would it be possible to give this a default? Scikit-build-core is using this so adding a new required argument broke the plugin. Ideally we should finish dynamic-metadata and then support that directly instead of wrapping it. I can work around it, just would have been nice.

henryiii commented 10 months ago

FYI, the dynamic-metadata spec currently doesn't have a way to access other metadata values. I wonder if it would be worth trying? It would also be important to make sure version was computed before the other values - in fact, I think it only makes sense for other plugins to be able to see the version, since otherwise you'd need to declare dependencies and topologically sort.

ofek commented 10 months ago
hynek commented 10 months ago

Aw sorry you need a default for build_text? I can do a 24.1 tomorrow when I’m sober again.