Permalink
Browse files

Fix #670. Add package.json and Gruntfile.js

  • Loading branch information...
1 parent cf35092 commit 597d5c7f36d4f77e18ef37275e441fd6110d5c85 @signalpoint committed Nov 29, 2015
Showing with 72 additions and 0 deletions.
  1. +40 −0 Gruntfile.js
  2. +32 −0 package.json
View
@@ -0,0 +1,40 @@
+var drupalgap_grunt_src = ['src/*.js', 'src/includes/*.inc.js', 'src/modules/*/*.js'];
+
+module.exports = function(grunt) {
+
+ // Project configuration.
+ grunt.initConfig({
+ pkg: grunt.file.readJSON('package.json'),
+ concat: {
+ options: {
+ banner: '/*! <%= pkg.name %> <%= grunt.template.today("yyyy-mm-dd") %> */\n'
+ /*separator: ';',*/
+ },
+ dist: {
+ src: drupalgap_grunt_src,
+ dest: 'bin/<%= pkg.name %>.js'
+ }
+ },
+ uglify: {
+ options: {
+ banner: '/*! <%= pkg.name %> <%= grunt.template.today("yyyy-mm-dd") %> */\n'
+ },
+ build: {
+ src: drupalgap_grunt_src,
+ dest: 'bin/<%= pkg.name %>.min.js'
+ }
+ },
+ watch: {
+ files: drupalgap_grunt_src,
+ tasks: ['concat', 'uglify'] // @see http://stackoverflow.com/a/20740693/763010
+ }
+ });
+
+ grunt.loadNpmTasks('grunt-contrib-concat');
+ grunt.loadNpmTasks('grunt-contrib-uglify');
+ grunt.loadNpmTasks('grunt-contrib-watch');
+
+ // Default task(s).
+ grunt.registerTask('default', ['concat', 'uglify', 'watch']);
+
+};
View
@@ -0,0 +1,32 @@
+{
+ "version": "7.0.0",
+ "name": "drupalgap",
+ "description": "An application development kit for Drupal 7.",
+ "main": "index.html",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/signalpoint/DrupalGap"
+ },
+ "keywords": [
+ "drupal",
+ "jquerymobile",
+ "phonegap"
+ ],
+ "license": "GNU",
+ "author": "Tyler Frankenstein <email@tylerfrankenstein.com> (http://tylerfrankenstein.com/)",
+ "bugs": {
+ "url": "https://github.com/signalpoint/DrupalGap/issues"
+ },
+ "homepage": "http://drupalgap.org",
+ "devDependencies": {
+ "grunt": "^0.4.5",
+ "grunt-contrib-concat": "^0.5.1",
+ "grunt-contrib-uglify": "^0.9.1",
+ "grunt-contrib-watch": "^0.6.1",
+ "shelljs": "^0.2.6",
+ "tmp": "0.0.23"
+ },
+ "scripts": {
+
+ }
+}

0 comments on commit 597d5c7

Please sign in to comment.