Redpoint.CommandLine 2025.1036.55

Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
dotnet add package Redpoint.CommandLine --version 2025.1036.55
                    
NuGet\Install-Package Redpoint.CommandLine -Version 2025.1036.55
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Redpoint.CommandLine" Version="2025.1036.55" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Redpoint.CommandLine" Version="2025.1036.55" />
                    
Directory.Packages.props
<PackageReference Include="Redpoint.CommandLine" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Redpoint.CommandLine --version 2025.1036.55
                    
#r "nuget: Redpoint.CommandLine, 2025.1036.55"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#addin nuget:?package=Redpoint.CommandLine&version=2025.1036.55
                    
Install Redpoint.CommandLine as a Cake Addin
#tool nuget:?package=Redpoint.CommandLine&version=2025.1036.55
                    
Install Redpoint.CommandLine as a Cake Tool

Redpoint.CommandLine

This library provides APIs for building dependency injected console applications, with both commands and option declarations being dependency injected.

To use this library, first define your command:

internal class SomeAction
{
	public class Options
	{
		public Option<string> SomeOpt = new Option<string>("--opt", "My option description.");

		// Add more fields or properties that use Option<> or Argument<> and they'll be automatically
		// registered to the command line parser.
	}

	public static Command CreateCommand(ICommandBuilder builder)
	{
		return new Command("some-action", "The description of your some-action command.");
	}

	public class CommandInstance : ICommandInstance
	{
        private readonly ILogger<CommandInstance> _logger;
        private readonly Options _options;

        public CommandInstance(
            ILogger<CommandInstance> logger,
            Options options)
        {
            _logger = logger;
            _options = options;
        }

        public Task<int> ExecuteAsync(ICommandInvocationContext context)
        {
            // Example on how to access an option's value.
            var value = context.ParseResult.GetValueForOption(_options.SomeOpt);

            // ... implement your command here ...
            _logger.LogInformation("Hello world!");

            // Return the exit code for the application.
            return Task.FromResult(0);
        }
	}
}

To register and execute commands, in your Program.Main:

// Use the command line builder APIs to build the root command.
var rootCommand = CommandLineBuilder.NewBuilder()
    .AddGlobalRuntimeServices((builder, services) =>
    {
        // Register global runtime services here, such as services.AddLogging(...)
    })
    .SetGlobalExecutionHandler(async (sp, executeCommand) =>
    {
        // Can be used to wrap execution of all commands, such as capturing
        // exceptions and logging them:

        var logger = sp.GetRequiredService<ILogger<Program>>();
        try
        {
            return await executeCommand().ConfigureAwait(true);
        }
        catch (Exception ex)
        {
            logger.LogError(ex, $"Uncaught exception during command execution: {ex}");
            return 1;
        }
    })
    // Add each of your commands like this:
    .AddCommand<SomeAction.CommandInstance, SomeAction.Options>(SomeAction.CreateCommand)
    // Then build the root command to use below.
    .Build("My console application description.");

