cargo-list 0.8.1

List and update installed crates
Documentation

Usage

$ cargo list -h
List and update installed crates

Usage: cargo list [OPTIONS]

Options:
  -f <FORMAT>       Output format [default: md] [possible values: json, json-pretty, md, rust, rust-pretty]
      --outdated    Hide up-to-date crates
      --update      Update outdated crates
      --update-all  Force reinstall all crates
  -r, --readme      Print the readme
  -h, --help        Print help
  -V, --version     Print version
$ cargo list -V
cargo-list 0.8.1

Examples

List installed crates

$ cargo list
* bat: v0.23.0
* kapow: v2.9.1 => v2.10.0

List installed crates in JSON

$ cargo list -f json
[{"name":"bat","installed":"v0.23.0","available":"v0.23.0",\
"outdated":false},{"name":"kapow","installed":"v2.9.1","ava\
ilable":"v2.10.0","outdated":true}]

List outdated crates

$ cargo list --outdated
* kapow: v2.9.1 => v2.10.0

List outdated crates in pretty-printed JSON

$ cargo list --outdated -f json-pretty
[
  {
    "name": "kapow",
    "installed": "v2.9.1",
    "available": "v2.10.0",
    "outdated": true
  }
]

Update outdated crates

$ cargo list --update
* bat: v0.23.0
* kapow: v2.9.1 => v2.10.0

```text
$ cargo install kapow
    Updating crates.io index
  Installing kapow v2.10.0
...
   Compiling kapow v2.10.0
    Finished release [optimized] target(s) in 7.22s
   Replacing /home/qtfkwk/.cargo/bin/kapow
    Replaced package `kapow v2.9.1` with `kapow v2.10.0` (e\
xecutable `kapow`)
```

List installed crates after updating

$ cargo list
* bat: v0.23.0
* kapow: v2.10.0

*All crates are up-to-date!*

List installed crates in JSON after updating

$ cargo list -f json
[{"name":"bat","installed":"v0.23.0","available":"v0.23.0",\
"outdated":false},{"name":"kapow","installed":"v2.10.0","av\
ailable":"v2.10.0","outdated":false}]

List installed crates in pretty-printed JSON after updating

$ cargo list -f json-pretty
[
  {
    "name": "bat",
    "installed": "v0.23.0",
    "available": "v0.23.0",
    "outdated": false
  },
  {
    "name": "kapow",
    "installed": "v2.10.0",
    "available": "v2.10.0",
    "outdated": false
  },
]

List outdated crates after updating

$ cargo list --outdated
*All crates are up-to-date!*

List outdated crates in JSON after updating

$ cargo list --outdated -f json
[]

Changelog

Please find the CHANGELOG.md in the repository.