https://pantsbuild.org/ logo
b

bored-glass-58755

08/23/2022, 6:56 PM
I want to publish a wheel built using Pants to an internal hosting site. What changes are required in
pants.toml
?
e

enough-analyst-54434

08/23/2022, 7:13 PM
I think twine is the keyword you're missing. You can pass options to it here: https://www.pantsbuild.org/docs/reference-twine#section-args and here is a twine reference for upload args: https://twine.readthedocs.io/en/stable/ - looks like you want at least -r and maybe user / pass args too depending.
b

bored-glass-58755

08/23/2022, 7:19 PM
Is Twine the only way to publish to any Python repository? I am asking just in case if it’s not supported - I still have to find out about that though.
e

enough-analyst-54434

08/23/2022, 7:28 PM
I think so currently. Pants is very pluggable though.
🆗 1
1
b

bored-glass-58755

08/24/2022, 3:19 PM
I am looking at the first option (skip) on the link you shared: skip --[no-]twine-skip PANTS_TWINE_SKIP default: False Don't use Twine when running ./pants publish. This is confusing because if the skip default is
False
then it should mean that we don’t skip Twine. But here
skip=False
means that we do skip Twine.
h

hundreds-father-404

08/24/2022, 3:21 PM
That wording is confusing. It should be:
If set to True, don't use Twine when running
./pants publish
It defaults to
False
because by default you *probably want to publish. This is an opt-out
👍 1
5 Views