diff --git a/.env.example b/.env.example index 5f8e07890..f6a88375f 100644 --- a/.env.example +++ b/.env.example @@ -1,4 +1,5 @@ FORK_URL= NODE_ENV= +DEV_RPC= STAKING_TEST_KEYS_PATH= -DEV_RPC= \ No newline at end of file +IS_STAGING= diff --git a/build.js b/build.js index 29e953fc4..a5059c953 100644 --- a/build.js +++ b/build.js @@ -1,6 +1,6 @@ const dotenv = require('dotenv'); const build = require('electron-builder').build; -const {publishOptions} = require('./electron/constants/publishOptions'); +const { publishOptions } = require('./electron/constants/publishOptions'); dotenv.config(); @@ -24,7 +24,7 @@ const main = async () => { target: [ { target: 'default', - arch: ['x64','arm64'], + arch: ['x64', 'arm64'], }, ], publish: publishOptions, @@ -35,11 +35,11 @@ const main = async () => { entitlements: 'electron/entitlements.mac.plist', entitlementsInherit: 'electron/entitlements.mac.plist', notarize: { - teamId: process.env.APPLETEAMID + teamId: process.env.APPLETEAMID, }, }, }, }); }; -main().then((response) => { console.log('Build & Notarize complete'); }).catch((e) => console.error(e)); \ No newline at end of file +main().then((response) => { console.log('Build & Notarize complete'); }).catch((e) => console.error(e)); diff --git a/electron/constants/publishOptions.js b/electron/constants/publishOptions.js index 1ecbc1d4e..3c57fb66d 100644 --- a/electron/constants/publishOptions.js +++ b/electron/constants/publishOptions.js @@ -2,10 +2,11 @@ const publishOptions = { provider: 'github', owner: 'valory-xyz', repo: 'olas-operate-app', - releaseType: 'release', token: process.env.GH_TOKEN, private: false, publishAutoUpdate: true, + releaseType: process.env.IS_STAGING === 'true' ? 'prerelease' : 'release', + channel: process.env.IS_STAGING === 'true' ? 'alpha' : 'latest', }; module.exports = { publishOptions };