yarn up
Upgrade dependencies across the project.
Usage
$> yarn up [-i,--interactive] [-v,--verbose] [-E,--exact] [-T,--tilde] [-C,--caret] ...
Examples
Upgrade all instances of lodash to the latest release :
yarn up lodash
Upgrade all instances of lodash to the latest release, but ask confirmation for each :
yarn up lodash -i
Upgrade all instances of lodash to 1.2.3 :
yarn up lodash@1.2.3
Upgrade all instances of packages with the @babel
scope to the latest release
:
yarn up '@babel/*'
Upgrade all instances of packages containing the word jest
to the latest release
:
yarn up '*jest*'
Upgrade all instances of packages with the @babel
scope to 7.0.0
:
yarn up '@babel/*@7.0.0'
Details
This command upgrades the packages matching the list of specified patterns to
their latest available version across the whole project (regardless of whether
they're part of dependencies
or devDependencies
- peerDependencies
won't
be affected). This is a project-wide command: all workspaces will be upgraded in
the process.
If -i,--interactive
is set (or if the preferInteractive
settings is toggled
on) the command will offer various choices, depending on the detected upgrade
paths. Some upgrades require this flag in order to resolve ambiguities.
The, -C,--caret
, -E,--exact
and -T,--tilde
options have the same meaning
as in the add
command (they change the modifier used when the range is missing
or a tag, and are ignored when the range is explicitly set).
This command accepts glob patterns as arguments (if valid Descriptors and supported by micromatch). Make sure to escape the patterns, to prevent your own shell from trying to expand them.
Note: The ranges have to be static, only the package scopes and names can contain glob patterns.