Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
darakuneko committed May 24, 2024
2 parents 85659d9 + 01ea957 commit e571f07
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions command.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const Store = require("electron-store")
const store = new Store()
const {app} = require("electron")

const dockerVersion = "gpk_fwmaker_0006"
const dockerVersion = /gpk_fwmaker_0006/
const cmdVersion = undefined

if (process.platform === 'darwin') process.env.PATH = `/usr/local/bin:${process.env.PATH}`
Expand Down Expand Up @@ -73,7 +73,8 @@ const command = {
upImage: async (mainWindow) => {
if (!skipCheckDocker) {
const cmd = async (result) => {
const isDockerVersion = result.stdout.match(dockerVersion)
const isDockerVersion = dockerVersion.test(result.stdout);
state.cmdVersion = state.cmdVersion ? state.cmdVersion : undefined
if (isDockerVersion && state.cmdVersion === cmdVersion) return "docker compose start"
else if (isDockerVersion && state.cmdVersion !== cmdVersion) {
state.cmdVersion = cmdVersion
Expand All @@ -82,7 +83,6 @@ const command = {
}
else return "docker compose up -d --build --force-recreate"
}

const result = await appExe("docker images")
const res = spawn(appSpawn(await cmd(result)), {shell: true})
streamLog(res, mainWindow, true)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"dist:linux": "npm run build && electron-builder -l"
},
"name": "gpk_fwbuilder",
"version": "0.10.2",
"version": "0.10.3",
"description": "GPK FWBuilder",
"homepage": "https://github.com/darakuneko",
"author": {
Expand Down

0 comments on commit e571f07

Please sign in to comment.