Skip to content
This repository has been archived by the owner on Apr 25, 2023. It is now read-only.

Commit

Permalink
Clean .gitignore file.
Browse files Browse the repository at this point in the history
And code reformatting.
  • Loading branch information
ofrogon committed May 30, 2015
1 parent bc451bd commit 6a2e62e
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 26 deletions.
18 changes: 0 additions & 18 deletions .gitignore
Expand Up @@ -4,31 +4,13 @@
logs
*.log

# Runtime data
pids
*.pid
*.seed

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release

# Dependency directory
# Commenting this out is preferred by some people, see
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git-
node_modules

# Users Environment Variables
.lock-wscript

.idea
*.iml

Expand Down
14 changes: 7 additions & 7 deletions lib/fileSystem.js
Expand Up @@ -124,7 +124,7 @@ fs.copyQ = function(from, to) {
*/
fs.rmdirR = function(path, callback) {
fs.readdir(path, function(err, files) {
if(err) {
if (err) {
// Pass the error on to callback
callback(err, []);
return;
Expand All @@ -134,26 +134,26 @@ fs.rmdirR = function(path, callback) {
folderDone = function(err) {
count++;
// If we cleaned out all the files, continue
if( count >= wait || err) {
fs.rmdir(path,callback);
if (count >= wait || err) {
fs.rmdir(path, callback);
}
};
// Empty directory to bail early
if(!wait) {
if (!wait) {
folderDone();
return;
}

// Remove one or more trailing slash to keep from doubling up
path = path.replace(/\/+$/,"");
path = path.replace(/\/+$/, "");
files.forEach(function(file) {
var curPath = path + "/" + file;
fs.lstat(curPath, function(err, stats) {
if( err ) {
if (err) {
callback(err, []);
return;
}
if( stats.isDirectory() ) {
if (stats.isDirectory()) {
fs.rmdirR(curPath, folderDone);
} else {
fs.unlink(curPath, folderDone);
Expand Down
2 changes: 1 addition & 1 deletion test/test.js
Expand Up @@ -312,7 +312,7 @@ var test = [
errors.push("Test" + currentTest + " error: The angular.js file was not copy by the command runMinR().");
}

var bc = path.join(__dirname, "test0/bower_components");
var bc = path.join(__dirname, "test0/bower_components");
if (fs.existsSync(bc)) {
fs.removeSync(bc);
}
Expand Down

0 comments on commit 6a2e62e

Please sign in to comment.