mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 10:45:47 +00:00
feature(main) rm WIN32
This commit is contained in:
parent
02e0477417
commit
e5e716de3c
2 changed files with 3 additions and 10 deletions
|
|
@ -12,7 +12,9 @@
|
|||
'# http://cloudcmd.io' + '\n');
|
||||
|
||||
var main = global.cloudcmd.main,
|
||||
|
||||
DIR = '../',
|
||||
WIN = process.platform === 'win32',
|
||||
|
||||
fs = require('fs'),
|
||||
Util = require(DIR + 'util'),
|
||||
|
|
@ -110,7 +112,7 @@
|
|||
};
|
||||
|
||||
function setWatachFunctions() {
|
||||
if (main.WIN32) {
|
||||
if (WIN) {
|
||||
/* good on windows */
|
||||
fs_watch = fs.watch;
|
||||
on_fs_watch = onWatch;
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@
|
|||
UTIL = 'util',
|
||||
|
||||
SLASH,
|
||||
ISWIN32,
|
||||
ext,
|
||||
path, zlib, url, CloudFunc, diffPatch, querystring,
|
||||
|
||||
|
|
@ -28,8 +27,6 @@
|
|||
exports.querystring = querystring = require('querystring'),
|
||||
|
||||
/* Constants */
|
||||
/* current dir + 2 levels up */
|
||||
exports.WIN32 = ISWIN32 = isWin32();
|
||||
exports.SLASH = SLASH = '/',
|
||||
|
||||
exports.SRVDIR = SRVDIR = __dirname + SLASH,
|
||||
|
|
@ -116,10 +113,4 @@
|
|||
function srvrequire(src) { return mrequire(SRVDIR + src); }
|
||||
|
||||
function jsonrequire(src) { return mrequire(JSONDIR + src);}
|
||||
|
||||
/**
|
||||
* function check is current platform is win32
|
||||
*/
|
||||
function isWin32() { return process.platform === 'win32'; }
|
||||
|
||||
})();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue