From e13230226fe91498b3a5f28a8de6edbe4f164944 Mon Sep 17 00:00:00 2001 From: David Sherret Date: Mon, 26 Aug 2024 19:01:50 -0400 Subject: feat: lockfile v4 by default (#25165) This won't be fully stabilized until 2.0 is released. --- cli/Cargo.toml | 4 ++-- cli/args/lockfile.rs | 20 +++----------------- 2 files changed, 5 insertions(+), 19 deletions(-) (limited to 'cli') diff --git a/cli/Cargo.toml b/cli/Cargo.toml index 8eeef8cb3..33a169458 100644 --- a/cli/Cargo.toml +++ b/cli/Cargo.toml @@ -72,13 +72,13 @@ deno_emit = "=0.44.0" deno_graph = { version = "=0.81.3" } deno_lint = { version = "=0.63.1", features = ["docs"] } deno_lockfile.workspace = true -deno_npm = "=0.23.1" +deno_npm = "=0.24.0" deno_package_json.workspace = true deno_runtime = { workspace = true, features = ["include_js_files_for_snapshotting"] } deno_semver = "=0.5.10" deno_task_shell = "=0.17.0" deno_terminal.workspace = true -eszip = "=0.75.0" +eszip = "=0.76.0" libsui = "0.3.0" napi_sym.workspace = true node_resolver.workspace = true diff --git a/cli/args/lockfile.rs b/cli/args/lockfile.rs index 00d1f929d..30db49b7a 100644 --- a/cli/args/lockfile.rs +++ b/cli/args/lockfile.rs @@ -225,26 +225,12 @@ impl CliLockfile { file_path, content: &text, overwrite: false, - is_deno_future: *super::DENO_FUTURE, })?, frozen, )), - Err(err) if err.kind() == std::io::ErrorKind::NotFound => { - Ok(CliLockfile::new( - if *super::DENO_FUTURE { - // force version 4 for deno future - Lockfile::new(deno_lockfile::NewLockfileOptions { - file_path, - content: r#"{"version":"4"}"#, - overwrite: false, - is_deno_future: true, - })? - } else { - Lockfile::new_empty(file_path, false) - }, - frozen, - )) - } + Err(err) if err.kind() == std::io::ErrorKind::NotFound => Ok( + CliLockfile::new(Lockfile::new_empty(file_path, false), frozen), + ), Err(err) => Err(err).with_context(|| { format!("Failed reading lockfile '{}'", file_path.display()) }), -- cgit v1.2.3