Backbone-Marionette-Gulp Starter
An ES6-ready boilerplate for building Backbone/Marionette apps using Gulp.
Getting Started
1. Install gulp globally:
$ npm install --global gulp
2. Install project dependencies:
$ npm install
3. Run gulp
Start a local dev environment:
$ gulp
Generate a production build:
$ gulp production
4. Deployment
Download [settings.json](link to settings.json file goes here) and place in root directory.
The following command will deploy to AWS S3:
$ gulp deploy --[env]
This boilerplate assumes you've created a settings.json
file in the project root. This file should be (git)ignored as it contains sensitive information, i.e. AWS keys, etc. When deployment is finished, a Slack hook will be triggered in a channel of your choice. If you haven't heard of Slack, close Skype immediately and read about it.
Environment options
--dev
or--development
--qa
--stage
or--staging
--prod
or--production
One of these arguments is required to successfully deploy files to S3, i.e gulp deploy --staging
.
settings.json
:
Sample {
"default": {
"aws": {
"accessKeyId": "xxx",
"secretAccessKey": "xxx",
"basePath": "xxx",
"bucket": "madeinhaus"
},
"slack": {
"hook_url": "https://hooks.slack.com/services/xxx/xxx/xxx",
"username": "Arnold Scavonegger",
"message": "New build up on: "
}
}
}
Individual envs can have their own settings by adding a corresponding 'env': {...}
to the settings file, only those settings which are different from default need to be set.