[Pkg-osm-commits] [SCM] leaflet branch, master, updated. debian/0.4.5-1-13-gdf68986

Andrew Harvey andrew.harvey4 at gmail.com
Sat Jan 19 00:21:07 UTC 2013


The following commit has been merged in the master branch:
commit 1fdc478df42c8eba51861faf5cc373675a989882
Author: Andrew Harvey <andrew.harvey4 at gmail.com>
Date:   Sat Jan 19 09:58:01 2013 +1100

    refresh patches

diff --git a/debian/patches/2001-dont_test_during_build.patch b/debian/patches/2001-dont_test_during_build.patch
index 24f3e5a..b323bcc 100644
--- a/debian/patches/2001-dont_test_during_build.patch
+++ b/debian/patches/2001-dont_test_during_build.patch
@@ -1,23 +1,86 @@
-Description: avoid running tests until jshlint is packaged
+Description: avoid running tests as jshlint isn't packaged
 Author: Andrew Harvey <andrew.harvey4 at gmail.com>
 Forwarded: not-needed
-Last-Update: 2012-02-14
+Last-Update: 2013-01-19
 
---- a/Jakefile.js
-+++ b/Jakefile.js
-@@ -1,5 +1,5 @@
- var build = require('./build/build.js'),
--    lint = require('./build/hint.js');
-+    lint = null;
- 
- var COPYRIGHT = '/*\n Copyright (c) 2010-2012, CloudMade, Vladimir Agafonkin\n' +
-                 ' Leaflet is an open-source JavaScript library for mobile-friendly interactive maps.\n' + 
-@@ -23,7 +23,7 @@
- });
+--- leaflet.orig/Jakefile.js
++++ leaflet/Jakefile.js
+@@ -5,7 +5,6 @@
  
+     npm install -g jake
+     npm install uglify-js
+-    npm install jshint
+ 
+ To check the code and build Leaflet from source, run "jake"
+ 
+@@ -14,10 +13,7 @@
+ 
+ var build = require('./build/build.js');
+ 
+-desc('Check Leaflet source for errors with JSHint');
+-task('lint', build.lint);
+-
  desc('Combine and compress Leaflet source files');
--task('build', ['lint'], function (compsBase32, buildName) {
-+task('build', function (compsBase32, buildName) {
+-task('build', ['lint'], build.build);
++task('build', [], build.build);
+ 
+ task('default', ['build']);
+--- leaflet.orig/build/build.js
++++ leaflet/build/build.js
+@@ -1,32 +1,10 @@
+ var fs = require('fs'),
+-    jshint = require('jshint'),
+     UglifyJS = require('uglify-js'),
+ 
+     deps = require('./deps.js').deps,
+     hintrc = require('./hintrc.js').config;
+ 
  
- 	var files = build.getFiles(compsBase32);
+-function lintFiles(files) {
+-
+-	var errorsFound = 0,
+-	    i, j, len, len2, src, errors, e;
+-
+-	for (i = 0, len = files.length; i < len; i++) {
+-
+-		jshint.JSHINT(fs.readFileSync(files[i], 'utf8'), hintrc);
+-		errors = jshint.JSHINT.errors;
+-
+-		for (j = 0, len2 = errors.length; j < len2; j++) {
+-			e = errors[j];
+-			console.log(files[i] + '\tline ' + e.line + '\tcol ' + e.character + '\t ' + e.reason);
+-		}
+-
+-		errorsFound += len2;
+-	}
+-
+-	return errorsFound;
+-}
+-
+ function getFiles(compsBase32) {
+ 	var memo = {},
+ 	    comps;
+@@ -64,23 +42,6 @@
+ 	return files;
+ }
  
+-exports.lint = function () {
+-
+-	var files = getFiles();
+-
+-	console.log('Checking for JS errors...');
+-
+-	var errorsFound = lintFiles(files);
+-
+-	if (errorsFound > 0) {
+-		console.log(errorsFound + ' error(s) found.\n');
+-		fail();
+-	} else {
+-		console.log('\tCheck passed');
+-	}
+-};
+-
+-
+ function getSizeDelta(newContent, oldContent) {
+ 	if (!oldContent) {
+ 		return 'new';

-- 
JavaScript library for displaying map data in web browsers



More information about the Pkg-osm-commits mailing list