Skip to main content

defaultconfiguration

Specifies the default build configuration for a workspace.

defaultconfiguration ("configuration_name")

If a default configuration is not specified through this API, the first configuration in alphabetical order from configurations will be used as the default.

Parameters

configuration_name - The name of the build configuration to use as default.

Applies To

Workspace configurations.

Availability

Premake 5.0.0 or later.

Examples

workspace "MyWorkspace"
configurations { "Debug", "Release" }
defaultconfiguration "Release"

When combined with defaultplatform, Premake will prefer the configuration/platform pair that matches both settings.

workspace "MyWorkspace"
configurations { "Debug", "Release" }
platforms { "x86", "x64" }
defaultconfiguration "Release"
defaultplatform "x64"

See Also