haskell / haskell/cabal

Componentwise hooks

Open
#7,350 5 comments 0 reactions 0 assignees View on GitHub
Cabal: hooks
Dominant language
Haskell
Stars
1.7k
Forks
750
Avg merge
4d 3h
Merged PRs (30d)
28

Description

[I have a use case](https://github.com/haskell/cabal/issues/6795) for running some random `IO` action just before each component is built. It is important that my action is run interleaved with the build itself, since the `IO` action for a component may require the build artifacts of other components that are earlier in the dependency list. The `IO` action returns an edited `BuildInfo`, which is then passed to the normal build hook.

I have a prototype implementation at https://github.com/gergoerdi/clashilator/blob/c2561e8465ba235aa4836e3bfae35f84fa578d26/src/Clash/Clashilator/Cabal.hs. I'm not too happy with how deeply it has to fiddle with Cabal internals, so it would be better if this, or something similar to this, was exposed via the Cabal API.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.