123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- #!/usr/bin/env node
-
-
-
- var fs = require('fs');
- var shell = require('shelljs');
- var path = require('path');
- var check_reqs = require('./check_reqs');
- var platformBuildDir = path.join('platforms', 'browser', 'www');
-
- var run = function () {
-
-
-
- if (!check_reqs.run()) {
- console.error('Please make sure you meet the software requirements in order to clean an browser cordova project');
- process.exit(2);
- }
-
- try {
- if (fs.existsSync(platformBuildDir)) {
- shell.rm('-r', platformBuildDir);
- }
- } catch (err) {
- console.log('could not remove ' + platformBuildDir + ' : ' + err.message);
- }
- };
-
- module.exports.run = run;
-
- module.exports.cleanProject = function () {
- console.log('lib/clean will soon only export a `run` command, please update to not call `cleanProject`.');
- return run();
- };
|