Skip to content

Latest commit

 

History

History
executable file
·
76 lines (57 loc) · 3.74 KB

tasks.md

File metadata and controls

executable file
·
76 lines (57 loc) · 3.74 KB

Gulp

The build system of this project is based on Gulp, to automate the development and build workflow.

The various tasks described here are defined in modules located in the gulp/ folder. You can read more about how to customize them and define your own tasks in the Gulp documentation.

Default task

gulp

Build and optimize the current project, ready for deployment. This includes linting as well as image, script, stylesheet and HTML optimization and minification.

Main tasks

Task Description
serve Launch a web server with live reload and open app in browser.
serve:dist Launch a web server using dist files with live reload and open app in browser.
build Build and optimize the current project, ready for deployment. This includes linting as well as image, script, stylesheet and HTML optimization and minification.
clean Delete temporary files and dist files.

When building the application, you can specify the target environment using the flag --environment <name>.

The default build environment is production. See this documentation for more details about multiple build environments management.

You can disable opening automatically your default browser when using the serve commands by using the flag --skip-open.

Tests

Task Description
test Launch unit tests using karma and jasmine.
test:auto Launch karma server and trigger unit tests after each change in project file.
protractor Launch e2e tests using protractor.
protractor:dist Launch e2e tests using protractor, using dist files.
webdriver:update Download/Update selenium standalone and chromedriver.
webdriver:standalone Launch a standalone selenium server.

Translations

Task Description
translations Generate translations file in .tmp that will be used by server.
translations:extract Extract Messages from Code and Templates to template.pot.

TypeScript

Task Description
scripts Convert all *.ts found in project to js in the temporary folder.
tsd Download and update all TypeScript definitions for Bower dependencies.
tsd:restore Download TypeScript definitions according to tsd.json.
tsd:clean Delete downloaded TypeScript definitions.

Build and assets

Task Description
build:source Build and optimize all source files, excluding assets.
partials Put all .html found in project folder + in temporary folder in a template cache file.
styles Generate main CSS file using project main style file.
fonts Copy fonts from bower dependencies in dist folder.
images Compress images (using imagemin) then copy them in dist folder.
other Copy project fonts and other misc files in dist folder.
extra Copy extra non-project files as specified in gulpfile.config.js.
clean:dist Clean the dist folder.

When building your app, you can use the --debug flag with any build task to skip the minification process. This can be useful to debug your production builds.