We need a feature toggle mechanism to allow new features to be built and released from the mainline at any time.
The PowerShell team ships experimental features with their preview and stable builds. They are disabled by default and controlled by a json file called powershell.config.json
PS /Users/megamorf> Get-ExperimentalFeature
Name Enabled Source Description
---- ------- ------ -----------
PSCommandNotFoundSuggestion False PSEngine Recommend potential commands based on fuzzy search on a CommandNotFoundException
PSImplicitRemotingBatching False PSEngine Batch implicit remoting proxy commands to improve performance
PSNullConditionalOperators False PSEngine Support the null conditional member access operators in PowerShell language
PSUnixFileStat False PSEngine Provide unix permission information for files and directories
Microsoft.PowerShell.Utility.PSMan… False /usr/local/microsoft/powershell/7/… Enables -BreakAll parameter on Debug-Runspace and Debug-Job cmdlets to allow users to decide if they want PowerShell to break immediately in the current location when they attach a debugger.
PSDesiredStateConfiguration.Invoke… False /usr/local/microsoft/powershell/7/… Enables the Invoke-DscResource cmdlet and related features.
You might get some inspiration from their RFC:
https://github.com/PowerShell/PowerShell-RFC/blob/master/5-Final/RFC0029-Support-Experimental-Features.md
Most helpful comment
The PowerShell team ships experimental features with their preview and stable builds. They are disabled by default and controlled by a json file called
powershell.config.jsonYou might get some inspiration from their RFC:
https://github.com/PowerShell/PowerShell-RFC/blob/master/5-Final/RFC0029-Support-Experimental-Features.md