diff -Nru node-ms-2.1.1/debian/changelog node-ms-2.1.2+~cs0.7.31/debian/changelog --- node-ms-2.1.1/debian/changelog 2018-01-12 12:11:34.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/changelog 2020-05-13 10:43:09.000000000 +0000 @@ -1,3 +1,33 @@ +node-ms (2.1.2+~cs0.7.31-1) unstable; urgency=medium + + * Team upload + + [ Joseph Nuthalapati ] + * New upstream release + * Add myself to uploaders + + [ Debian Janitor ] + * Use secure copyright file specification URI. + * Bump debhelper from old 9 to 12. + * Set debhelper-compat version in Build-Depends. + * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository, + Repository-Browse. + + [ Xavier Guimard ] + * Declare compliance with policy 4.5.0 + * Add "Rules-Requires-Root: no" + * Add debian/gbp.conf + * Use pkg-js-tools auto install + * Embed @types/ms (0.7.31) + + -- Xavier Guimard Wed, 13 May 2020 12:43:09 +0200 + +node-ms (2.1.1-2) UNRELEASED; urgency=medium + + * Update Vcs fields for migration to https://salsa.debian.org/ + + -- Paolo Greppi Thu, 05 Apr 2018 15:56:20 +0200 + node-ms (2.1.1-1) unstable; urgency=medium * New upstream release diff -Nru node-ms-2.1.1/debian/compat node-ms-2.1.2+~cs0.7.31/debian/compat --- node-ms-2.1.1/debian/compat 2017-09-09 15:52:44.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/compat 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -9 diff -Nru node-ms-2.1.1/debian/control node-ms-2.1.2+~cs0.7.31/debian/control --- node-ms-2.1.1/debian/control 2018-01-09 10:50:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/control 2020-05-13 10:43:09.000000000 +0000 @@ -2,23 +2,24 @@ Section: javascript Priority: optional Maintainer: Debian Javascript Maintainers -Uploaders: Paolo Greppi -Build-Depends: - debhelper (>= 9) - , dh-buildinfo - , nodejs +Uploaders: Paolo Greppi , + Joseph Nuthalapati +Build-Depends: debhelper-compat (= 12) , mocha , node-expect.js -Standards-Version: 4.1.3 -Homepage: https://github.com/zeit/ms#readme -Vcs-Git: https://anonscm.debian.org/git/pkg-javascript/node-ms.git -Vcs-Browser: https://anonscm.debian.org/cgit/pkg-javascript/node-ms.git + , pkg-js-tools (>= 0.9.35~) +Standards-Version: 4.5.0 +Vcs-Browser: https://salsa.debian.org/js-team/node-ms +Vcs-Git: https://salsa.debian.org/js-team/node-ms.git +Homepage: https://github.com/zeit/ms +Testsuite: autopkgtest-pkg-nodejs +Rules-Requires-Root: no Package: node-ms Architecture: all -Depends: - ${misc:Depends} +Depends: ${misc:Depends} , nodejs +Provides: ${nodejs:Provides} Description: milliseconds conversion utility - Node.js module This module provides a tiny milliseconds conversion utility able to transform a string with a valid time unit to the equivalent number diff -Nru node-ms-2.1.1/debian/copyright node-ms-2.1.2+~cs0.7.31/debian/copyright --- node-ms-2.1.1/debian/copyright 2018-01-09 10:48:01.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/copyright 2020-05-13 10:40:40.000000000 +0000 @@ -1,17 +1,22 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: ms Upstream-Contact: https://github.com/zeit/ms/issues Source: https://github.com/zeit/ms + https://registry.npmjs.org/@types/ms Files: * -Copyright: +Copyright: 2012-2015 Guillermo Rauch 2012-2013 TJ Holowaychuk 2016-2017 Leo Lamprecht License: Expat +Files: typesms/* +Copyright: Microsoft Corporation +License: Expat + Files: debian/* -Copyright: +Copyright: 2014 Leo Iannacone 2017 Paolo Greppi License: Expat @@ -36,4 +41,3 @@ ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - diff -Nru node-ms-2.1.1/debian/gbp.conf node-ms-2.1.2+~cs0.7.31/debian/gbp.conf --- node-ms-2.1.1/debian/gbp.conf 1970-01-01 00:00:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/gbp.conf 2020-05-13 10:38:10.000000000 +0000 @@ -0,0 +1,6 @@ +[DEFAULT] +pristine-tar=True +component=['typesms'] + +[import-orig] +filter=[ '.gitignore', '.travis.yml', '.git*' ] diff -Nru node-ms-2.1.1/debian/install node-ms-2.1.2+~cs0.7.31/debian/install --- node-ms-2.1.1/debian/install 2017-09-09 15:52:44.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/install 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -package.json usr/lib/nodejs/ms/ -index.js usr/lib/nodejs/ms/ diff -Nru node-ms-2.1.1/debian/nodejs/root_modules node-ms-2.1.2+~cs0.7.31/debian/nodejs/root_modules --- node-ms-2.1.1/debian/nodejs/root_modules 1970-01-01 00:00:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/nodejs/root_modules 2020-05-13 10:41:48.000000000 +0000 @@ -0,0 +1 @@ +* diff -Nru node-ms-2.1.1/debian/rules node-ms-2.1.2+~cs0.7.31/debian/rules --- node-ms-2.1.1/debian/rules 2017-09-09 15:52:44.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/rules 2020-05-13 10:42:31.000000000 +0000 @@ -5,9 +5,4 @@ #export DH_VERBOSE=1 %: - dh $@ - -override_dh_auto_build: - -override_dh_auto_test: - mocha -C tests.js + dh $@ --with nodejs diff -Nru node-ms-2.1.1/debian/tests/control node-ms-2.1.2+~cs0.7.31/debian/tests/control --- node-ms-2.1.1/debian/tests/control 2017-09-09 15:52:44.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/tests/control 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -Tests: require -Depends: node-ms diff -Nru node-ms-2.1.1/debian/tests/pkg-js/test node-ms-2.1.2+~cs0.7.31/debian/tests/pkg-js/test --- node-ms-2.1.1/debian/tests/pkg-js/test 1970-01-01 00:00:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/tests/pkg-js/test 2020-05-13 10:37:03.000000000 +0000 @@ -0,0 +1 @@ +mocha -C tests.js diff -Nru node-ms-2.1.1/debian/tests/require node-ms-2.1.2+~cs0.7.31/debian/tests/require --- node-ms-2.1.1/debian/tests/require 2017-09-09 15:52:44.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/tests/require 1970-01-01 00:00:00.000000000 +0000 @@ -1,3 +0,0 @@ -#!/bin/sh -set -e -nodejs -e "require('ms');" diff -Nru node-ms-2.1.1/debian/upstream/metadata node-ms-2.1.2+~cs0.7.31/debian/upstream/metadata --- node-ms-2.1.1/debian/upstream/metadata 1970-01-01 00:00:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/upstream/metadata 2020-05-13 10:36:24.000000000 +0000 @@ -0,0 +1,4 @@ +Bug-Database: https://github.com/guille/ms.js/issues +Bug-Submit: https://github.com/guille/ms.js/issues/new +Repository: https://github.com/guille/ms.js.git +Repository-Browse: https://github.com/guille/ms.js diff -Nru node-ms-2.1.1/debian/watch node-ms-2.1.2+~cs0.7.31/debian/watch --- node-ms-2.1.1/debian/watch 2017-09-09 15:52:44.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/debian/watch 2020-05-13 10:39:42.000000000 +0000 @@ -1,5 +1,10 @@ -version=3 +version=4 opts=\ -dversionmangle=s/\+(debian|dfsg|ds|deb)(\.\d+)?$//,\ +dversionmangle=auto,\ filenamemangle=s/.*\/v?([\d\.-]+)\.tar\.gz/node-ms-$1.tar.gz/ \ - https://github.com/guille/ms.js/tags .*/archive/v?([\d\.]+).tar.gz + https://github.com/guille/ms.js/tags .*/archive/v?([\d\.]+).tar.gz group + +# It is not recommended use npmregistry. Please investigate more. +# Take a look at https://wiki.debian.org/debian/watch/ +opts="searchmode=plain,component=typesms,pgpmode=none" \ + https://registry.npmjs.org/@types/ms https://registry.npmjs.org/@types/ms/-/ms-([\d\.]+)@ARCHIVE_EXT@ checksum diff -Nru node-ms-2.1.1/index.js node-ms-2.1.2+~cs0.7.31/index.js --- node-ms-2.1.1/index.js 2017-11-30 18:18:20.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/index.js 2019-07-24 13:52:43.000000000 +0000 @@ -28,7 +28,7 @@ var type = typeof val; if (type === 'string' && val.length > 0) { return parse(val); - } else if (type === 'number' && isNaN(val) === false) { + } else if (type === 'number' && isFinite(val)) { return options.long ? fmtLong(val) : fmtShort(val); } throw new Error( @@ -50,7 +50,7 @@ if (str.length > 100) { return; } - var match = /^((?:\d+)?\-?\d?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec( + var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec( str ); if (!match) { diff -Nru node-ms-2.1.1/package.json node-ms-2.1.2+~cs0.7.31/package.json --- node-ms-2.1.1/package.json 2017-11-30 18:18:20.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/package.json 2019-07-24 13:52:43.000000000 +0000 @@ -1,6 +1,6 @@ { "name": "ms", - "version": "2.1.1", + "version": "2.1.2", "description": "Tiny millisecond conversion utility", "repository": "zeit/ms", "main": "./index", diff -Nru node-ms-2.1.1/package-lock.json node-ms-2.1.2+~cs0.7.31/package-lock.json --- node-ms-2.1.1/package-lock.json 2017-11-30 18:18:20.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/package-lock.json 2019-07-24 13:52:43.000000000 +0000 @@ -1,6 +1,6 @@ { "name": "ms", - "version": "2.1.1", + "version": "2.1.2", "lockfileVersion": 1, "requires": true, "dependencies": { diff -Nru node-ms-2.1.1/readme.md node-ms-2.1.2+~cs0.7.31/readme.md --- node-ms-2.1.1/readme.md 2017-11-30 18:18:20.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/readme.md 2019-07-24 13:52:43.000000000 +0000 @@ -1,7 +1,7 @@ # ms [![Build Status](https://travis-ci.org/zeit/ms.svg?branch=master)](https://travis-ci.org/zeit/ms) -[![Slack Channel](http://zeit-slackin.now.sh/badge.svg)](https://zeit.chat/) +[![Join the community on Spectrum](https://withspectrum.github.io/badge/badge.svg)](https://spectrum.chat/zeit) Use this package to easily convert various time formats to milliseconds. diff -Nru node-ms-2.1.1/tests.js node-ms-2.1.2+~cs0.7.31/tests.js --- node-ms-2.1.1/tests.js 2017-11-30 18:18:20.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/tests.js 2019-07-24 13:52:43.000000000 +0000 @@ -55,6 +55,7 @@ it('should return NaN if invalid', function() { expect(isNaN(ms('☃'))).to.be(true); + expect(isNaN(ms('10-.5'))).to.be(true); }); it('should be case-insensitive', function() { @@ -71,6 +72,7 @@ it('should work with negative decimals', function() { expect(ms('-1.5h')).to.be(-5400000); + expect(ms('-10.5h')).to.be(-37800000); }); it('should work with negative decimals starting with "."', function() { @@ -282,4 +284,16 @@ ms(NaN); }).to.throwError(); }); + + it('should throw an error, when ms(Infinity)', function() { + expect(function() { + ms(Infinity); + }).to.throwError(); + }); + + it('should throw an error, when ms(-Infinity)', function() { + expect(function() { + ms(-Infinity); + }).to.throwError(); + }); }); diff -Nru node-ms-2.1.1/typesms/index.d.ts node-ms-2.1.2+~cs0.7.31/typesms/index.d.ts --- node-ms-2.1.1/typesms/index.d.ts 1970-01-01 00:00:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/typesms/index.d.ts 2019-09-04 20:48:21.000000000 +0000 @@ -0,0 +1,25 @@ +// Type definitions for ms v0.7.1 +// Project: https://github.com/zeit/ms +// Definitions by: Zhiyuan Wang +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped + + + +/** +* Short/Long format for `value`. +* +* @param {Number} value +* @param {{long: boolean}} options +* @return {String} +*/ +declare function ms(value: number, options?: { long: boolean }): string; + +/** +* Parse the given `value` and return milliseconds. +* +* @param {String} value +* @return {Number} +*/ +declare function ms(value: string): number; + +export = ms; diff -Nru node-ms-2.1.1/typesms/LICENSE node-ms-2.1.2+~cs0.7.31/typesms/LICENSE --- node-ms-2.1.1/typesms/LICENSE 1970-01-01 00:00:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/typesms/LICENSE 2019-09-04 20:48:21.000000000 +0000 @@ -0,0 +1,21 @@ + MIT License + + Copyright (c) Microsoft Corporation. All rights reserved. + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + SOFTWARE diff -Nru node-ms-2.1.1/typesms/package.json node-ms-2.1.2+~cs0.7.31/typesms/package.json --- node-ms-2.1.1/typesms/package.json 1970-01-01 00:00:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/typesms/package.json 2019-09-04 20:48:21.000000000 +0000 @@ -0,0 +1,24 @@ +{ + "name": "@types/ms", + "version": "0.7.31", + "description": "TypeScript definitions for ms", + "license": "MIT", + "contributors": [ + { + "name": "Zhiyuan Wang", + "url": "https://github.com/danny8002", + "githubUsername": "danny8002" + } + ], + "main": "", + "types": "index", + "repository": { + "type": "git", + "url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git", + "directory": "types/ms" + }, + "scripts": {}, + "dependencies": {}, + "typesPublisherContentHash": "ff2ed90b1d3539f07c5e91fe5cac8d4aa504a3290632a4e76a02d1684dcfabfc", + "typeScriptVersion": "2.0" +} \ No newline at end of file diff -Nru node-ms-2.1.1/typesms/README.md node-ms-2.1.2+~cs0.7.31/typesms/README.md --- node-ms-2.1.1/typesms/README.md 1970-01-01 00:00:00.000000000 +0000 +++ node-ms-2.1.2+~cs0.7.31/typesms/README.md 2019-09-04 20:48:21.000000000 +0000 @@ -0,0 +1,16 @@ +# Installation +> `npm install --save @types/ms` + +# Summary +This package contains type definitions for ms (https://github.com/zeit/ms). + +# Details +Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/ms + +Additional Details + * Last updated: Wed, 04 Sep 2019 20:48:21 GMT + * Dependencies: none + * Global values: none + +# Credits +These definitions were written by Zhiyuan Wang .