This repository has been archived by the owner on Nov 3, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
15 changed files
with
65 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
/** | ||
* FileName: baseAction.js | ||
* Author: @mxfli | ||
* CreateTime: 2011-12-09 22:06 | ||
* Description: | ||
* Description of baseAction.js | ||
*/ | ||
var ota = require("../module/ota.js"); | ||
|
||
exports.registerActions = function (app, templateEngine) { | ||
app.get("/", function (req, res, next) { | ||
next(new Error("method not implements.")); | ||
}); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
//show runtime info on console every 1 minute | ||
var express = require('express'); | ||
(function appInfo() { | ||
//print app info on the console | ||
console.log("\n#############################################"); | ||
console.log("## ", config.appName, config.version); | ||
console.log('## Running under "Express" middleware'); | ||
console.log('## Express version:', express.version); | ||
console.log('## Node.js version:', process.version); | ||
console.log("#############################################\n"); | ||
|
||
function sysInfo() { | ||
console.log("System memory usage:", (process.memoryUsage().rss / (1024 * 1024)).toFixed(2), "Mb"); | ||
} | ||
|
||
process.title = config.appName; | ||
sysInfo(); | ||
|
||
setInterval(sysInfo, 1000 * 600); | ||
})(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
/** | ||
* FileName: common.js | ||
* Author: @mxfli | ||
* CreateTime: 2010-08-15 00:52 | ||
* Description: | ||
* Including common files, others should include this file. | ||
*/ | ||
|
||
process.env['MONGO_NODE_DRIVER_HOST'] = "localhost"; | ||
process.env['MONGO_NODE_DRIVER_PORT'] = 27017; | ||
process.env['MONGO_NODE_DATABASE_NAME'] = "wap_game"; | ||
|
||
var myUtil = require("./util.js"); | ||
var sysUtil = require("util"); | ||
|
||
//var util = Object.create(sysUtil, myUtil.prototype); | ||
Object.keys(myUtil).forEach(function(key) { | ||
sysUtil[key] = myUtil[key]; | ||
}); | ||
|
||
global.util = sysUtil; //merge node utils and custom utils. | ||
global.config = require("./config/config.js"); | ||
global.assert = require("assert"); | ||
//load patchs | ||
//util.loadPatch(__dirname + "/patch"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.