Created create-installer scripts
This commit is contained in:
parent
bddeebb2a9
commit
8ab47f9e42
8 changed files with 452 additions and 42 deletions
16
installers/create-appx.js
Normal file
16
installers/create-appx.js
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
const convertToWindowsStore = require('electron-windows-store')
|
||||
const path = require('path')
|
||||
|
||||
convertToWindowsStore({
|
||||
containerVirtualization: false,
|
||||
inputDirectory: path.join(__dirname, '../release-builds/openflexure-microscope-js-win32-x64'),
|
||||
outputDirectory: path.join(__dirname, '/release-builds'),
|
||||
assets: path.join(__dirname, '/appx/assets'),
|
||||
manifest: path.join(__dirname, '/appx/AppXManifest.xml'),
|
||||
packageName: 'OpenFlexureMicroscopeJS',
|
||||
deploy: false,
|
||||
publisher: 'CN=bath-open-instrumentation-group',
|
||||
publisherDisplayName: "Bath Open Instrumentation Group",
|
||||
devCert: "C:\\Users\\jtc92\\AppData\\Roaming\\electron-windows-store\\bath-open-instrumentation-group\\bath-open-instrumentation-group.pfx",
|
||||
windowsKit: 'C:\\Program Files (x86)\\Windows Kits\\10\\bin\\10.0.17763.0\\x64'
|
||||
})
|
||||
24
installers/create-deb-arm.js
Normal file
24
installers/create-deb-arm.js
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
const installer = require('electron-installer-debian')
|
||||
const path = require('path')
|
||||
|
||||
const options = {
|
||||
src: path.join(__dirname, '../release-builds/openflexure-microscope-js-linux-armv7l/'),
|
||||
dest: path.join(__dirname, '/release-builds'),
|
||||
arch: 'armhf',
|
||||
icon: path.join(__dirname, '../icons/png/1024x1024.png'),
|
||||
categories: [
|
||||
"Science"
|
||||
],
|
||||
lintianOverrides: [
|
||||
"changelog-file-missing-in-native-package"
|
||||
]
|
||||
}
|
||||
|
||||
console.log('Creating package (this may take a while)')
|
||||
|
||||
installer(options)
|
||||
.then(() => console.log(`Successfully created package at ${options.dest}`))
|
||||
.catch(err => {
|
||||
console.error(err, err.stack)
|
||||
process.exit(1)
|
||||
})
|
||||
24
installers/create-deb-x64.js
Normal file
24
installers/create-deb-x64.js
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
const installer = require('electron-installer-debian')
|
||||
const path = require('path')
|
||||
|
||||
const options = {
|
||||
src: path.join(__dirname, '../release-builds/openflexure-microscope-js-linux-x64/'),
|
||||
dest: path.join(__dirname, '/release-builds'),
|
||||
arch: 'amd64',
|
||||
icon: path.join(__dirname, '../icons/png/1024x1024.png'),
|
||||
categories: [
|
||||
"Science"
|
||||
],
|
||||
lintianOverrides: [
|
||||
"changelog-file-missing-in-native-package"
|
||||
]
|
||||
}
|
||||
|
||||
console.log('Creating package (this may take a while)')
|
||||
|
||||
installer(options)
|
||||
.then(() => console.log(`Successfully created package at ${options.dest}`))
|
||||
.catch(err => {
|
||||
console.error(err, err.stack)
|
||||
process.exit(1)
|
||||
})
|
||||
23
installers/create-exe.js
Normal file
23
installers/create-exe.js
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
const createWindowsInstaller = require('electron-winstaller').createWindowsInstaller
|
||||
const path = require('path')
|
||||
|
||||
getInstallerConfig()
|
||||
.then(createWindowsInstaller)
|
||||
.catch((error) => {
|
||||
console.error(error.message || error)
|
||||
process.exit(1)
|
||||
})
|
||||
|
||||
function getInstallerConfig () {
|
||||
console.log('creating windows installer')
|
||||
|
||||
return Promise.resolve({
|
||||
appDirectory: path.join(__dirname, '../release-builds/openflexure-microscope-js-win32-x64'),
|
||||
authors: 'OpenFlexure',
|
||||
noMsi: true,
|
||||
outputDirectory: path.join(__dirname, '/release-builds'),
|
||||
exe: 'openflexure-microscope-js.exe',
|
||||
setupExe: 'OpenFlexureMicroscopeJsInstaller.exe',
|
||||
setupIcon: path.join(__dirname, '../icons/win/icon.ico')
|
||||
})
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue