Skip to content

Commit

Permalink
fix: move cache folder outside node_modules
Browse files Browse the repository at this point in the history
  • Loading branch information
hugomrdias committed Jul 11, 2019
1 parent f7df20a commit 0a52bff
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ async function reset() {
value.snapshot.type === 'dev' ? '--dev' : ''
], { cwd }));
all.push(del(path.join(cwd, '.connect-deps.json')));
all.push(del(path.join(value.path, 'node_modules/.connect-deps-cache'), { force: true }));
all.push(del(path.join(value.path, '.connect-deps-cache'), { force: true }));
}

try {
Expand All @@ -175,9 +175,9 @@ async function packInstall(config) {

conf.set(config.name, Object.assign(config, { running: true }));
console.log(`Connecting ${config.name}...`);
const name = `./node_modules/.connect-deps-cache/${config.name}-${config.version}-${Date.now()}.tgz`;
const name = `./.connect-deps-cache/${config.name}-${config.version}-${Date.now()}.tgz`;

fs.mkdirSync(path.join(config.path, 'node_modules/.connect-deps-cache'), { recursive: true });
fs.mkdirSync(path.join(config.path, '.connect-deps-cache'), { recursive: true });
try {
await execa('yarn', ['pack', '--filename', name], { cwd: config.path });
await execa('yarn', [
Expand Down

0 comments on commit 0a52bff

Please sign in to comment.