Skip to content

Commit 84b75d6

Browse files
docs(readme): describe token setup in prerequisites
1 parent 98525cc commit 84b75d6

1 file changed

Lines changed: 13 additions & 5 deletions

File tree

README.md

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# @remarkablemark/test
22

3-
[GitHub Package](https://docs.github.com/packages) test
3+
📦 [GitHub Package](https://docs.github.com/packages) test:
4+
5+
- [npm](https://github.com/remarkablemark/github-package-test/pkgs/npm/test)
46

57
## Prerequisites
68

@@ -11,14 +13,20 @@ Update `.npmrc`:
1113
//npm.pkg.github.com/:_authToken=${GITHUB_TOKEN}
1214
```
1315

14-
Create a [token](https://github.com/settings/tokens):
16+
Create a [token](https://github.com/settings/tokens) with scope `read:packages` and add to your shell config (e.g., `.zshrc`):
17+
18+
```sh
19+
export GITHUB_TOKEN=ghp_xxx
20+
```
1521

16-
- `read:packages`
22+
Or do with with [GitHub CLI](https://cli.github.com/):
1723

18-
Add to your `.zshrc` or `.bashrc`:
24+
```sh
25+
gh auth refresh -h github.com -s read:packages
26+
```
1927

2028
```sh
21-
export GITHUB_TOKEN=ghp_xxx
29+
echo 'export GITHUB_TOKEN=$(gh auth token)' >> ~/.zshrc
2230
```
2331

2432
## Install

0 commit comments

Comments
 (0)