-
Notifications
You must be signed in to change notification settings - Fork 0
update(major): publish package to github #14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -57,6 +57,12 @@ jobs: | |||||||||||||||||||
| skip-push: "true" | ||||||||||||||||||||
| skip-commit: "true" | ||||||||||||||||||||
| bump-policy: "ignore" | ||||||||||||||||||||
|
|
||||||||||||||||||||
| - name: Setup .npmrc | ||||||||||||||||||||
| run: | | ||||||||||||||||||||
| echo "@fundwave:registry=https://npm.pkg.github.com" >> ~/.npmrc | ||||||||||||||||||||
| echo "//npm.pkg.github.com/:_authToken=${{ secrets.GITHUB_TOKEN }}" >> ~/.npmrc | ||||||||||||||||||||
| echo "ignore-scripts=true" >> ~/.npmrc | ||||||||||||||||||||
|
|
||||||||||||||||||||
| - name: Install dependencies | ||||||||||||||||||||
| run: npm ci | ||||||||||||||||||||
|
|
@@ -72,12 +78,11 @@ jobs: | |||||||||||||||||||
| git config user.name "fundabot" | ||||||||||||||||||||
| git commit -a -m "CI: bumps @fundwave/fetch-queue to $VERSION" -m "[skip ci]" | ||||||||||||||||||||
|
|
||||||||||||||||||||
| - name: Publish package to gitlab | ||||||||||||||||||||
| env: | ||||||||||||||||||||
| GITLAB_TOKEN: ${{secrets.GITLAB_TOKEN}} | ||||||||||||||||||||
| - name: Build package | ||||||||||||||||||||
| run: npm run build | ||||||||||||||||||||
|
|
||||||||||||||||||||
|
||||||||||||||||||||
| - name: Verify package name scope | |
| run: | | |
| PKG_NAME=$(jq -r .name package.json) | |
| if [ "$PKG_NAME" != "@fundwave/fetch-queue" ]; then | |
| echo "Error: package.json name must be '@fundwave/fetch-queue', found '$PKG_NAME'" | |
| exit 1 | |
| fi |
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -11,16 +11,16 @@ | |||||||
| }, | ||||||||
| "scripts": { | ||||||||
| "build:esm": "tsc --module NodeNext --outDir ./dist/esm", | ||||||||
| "build": "tsc --module commonjs --outDir ./dist/cjs", | ||||||||
| "prepare": "npm run build && npm run build:esm", | ||||||||
| "build:cjs": "tsc --module commonjs --outDir ./dist/cjs", | ||||||||
| "build": "npm run build:cjs && npm run build:esm", | ||||||||
|
||||||||
| "build": "npm run build:cjs && npm run build:esm", | |
| "build": "npm run build:cjs && npm run build:esm", | |
| "prepare": "npm run build", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The .npmrc configuration is set up before 'npm ci' but the package still needs to be published. The 'ignore-scripts=true' setting will prevent lifecycle scripts from running during install, but this configuration will also affect the 'npm publish' command later. Consider moving this setup to just before the publish step, or use a more targeted approach like creating a separate .npmrc for publishing.