How to include library dependency in Mix release without starting library Application


I’m trying to include a library dependency in a mix release without having it start its Application.
If I set runtime: false or app: false in the dependency config to prevent the library Application from being started, then the library doesn’t get included in the build, thus making the library modules unavailable for the release.

The reason for this is that I forked a library that starts its own Application to make the Supervisor available so that I can put it under my own supervision tree, but I left the Application in for backwards compatibility.
So I want to prevent the Application from being started, but I still want to use the library in the release.

This seems like something that should be easy since it should also be possible to do Application.start or Application.stop in case you want better control for when an Application is started.

Is this at all possible?

1 Like