Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

chg

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

chg - npm Package Compare versions

Comparing version 0.1.4 to 0.1.5

3

CHANGELOG.md

@@ -9,2 +9,5 @@ CHANGELOG

## 0.1.5 (2014-01-27)
* Release prompt now has the current package version as the default
## 0.1.4 (2014-01-27)

@@ -11,0 +14,0 @@ * Added line and version args to grunt cli commands

2

Gruntfile.js

@@ -41,3 +41,3 @@ 'use strict';

// These plugins provide necessary tasks.
grunt.loadTasks('./tasks')
grunt.loadTasks('./tasks');
grunt.loadNpmTasks('grunt-contrib-nodeunit');

@@ -44,0 +44,0 @@ grunt.loadNpmTasks('grunt-contrib-jshint');

@@ -12,2 +12,3 @@ /*

var prompt = require('prompt');
var fs = require('fs');

@@ -24,3 +25,3 @@ var commands = module.exports = {};

} else {
textPrompt('Add one line to the changelog', function(err, text){
textPrompt('Add one line to the changelog', {}, function(err, text){
if (err) { return callback(err); }

@@ -33,6 +34,13 @@ chg.add(text, {}, callback);

commands.release = function(version, options, callback){
options = options || {};
if (version) {
chg.release(version, options, callback);
} else {
textPrompt('What is the release version number?', function(err, text){
// use current package.json version as the default prompt value
if (fs.existsSync('./package.json')) {
options.default = require(process.cwd() + '/package.json').version;
}
textPrompt('What is the release version number?', options, function(err, text){
if (err) { return callback(err); }

@@ -58,9 +66,14 @@ chg.release(text, options, callback);

function textPrompt(message, callback){
function textPrompt(message, options, callback){
if (!options) {
callback = options;
options = {};
}
options.name = 'text';
options.message = message;
options.required = true;
prompt.start();
prompt.get({
name: 'text',
message: message,
required: true
}, function (err, result) {
prompt.get(options, function (err, result) {
if (err) {

@@ -67,0 +80,0 @@ return callback(err);

{
"name": "chg",
"version": "0.1.4",
"version": "0.1.5",
"main": "lib/changelog.js",

@@ -5,0 +5,0 @@ "description": "simple changelog/release history manager",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc