Skip to content
This repository was archived by the owner on Jun 30, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .jshintrc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"globals" : {
"mendix" : false,
"mx" : false,
"logger" : false
"logger" : false,
"ga" : false
},

// Relaxing
Expand Down
233 changes: 0 additions & 233 deletions Gruntfile.js

This file was deleted.

86 changes: 86 additions & 0 deletions Gulpfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
// Generated on 2016-11-08 using generator-mendix 2.0.1 :: git+https://github.com/mendix/generator-mendix.git
/*jshint -W069,-W097*/
"use strict";

// In case you seem to have trouble starting Mendix through `gulp modeler`, you might have to set the path to the Mendix application, otherwise leave both values as they are
var MODELER_PATH = null;
var MODELER_ARGS = "/file:{path}";

/********************************************************************************
* Do not edit anything below, unless you know what you are doing
********************************************************************************/
var gulp = require("gulp"),
zip = require("gulp-zip"),
del = require("del"),
newer = require("gulp-newer"),
gutil = require("gulp-util"),
gulpif = require("gulp-if"),
jsonTransform = require("gulp-json-transform"),
intercept = require("gulp-intercept"),
argv = require("yargs").argv,
widgetBuilderHelper = require("widgetbuilder-gulp-helper");

var pkg = require("./package.json"),
paths = widgetBuilderHelper.generatePaths(pkg),
xmlversion = widgetBuilderHelper.xmlversion;

gulp.task("default", function() {
gulp.watch("./src/**/*", ["compress"]);
gulp.watch("./src/**/*.js", ["copy:js"]);
});

gulp.task("clean", function () {
return del([
paths.WIDGET_TEST_DEST,
paths.WIDGET_DIST_DEST
], { force: true });
});

gulp.task("compress", ["clean"], function () {
return gulp.src("src/**/*")
.pipe(zip(pkg.name + ".mpk"))
.pipe(gulp.dest(paths.TEST_WIDGETS_FOLDER))
.pipe(gulp.dest("dist"));
});

gulp.task("copy:js", function () {
return gulp.src(["./src/**/*.js"])
.pipe(newer(paths.TEST_WIDGETS_DEPLOYMENT_FOLDER))
.pipe(gulp.dest(paths.TEST_WIDGETS_DEPLOYMENT_FOLDER));
});

gulp.task("version:xml", function () {
return gulp.src(paths.PACKAGE_XML)
.pipe(xmlversion(argv.n))
.pipe(gulp.dest("./src/"));
});

gulp.task("version:json", function () {
return gulp.src("./package.json")
.pipe(gulpif(typeof argv.n !== "undefined", jsonTransform(function(data) {
data.version = argv.n;
return data;
}, 2)))
.pipe(gulp.dest("./"));
});

gulp.task("icon", function (cb) {
var icon = (typeof argv.file !== "undefined") ? argv.file : "./icon.png";
console.log("\nUsing this file to create a base64 string: " + gutil.colors.cyan(icon));
gulp.src(icon)
.pipe(intercept(function (file) {
console.log("\nCopy the following to your " + pkg.name + ".xml (after description):\n\n" + gutil.colors.cyan("<icon>") + file.contents.toString("base64") + gutil.colors.cyan("<\\icon>") + "\n");
cb();
}));
});

gulp.task("folders", function () {
paths.showPaths(); return;
});

gulp.task("modeler", function (cb) {
widgetBuilderHelper.runmodeler(MODELER_PATH, MODELER_ARGS, paths.TEST_PATH, cb);
});

gulp.task("build", ["compress"]);
gulp.task("version", ["version:xml", "version:json"]);
34 changes: 18 additions & 16 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,34 +1,36 @@
{
"name": "GoogleAnalytics",
"version": "3.3.2",
"version": "3.3.3",
"description": "",
"license": "",
"author": "",
"private": true,
"dependencies": {},
"devDependencies": {
"grunt": "1.0.1",
"grunt-contrib-clean": "^1.0.0",
"grunt-contrib-compress": "^1.2.0",
"grunt-contrib-copy": "^1.0.0",
"grunt-contrib-watch": "^1.0.0",
"grunt-contrib-csslint": "^1.0.0",
"grunt-newer": "^1.1.1",
"node-base64-image": "^0.1.0",
"shelljs": "^0.7.0",
"xml2js": "^0.4.15",
"semver": "^5.1.0",
"node-mendix-modeler-path": "https://github.com/JelteMX/node-mendix-modeler-path/archive/v1.0.0.tar.gz"
"del": "^2.2.2",
"gulp": "^3.9.1",
"gulp-if": "^2.0.1",
"gulp-intercept": "^0.1.0",
"gulp-json-transform": "^0.4.2",
"gulp-newer": "^1.3.0",
"gulp-util": "^3.0.7",
"gulp-zip": "^3.2.0",
"widgetbuilder-gulp-helper": "https://github.com/JelteMX/widgetbuilder-gulp-helper/archive/1.0.1.tar.gz",
"yargs": "^6.0.0"
},
"engines": {
"node": ">=0.12.0"
"node": ">=5"
},
"generatorVersion": "1.3.5",
"generatorVersion": "2.0.1",
"paths": {
"testProjectFolder": "./test/",
"testProjectFileName": "Test.mpr"
},
"scripts": {
"test": "grunt test"
"build": "node ./node_modules/gulp/bin/gulp build",
"version": "node ./node_modules/gulp/bin/gulp version",
"icon": "node ./node_modules/gulp/bin/gulp icon",
"folders": "node ./node_modules/gulp/bin/gulp folders",
"modeler": "node ./node_modules/gulp/bin/gulp modeler"
}
}
4 changes: 1 addition & 3 deletions src/GoogleAnalytics/widget/AdvancedPageTracker.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,4 @@ define("GoogleAnalytics/widget/AdvancedPageTracker", [
});
});

require(["GoogleAnalytics/widget/AdvancedPageTracker"], function () {
"use strict";
});
require(["GoogleAnalytics/widget/AdvancedPageTracker"]);
Loading