Skip to content

Commit 9250455

Browse files
committed
release 19.0.0
1 parent f23b2eb commit 9250455

File tree

3 files changed

+93
-1
lines changed

3 files changed

+93
-1
lines changed

PUBLISH.md

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
# Publishing to GitHub Package Registry
2+
3+
This guide explains how to publish the `ngx-angular-query-builder` library to GitHub Package Registry.
4+
5+
## Prerequisites
6+
7+
1. **GitHub Repository**: Ensure your code is pushed to a GitHub repository
8+
2. **GitHub Personal Access Token**: Create a token with `write:packages` scope
9+
3. **Updated Configuration**: Make sure all configuration files are properly set up
10+
11+
## Local Publishing (Manual)
12+
13+
If you want to publish manually:
14+
15+
1. **Build the library:**
16+
```bash
17+
npm run build-package
18+
```
19+
20+
2. **Navigate to the dist folder:**
21+
```bash
22+
cd dist/ngx-angular-query-builder
23+
```
24+
25+
3. **Login to GitHub Package Registry:**
26+
```bash
27+
npm login --registry=https://npm.pkg.github.com
28+
```
29+
- Username: Your GitHub username (lowercase)
30+
- Password: Your GitHub Personal Access Token (classic)
31+
32+
4. **Publish:**
33+
```bash
34+
npm publish
35+
```
36+
37+
## Installation for Users
38+
39+
Once published, users can install your package by:
40+
41+
1. **Creating `.npmrc` in their project:**
42+
```
43+
@YOUR_GITHUB_USERNAME:registry=https://npm.pkg.github.com
44+
//npm.pkg.github.com/:_authToken=THEIR_GITHUB_TOKEN
45+
```
46+
47+
2. **Installing the package:**
48+
```bash
49+
npm install @YOUR_GITHUB_USERNAME/ngx-angular-query-builder
50+
```
51+
52+
## Troubleshooting
53+
54+
### Common Issues:
55+
56+
1. **Authentication Error:**
57+
- Ensure you are using a GitHub classic access token with `write:packages` scope
58+
- Verify the token is not expired
59+
60+
2. **Package Not Found:**
61+
- Check the package name includes the @csfloat scope
62+
- Ensure the repository is public and you have access to it
63+
64+
4. **Workflow Failures:**
65+
- Check the Actions tab for detailed error logs
66+
- Ensure GITHUB_TOKEN has sufficient permissions

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,25 @@ Use the following versions depending upon your angular version
3232
- Angular 18 - Versions 18.x.x
3333
- Angular 19 - Versions 19.x.x
3434

35+
# Installation
36+
37+
## From GitHub Package Registry
38+
39+
To install from GitHub Package Registry, you need to:
40+
41+
1. Create a `.npmrc` file in your project root with:
42+
```
43+
@your-github-username:registry=https://npm.pkg.github.com
44+
//npm.pkg.github.com/:_authToken=YOUR_GITHUB_TOKEN
45+
```
46+
47+
2. Install the package:
48+
```bash
49+
npm install @csfloat/ngx-angular-query-builder
50+
```
51+
52+
**Note:** You'll need a [GitHub Personal Access Token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token) with `read:packages` scope to install packages from GitHub Package Registry.
53+
3554
# Examples
3655

3756
npm install ngx-angular-query-builder

projects/ngx-angular-query-builder/package.json

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,15 @@
11
{
2-
"name": "ngx-angular-query-builder",
2+
"name": "@csfloat/ngx-angular-query-builder",
33
"version": "19.0.0",
44
"description": "Port of angular2-query-builder from github.com/designermanjeets/Angular-QueryBuilder in order to support angular 12+",
55
"license": "MIT",
6+
"repository": {
7+
"type": "git",
8+
"url": "git+https://github.com/csfloat/ngx-angular-query-builder.git"
9+
},
10+
"publishConfig": {
11+
"registry": "https://npm.pkg.github.com"
12+
},
613
"peerDependencies": {
714
"@angular/common": "^19.2.14",
815
"@angular/core": "^19.2.14"

0 commit comments

Comments
 (0)