Updating Dependencies
Update npm Packages​
If you are using the tauri
package:
- npm
- Yarn Classic
- Yarn Berry
- pnpm
- Bun
npm install @tauri-apps/cli@">1.0.0" @tauri-apps/api@">1.0.0"
yarn upgrade @tauri-apps/cli@^1.0.0 @tauri-apps/api@^1.0.0
yarn up @tauri-apps/cli@^1.0.0 @tauri-apps/api@^1.0.0
pnpm update @tauri-apps/cli@1 @tauri-apps/api@1
bun update @tauri-apps/cli @tauri-apps/api
You can also detect what the latest version of Tauri is on the command line, using:
- npm
- Yarn
- pnpm
npm outdated @tauri-apps/cli
yarn outdated @tauri-apps/cli
pnpm outdated @tauri-apps/cli
Alternatively, if you are using the vue-cli-plugin-tauri
approach:
- npm
- Yarn Classic
- Yarn Berry
- pnpm
npm install vue-cli-plugin-tauri@latest
yarn upgrade vue-cli-plugin-tauri --latest
yarn up vue-cli-plugin-tauri
pnpm update vue-cli-plugin-tauri --latest
Update Cargo Packages​
You can check for outdated packages with cargo outdated
or on the crates.io pages: tauri / tauri-build.
Go to src-tauri/Cargo.toml
and change tauri
and tauri-build
to
[build-dependencies]
tauri-build = "%version%"
[dependencies]
tauri = { version = "%version%" }
where %version%
is the corresponding version number from above.
Then do the following:
cd src-tauri
cargo update
Alternatively, you can run the cargo upgrade
command provided by cargo-edit which does all of this automatically.