How to use the wrench.rmdirSyncRecursive function in wrench

To help you get started, we’ve selected a few wrench examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github jesseditson / Urza / grunt.js View on Github external
grunt.registerTask('cleanup','Removes the urza scratch dir',function(){
    console.log('Cleaning up...')
    wrench.rmdirSyncRecursive(scratchDir)
    wrench.rmdirSyncRecursive(workingDir + '/public')
    wrench.rmdirSyncRecursive(workingDir + '/public_web')
    wrench.rmdirSyncRecursive(workingDir + '/public_mobile')
  })
  // set up grunt task to upload to s3
github appcelerator-archive / titanium_cli / lib / commands / clean.js View on Github external
cleanArray.forEach(function(target) {
				target = target === 'ios' ? 'iphone' : target;
				var cleanPath = path.join(buildPath, target); 

				// delete and recreate build paths
				logger.debug('* Cleaning "' + cleanPath + "'");
				wrench.rmdirSyncRecursive(cleanPath, true);
				fs.mkdirSync(cleanPath,'777');
			});
			logger.info('Project build directories cleaned and reinitialized.');
github joshuavial / sustain / test / helpers / sustain-fixture-manager.js View on Github external
cleanup: function () {
    try {
      fs.unlinkSync(__dirname + '/../sustain.json')
    } catch (err) { }
    wrench.rmdirSyncRecursive(__dirname + '/../node_modules', 'failSilently')
  }
}
github imdone / imdone-core / test / repository-spec.js View on Github external
repo.saveConfig(function(err) {
        expect(err).to.be(null);
        expect(fs.existsSync(configDir)).to.be(true);
        wrench.rmdirSyncRecursive(configDir, true);
        expect(fs.existsSync(configDir)).to.be(false);
        done();
      });
    });
github libgit2 / node-gitteh / test / gitteh.js View on Github external
gitteh.initRepository(tempPath, true, function (err, repo) {
      t.ok(repo instanceof gitteh.Repository, 'returns an instance of #gitteh.Repository');
      t.ok(repo.bare, 'works');
      t.equal(path.relative(repo.path, tempPath), '', 'initialises a bare repo in the specified path');

      wrench.rmdirSyncRecursive(tempPath, true);

      t.end();
    });
  });
github imdone / imdone-core / test / search-spec.js View on Github external
afterEach(function() {
    repo1.destroy();
    repo2.destroy();
    wrench.rmdirSyncRecursive(tmpDir, true);
  });
github imdone / imdone-core / test / project-spec.js View on Github external
afterEach(function() {
    repo1.destroy();
    repo2.destroy();
    wrench.rmdirSyncRecursive(tmpDir, true);
  });
github martoo6 / ScalaZen-IDE / www / js / main.js View on Github external
.forEach(function(folder){
            try{
                wrench.rmdirSyncRecursive(folderPath + '/' + folder + '/.ensime_cache');
                console.log('Removed: ' + folder + '\'s cache');
            }catch(e){
                //Do nothing
            }
        });
    }
github mcantelon / node-deja / lib / commands.js View on Github external
fs.exists(pathToRepo, function(exists) {

    if (exists) {

      helpers.deleteSymlinksToRepo(home, pathToRepo)
      wrench.rmdirSyncRecursive(pathToRepo)
      console.log('Repo removed.')
    }
    else {

      console.log('Error: Not a valid repo.')
    }
  })
}
github mortie / mmpc-media-streamer / js / torrent-player.js View on Github external
this.player.onexit = function() {
		streamers.forEach(function(streamer) {
			streamer.free();
		});
		this.media.forEach(function(f) {
			f.cleanup();
		});
		if (this.subtitles.cleanup) {
			this.subtitles.cleanup();
		}
		this.engine.destroy();

		//Clean up temp files
		wrench.rmdirSyncRecursive(os.tmpdir()+"/mmpc-"+this.id);
	}.bind(this);

wrench

Recursive filesystem (and other) operations that Node *should* have.

MIT
Latest version published 9 years ago

Package Health Score

53 / 100
Full package analysis