I'm looking at how to create a section of code that works differently depending on BUILD type. One example of a problem that I'd like to solve:
I have internal resources, and I want the binary to use different versions whether I'm developing, or in production (e.g. serving minified JS resources vs the uncompressed debuggable version).
I could just add a flag to specify the difference between the two, but the serving model is different between the two (paths change, files can be combined, etc.).
I've done some searching, and it looks like the suggestions given were to use your build system to conditionally change packages. What's not clear to me is: Should I be writing two different packages with identical APIs, and use the build system to load one or the other into the same package name? Is there a way to attempt importing of a package, and not use it if it isn't part of the binary?
Thanks,
Doug