Casini
Casini

Reputation: 33

Cabal: installing a Bash script alongside a library

I have a non-Haskell executable (bash script) that I would like cabal to install in ~/.cabal/bin along with my Haskell library. How can I achieve this simply with cabal?

Edit: as I mentioned in a comment below: installing specifically to ~/.cabal/bin isn't crucial, I just need the script to be available in my library.

Upvotes: 1

Views: 171

Answers (1)

Daniel Wagner
Daniel Wagner

Reputation: 153172

You can use cabal's data-files field to have some extra files installed, and then use the getDataFileName function created by cabal to retrieve the file. Details are available in the documentation and this blog post.

Upvotes: 2

Related Questions