cabal icon indicating copy to clipboard operation
cabal copied to clipboard

Add support for setting custom project file in cabal script-metadata

Open jneira opened this issue 5 years ago • 0 comments

Hi, in haskell-ide-engine there exist an script to build the project using shake. Actually the script has to be ran with cabal this way:

cabal v2-run install.hs --project-file install/shake.project <target>

I think @power-fungus mentioned that maybe the cabal script feature could be improved adding the option to set a custom project file in the script metadata and be able to run it simply with:

 cabal v2-run install.hs <target>

adding in the script somewhat like:

{- cabal:
build-depends:
    base
  , hie-install
project-file: install/shake.project
-}

I've not found any issue about, sorry if it already exists.

This one is related with #5698 cause you could set all available cabal.project-fields in the custom project file.

jneira avatar Nov 14 '19 07:11 jneira