1dotnet-tool-update(1)         .NET Documentation         dotnet-tool-update(1)
2
3
4

dotnet tool update

6       This article applies to: ✔️ .NET Core 3.1 SDK and later versions
7

NAME

9       dotnet-tool-update - Updates the specified .NET tool on your machine.
10

SYNOPSIS

12              dotnet tool update <PACKAGE_ID> -g|--global
13                  [--add-source <SOURCE>] [--configfile <FILE>]
14                  [--disable-parallel] [--framework <FRAMEWORK>]
15                  [--ignore-failed-sources] [--interactive] [--no-cache]
16                  [-v|--verbosity <LEVEL>] [--version <VERSION>]
17
18              dotnet tool update <PACKAGE_ID> --tool-path <PATH>
19                  [--add-source <SOURCE>] [--configfile <FILE>]
20                  [--disable-parallel] [--framework <FRAMEWORK>]
21                  [--ignore-failed-sources] [--interactive] [--no-cache]
22                  [-v|--verbosity <LEVEL>] [--version <VERSION>]
23
24              dotnet tool update <PACKAGE_ID> --local
25                  [--add-source <SOURCE>] [--configfile <FILE>]
26                  [--disable-parallel] [--framework <FRAMEWORK>]
27                  [--ignore-failed-sources] [--interactive] [--no-cache]
28                  [--tool-manifest <PATH>]
29                  [-v|--verbosity <LEVEL>] [--version <VERSION>]
30
31              dotnet tool update -h|--help
32

DESCRIPTION

34       The  dotnet  tool  update command provides a way for you to update .NET
35       tools on your machine to the latest stable version of the package.  The
36       command  uninstalls and reinstalls a tool, effectively updating it.  To
37       use the command, you specify one of the following options:
38
39       • To update a global tool that was installed in the  default  location,
40         use the --global option
41
42       • To  update a global tool that was installed in a custom location, use
43         the --tool-path option.
44
45       • To update a local tool, use the --local option.
46

ARGUMENTS

48PACKAGE_ID
49
50         Name/ID of the NuGet package that contains the .NET  global  tool  to
51         update.   You  can  find  the package name using the dotnet tool list
52         command.
53

OPTIONS

55--add-source <SOURCE>
56
57         Adds an additional NuGet package source to use  during  installation.
58         Feeds  are  accessed  in  parallel, not sequentially in some order of
59         precedence.  If the same package and version is  in  multiple  feeds,
60         the fastest feed wins.  For more information, see What happens when a
61         NuGet package is installed?.
62
63--configfile <FILE>
64
65         The NuGet configuration file (nuget.config) to  use.   If  specified,
66         only the settings from this file will be used.  If not specified, the
67         hierarchy of configuration files from the current directory  will  be
68         used.  For more information, see Common NuGet Configurations.
69
70--disable-parallel
71
72         Prevent restoring multiple projects in parallel.
73
74--framework <FRAMEWORK>
75
76         Specifies the target framework to update the tool for.
77
78-g|--global
79
80         Specifies that the update is for a user-wide tool.  Can’t be combined
81         with the --tool-path option.  Omitting both --global and  --tool-path
82         specifies that the tool to be updated is a local tool.
83
84-?|-h|--help
85
86         Prints out a description of how to use the command.
87
88--ignore-failed-sources
89
90         Treat package source failures as warnings.
91
92--interactive
93
94         Allows  the  command  to stop and wait for user input or action.  For
95         example, to complete authentication.
96
97--local
98
99         Update the tool and the local tool manifest.  Can’t be combined  with
100         the --global option or the --tool-path option.
101
102--no-cache
103
104         Do not cache packages and HTTP requests.
105
106--tool-manifest <PATH>
107
108         Path to the manifest file.
109
110--tool-path <PATH>
111
112         Specifies  the location where the global tool is installed.  PATH can
113         be absolute or relative.  Can’t be combined with the --global option.
114         Omitting  both --global and --tool-path specifies that the tool to be
115         updated is a local tool.
116
117-v|--verbosity <LEVEL>
118
119         Sets the verbosity level of the command.  Allowed values are q[uiet],
120         m[inimal], n[ormal], d[etailed], and diag[nostic].  For more informa‐
121         tion, see <xref:Microsoft.Build.Framework.LoggerVerbosity>.
122
123--version <VERSION>
124
125         The version range of the tool package to update to.  This  cannot  be
126         used to downgrade versions, you must uninstall newer versions first.
127

EXAMPLES

129dotnet tool update -g dotnetsay
130
131         Updates   the  dotnetsay  (https://www.nuget.org/packages/dotnetsay/)
132         global tool.
133
134dotnet tool update dotnetsay --tool-path c:\global-tools
135
136         Updates  the  dotnetsay   (https://www.nuget.org/packages/dotnetsay/)
137         global tool located in a specific Windows directory.
138
139dotnet tool update dotnetsay --tool-path ~/bin
140
141         Updates   the  dotnetsay  (https://www.nuget.org/packages/dotnetsay/)
142         global tool located in a specific Linux/macOS directory.
143
144dotnet tool update dotnetsay
145
146         Updates the dotnetsay (https://www.nuget.org/packages/dotnetsay/) lo‐
147         cal tool installed for the current directory.
148
149dotnet tool update -g dotnetsay --version 2.0.*
150
151         Updates   the  dotnetsay  (https://www.nuget.org/packages/dotnetsay/)
152         global tool to the latest patch version, with a major version  of  2,
153         and a minor version of 0.
154
155dotnet tool update -g dotnetsay --version (2.0.*,2.1.4)
156
157         Updates   the  dotnetsay  (https://www.nuget.org/packages/dotnetsay/)
158         global tool to the lowest version within the specified range (> 2.0.0
159         &&  < 2.1.4), version 2.1.0 would be installed.  For more information
160         on semantic versioning ranges, see NuGet packaging version ranges.
161

SEE ALSO

163       • .NET tools
164
165       • Semantic versioning (https://semver.org)
166
167       • Tutorial: Install and use a .NET global tool using the .NET CLI
168
169       • Tutorial: Install and use a .NET local tool using the .NET CLI
170
171
172
173                                  2022-10-10             dotnet-tool-update(1)
Impressum