Skip to content

Commit

Permalink
If packageDir does not exist, run Install
Browse files Browse the repository at this point in the history
  • Loading branch information
blast-hardcheese committed Feb 15, 2024
1 parent f33424b commit 7c52057
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion internal/cli/cmds.go
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,11 @@ func maybeInstall(ctx context.Context, b api.LanguageBackend, forceInstall bool)
if !util.Exists(b.Specfile) {
return
}
if forceInstall || store.HasSpecfileChanged(b) {
var needsPackageDir bool
if packageDir := b.GetPackageDir(); packageDir != "" {
needsPackageDir = !util.Exists(packageDir)
}
if forceInstall || store.HasSpecfileChanged(b) || needsPackageDir {
b.Install(ctx)
}
}
Expand Down

0 comments on commit 7c52057

Please sign in to comment.