Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(link): Use
publishConfig.directory
as symlink source if it exi…
…sts to allow linking sub-directories (#2274)
- Loading branch information
1 parent
f057409
commit d04ce8e
Showing
23 changed files
with
269 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
commands/link/__tests__/__fixtures__/with-contents/lerna.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"version": "1.0.0" | ||
} |
3 changes: 3 additions & 0 deletions
3
commands/link/__tests__/__fixtures__/with-contents/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"name": "independent" | ||
} |
7 changes: 7 additions & 0 deletions
7
commands/link/__tests__/__fixtures__/with-contents/packages/package-1/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"name": "@test/package-1", | ||
"version": "1.0.0", | ||
"publishConfig": { | ||
"directory": "dist" | ||
} | ||
} |
3 changes: 3 additions & 0 deletions
3
commands/link/__tests__/__fixtures__/with-contents/packages/package-2/dist/cli.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
/* eslint-disable node/shebang */ | ||
console.log("Hello, world!"); |
11 changes: 11 additions & 0 deletions
11
commands/link/__tests__/__fixtures__/with-contents/packages/package-2/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"name": "@test/package-2", | ||
"version": "1.0.0", | ||
"publishConfig": { | ||
"directory": "dist" | ||
}, | ||
"bin": "cli.js", | ||
"dependencies": { | ||
"@test/package-1": "^1.0.0" | ||
} | ||
} |
3 changes: 3 additions & 0 deletions
3
commands/link/__tests__/__fixtures__/with-contents/packages/package-2/src/cli.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
/* eslint-disable node/shebang */ | ||
console.log("Hello, world!"); |
3 changes: 3 additions & 0 deletions
3
commands/link/__tests__/__fixtures__/with-contents/packages/package-3/dist/cli1.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
/* eslint-disable node/shebang */ | ||
console.log("Hello, world!"); |
3 changes: 3 additions & 0 deletions
3
commands/link/__tests__/__fixtures__/with-contents/packages/package-3/dist/cli2.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
/* eslint-disable node/shebang */ | ||
console.log("Hello, world!"); |
15 changes: 15 additions & 0 deletions
15
commands/link/__tests__/__fixtures__/with-contents/packages/package-3/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"name": "package-3", | ||
"version": "1.0.0", | ||
"publishConfig": { | ||
"directory": "dist" | ||
}, | ||
"bin": { | ||
"package3cli1": "cli1.js", | ||
"package3cli2": "cli2.js" | ||
}, | ||
"devDependencies": { | ||
"@test/package-1": "^1.0.0", | ||
"@test/package-2": "^1.0.0" | ||
} | ||
} |
3 changes: 3 additions & 0 deletions
3
commands/link/__tests__/__fixtures__/with-contents/packages/package-3/src/cli1.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
/* eslint-disable node/shebang */ | ||
console.log("Hello, world!"); |
3 changes: 3 additions & 0 deletions
3
commands/link/__tests__/__fixtures__/with-contents/packages/package-3/src/cli2.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env node | ||
/* eslint-disable node/shebang */ | ||
console.log("Hello, world!"); |
11 changes: 11 additions & 0 deletions
11
commands/link/__tests__/__fixtures__/with-contents/packages/package-4/package.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"name": "package-4", | ||
"version": "1.0.0", | ||
"publishConfig": { | ||
"directory": "dist" | ||
}, | ||
"dependencies": { | ||
"@test/package-1": "^0.0.0", | ||
"package-3": "^1.0.0" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters