mirror of
https://github.com/denoland/deno.git
synced 2025-10-01 14:41:15 +00:00
refactor: do not use deno_fs::FileSystem
everywhere (#27508)
This changes the cli to mostly use `std::fs` via `sys_traits` instead of the implemention of `deno_fs::FileSystem`.
This commit is contained in:
parent
1cd36009b0
commit
4638caa740
74 changed files with 1304 additions and 1437 deletions
|
@ -18,7 +18,6 @@ use deno_core::unsync::sync::AtomicFlag;
|
|||
use deno_path_util::get_atomic_path;
|
||||
use deno_runtime::code_cache::CodeCache;
|
||||
use deno_runtime::code_cache::CodeCacheType;
|
||||
use deno_runtime::deno_fs::FsSysTraitsAdapter;
|
||||
|
||||
use crate::cache::FastInsecureHasher;
|
||||
use crate::worker::CliCodeCache;
|
||||
|
@ -191,7 +190,7 @@ impl FirstRunCodeCacheStrategy {
|
|||
) {
|
||||
let count = cache_data.len();
|
||||
let temp_file =
|
||||
get_atomic_path(&FsSysTraitsAdapter::new_real(), &self.file_path);
|
||||
get_atomic_path(&sys_traits::impls::RealSys, &self.file_path);
|
||||
match serialize(&temp_file, self.cache_key, cache_data) {
|
||||
Ok(()) => {
|
||||
if let Err(err) = std::fs::rename(&temp_file, &self.file_path) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue