Skip to content

Commit

Permalink
feature(gulp) add place from npm
Browse files Browse the repository at this point in the history
  • Loading branch information
coderaiser committed Nov 18, 2014
1 parent 2debe0d commit ab424fe
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 11 deletions.
18 changes: 8 additions & 10 deletions gulp/tasks/docs.js
Expand Up @@ -5,6 +5,7 @@
fs = require('fs'),

cl = require('../cl'),
place = require('place'),
Util = require(DIR + 'lib/util'),
Info = require(DIR + 'package');

Expand Down Expand Up @@ -34,16 +35,13 @@
};

function replaceVersion(name, version, versionNew, callback) {
fs.readFile(name, 'utf8', function(error, data) {
if (error)
callback(error);
else
fs.writeFile(
name,
data.replace(version, versionNew),
function(error) {
callback(error, 'done: ' + name);
});
place(name, version, versionNew, function(error) {
var msg;

if (!error)
msg = 'done: ' + name;

callback(error, msg);
});
}
})();
3 changes: 2 additions & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "cloudcmd",
"version": "1.4.1",
"version": "1.5.0",
"author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
"description": "Cloud Commander orthodox web file manager with console and editor",
"homepage": "http://cloudcmd.io",
Expand Down Expand Up @@ -47,6 +47,7 @@
"gulp-recess": "~1.0.0",
"minor": "~1.2.2",
"morgan": "~1.5.0",
"place": "~1.0.0",
"should": "~4.2.1",
"version-io": "~1.0.3"
},
Expand Down

0 comments on commit ab424fe

Please sign in to comment.