// Parse and execute the command.
var exitCode = await rootCommand.InvokeAsync(args).ConfigureAwait(false);
await Console.Out.FlushAsync().ConfigureAwait(false);
await Console.Error.FlushAsync().ConfigureAwait(false);
Environment.Exit(exitCode);
throw new BadImageFormatException();
Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2025.1141.1424 105 7 days ago
2025.1140.383 121 9 days ago
2025.1140.377 131 9 days ago
2025.1139.983 122 9 days ago
2025.1139.952 122 9 days ago
2025.1139.941 122 9 days ago
2025.1139.855 119 9 days ago
2025.1139.850 121 9 days ago
2025.1139.837 123 9 days ago
2025.1139.811 126 9 days ago
2025.1139.806 119 9 days ago
2025.1139.796 123 9 days ago
2025.1139.729 119 9 days ago
2025.1139.719 121 9 days ago
2025.1139.706 131 9 days ago
2025.1139.694 123 9 days ago
2025.1139.679 117 9 days ago
2025.1139.662 124 9 days ago
2025.1139.638 123 9 days ago
2025.1139.628 126 9 days ago
2025.1139.626 126 9 days ago
2025.1139.619 126 9 days ago
2025.1139.605 123 9 days ago
2025.1139.600 125 9 days ago
2025.1139.583 125 9 days ago
2025.1139.573 121 9 days ago
2025.1139.564 121 9 days ago
2025.1139.552 119 9 days ago
2025.1139.543 123 9 days ago
2025.1138.909 123 10 days ago
2025.1136.150 194 13 days ago
2025.1135.267 202 14 days ago
2025.1135.143 205 14 days ago
2025.1133.453 218 15 days ago
2025.1133.351 212 16 days ago
2025.1133.349 209 16 days ago
2025.1133.347 211 16 days ago
2025.1130.236 61 19 days ago
2025.1129.831 92 19 days ago
2025.1129.346 111 20 days ago
2025.1129.345 111 20 days ago
2025.1121.1370 137 a month ago
2025.1119.450 141 a month ago
2025.1119.436 141 a month ago
2025.1119.409 141 a month ago
2025.1119.388 141 a month ago
2025.1119.360 131 a month ago
2025.1119.328 159 a month ago
2025.1119.299 143 a month ago
2025.1119.287 141 a month ago
2025.1116.868 68 a month ago
2025.1116.841 71 a month ago
2025.1116.444 73 a month ago
2025.1115.498 119 a month ago
2025.1115.491 118 a month ago
2025.1100.365 168 2 months ago
2025.1100.336 158 2 months ago
2025.1100.331 159 2 months ago
2025.1098.108 148 2 months ago
2025.1093.291 167 2 months ago
2025.1091.38 147 2 months ago
2025.1091.26 156 2 months ago
2025.1090.237 154 2 months ago
2025.1089.1386 151 2 months ago
2025.1083.515 403 2 months ago
2025.1083.408 329 2 months ago
2025.1083.398 330 2 months ago
2025.1083.125 334 2 months ago
2025.1080.41 139 2 months ago
2025.1075.357 135 2 months ago
2025.1073.332 132 2 months ago
2025.1072.541 147 3 months ago
2025.1072.536 148 3 months ago
2025.1064.602 210 3 months ago
2025.1064.546 220 3 months ago
2025.1062.589 156 3 months ago
2025.1061.513 111 3 months ago
2025.1060.490 107 3 months ago
2025.1059.134 115 3 months ago
2025.1057.1020 108 3 months ago
2025.1056.584 103 3 months ago
2025.1050.282 103 3 months ago
2025.1050.232 98 3 months ago
2025.1049.55 108 3 months ago
2025.1045.285 113 3 months ago
2025.1043.288 103 4 months ago
2025.1043.246 97 4 months ago
2025.1043.197 98 4 months ago
2025.1043.180 98 4 months ago
2025.1043.108 98 4 months ago
2025.1043.38 98 4 months ago
2025.1043.27 108 4 months ago
2025.1042.725 97 4 months ago
2025.1042.690 94 4 months ago
2025.1042.688 99 4 months ago
2025.1042.418 104 4 months ago
2025.1042.215 94 4 months ago
2025.1042.203 111 4 months ago
2025.1042.184 102 4 months ago
2025.1042.142 97 4 months ago
2025.1042.127 95 4 months ago
2025.1037.1327 98 4 months ago
2025.1036.280 105 4 months ago
2025.1036.55 99 4 months ago
2025.1035.1387 114 4 months ago
2025.1031.111 106 4 months ago
2025.1030.916 113 4 months ago
2025.1030.895 100 4 months ago
2025.1030.592 103 4 months ago
2025.1029.664 87 4 months ago
2025.1029.632 85 4 months ago
2025.1029.596 87 4 months ago
2025.1028.386 93 4 months ago
2025.1025.723 91 4 months ago
2025.1025.712 90 4 months ago
2025.1019.913 94 4 months ago
2025.1018.374 93 4 months ago
2025.1018.285 84 4 months ago
2025.1017.646 89 4 months ago
2025.1017.379 97 4 months ago
2025.1016.1370 92 4 months ago
2025.1016.765 89 4 months ago
2025.1016.712 91 4 months ago
2025.1016.550 85 4 months ago
2025.1016.541 87 4 months ago
2025.1016.532 91 4 months ago
2025.1016.325 79 4 months ago
2025.1016.308 84 4 months ago
2025.1016.296 80 4 months ago
2025.1016.237 88 4 months ago
2025.1016.184 86 4 months ago
2025.1016.70 86 4 months ago
2025.1016.6 84 4 months ago
2025.1015.1438 86 4 months ago
2025.1015.1437 83 4 months ago
2025.1015.1411 86 4 months ago
2025.1015.240 68 4 months ago
2025.1015.223 64 4 months ago
2025.1015.183 65 4 months ago
2025.1014.1342 72 4 months ago
2025.1014.273 82 4 months ago
2025.1014.256 84 4 months ago
2025.1012.440 98 5 months ago
2025.1012.327 83 5 months ago
2025.1012.279 88 5 months ago
2025.1002.636 107 5 months ago
2025.1001.1435 103 5 months ago
2025.1001.1397 102 5 months ago
2025.1001.770 112 5 months ago
2025.1001.570 114 5 months ago
2025.1001.558 104 5 months ago
2025.1001.421 113 5 months ago
2025.1001.390 107 5 months ago
2025.1001.234 118 5 months ago
2025.1001.123 108 5 months ago
2024.1360.354 99 5 months ago
2024.1360.60 95 5 months ago
2024.1360.32 99 5 months ago
2024.1358.450 106 5 months ago
2024.1358.359 97 5 months ago
2024.1358.312 103 5 months ago
2024.1358.244 100 5 months ago
2024.1358.120 108 5 months ago
2024.1348.253 107 6 months ago
2024.1345.1379 97 6 months ago
2024.1345.506 100 6 months ago
2024.1345.379 96 6 months ago
2024.1345.145 93 6 months ago
2024.1345.72 100 6 months ago
2024.1345.69 91 6 months ago
2024.1345.15 98 6 months ago
2024.1344.1436 99 6 months ago
2024.1344.600 109 6 months ago
2024.1344.411 98 6 months ago
2024.1340.379 105 6 months ago
2024.1340.15 106 6 months ago
2024.1338.786 102 6 months ago
2024.1338.722 116 6 months ago
2024.1338.697 105 6 months ago
2024.1338.639 107 6 months ago
2024.1338.541 105 6 months ago
2024.1338.318 97 6 months ago
2024.1338.298 101 6 months ago
2024.1338.98 111 6 months ago
2024.1337.756 107 6 months ago
2024.1337.634 105 6 months ago
2024.1337.625 105 6 months ago
2024.1337.621 108 6 months ago
2024.1337.594 103 6 months ago
2024.1337.136 87 6 months ago
2024.1336.793 107 6 months ago
2024.1336.773 107 6 months ago
2024.1336.305 104 6 months ago
2024.1336.12 110 6 months ago
2024.1335.1421 104 6 months ago
2024.1335.1384 105 6 months ago
2024.1334.1308 100 6 months ago
2024.1334.764 104 6 months ago
2024.1334.722 104 6 months ago
2024.1330.185 102 6 months ago
2024.1328.505 103 6 months ago
2024.1328.470 104 6 months ago
2024.1328.452 103 6 months ago
2024.1323.910 102 6 months ago
2024.1323.653 95 6 months ago
2024.1323.185 106 6 months ago
2024.1323.49 97 6 months ago
2024.1322.714 105 6 months ago
2024.1320.653 102 6 months ago
2024.1320.619 94 6 months ago
2024.1320.601 103 6 months ago
2024.1320.159 98 6 months ago
2024.1320.98 98 6 months ago
2024.1320.2 96 6 months ago
2024.1319.1431 104 6 months ago
2024.1319.1335 97 6 months ago
2024.1317.631 106 7 months ago
2024.1316.330 118 7 months ago
2024.1311.540 111 7 months ago
2024.1306.225 106 7 months ago
2024.1306.199 106 7 months ago
2024.1306.171 103 7 months ago
2024.1306.117 102 7 months ago
2024.1305.506 97 7 months ago
2024.1305.502 109 7 months ago
2024.1305.465 103 7 months ago
2024.1305.442 97 7 months ago
2024.1305.399 107 7 months ago
2024.1299.1070 97 7 months ago
2024.1289.621 103 7 months ago
2024.1289.338 101 7 months ago
2024.1277.836 107 8 months ago
2024.1277.711 101 8 months ago
2024.1277.695 102 8 months ago
2024.1270.409 112 8 months ago
2024.1269.621 127 8 months ago
2024.1269.619 112 8 months ago
2024.1269.605 114 8 months ago
2024.1242.282 121 9 months ago
2024.1242.261 103 9 months ago
2024.1242.233 124 9 months ago
2024.1238.829 121 9 months ago
2024.1238.327 144 9 months ago
2024.1225.297 133 10 months ago
2024.1205.140 89 7/23/2024
2024.1204.110 126 7/22/2024
2024.1204.62 92 7/22/2024
2024.1190.491 123 7/8/2024
2024.1177.305 128 6/25/2024
2024.1168.700 107 6/16/2024
2024.1168.649 121 6/16/2024
2024.1168.535 107 6/16/2024
2024.1167.643 116 6/15/2024
2024.1166.989 127 6/14/2024
2024.1166.818 99 6/14/2024
2024.1166.535 102 6/14/2024
2024.1166.422 119 6/14/2024
2024.1166.362 105 6/14/2024
2024.1166.360 104 6/14/2024
2024.1165.1212 110 6/13/2024
2024.1165.1160 100 6/13/2024
2024.1165.1019 114 6/13/2024
2024.1165.978 119 6/13/2024
2024.1165.920 114 6/13/2024
2024.1165.908 100 6/13/2024
2024.1165.873 99 6/13/2024
2024.1165.830 122 6/13/2024
2024.1165.806 128 6/13/2024
2024.1165.794 101 6/13/2024
2024.1165.792 115 6/13/2024
2024.1165.761 114 6/13/2024
2024.1165.743 115 6/13/2024
2024.1165.735 98 6/13/2024
2024.1165.713 122 6/13/2024
2024.1165.640 109 6/13/2024
2024.1165.574 118 6/13/2024
2024.1165.466 115 6/13/2024
2024.1165.417 133 6/13/2024
2024.1165.392 118 6/13/2024
2024.1164.341 92 6/12/2024
2024.1155.941 126 6/3/2024
2024.1140.783 126 5/19/2024
2024.1140.692 126 5/19/2024
2024.1140.673 106 5/19/2024
2024.1129.506 130 5/8/2024
2024.1128.831 144 5/7/2024
2024.1124.465 101 5/3/2024
2024.1123.1162 97 5/2/2024
2024.1123.1117 81 5/2/2024
2024.1123.1050 90 5/2/2024
2024.1122.352 128 5/1/2024
2024.1122.233 114 5/1/2024
2024.1115.1101 137 4/24/2024
2024.1115.1048 110 4/24/2024
2024.1115.932 119 4/24/2024
2024.1115.858 106 4/24/2024
2024.1115.665 116 4/24/2024
2024.1115.648 136 4/24/2024
2024.1115.591 110 4/24/2024
2024.1101.390 117 4/10/2024
2024.1100.741 135 4/9/2024
2024.1099.526 113 4/8/2024
2024.1099.466 119 4/8/2024
2024.1098.573 134 4/7/2024
2024.1095.977 116 4/4/2024
2024.1095.847 109 4/4/2024
2024.1095.604 117 4/4/2024
2024.1095.485 130 4/4/2024
2024.1094.930 112 4/3/2024
2024.1094.910 128 4/3/2024
2024.1094.387 127 4/3/2024
2024.1094.313 127 4/3/2024
2024.1093.520 125 4/2/2024
2024.1092.240 119 4/1/2024
2024.1089.1425 131 3/29/2024
2024.1089.983 116 3/29/2024
2024.1089.942 110 3/29/2024
2024.1089.2 116 3/29/2024
2024.1088.1343 141 3/28/2024
2024.1088.1139 132 3/28/2024
2024.1088.875 126 3/28/2024
2024.1088.700 146 3/28/2024
2024.1088.603 133 3/28/2024
2024.1088.590 106 3/28/2024
2024.1088.575 136 3/28/2024
2024.1088.561 137 3/28/2024
2024.1088.506 117 3/28/2024
2024.1088.18 115 3/28/2024
2024.1087.1181 148 3/27/2024
2024.1087.1173 116 3/27/2024
2024.1087.1143 136 3/27/2024
2024.1087.1108 120 3/27/2024
2024.1087.950 152 3/27/2024
2024.1087.939 127 3/27/2024
2024.1087.252 128 3/27/2024
2024.1070.736 148 3/10/2024
2024.1049.1437 158 2/19/2024
2024.1036.571 144 2/5/2024
2024.1036.508 109 2/5/2024
2024.1032.1204 121 2/1/2024
2024.1032.1133 109 2/1/2024
2024.1032.1122 125 2/1/2024
2024.1032.1071 105 2/1/2024
2024.1032.940 127 2/1/2024
2024.1031.912 122 1/31/2024
2024.1031.893 104 1/31/2024
2024.1031.851 123 1/31/2024
2024.1031.829 118 1/31/2024
2024.1031.386 133 1/31/2024
2024.1031.318 128 1/31/2024
2024.1017.460 136 1/17/2024
2024.1017.420 124 1/17/2024
2024.1017.163 124 1/17/2024
2024.1016.414 329 1/16/2024
2024.1012.167 145 1/12/2024
2024.1011.406 127 1/11/2024
2024.1010.315 134 1/10/2024
2023.1358.326 164 12/24/2023
2023.1351.473 155 12/17/2023
2023.1351.445 126 12/17/2023
2023.1351.432 145 12/17/2023
2023.1350.478 126 12/16/2023
2023.1344.600 134 12/10/2023
2023.1344.529 144 12/10/2023
2023.1339.582 164 12/5/2023
2023.1338.1072 135 12/4/2023
2023.1336.844 138 12/2/2023
2023.1335.378 145 12/1/2023
2023.1335.236 142 12/1/2023
2023.1335.203 138 12/1/2023
2023.1334.814 132 11/30/2023
2023.1332.652 128 11/28/2023
2023.1332.622 142 11/28/2023
2023.1332.524 157 11/28/2023
2023.1331.1073 120 11/27/2023
2023.1331.423 128 11/27/2023
2023.1328.513 138 11/24/2023
2023.1327.985 146 11/23/2023
2023.1325.593 139 11/21/2023
2023.1325.551 141 11/21/2023
2023.1325.529 131 11/21/2023