compile
This commit is contained in:
parent
61d7ac981b
commit
d9f75c236f
6
dist/index.js
vendored
6
dist/index.js
vendored
@ -28,7 +28,7 @@ class SmartUpdate {
|
|||||||
let lastCheckTimeStamp = smarttime_1.TimeStamp.fromMilliSeconds(result.lastCheck);
|
let lastCheckTimeStamp = smarttime_1.TimeStamp.fromMilliSeconds(result.lastCheck);
|
||||||
let compareTime = plugins.smarttime.getMilliSecondsFromUnits({ hours: 1 });
|
let compareTime = plugins.smarttime.getMilliSecondsFromUnits({ hours: 1 });
|
||||||
if (!lastCheckTimeStamp.isOlderThan(timeStamp, compareTime)) {
|
if (!lastCheckTimeStamp.isOlderThan(timeStamp, compareTime)) {
|
||||||
plugins.beautylog.log(`smartupdate: next check tomorrow: ` +
|
plugins.beautylog.log(`smartupdate: next check in : ` +
|
||||||
`${plugins.beautycolor.coloredString(`${npmnameArg} has already been checked within the last hour.`, 'pink')}`);
|
`${plugins.beautycolor.coloredString(`${npmnameArg} has already been checked within the last hour.`, 'pink')}`);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -54,7 +54,7 @@ class SmartUpdate {
|
|||||||
// create Version objects
|
// create Version objects
|
||||||
let versionNpm = new plugins.smartversion.SmartVersion(npmPackage.version);
|
let versionNpm = new plugins.smartversion.SmartVersion(npmPackage.version);
|
||||||
let versionLocal = new plugins.smartversion.SmartVersion(localVersionStringArg);
|
let versionLocal = new plugins.smartversion.SmartVersion(localVersionStringArg);
|
||||||
if (versionNpm.greaterThan(versionLocal)) {
|
if (!versionNpm.greaterThan(versionLocal)) {
|
||||||
plugins.beautylog.ok(`smartupdate: You are running the latest version of ${plugins.beautycolor.coloredString(npmPackage.name, 'pink')}`);
|
plugins.beautylog.ok(`smartupdate: You are running the latest version of ${plugins.beautycolor.coloredString(npmPackage.name, 'pink')}`);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -72,4 +72,4 @@ class SmartUpdate {
|
|||||||
}
|
}
|
||||||
exports.SmartUpdate = SmartUpdate;
|
exports.SmartUpdate = SmartUpdate;
|
||||||
exports.standardHandler = new SmartUpdate();
|
exports.standardHandler = new SmartUpdate();
|
||||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi90cy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7O0FBQUEsaURBQWdEO0FBRWhELHlDQUFxQztBQVVyQztJQUFBO1FBQ0UsWUFBTyxHQUFHLElBQUksT0FBTyxDQUFDLFFBQVEsQ0FBQyxhQUFhLENBQUMsUUFBUSxFQUFFLG9CQUFvQixDQUFDLENBQUE7SUErRDlFLENBQUM7SUE3RE8sS0FBSyxDQUFFLFVBQWtCLEVBQUUsY0FBc0IsRUFBRSxlQUF3Qjs7WUFDL0UsSUFBSSxNQUFNLEdBQWlCLE1BQU0sSUFBSSxDQUFDLE9BQU8sQ0FBQyxPQUFPLENBQUMsVUFBVSxDQUFDLENBQUE7WUFDakUsSUFBSSxTQUFTLEdBQUcsSUFBSSxxQkFBUyxFQUFFLENBQUE7WUFFL0IsdUJBQXVCO1lBQ3ZCLElBQUksT0FBTyxHQUFHO2dCQUNaLFNBQVMsRUFBRSxTQUFTLENBQUMsWUFBWTtnQkFDakMsYUFBYSxFQUFFLE9BQU87Z0JBQ3RCLGdCQUFnQixFQUFFLEtBQUs7YUFDeEIsQ0FBQTtZQUNELEVBQUUsQ0FBQyxDQUFDLE1BQU0sQ0FBQyxDQUFDLENBQUM7Z0JBQ1gsSUFBSSxrQkFBa0IsR0FBRyxxQkFBUyxDQUFDLGdCQUFnQixDQUFDLE1BQU0sQ0FBQyxTQUFTLENBQUMsQ0FBQTtnQkFDckUsSUFBSSxXQUFXLEdBQUcsT0FBTyxDQUFDLFNBQVMsQ0FBQyx3QkFBd0IsQ0FBQyxFQUFFLEtBQUssRUFBRSxDQUFDLEVBQUUsQ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LGFBQWEsQ0FBQyxVQUFVLENBQUMsSUFBSSxFQUFFLE1BQU0sQ0FBQyxFQUFFLENBQUMsQ0FBQTtnQkFDeEksTUFBTSxDQUFDLEtBQUssQ0FBQTtZQUNkLENBQUM7WUFBQyxJQUFJLENBQUMsQ0FBQztnQkFDTixPQUFPLENBQUMsU0FBUyxDQUFDLElBQUksQ0FBQywrQkFBK0IsVUFBVSxDQUFDLElBQUksb0JBQW9CLENBQUMsQ0FBQTtnQkFDMUYsT0FBTyxDQUFDLFNBQVMsQ0FBQyxJQUFJLENBQUMsaUJBQWlCLFlBQVksQ0FBQyxhQUFhLHNCQUFzQixVQUFVLENBQUMsYUFBYSxFQUFFLENBQUMsQ0FBQTtnQkFDbkgsRUFBRSxDQUFDLENBQUMsQ0FBQyxPQUFPLENBQUMsR0FBRyxDQUFDLEVBQUUsSUFBSSxlQUFlLENBQUMsQ0FBQyxDQUFDO29CQUN2QyxPQUFPLENBQUMsU0FBUyxDQUFDLEdBQUcsQ0FBQyw2QkFBNkIsQ0FBQyxDQUFBO29CQUNwRCxPQUFPLENBQUMsU0FBUyxDQUFDLE9BQU8sQ0FBQyxlQUFlLENBQUMsQ0FBQTtnQkFDNUMsQ0FBQztnQkFDRCxNQUFNLENBQUMsSUFBSSxDQUFBO1lBQ2IsQ0FBQztRQUNILENBQUM7S0FBQTtDQUNGO0FBaEVELGtDQWdFQztBQUNVLFFBQUEsZUFBZSxHQUFHLElBQUksV0FBVyxFQUFFLENBQUEifQ==
|
@ -61,7 +61,7 @@ export class SmartUpdate {
|
|||||||
// create Version objects
|
// create Version objects
|
||||||
let versionNpm = new plugins.smartversion.SmartVersion(npmPackage.version)
|
let versionNpm = new plugins.smartversion.SmartVersion(npmPackage.version)
|
||||||
let versionLocal = new plugins.smartversion.SmartVersion(localVersionStringArg)
|
let versionLocal = new plugins.smartversion.SmartVersion(localVersionStringArg)
|
||||||
if (versionNpm.greaterThan(versionLocal)) {
|
if (!versionNpm.greaterThan(versionLocal)) {
|
||||||
plugins.beautylog.ok(`smartupdate: You are running the latest version of ${plugins.beautycolor.coloredString(npmPackage.name, 'pink')}`)
|
plugins.beautylog.ok(`smartupdate: You are running the latest version of ${plugins.beautycolor.coloredString(npmPackage.name, 'pink')}`)
|
||||||
return false
|
return false
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user