chore: Use forge config for current version of desktop
This commit is contained in:
3 files changed
+9
-3
No files matched your search
@@ -72,7 +72,8 @@ These environment variables may be used to customized the build.
|
||||
| Variable | Description |
|
||||
| -------- | ----------- |
|
||||
| `DEBUG_APP_UPDATER` | Enable to debug app updater feature. Must be enabled for all `APP_UPDATER_*` variables to be used. |
|
||||
| `APP_UPDATER_LATEST_VERSION_TAG` | Version string for comparison with current release version. |
|
||||
| `APP_UPDATER_CURRENT_VERSION` | Version of client. |
|
||||
| `APP_UPDATER_LATEST_VERSION_TAG` | Next version for comparison with current version. |
|
||||
| `APP_UPDATER_LATEST_VERSION_LOCATION` | Location of app release to use for updating client. Can be a filepath or url. |
|
||||
|
||||
### Building for Production
|
||||
|
||||
@@ -18,12 +18,13 @@ console.log('RELEASE_VERSION ', process.env.RELEASE_VERSION);
|
||||
console.log('RELEASE_COMMIT ', process.env.RELEASE_COMMIT);
|
||||
|
||||
module.exports = {
|
||||
releaseVersion: process.env.RELEASE_VERSION,
|
||||
hooks: {
|
||||
prePackage: () => {
|
||||
if (!process.env.BOUNDARY_DESKTOP_SIGNING_IDENTITY) {
|
||||
console.warn('\nWARNING: Could not find signing identity.');
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
packagerConfig: {
|
||||
ignore: ['/ember-test(/|$)', '/tests(/|$)'],
|
||||
|
||||
@@ -4,10 +4,14 @@ const https = require('https');
|
||||
const semver = require('semver');
|
||||
const { parse } = require('node-html-parser');
|
||||
const { autoUpdater, dialog } = require('electron');
|
||||
const { releaseVersion } = require('../config/forge.config.js');
|
||||
|
||||
const debug = process.env.DEBUG_APP_UPDATER;
|
||||
const releasesUrl = 'https://releases.hashicorp.com/boundary-desktop/';
|
||||
const currentVersion = '1.0.0-beta';
|
||||
let currentVersion = releaseVersion;
|
||||
if (debug && process.env.APP_UPDATER_CURRENT_VERSION) {
|
||||
currentVersion = process.env.APP_UPDATER_CURRENT_VERSION;
|
||||
}
|
||||
|
||||
// Query releases url to find latest version
|
||||
const findLatestVersion = (url) => {
|
||||
|
||||
Reference in new issue
Block a user