mirror of
https://github.com/thinkjs/thinkjs.git
synced 2026-01-18 14:26:56 +00:00
20 lines
466 B
JavaScript
20 lines
466 B
JavaScript
#!/usr/bin/env node
|
|
|
|
var thinkjs = require('thinkjs');
|
|
var path = require('path');
|
|
var WatchCompile = require('thinkjs/lib/util/watch_compile.js');
|
|
|
|
var rootPath = path.dirname(__dirname);
|
|
var srcPath = rootPath + think.sep + 'src';
|
|
var outPath = rootPath + think.sep + 'app';
|
|
|
|
think.ROOT_PATH = rootPath;
|
|
think.APP_PATH = outPath;
|
|
|
|
WatchCompile = WatchCompile.default || WatchCompile;
|
|
//compile src to app
|
|
WatchCompile.compile(srcPath, outPath, {
|
|
type: 'ts'
|
|
});
|
|
|