Hello community, here is the log from the commit of package nodejs-node-uuid for openSUSE:Factory checked in at 2015-06-30 10:17:47 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/nodejs-node-uuid (Old) and /work/SRC/openSUSE:Factory/.nodejs-node-uuid.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "nodejs-node-uuid" Changes: -------- --- /work/SRC/openSUSE:Factory/nodejs-node-uuid/nodejs-node-uuid.changes 2015-04-27 13:03:32.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.nodejs-node-uuid.new/nodejs-node-uuid.changes 2015-06-30 10:17:48.000000000 +0200 @@ -1,0 +2,5 @@ +Sat Jun 27 06:18:23 UTC 2015 - [email protected] + +- update version 1.4.3 + +------------------------------------------------------------------- Old: ---- node-uuid-1.4.1.tgz New: ---- node-uuid-1.4.3.tgz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ nodejs-node-uuid.spec ++++++ --- /var/tmp/diff_new_pack.REsnyE/_old 2015-06-30 10:17:49.000000000 +0200 +++ /var/tmp/diff_new_pack.REsnyE/_new 2015-06-30 10:17:49.000000000 +0200 @@ -19,7 +19,7 @@ %define base_name node-uuid Name: nodejs-node-uuid -Version: 1.4.1 +Version: 1.4.3 Release: 0 Summary: Generate RFC-compliant UUIDs in JavaScript License: MIT @@ -42,7 +42,7 @@ %install mkdir -p %{buildroot}%{nodejs_modulesdir}/%{base_name} -cp -pr *.json uuid.js benchmark \ +cp -pr *.json uuid.js benchmark bin \ %{buildroot}%{nodejs_modulesdir}/%{base_name}/ %files ++++++ node-uuid-1.4.1.tgz -> node-uuid-1.4.3.tgz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/package/LICENSE.md new/package/LICENSE.md --- old/package/LICENSE.md 2012-10-22 19:34:32.000000000 +0200 +++ new/package/LICENSE.md 2015-03-05 20:29:36.000000000 +0100 @@ -1,2 +1,21 @@ -Copyright (c) 2010-2012 Robert Kieffer -MIT License - http://opensource.org/licenses/mit-license.php +The MIT License (MIT) + +Copyright (c) 2010-2012 Robert Kieffer + +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 -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/package/README.md new/package/README.md --- old/package/README.md 2013-08-17 14:49:57.000000000 +0200 +++ new/package/README.md 2015-03-05 20:29:36.000000000 +0100 @@ -10,6 +10,7 @@ * Cryptographically strong random # generation on supporting platforms * 1.1K minified and gzip'ed (Want something smaller? Check this [crazy shit](https://gist.github.com/982883) out! ) * [Annotated source code](http://broofa.github.com/node-uuid/docs/uuid.html) +* Comes with a Command Line Interface for generating uuids on the command line ## Getting Started @@ -160,13 +161,48 @@ The class of container created when generating binary uuid data if no buffer argument is specified. This is expected to go away, with no replacement API. +## Command Line Interface + +To use the executable, it's probably best to install this library globally. + +`npm install -g node-uuid` + +Usage: + +``` +USAGE: uuid [version] [options] + + +options: + +--help Display this message and exit +``` + +`version` must be an RFC4122 version that is supported by this library, which is currently version 1 and version 4 (denoted by "v1" and "v4", respectively). `version` defaults to version 4 when not supplied. + +### Examples + +``` +> uuid +3a91f950-dec8-4688-ba14-5b7bbfc7a563 +``` + +``` +> uuid v1 +9d0b43e0-7696-11e3-964b-250efa37a98e +``` + +``` +> uuid v4 +6790ac7c-24ac-4f98-8464-42f6d98a53ae +``` + ## Testing In node.js ``` -> cd test -> node test.js +npm test ``` In Browser diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/package/bin/uuid new/package/bin/uuid --- old/package/bin/uuid 1970-01-01 01:00:00.000000000 +0100 +++ new/package/bin/uuid 2015-03-05 20:29:36.000000000 +0100 @@ -0,0 +1,26 @@ +#!/usr/bin/env node + +var path = require('path'); +var uuid = require(path.join(__dirname, '..')); + +var arg = process.argv[2]; + +if ('--help' === arg) { + console.log('\n USAGE: uuid [version] [options]\n\n'); + console.log(' options:\n'); + console.log(' --help Display this message and exit\n'); + process.exit(0); +} + +if (null == arg) { + console.log(uuid()); + process.exit(0); +} + +if ('v1' !== arg && 'v4' !== arg) { + console.error('Version must be RFC4122 version 1 or version 4, denoted as "v1" or "v4"'); + process.exit(1); +} + +console.log(uuid[arg]()); +process.exit(0); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/package/bower.json new/package/bower.json --- old/package/bower.json 1970-01-01 01:00:00.000000000 +0100 +++ new/package/bower.json 2015-03-05 20:30:29.000000000 +0100 @@ -0,0 +1,23 @@ +{ + "name": "node-uuid", + "version": "1.4.3", + "homepage": "https://github.com/broofa/node-uuid", + "authors": [ + "Robert Kieffer <[email protected]>" + ], + "description": "Rigorous implementation of RFC4122 (v1 and v4) UUIDs.", + "main": "uuid.js", + "keywords": [ + "uuid", + "gid", + "rfc4122" + ], + "license": "MIT", + "ignore": [ + "**/.*", + "node_modules", + "bower_components", + "test", + "tests" + ] +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/package/component.json new/package/component.json --- old/package/component.json 2013-08-17 14:49:57.000000000 +0200 +++ new/package/component.json 2015-03-05 20:30:29.000000000 +0100 @@ -2,7 +2,7 @@ "name": "node-uuid", "repo": "broofa/node-uuid", "description": "Rigorous implementation of RFC4122 (v1 and v4) UUIDs.", - "version": "1.4.0", + "version": "1.4.3", "author": "Robert Kieffer <[email protected]>", "contributors": [ {"name": "Christoph Tavan <[email protected]>", "github": "https://github.com/ctavan"} @@ -15,4 +15,4 @@ "uuid.js" ], "license": "MIT" -} \ No newline at end of file +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/package/package.json new/package/package.json --- old/package/package.json 2013-08-17 14:50:23.000000000 +0200 +++ new/package/package.json 2015-03-05 20:30:29.000000000 +0100 @@ -7,8 +7,20 @@ "contributors" : [ {"name": "Christoph Tavan <[email protected]>", "github": "https://github.com/ctavan"} ], + "bin": { + "uuid": "./bin/uuid" + }, + "scripts": { + "test": "node test/test.js" + }, "lib" : ".", "main" : "./uuid.js", "repository" : { "type" : "git", "url" : "https://github.com/broofa/node-uuid.git" }, - "version" : "1.4.1" + "version" : "1.4.3", + "licenses": [ + { + "type": "MIT", + "url": "https://raw.github.com/broofa/node-uuid/master/LICENSE.md" + } + ] } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/package/uuid.js new/package/uuid.js --- old/package/uuid.js 2013-08-17 14:49:57.000000000 +0200 +++ new/package/uuid.js 2015-03-05 20:29:39.000000000 +0100 @@ -14,9 +14,9 @@ // Node.js crypto-based RNG - http://nodejs.org/docs/v0.6.2/api/crypto.html // // Moderately fast, high quality - if (typeof(require) == 'function') { + if (typeof(_global.require) == 'function') { try { - var _rb = require('crypto').randomBytes; + var _rb = _global.require('crypto').randomBytes; _rng = _rb && function() {return _rb(16);}; } catch(e) {} } @@ -49,7 +49,7 @@ } // Buffer class to use - var BufferClass = typeof(Buffer) == 'function' ? Buffer : Array; + var BufferClass = typeof(_global.Buffer) == 'function' ? _global.Buffer : Array; // Maps for number <-> hex string conversion var _byteToHex = []; @@ -224,12 +224,14 @@ uuid.unparse = unparse; uuid.BufferClass = BufferClass; - if (typeof define === 'function' && define.amd) { - // Publish as AMD module - define(function() {return uuid;}); - } else if (typeof(module) != 'undefined' && module.exports) { + if (typeof(module) != 'undefined' && module.exports) { // Publish as node.js module module.exports = uuid; + } else if (typeof define === 'function' && define.amd) { + // Publish as AMD module + define(function() {return uuid;}); + + } else { // Publish as global (in browsers) var _previousRoot = _global.uuid;
