mirror of
https://gitlab.com/futo-org/fcast.git
synced 2025-06-24 21:25:23 +00:00
Fixed terminal version and help flags
This commit is contained in:
parent
ec94437c0d
commit
ce0865bca6
1 changed files with 12 additions and 11 deletions
|
@ -420,9 +420,20 @@ export default class Main {
|
|||
static async main(app: Electron.App) {
|
||||
try {
|
||||
Main.application = app;
|
||||
|
||||
const argv = yargs(hideBin(process.argv))
|
||||
.version(app.getVersion())
|
||||
.parserConfiguration({
|
||||
'boolean-negation': false
|
||||
})
|
||||
.options({
|
||||
'no-main-window': { type: 'boolean', default: false, desc: "Start minimized to tray" },
|
||||
'fullscreen': { type: 'boolean', default: false, desc: "Start application in fullscreen" }
|
||||
})
|
||||
.parseSync();
|
||||
|
||||
const isUpdating = Updater.isUpdating();
|
||||
const fileLogType = isUpdating ? 'fileSync' : 'file';
|
||||
|
||||
log4js.configure({
|
||||
appenders: {
|
||||
out: { type: 'stdout' },
|
||||
|
@ -442,16 +453,6 @@ export default class Main {
|
|||
await Updater.processUpdate();
|
||||
}
|
||||
|
||||
const argv = yargs(hideBin(process.argv))
|
||||
.parserConfiguration({
|
||||
'boolean-negation': false
|
||||
})
|
||||
.options({
|
||||
'no-main-window': { type: 'boolean', default: false, desc: "Start minimized to tray" },
|
||||
'fullscreen': { type: 'boolean', default: false, desc: "Start application in fullscreen" }
|
||||
})
|
||||
.parseSync();
|
||||
|
||||
Main.startFullscreen = argv.fullscreen;
|
||||
Main.shouldOpenMainWindow = !argv.noMainWindow;
|
||||
Main.application.on('ready', Main.onReady);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue