<commit_before>/*jshint node: true */

"use strict";

module.exports = function (grunt) {

	grunt.initConfig({
		pkg: grunt.file.readJSON("package.json"),
		exec: {
			tabfix: {
				// Cleanup whitespace according to http://contribute.jquery.org/style-guide/js/
				// (requires https://github.com/mar10/tabfix)
				cmd: "tabfix -t --line=UNIX -r -m *.js,*.css,*.html,*json,*.yaml -i node_modules ."
			},
			upload: {
				// FTP upload the demo files (requires https://github.com/mar10/pyftpsync)
				cmd: "pyftpsync --progress upload . ftp://www.wwwendt.de/tech/demo/jquery-contextmenu --delete-unmatched --omit dist,node_modules,.*,_* -x"
			}
		},
		qunit: {
			all: ["test/index.html"]
		},
		jshint: {
			files: [
				"Gruntfile.js",
				"jquery.contextmenu.js"
			],
			options: {
				jshintrc: ".jshintrc"
			}
		},
		uglify: {
			options: {
//				banner: "/*! <%= pkg.name %> v<%= pkg.version %> | <%= pkg.license %> */\n"
				banner: "/*! <%= pkg.title || pkg.name %> - v<%= pkg.version %> - " +
				"<%= grunt.template.today('yyyy-mm-dd') %> | " +
				"<%= pkg.homepage ? ' ' + pkg.homepage + ' | ' : '' %>" +
				" Copyright (c) <%= grunt.template.today('yyyy') %> <%= pkg.author.name %>;" +
				" Licensed <%= _.pluck(pkg.licenses, 'type').join(', ') %> */\n"
			},
			build: {
				src: "jquery.contextmenu.js",
//                dest: "build/jquery.contextmenu-<%= pkg.version %>.min.js"
				dest: "jquery.contextmenu.min.js"
			}
		},
		connect: {
			demo: {
				options: {
					port: 8080,
					base: "./",
					keepalive: true
				}
			}
		}
	});

	grunt.loadNpmTasks("grunt-contrib-connect");
	grunt.loadNpmTasks("grunt-contrib-jshint");
	grunt.loadNpmTasks("grunt-contrib-qunit");
	grunt.loadNpmTasks("grunt-contrib-uglify");
	grunt.loadNpmTasks("grunt-contrib-connect");
	grunt.loadNpmTasks("grunt-exec");

	// The 'ci' task is run on travis
	grunt.registerTask("server", ["connect:demo"]);
	grunt.registerTask("test", ["jshint",
								"qunit"]);
	grunt.registerTask("ci", ["test"]);
	grunt.registerTask("default", ["test"]);
	grunt.registerTask("build", ["exec:tabfix",
								 "test",
								 "uglify"]);
	grunt.registerTask("upload", ["build",
								  "exec:upload"]);
	grunt.registerTask("server", ["connect:demo"]);
};
<commit_msg>minor2<commit_after>/*jshint node: true */

"use strict";

module.exports = function (grunt) {

	grunt.initConfig({
		pkg: grunt.file.readJSON("package.json"),
		exec: {
			tabfix: {
				// Cleanup whitespace according to http://contribute.jquery.org/style-guide/js/
				// (requires https://github.com/mar10/tabfix)
				cmd: "tabfix -t --line=UNIX -r -m *.js,*.css,*.html,*json,*.yaml -i node_modules ."
			},
			upload: {
				// FTP upload the demo files (requires https://github.com/mar10/pyftpsync)
				cmd: "pyftpsync --progress upload . ftp://www.wwwendt.de/tech/demo/jquery-contextmenu --delete-unmatched --omit dist,node_modules,.*,_* -x"
			}
		},
		qunit: {
			all: ["test/index.html"]
		},
		jshint: {
			files: [
				"Gruntfile.js",
				"jquery.contextmenu.js"
			],
			options: {
				jshintrc: ".jshintrc"
			}
		},
		uglify: {
			options: {
				banner: "/*! <%= pkg.title || pkg.name %> - v<%= pkg.version %> - " +
				"<%= grunt.template.today('yyyy-mm-dd') %> | " +
				"<%= pkg.homepage ? ' ' + pkg.homepage + ' | ' : '' %>" +
				" Copyright (c) <%= grunt.template.today('yyyy') %> <%= pkg.author.name %>;" +
				" Licensed <%= _.pluck(pkg.licenses, 'type').join(', ') %> */\n"
			},
			build: {
				src: "jquery.contextmenu.js",
//                dest: "build/jquery.contextmenu-<%= pkg.version %>.min.js"
				dest: "jquery.contextmenu.min.js"
			}
		},
		connect: {
			demo: {
				options: {
					port: 8080,
					base: "./",
					keepalive: true
				}
			}
		}
	});

	grunt.loadNpmTasks("grunt-contrib-connect");
	grunt.loadNpmTasks("grunt-contrib-jshint");
	grunt.loadNpmTasks("grunt-contrib-qunit");
	grunt.loadNpmTasks("grunt-contrib-uglify");
	grunt.loadNpmTasks("grunt-contrib-connect");
	grunt.loadNpmTasks("grunt-exec");

	// The 'ci' task is run on travis
	grunt.registerTask("server", ["connect:demo"]);
	grunt.registerTask("test", ["jshint",
								"qunit"]);
	grunt.registerTask("ci", ["test"]);
	grunt.registerTask("default", ["test"]);
	grunt.registerTask("build", ["exec:tabfix",
								 "test",
								 "uglify"]);
	grunt.registerTask("upload", ["build",
								  "exec:upload"]);
	grunt.registerTask("server", ["connect:demo"]);
};

{'fraction_non_alphanumeric': 0.21871476888387825, 'fraction_numerical': 0.0038331454340473506, 'mean_word_length': 2.9536541889483066, 'pattern_counts': {'":': 0, '<': 22, '<?xml version=': 0, '>': 22, 'https://': 4, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4348009', 'n_tokens_mistral': 2033, 'n_tokens_neox': 1662, 'n_words': 250}