forked from nrwl/nx
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(repo): change workspace to use verdaccio executor (nrwl#17280)
- Loading branch information
Showing
4 changed files
with
18 additions
and
39 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -73,18 +73,15 @@ it can be useful to publish to a local registry. | |
|
||
Check out [this video for a live walkthrough](https://youtu.be/Tx257WpNsxc) or follow the instructions below: | ||
|
||
- Run `pnpm local-registry start` in Terminal 1 (keep it running) | ||
- Run `pnpm local-registry` in Terminal 1 (keep it running) | ||
- Run `npm adduser --registry http://localhost:4873` in Terminal 2 (real credentials are not required, you just need to | ||
be logged in. You can use test/test/[email protected].) | ||
- Run `pnpm local-registry enable` in Terminal 2 | ||
- Run `pnpm nx-release 16.0.0 --local` in Terminal 2 - you can choose any nonexistent version number here, but it's recommended to use the next major | ||
- Run `cd ./tmp` in Terminal 2 | ||
- Run `npx create-nx-workspace@16.0.0` in Terminal 2 | ||
- Run `npx create-nx-workspace@17.0.0` in Terminal 2 | ||
|
||
If you have problems publishing, make sure you use Node 18 and NPM 8. | ||
|
||
**NOTE:** After you finish with local testing don't forget to stop the local registry (e.g. closing the Terminal 1) and disabling the local registy using `pnpm local-registry disable`. Keeping local registry enabled will change your lock file resolutions to `localhost:4873` on the next `pnpm i`. You can also run `pnpm local-registry clear` to clean all packages in that local registry. | ||
|
||
**NOTE:** To use this newly published local version, you need to make a new workspace or change all of your target packages to this new version, eg: `"nx": "^16.0.0",` and re-run `pnpm i` in your testing project. | ||
|
||
### Publishing for Yarn 2+ (Berry) | ||
|
@@ -101,7 +98,7 @@ Yarn Berry operates slightly differently than Yarn Classic. In order to publish | |
- localhost | ||
``` | ||
- Run `pnpm local-registry start` in Terminal 1 (keep it running) | ||
- Run `pnpm local-registry` in Terminal 1 (keep it running) | ||
- If you are creating nx workspace outside of your nx repo, make sure to add npm registry info to your root yarnrc ( | ||
usually in ~/.yarnrc.yml). The file should look something like this: | ||
|
||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"name": "@nx/nx-source", | ||
"$schema": "node_modules/nx/schemas/project-schema.json", | ||
"targets": { | ||
"local-registry": { | ||
"executor": "@nx/js:verdaccio", | ||
"options": { | ||
"port": 4873, | ||
"config": ".verdaccio/config.yml", | ||
"storage": "build/local-registry/storage" | ||
} | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.