Skip to content

Commit

Permalink
chore(core): adjust cache storage to not include machine id in stored…
Browse files Browse the repository at this point in the history
… file path
  • Loading branch information
AgentEnder committed Sep 13, 2024
1 parent 4a94fc9 commit 09b66a4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions packages/nx/src/native/cache/cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ use tracing::trace;

use crate::native::cache::expand_outputs::_expand_outputs;
use crate::native::cache::file_ops::_copy;
use crate::native::machine_id::get_machine_id;
use crate::native::utils::Normalize;

#[napi(object)]
Expand All @@ -37,8 +36,7 @@ impl NxCache {
cache_path: String,
db_connection: External<Connection>,
) -> anyhow::Result<Self> {
let machine_id = get_machine_id();
let cache_path = PathBuf::from(&cache_path).join(machine_id);
let cache_path = PathBuf::from(&cache_path);

create_dir_all(&cache_path)?;
create_dir_all(cache_path.join("terminalOutputs"))?;
Expand Down
2 changes: 1 addition & 1 deletion packages/nx/src/tasks-runner/cache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ export class DbCache {
if (/* { TODO: INSERT HAS POWERPACK CHECK HERE } */ true) {
this.fallbackDbCache = new NxCache(
workspaceRoot,
process.env.NX_SHARED_CACHE_DIRECTORY,
cacheDir,
getDbConnection({
dbName: 'shared',
directory: cacheDir,
Expand Down

0 comments on commit 09b66a4

Please sign in to comment.