Comparing version 0.2.0-alpha.5 to 0.2.1-alpha.0
@@ -103,3 +103,4 @@ "use strict"; | ||
var path = utils.absolutePath(args.path, _this.currentSharedFolder); | ||
if (fs.existsSync(path) && !isRealPath(path)) | ||
var exists = fs.existsSync(path); | ||
if (exists && !isRealPath(path)) | ||
reject(); | ||
@@ -112,3 +113,9 @@ if (args.content === 'undefined') { // no !!!!! | ||
if (isFolder) { | ||
fs.mkdirp(path).then(function () { return resolve(); }).catch(function (e) { return reject(e); }); | ||
fs.mkdirp(path).then(function () { | ||
var splitPath = args.path.split('/'); | ||
splitPath = splitPath.filter(function (dir) { return dir; }); | ||
var dir = '/' + splitPath.join('/'); | ||
_this.emit('folderAdded', dir); | ||
resolve(); | ||
}).catch(function (e) { return reject(e); }); | ||
} | ||
@@ -125,2 +132,8 @@ else { | ||
}).catch(function (e) { return reject(e); }); | ||
if (!exists) { | ||
_this.emit('fileAdded', args.path); | ||
} | ||
else { | ||
_this.emit('fileChanged', args.path); | ||
} | ||
} | ||
@@ -151,2 +164,3 @@ }); | ||
} | ||
_this.emit('fileRenamed', args.oldPath, args.newPath); | ||
resolve(true); | ||
@@ -176,2 +190,3 @@ }); | ||
} | ||
_this.emit('fileRemoved', args.path); | ||
resolve(true); | ||
@@ -178,0 +193,0 @@ }); |
{ | ||
"name": "remixd", | ||
"version": "0.2.0-alpha.5", | ||
"version": "0.2.1-alpha.0", | ||
"description": "remix server: allow accessing file system from remix.ethereum.org and start a dev environment (see help section)", | ||
@@ -5,0 +5,0 @@ "main": "./lib/src/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
23273
16
504
2