5 implementations of IShellProvider
System.CommandLine.StaticCompletions (5)
shells\BashShellProvider.cs (1)
12
public class BashShellProvider :
IShellProvider
shells\FishShellProvider.cs (1)
8
public class FishShellProvider :
IShellProvider
shells\NuShellShellProvider.cs (1)
8
public class NushellShellProvider :
IShellProvider
shells\PowershellShellProvider.cs (1)
11
public class PowershellShellProvider :
IShellProvider
shells\ZshShellProvider.cs (1)
9
public class ZshShellProvider :
IShellProvider
17 references to IShellProvider
dotnet.Tests (2)
CompletionTests\DotnetCliSnapshotTests.cs (2)
17
var
provider = CompletionsCommand.DefaultShells.Single(x => x.ArgumentName == shellName);
34
public static IEnumerable<object[]> ShellNames = CompletionsCommand.DefaultShells.Select<
IShellProvider
, object[]>(x => [x.ArgumentName]);
System.CommandLine.StaticCompletions (11)
CompletionsCommand.cs (11)
14
public static
IShellProvider
[] DefaultShells = [
28
public CompletionsCommand(IEnumerable<
IShellProvider
>? supportedShells = null, string commandName = "completions", string? commandDescription = null) : this((supportedShells ?? DefaultShells).ToDictionary(s => s.ArgumentName, StringComparer.OrdinalIgnoreCase), commandName, commandDescription ?? Strings.CompletionsCommand_Description)
31
private CompletionsCommand(Dictionary<string,
IShellProvider
> shellMap, string commandName, string commandDescription) : base(commandName, commandDescription)
33
var shellArg = new Argument<
IShellProvider
>("shell")
59
static
IShellProvider
LookupShellFromEnvironment(Dictionary<string,
IShellProvider
> shellMap)
71
if (shellMap.TryGetValue(shellPath, out
var
shellProvider))
81
static Action<Parsing.ArgumentResult> OnlyAcceptSupportedShells(Dictionary<string,
IShellProvider
> shellMap)
97
static Func<CompletionContext, IEnumerable<CompletionItem>> CreateCompletions(Dictionary<string,
IShellProvider
> shellMap)
109
public GenerateScriptCommand(Argument<
IShellProvider
> shellArg)
115
IShellProvider
shell = args.GetValue(shellArg)!; // this cannot be null due to the way the shellArg is defined/configured
System.CommandLine.StaticCompletions.Tests (4)
BashShellProviderTests.cs (1)
14
private
IShellProvider
provider = new BashShellProvider();
PowershellProviderTests.cs (1)
15
private
IShellProvider
provider = new PowershellShellProvider();
VerifyExtensions.cs (1)
12
public static async Task Verify(this
IShellProvider
provider, Command command, ITestOutputHelper log, [CallerFilePath] string sourceFile = "")
ZshShellProviderTests.cs (1)
15
private
IShellProvider
_provider = new ZshShellProvider();