dotnet-nuget-locals(1)

πŸ“¦
version 11.0.0~rc3 Β· 6 versions
, in alpine 3.24, centos-stream 10, centos-stream 9, fedora 43, fedora 44, nixpkgs unstable, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’… dotnet-nuget-locals β€” the dotnet-nuget-locals(1) glow-up

okay bestie, welcome to the .NET Documentation corner of the terminal, where today we're talking about dotnet nuget locals. Also quick vibe check: this article applies to βœ”οΈ .NET 6 SDK and later versions ✨


🌸 NAME 🌸

dotnet-nuget-locals β€” clears or lists local NuGet resources. that's it, that's the whole job, and she does it flawlessly πŸ’–


✨ SYNOPSIS ✨

dotnet nuget locals <CACHE_LOCATION> [(-c|--clear)|(-l|--list)] [--force-english-output]

dotnet nuget locals -h|--help

πŸ¦‹ DESCRIPTION πŸ¦‹

so the dotnet nuget locals command is literally the one who clears or lists your local NuGet resources. and where do those live? in the http-request cache, the temporary cache, or the machine-wide global packages folder. three whole neighborhoods of cache, and she knows all of them 🫢


πŸŽ€ ARGUMENTS πŸŽ€

  • CACHE_LOCATION β€” the cache location you want to list or clear. she accepts one of these values, and no, you can't freestyle your own:
    • all β€” says the operation applies to all cache types: http-request cache, global packages cache, temporary cache, and plugins cache. the whole squad πŸ’…
    • http-cache β€” says the operation applies only to the http-request cache. the other cache locations aren't affected, they're minding their own business πŸ™ˆ
    • global-packages β€” says the operation applies only to the global packages cache. the other cache locations aren't affected.
    • temp β€” says the operation applies only to the temporary cache. the other cache locations aren't affected.
    • plugins-cache β€” says the operation applies only to the plugins cache. the other cache locations aren't affected.

πŸ‘‘ OPTIONS πŸ‘‘

  • --force-english-output β€” forces the application to run using an invariant, English-based culture. no localization drama, just English, periodt ✨
  • -? | -h | --help β€” prints out a description of how to use the command. your lil tutorial bestie πŸŽ€
  • -c | --clear β€” the clear option executes a clear operation on the specified cache type. the contents of the cache directories get deleted recursively. heads up though: the executing user/group must have permission to the files in the cache directories. if not, an error is displayed indicating the files/folders that weren't cleared. so if it yells, that's why 😭
  • -l | --list β€” the list option is used to display the location of the specified cache type. no deleting, just showing you where things live πŸ‘€

🌈 EXAMPLES 🌈

  • displays the paths of all the local cache directories (http-cache directory, global-packages cache directory, temporary cache directory, and plugins cache directory):
dotnet nuget locals all -l
  • displays the path for the local http-cache directory:
dotnet nuget locals http-cache --list
  • displays the path for the local plugins cache directory:
dotnet nuget locals plugins-cache --list
  • clears all files from all local cache directories (http-cache directory, global-packages cache directory, temporary cache directory, and plugins cache directory):
dotnet nuget locals all --clear
  • clears all files in local global-packages cache directory:
dotnet nuget locals global-packages -c
  • clears all files in local temporary cache directory:
dotnet nuget locals temp -c
  • clears all files in local plugins cache directory:
dotnet nuget locals plugins-cache -c

🧚 Troubleshooting 🧚

for info on common problems and errors while you're out here using the dotnet nuget locals command, go see Managing the NuGet cache. she's got the answers, iykyk πŸ’œ


and that's the whole page bestie, no notes, she ate πŸ’…

okay signing off: this was dotnet-nuget-locals(1) from the .NET Documentation, dated 2025-10-30 β€” love her, bookmark her, run her responsibly πŸ”₯πŸ’–

πŸ“¦ where this page comes from