0.1.0 • Published 9 years ago
grunt-cdn-heroku-var v0.1.0
grunt-cdn-heroku-var
Generate CDN information from Bower and save it in a Heroku environment variable.
Getting Started
This plugin requires Grunt ~0.4.5
If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:
npm install grunt-cdn-heroku-var --save-dev
Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:
grunt.loadNpmTasks('grunt-cdn-heroku-var');
The "cdn_heroku_var" task
Overview
In your project's Gruntfile, add a section named cdn_heroku_var
to the data object passed into grunt.initConfig()
.
grunt.initConfig({
cdn_heroku_var: {
options: {
bower_location: 'test/bower.json',
heroku_app_name: 'tsf-pix-beta',
templates: {
'jquery': [{
url_template: '//cdnjs.cloudflare.com/ajax/libs/jquery/{{VERSION}}/jquery.min.js',
type: 'js'
}],
'angular': [{
url_template: '//cdnjs.cloudflare.com/ajax/libs/angular.js/{{VERSION}}/angular.min.js',
type: 'js'
}]
}
}
}
});
0.1.0
9 years ago