Search code examples
cabalyesodstackage

`stack build` a fresh `yesod init` not store executable into `dist/build`


When I used cabal build I found the yesod executable into dist/build directory but now, using stack build I found this into

./.stack-work/install/x86_64-linux/lts-3.1/7.10.2/bin/Test02
./.stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/Test02
./.stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/Test02/Test02

I cannot find the reason (some cabal/stack behavior change, my fault, ...).

I prefer use dist/build instead versioned paths to script out my deploy.

Thank you!


Solution

  • The case of deployments can be handled with the --copy-bins --local-bin-path somedir flags, which will have the executables copied to the target directory.