A tool that helps you run .NET tools without first having to install them.
.NET global tools are a new feature in .NET 2.1, which is currently in preview.
dx [options] <command> [--] [<arguments>]...For example, for dotnetsay:
dx dotnetsay Hello World!The output will be exactly the same as if the tool was installed and then executed.
Install .NET Core CLI at least 2.1 from microsoft.com, then run:
dotnet tool install -g dxRun dx with --help to see possible options. Here we document a few:
--rmRemoves the executable if it was installed. You can also set the environment variableDX_REMOVE_AFTER_RUNtotrueso you don't have to set it every time.--packageallows you to specify a package name different from the command name.--package-versionallows you to specify a version different from latest.--verboseshows you logs about installing, execution and debuggin.
Use -- to separate dx parameters from tool parameters.
The tool will exit with 1 if installation failed of dotnet was not found.
If the installation is successful then the executed application exit code will be used as exit code.
Just cd to src/dx and run dotnet pack -C Release -o ../nupkg.
Then cd to src/nupkg and run dotnet install tool -g dx.
- Giovanni Bassi, aka Giggio, Lambda3, @giovannibassi
Contributors can be found at the contributors page on Github.
Use Twitter.
This software is open source, licensed under the Apache License, Version 2.0. See LICENSE.txt for details. Check out the terms of the license before you contribute, fork, copy or do anything with the code. If you decide to contribute you agree to grant copyright of all your contribution to this project, and agree to mention clearly if do not agree to these terms. Your work will be licensed with the project at Apache V2, along the rest of the code.