Skip to content

Commit

Permalink
fix(apps): allow override path and args
Browse files Browse the repository at this point in the history
  • Loading branch information
fiftin committed Jul 10, 2024
1 parent c75aaaa commit 3a71336
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions db_lib/ShellApp.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,13 +91,17 @@ func (t *ShellApp) makeShellCmd(args []string, environmentVars *[]string) *exec.
command = "powershell"
appArgs = []string{"-File"}
default:
if app, ok := util.Config.Apps[string(t.App)]; ok && app.AppPath != "" {
command = app.AppPath
}

if app, ok := util.Config.Apps[string(t.App)]; ok && app.AppPath != "" {
command = app.AppPath
if app.AppArgs != nil {
appArgs = app.AppArgs
} else {
command = string(t.App)
}
} else {
command = string(t.App)
}

return t.makeCmd(command, append(appArgs, args...), environmentVars)
}

Expand Down

0 comments on commit 3a71336

Please sign in to comment.