Skip to content

Commit 1578184

Browse files
Jerry XieJerry Xie
authored andcommitted
fix: include GUI apps (casks) when installing from remote config
When installing from a remote config (e.g., 'openboot install jx'), GUI apps (casks) were being silently skipped. The code only added CLI packages to the SelectedPkgs map but never added the Casks. This fix adds the missing loop to include casks in both: - internal/installer/installer.go (runCustomInstall) - internal/installer/step_packages.go (stepPackageCustomization) Closes #17
1 parent b859bc0 commit 1578184

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

internal/installer/installer.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,9 @@ func runCustomInstall(opts *config.InstallOptions, st *config.InstallState) erro
142142
for _, pkg := range st.RemoteConfig.Packages {
143143
st.SelectedPkgs[pkg.Name] = true
144144
}
145+
for _, cask := range st.RemoteConfig.Casks {
146+
st.SelectedPkgs[cask.Name] = true
147+
}
145148

146149
if err := stepInstallPackages(opts, st); err != nil {
147150
return err

internal/installer/step_packages.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,11 @@ func stepPackageCustomization(opts *config.InstallOptions, st *config.InstallSta
146146
st.SelectedPkgs[pkg.Name] = true
147147
}
148148
}
149+
if st.RemoteConfig != nil && len(st.RemoteConfig.Casks) > 0 {
150+
for _, cask := range st.RemoteConfig.Casks {
151+
st.SelectedPkgs[cask.Name] = true
152+
}
153+
}
149154

150155
count := 0
151156
for _, v := range selected {

0 commit comments

Comments
 (0)