Switch branches/tags
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
30 lines (25 sloc) 820 Bytes

Build Vars

Inject variables into your app's Config constants at build time. For instance build numbers which is essential for Continuous Integration and delivery purposes. Consult our Continuous Integration Guide for a full sample use case.

Adding the --buildVars flag to gulp watch, gulp build or any gulp task that runs gulp build implicitly, for instance:

gulp watch --buildVars="build:12343,key:value"

will result in Config constants that look like this:

'use strict';
.constant('Config', {

  ENV: {
    // ..

  BUILD: {
    'build': '12343',
    'keys2': 'value2'


Of course this works nicely in conjunction with environments as well.