---
name: "dub-remove"
section: "1"
platform: "linux"
package: "dub"
version: "1.42.0-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/dub-remove"
---

# dub-remove(1)

Removes a cached package

## NAME

dub-remove - Removes a cached package

## SYNOPSIS

**dub remove** \<*package*\>\[@\<*version-spec*\>\] *OPTIONS...*

## DESCRIPTION

Removes a package that is cached on the local system.

## OPTIONS

- **--version**=*VALUE*

  Use the specified version/branch instead of the latest available match The remove command also accepts "\*" here as a wildcard to remove all versions of the package from the specified location

- **--force-remove**

  Deprecated option that does nothing

- **-n**, **--non-interactive**

  Don't enter interactive mode.

### COMMON OPTIONS

See [**dub**(1)](/dub/1.md)

## EXIT STATUS

- **0**

  DUB succeeded

- **1**

  usage errors, unknown command line flags

- **2**

  package not found, package failed to load, miscellaneous error

## FILES

*dub.sdl*, *dub.json*

## AUTHOR

Copyright (c) 1999-2026 by The D Language Foundation

## ONLINE DOCUMENTATION

http://code.dlang.org/docs/commandline

## SEE ALSO

[**dub**(1)](/dub/1.md), [**dub-clean**(1)](/dub-clean/1.md), [**dub-clean-caches**(1)](/dub-clean-caches/1.md)
