2012-05-02 10:02:47 +00:00
|
|
|
/*\
|
2012-05-03 20:47:16 +00:00
|
|
|
title: $:/core/modules/commands/version.js
|
2012-05-02 10:02:47 +00:00
|
|
|
type: application/javascript
|
|
|
|
module-type: command
|
|
|
|
|
2012-05-02 14:02:58 +00:00
|
|
|
Version command
|
2012-05-02 10:02:47 +00:00
|
|
|
|
|
|
|
\*/
|
|
|
|
(function(){
|
|
|
|
|
|
|
|
/*jslint node: true, browser: true */
|
|
|
|
"use strict";
|
|
|
|
|
|
|
|
exports.info = {
|
|
|
|
name: "version",
|
2012-05-02 16:26:36 +00:00
|
|
|
synchronous: true
|
2012-05-02 10:02:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
var Command = function(params,commander) {
|
|
|
|
this.params = params;
|
|
|
|
this.commander = commander;
|
|
|
|
};
|
|
|
|
|
|
|
|
Command.prototype.execute = function() {
|
|
|
|
this.commander.streams.output.write($tw.utils.getVersionString() + "\n");
|
2012-05-02 14:02:58 +00:00
|
|
|
return null; // No error
|
2012-05-02 10:02:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
exports.Command = Command;
|
|
|
|
|
|
|
|
})();
|