Provided by: dotnet-host-7.0_7.0.105-0ubuntu2_amd64 bug

dotnet new update

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

NAME

       dotnet-new-update - updates installed template packages.

SYNOPSIS

              dotnet new update [--interactive] [--add-source|--nuget-source <SOURCE>]
                  [-d|--diagnostics] [--verbosity <LEVEL>] [-h|--help]

              dotnet new update --check-only|--dry-run [--interactive] [--add-source|--nuget-source <SOURCE>]
                  [-d|--diagnostics] [--verbosity <LEVEL>] [-h|--help]

DESCRIPTION

       The  dotnet new update command updates installed template packages.  The dotnet new update
       command with --check-only option checks  for  available  updates  for  installed  template
       packages without applying them.

       Starting with the .NET 7 SDK, the dotnet new syntax has changed:

       • The  --list,  --search,  --install, and --uninstall options became list, search, install
         and uninstall subcommands.

       • The --update-apply option became the update subcommand.

       • To use --update-check, use the update subcommand with the --check-only option.

       Other options that were available before are still available to use with their  respective
       subcommands.   Separate help for each subcommand is available via the -h or --help option:
       dotnet new <subcommand> --help lists all supported options for the subcommand.

       Additionally, tab completion is now available for dotnet new.  It supports completion  for
       installed  template  names  and for the options a selected template provides.  To activate
       tab completion for the .NET SDK, see Enable tab completion.   >  >  Examples  of  the  old
       syntax:  > > - Show help for the update subcommand.  > > - Check for updates for installed
       template packages: > > dotnetcli >   dotnet new --update-check > > >  -  Update  installed
       template packages: > > dotnetcli >   dotnet new --update-apply >

OPTIONS

--interactive

         Allows  the command to stop and wait for user input or action.  For example, to complete
         authentication.  Available since .NET 5.0 SDK.

       • --add-source|nuget-source <SOURCE>

         By default, dotnet new install uses the hierarchy of NuGet configuration files from  the
         current  directory  to determine the NuGet source the package can be installed from.  If
         --nuget-source is specified, the source will be added to  the  list  of  sources  to  be
         checked.
         To  check the configured sources for the current directory use dotnet nuget list source.
         For more information,  see  Common  NuGet  Configurations.   Available  since  .NET  SDK
         7.0.100.

       • -d|--diagnostics

         Enables diagnostic output.  Available since .NET SDK 7.0.100.

       • -h|--help

         Prints out help for the update command.  Available since .NET SDK 7.0.100.

       • -v|--verbosity <LEVEL>

         Sets  the  verbosity  level  of  the  command.   Allowed  values are q[uiet], m[inimal],
         n[ormal], and diag[nostic].  Available since .NET SDK 7.0.100.

EXAMPLES

       • Updates the installed template  packages  using  NuGet  configuration  for  the  current
         directory:

                dotnet new update

       • Updates  the  installed  template  packages  also  checking  a custom NuGet source using
         interactive mode:

                dotnet new update --add-source "https://api.my-custom-nuget.com/v3/index.json" --interactive

SEE ALSO

       • dotnet new command

       • dotnet new search command

       • dotnet new install command

       • Custom templates for dotnet new

                                            2022-11-08                       dotnet-new-update(1)