Getting Started
This guide installs ArtifactClean and runs a first cleanup. It takes a couple of minutes and needs only the .NET SDK.
Prerequisites
- The .NET 10 SDK (
dotnet tool install,dotnet cleananddotnet restoreare SDK commands) - The
dotnetcommand onPATH(ArtifactClean callsdotnet cleananddotnet restore)
The workspaces you clean can target any .NET version.
Install
dotnet tool install --global Invex.Tools.ArtifactClean
Check that the command is available:
artclean --help
To pick up a newer version later, run dotnet tool update --global Invex.Tools.ArtifactClean.
Run your first cleanup
Warning
ArtifactClean permanently deletes every bin and obj directory below the selected path. Run it from, or point it
at, the root of the workspace you mean to clean.
Change to the root of a .NET workspace (the folder with your .sln, .slnx or project files) and run:
artclean
The tool prints one line per step:
'dotnet clean' completed successfully.
Deleted 12 'bin' / 'obj' directories.
'dotnet restore' completed successfully.
To clean another directory without changing to it, pass --path:
artclean --path "path/to/workspace"
Next steps
- ArtifactClean: every option, the exact behavior and the exit codes
- Introduction: when the tool is the right choice and when it is not