CompletionInstaller constructor

CompletionInstaller({
  1. Map<String, String>? environment,
  2. String? operatingSystem,
  3. String? powerShellProfile()?,
})

environment and operatingSystem default to those of the process.

powerShellProfile returns the path of the PowerShell profile on Windows, or null if unknown. By default PowerShell is asked for it, since the location depends on the PowerShell edition and on where the user's documents folder is. Elsewhere the path follows from the environment.

Implementation

CompletionInstaller({
  final Map<String, String>? environment,
  final String? operatingSystem,
  final String? Function()? powerShellProfile,
}) : this._(
       environment ?? Platform.environment,
       operatingSystem ?? Platform.operatingSystem,
       powerShellProfile ?? _askPowerShellForProfile,
     );