[Pkg-javascript-commits] [node-tap] 04/06: Use node-clean-yaml-object instead of patch

Bastien Roucariès rouca at moszumanska.debian.org
Thu Sep 7 09:30:09 UTC 2017


This is an automated email from the git hooks/post-receive script.

rouca pushed a commit to branch master
in repository node-tap.

commit eabcec322b44b9312fadd70deb8e1feabd1046e7
Author: Bastien ROUCARIÈS <roucaries.bastien at gmail.com>
Date:   Thu Sep 7 11:12:08 2017 +0200

    Use node-clean-yaml-object instead of patch
---
 debian/changelog                              |  7 ++
 debian/control                                |  2 +
 debian/patches/module-buffer-to-string.patch  | 26 -------
 debian/patches/module-clean-yaml-object.patch | 98 ---------------------------
 debian/patches/series                         |  2 -
 5 files changed, 9 insertions(+), 126 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 53b23d5..9e5af2d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+node-tap (8.0.0-6) unstable; urgency=medium
+
+  * Team upload
+  * Use module node-clean-yaml-object instad of patch
+
+ -- Bastien Roucariès <rouca at debian.org>  Thu, 07 Sep 2017 11:11:55 +0200
+
 node-tap (8.0.0-5) unstable; urgency=medium
 
   * Team upload.
diff --git a/debian/control b/debian/control
index 607d993..baf94cf 100644
--- a/debian/control
+++ b/debian/control
@@ -9,6 +9,7 @@ Build-Depends:
  , nodejs
  , dpkg-dev (>= 1.17.14)
  , help2man <!nodoc>
+ , node-clean-yaml-object (>= 0.1.0) <!nocheck> <!nodoc>
  , node-supports-color  <!nocheck> <!nodoc>
  , node-foreground-child (>= 1.3.3) <!nocheck> <!nodoc>
  , node-glob (>= 7) <!nocheck> <!nodoc>
@@ -34,6 +35,7 @@ Architecture: all
 Depends:
  ${misc:Depends}
  , nodejs
+ , node-clean-yaml-object (>= 0.1.0)
  , node-supports-color
  , node-foreground-child (>= 1.3.3)
  , node-glob (>= 7)
diff --git a/debian/patches/module-buffer-to-string.patch b/debian/patches/module-buffer-to-string.patch
deleted file mode 100644
index 91be536..0000000
--- a/debian/patches/module-buffer-to-string.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-Description: bundle module buffer-to-string
- See copyright for more information
-Last-Update: 2016-11-11
-Forwarded: not-needed
-Author: Jérémy Lal <kapouer at melix.org>
---- /dev/null
-+++ b/node_modules/buffer-to-string.js
-@@ -0,0 +1,18 @@
-+'use strict';
-+module.exports = function (buffer, limit) {
-+	limit = limit || 20;
-+	return buffer.toString('hex').split('')
-+		.reduce(function (arr, char) {
-+			if (arr.length && arr[arr.length - 1].length === 1) {
-+				arr[arr.length - 1] += char;
-+				if (arr.length && arr.length % limit === 0) {
-+					arr[arr.length - 1] += '\n';
-+				} else {
-+					arr[arr.length - 1] += ' ';
-+				}
-+			} else {
-+				arr.push(char);
-+			}
-+			return arr;
-+		}, []).join('').trim();
-+};
diff --git a/debian/patches/module-clean-yaml-object.patch b/debian/patches/module-clean-yaml-object.patch
deleted file mode 100644
index 6db2282..0000000
--- a/debian/patches/module-clean-yaml-object.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-Description: bundle module clean-yaml-object
- See copyright for more information
-Last-Update: 2016-11-11
-Forwarded: not-needed
-Author: Jérémy Lal <kapouer at melix.org>
---- /dev/null
-+++ b/node_modules/clean-yaml-object.js
-@@ -0,0 +1,90 @@
-+'use strict';
-+var bufferToString = require('buffer-to-string');
-+
-+module.exports = function (object, filterFn) {
-+	return cleanYamlObj(object, filterFn || defaultFilter, true, []);
-+};
-+
-+function cleanYamlObj(object, filter, isRoot, seen) {
-+	if (object === undefined) {
-+		return null;
-+	}
-+
-+	if (typeof object === 'function') {
-+		return object.toString();
-+	}
-+
-+	if (Buffer.isBuffer(object)) {
-+		return 'Buffer\n' + bufferToString(object);
-+	}
-+
-+	if (object && typeof object === 'object') {
-+		if (object instanceof RegExp) {
-+			return object.toString();
-+		}
-+
-+		seen = seen.concat([object]);
-+
-+		var isArray = Array.isArray(object);
-+
-+		// Fill in any holes.  This means we lose expandos,
-+		// but we were gonna lose those anyway.
-+		if (isArray) {
-+			object = fillHoles(object);
-+		}
-+
-+		var isError = object && typeof object === 'object' && object instanceof Error;
-+
-+		var set = isArray ? [] : {};
-+
-+		// name is typically not an ownProperty on an Error
-+		if (isError && object.name && !{}.hasOwnProperty.call(object, 'name') && filter('name', isRoot, object, set)) {
-+			setProp('name', object, set, seen, filter);
-+		}
-+
-+		var keys = Object.getOwnPropertyNames(object);
-+		return keys.reduce(function (set, k) {
-+			// magic property!
-+			if (isArray && k === 'length') {
-+				return set;
-+			}
-+
-+			// Don't dump massive EventEmitter and Domain
-+			// objects onto the output, that's never friendly.
-+			if (isError && /^domain/.test(k)) {
-+				return set;
-+			}
-+
-+			if (!filter(k, isRoot, object, set)) {
-+				return set;
-+			}
-+
-+			setProp(k, object, set, seen, filter);
-+
-+			return set;
-+		}, set);
-+	}
-+
-+	return object;
-+}
-+
-+function setProp(propName, source, target, seen, filter) {
-+	if (seen.indexOf(source[propName]) === -1) {
-+		target[propName] = cleanYamlObj(source[propName], filter, false, seen);
-+	} else {
-+		target[propName] = '[Circular]';
-+	}
-+}
-+
-+function defaultFilter() {
-+	return true;
-+}
-+
-+function fillHoles(arr) {
-+	var result = [];
-+	for (var i = 0; i < arr.length; i++) {
-+		result[i] = arr[i];
-+	}
-+	return result;
-+}
-+
diff --git a/debian/patches/series b/debian/patches/series
index 7042688..861c4c0 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,7 +1,5 @@
 module-tap-mocha-reporter.patch
 module-stack-utils.patch
-module-clean-yaml-object.patch
-module-buffer-to-string.patch
 nodejs_rename.patch
 use_available_modules.patch
 script-not-executable.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-tap.git



More information about the Pkg-javascript-commits mailing list