diff options
author | Nathan Whitaker <17734409+nathanwhit@users.noreply.github.com> | 2024-07-02 15:00:16 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-02 15:00:16 -0700 |
commit | c13b6d1413859d03b41b97d4c671fccfd388b2cc (patch) | |
tree | 503c5d2c51c71f3daa79950b6862b725e9211822 /cli/lsp/config.rs | |
parent | d379c0b299411a847765e2879f8ed14bdb2d0298 (diff) |
feat(cli): Add `--frozen` flag to error out if lockfile is out of date (#24355)
Closes #18296.
Adds a `--frozen` (alias `--frozen-lockfile`) flag that errors out if
the lockfile is out of date. This is useful for running in CI (where an
out of date lockfile is usually a mistake) or to prevent accidental
changes in dependencies.

Diffstat (limited to 'cli/lsp/config.rs')
-rw-r--r-- | cli/lsp/config.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cli/lsp/config.rs b/cli/lsp/config.rs index 89b2a2e60..e1f3e3207 100644 --- a/cli/lsp/config.rs +++ b/cli/lsp/config.rs @@ -1825,7 +1825,7 @@ fn resolve_node_modules_dir( } fn resolve_lockfile_from_path(lockfile_path: PathBuf) -> Option<CliLockfile> { - match CliLockfile::read_from_path(lockfile_path) { + match CliLockfile::read_from_path(lockfile_path, false) { Ok(value) => { if value.filename.exists() { if let Ok(specifier) = ModuleSpecifier::from_file_path(&value.filename) |