Ahmad Ismail
Ahmad Ismail

Reputation: 13862

what is the command to update all my rust packages

I installed several rust applications using:

cargo install fd-find sd ripgrep rga bat tealdeer exa git-delta du-dust

Is there any command like sudo apt update && sudo apt upgrade which I can use to update the packages.

Upvotes: 11

Views: 5043

Answers (2)

Karthik Balaguru
Karthik Balaguru

Reputation: 7842

Cargo subcommand can be used for checking and applying updates to installed executables.

You can try cargo-update

cargo install cargo-update

General syntax

cargo install-update [OPTIONS] [PACKAGE…]

Update all installed packages :

cargo install-update -af

Update only selective packages :

cargo install-update fd-find sd ripgrep rga bat tealdeer exa git-delta du-dust

Reference : https://docs.rs/cargo-update/7.0.1/cargo_update/index.html

Upvotes: 3

Stargateur
Stargateur

Reputation: 26727

There is a optional subcommand cargo-update to do that:

cargo install cargo-update
cargo install-update -a

Done.

Upvotes: 15

Related Questions