Exclude Elm source files from SBT binary distribution

I use the Elm integration module for Scala / Play projects known as sbt-elm in conjunction with the Play Framework,

I notice that in addition to the file elmMain.jscreated by the command elm-make, all .elm source files fall into the directory target/web/public/main/elm. I am not sure if this is the expected behavior; perhaps this is the normal operation of the SbtWeb pipeline; but this means that ultimately the binary distribution contains the Elm source code, which is not really needed at runtime.

To optimize the deployment of my application, I would like to exclude Elm source files from distribution artifacts.

Should I look for a way to prevent copying .elm files to target/web/public/main directory; or look for a way to prevent the placement of .elm files in distribution artifacts? How can i do this?

Thank you very much for your attention and for any recommendations that you could offer.

+4
source share
1 answer

I support sbt-elm, thank you for raising this issue, and unfortunately I do not have an immediate solution for this. So I opened the Github question, which you can see here: https://github.com/choucrifahed/sbt-elm/issues/13

Cheers, Choucri

+1
source

Source: https://habr.com/ru/post/1677429/


All Articles