Skip to content

Help with hooking into poetry commands #190

Answered by nat-n
drjct asked this question in Q&A
Discussion options

You must be logged in to vote

hi @drjct,

Making a poetry task hook depend on the arguments to the poetry task is not supported today.

If you think this is important (and you're willing to help) then we could look into enhancing the poetry plugin to enable this. There's probably a way for the plugin to know what arguments we passed to the poetry install command (TBC), but then how to configure the hook to depend on this is a bit of a trickier question. Off the top of my head I can't think of an elegant solution.

An alternative approach would be perhaps to expose the poetry arguments to the hook task, either by forwarding them directly or setting an env var. Would that work for your use case?

I imagine something like:

[t…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@drjct
Comment options

Answer selected by drjct
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants