Skip to content

Commit

Permalink
require '-tags exp' for hybrid / server builds
Browse files Browse the repository at this point in the history
  • Loading branch information
tmclane committed May 1, 2024
1 parent cc6158b commit 4cdc166
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 6 deletions.
7 changes: 7 additions & 0 deletions v2/cmd/wails/internal/commands/build/build.go
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,13 @@ func AddBuildSubcommand(app *clir.Cli, w io.Writer) {
}
}

// Validate experimental
if slicer.String([]string{"hybrid", "server"}).Contains(outputType) {
if !slicer.String(userTags).Contains("exp") {
return fmt.Errorf("output type '%s' requires the '-tags exp'", outputType)
}
}

// Webview2 installer strategy (download by default)
wv2rtstrategy := ""
webview2 = strings.ToLower(webview2)
Expand Down
4 changes: 2 additions & 2 deletions v2/internal/app/app_hybrid_server.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//go:build hybrid || server
// +build hybrid server
//go:build (exp && hybrid) || (exp && server)
// +build exp,hybrid exp,server

package app

Expand Down
4 changes: 2 additions & 2 deletions v2/internal/frontend/hybrid/hybrid.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//go:build hybrid
// +build hybrid
//go:build exp && hybrid
// +build exp,hybrid

package hybrid

Expand Down
4 changes: 2 additions & 2 deletions v2/internal/frontend/hybrid/server.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//go:build server
// +build server
//go:build exp && server
// +build exp,server

package hybrid

Expand Down

0 comments on commit 4cdc166

Please sign in to comment.