You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-06-15 23:00:36 +02:00
Cross-platform version number retrieval (#2355)
* Add shim to retrieve application version. * Create shim to retrieve app version number. * Add a fall through handler to throw an error.
This commit is contained in:
@ -378,6 +378,15 @@ function shimInit() {
|
||||
};
|
||||
|
||||
shim.waitForFrame = () => {};
|
||||
|
||||
shim.appVersion = () => {
|
||||
if (shim.isElectron()) {
|
||||
const p = require('../packageInfo.js');
|
||||
return p.version;
|
||||
}
|
||||
const p = require('../package.json');
|
||||
return p.version;
|
||||
};
|
||||
}
|
||||
|
||||
module.exports = { shimInit };
|
||||
|
Reference in New Issue
Block a user