From c62e75d789787cc21438dde943885dda9f0ae387 Mon Sep 17 00:00:00 2001 From: Klaus Weidenbach Date: Thu, 14 May 2015 10:39:56 +0200 Subject: Add sprintf.js v1.0.2. This script provides sprintf() for JavaScript. It can be used for example for translating strings used in JavaScript with variables. It is licensed under BSD-3-Clause and can be found on GitHub: https://github.com/alexei/sprintf.js --- library/sprintf.js/gruntfile.js | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 library/sprintf.js/gruntfile.js (limited to 'library/sprintf.js/gruntfile.js') diff --git a/library/sprintf.js/gruntfile.js b/library/sprintf.js/gruntfile.js new file mode 100644 index 000000000..246e1c3b9 --- /dev/null +++ b/library/sprintf.js/gruntfile.js @@ -0,0 +1,36 @@ +module.exports = function(grunt) { + grunt.initConfig({ + pkg: grunt.file.readJSON("package.json"), + + uglify: { + options: { + banner: "/*! <%= pkg.name %> | <%= pkg.author %> | <%= pkg.license %> */\n", + sourceMap: true + }, + build: { + files: [ + { + src: "src/sprintf.js", + dest: "dist/sprintf.min.js" + }, + { + src: "src/angular-sprintf.js", + dest: "dist/angular-sprintf.min.js" + } + ] + } + }, + + watch: { + js: { + files: "src/*.js", + tasks: ["uglify"] + } + } + }) + + grunt.loadNpmTasks("grunt-contrib-uglify") + grunt.loadNpmTasks("grunt-contrib-watch") + + grunt.registerTask("default", ["uglify", "watch"]) +} -- cgit v1.2.3