Repository navigation
GH197: Take Cake.Sdk verbosity from configuration, command line wins - #198
Merged
Merged
Conversation
…d line wins - Make `CakeAppSettings.Verbosity` nullable and drop `[DefaultValue(Verbosity.Normal)]`, so an omitted `--verbosity` is distinguishable from an explicit `--verbosity normal` - Resolve the effective verbosity through `ICakeConfiguration.GetVerbosity`, giving command line first, then configuration, then `Normal`, matching Cake.Tool and Frosting - Apply the command line verbosity before setting the working directory, so failures while setting it are still logged at the requested level - Build `ICakeConfiguration` from `ICakeEnvironment.WorkingDirectory` rather than `Environment.CurrentDirectory`, so `--working` decides where `cake.config` is read from for every file based setting, not just verbosity - Update the generated code snapshots across all generator scenarios - Add an `IntegrationTest-Verbosity` step covering the precedence chain end to end: `CAKE_SETTINGS_VERBOSITY` alone, command line overriding it in both directions, and a `cake.config` inside versus outside the working directory - fixes cake-build#197
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
CakeAppSettings.Verbositynullable and drop[DefaultValue(Verbosity.Normal)], so an omitted--verbosityis distinguishable from an explicit--verbosity normalICakeConfiguration.GetVerbosity, giving command line first, then configuration, thenNormal, matching Cake.Tool and FrostingICakeConfigurationfromICakeEnvironment.WorkingDirectoryrather thanEnvironment.CurrentDirectory, so--workingdecides wherecake.configis read from for every file based setting, not just verbosityIntegrationTest-Verbositystep covering the precedence chain end to end:CAKE_SETTINGS_VERBOSITYalone, command line overriding it in both directions, and acake.configinside versus outside the working directory