mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
The exact borderline between "Isobuild" and "the tool" is a little hazy, but the idea is that "Isobuild" is the part that you could imagine being embedded in a non-command-line build tool. It's not about commands or UI, but just about building packages and apps. A next step could be moving things that are strictly "the command-line tool" into their own subdir, and leaving the top directory mostly just for shared utilities like buildmessage. (Which could even go in a utils subdir?)
38 lines
872 B
JavaScript
38 lines
872 B
JavaScript
var buildPluginModule = require('./build-plugin.js');
|
|
var util = require('util');
|
|
var _ = require('underscore');
|
|
|
|
exports.LinterPlugin = function (pluginDefinition, userPlugin) {
|
|
var self = this;
|
|
self.userPlugin = userPlugin;
|
|
self.pluginDefinition = pluginDefinition;
|
|
};
|
|
|
|
var LintingFile = exports.LintingFile = function (source) {
|
|
buildPluginModule.InputFile.call(this);
|
|
|
|
var self = this;
|
|
self._source = source;
|
|
};
|
|
|
|
util.inherits(LintingFile, buildPluginModule.InputFile);
|
|
|
|
_.extend(LintingFile.prototype, {
|
|
getContentsAsBuffer: function () {
|
|
return this._source.contents;
|
|
},
|
|
getPathInPackage: function () {
|
|
return this._source.relPath;
|
|
},
|
|
getPackageName: function () {
|
|
return this._source['package'];
|
|
},
|
|
getSourceHash: function () {
|
|
return this._source.hash;
|
|
},
|
|
getArch: function () {
|
|
return this._source.arch;
|
|
}
|
|
});
|
|
|