Set environment variable during build
<p>I created an app with Angular-CLI and for debugging purposes would like to show some info in the app about the build that is running. For example, the git branch or build time, etc.</p>

<p>I could write a script that manipulates <code>src/environments/environment.ts</code> but I'm asking myself if there is a better way. Especially since that file is part of source control.</p>

<p>A switch on the Angular-CLI to overwrite a variable's value would be nice. Let's say the variables <code>environment.build</code> and <code>environment.time</code> are set to dummys in <code>environment.ts</code>. Then with <code>ng --env[build]=master --env[time]=201612130742</code> I'd overwrite those with the computed values.</p>

<p>But to my knowledge something like that doesn't exist?</p>