Skip to content

Commit 04ce83c

Browse files
committed
feat: read from GITHUB_TOKEN
1 parent 88ff4fa commit 04ce83c

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@
44
55
Fork from [`conventional-github-releaser`](https://github.com/conventional-changelog/releaser-tools/tree/master/packages/conventional-github-releaser).
66

7-
## Changes
7+
## Changes in this fork
88

99
- The preset is default to `angular`. `-p angular` is no longer required.
10+
- It also reads `GITHUB_TOKEN` from env as fallback
1011

1112
## Quick start
1213

src/cli.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,12 @@ const cli = meow({
4141
flags: {
4242
url: {
4343
alias: 'u',
44-
default: process.env.CONVENTIONAL_GITHUB_URL || 'https://api.github.com/',
44+
default: process.env.CONVENTIONAL_GITHUB_URL || process.env.GITHUB_URL || 'https://api.github.com/',
4545
type: 'string',
4646
},
4747
token: {
4848
alias: 't',
49-
default: process.env.CONVENTIONAL_GITHUB_RELEASER_TOKEN,
49+
default: process.env.CONVENTIONAL_GITHUB_RELEASER_TOKEN || process.env.GITHUB_TOKEN,
5050
type: 'string',
5151
},
5252
preset: {

0 commit comments

Comments
 (0)