git - How to deploy gulp on production server -


when building website (for sake of clarity html/js website) use gulp compile , concat files placed in build/ folder.

the folder structure looks this:

├── assets │   ├── images │   ├── javascripts │   │   └── app.js │   └── stylesheets │       └── style.scss ├── bower.json ├── build │   ├── bower_components │   ├── images │   ├── index.html │   ├── scripts.min.js │   └── styles.min.css ├── gulpfile.js ├── index.html ├── node_modules │   ├── gulp-module-1 │   └── gulp-module-2 ├── package.json └── readme 

if include these files in git repo, of changes committed twice. is: change in assets/stylesheets/style.scss lead change in build/styles.min.css. however, if decide exclude build/ folder repository, need development tools on production server (i.e. gulp, npm, etc.) can difficult when there's limited privileges on production server. excluding assets/ folder not option lose source compiled files.

therefore question is: considered best practice deploy on production server? include build/ folder in repo, compile build/ folder on production server or there third solution?

although not might agree on best solution problem, think there third solution have missed , prefer. can build files on development machine, , deploy files built production server. copy action.

this way not need have development tools on server , not have build output in version control system.


Comments

Popular posts from this blog

html - Firefox flex bug applied to buttons? -

html - Missing border-right in select on Firefox -

c# - two queries in same method -