Skip to content

Commit 85d889e

Browse files
authored
Merge pull request ericc-ch#41 from Luminger/support-enterprise-endpoint
feat: allow use of GitHub enterprise account type endpoint
2 parents cabcf0c + 37293e3 commit 85d889e

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

src/main.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ interface RunServerOptions {
1616
port: number
1717
verbose: boolean
1818
business: boolean
19+
enterprise: boolean
1920
manual: boolean
2021
rateLimit?: number
2122
rateLimitWait: boolean
@@ -31,6 +32,9 @@ export async function runServer(options: RunServerOptions): Promise<void> {
3132
if (options.business) {
3233
state.accountType = "business"
3334
consola.info("Using business plan GitHub account")
35+
} else if (options.enterprise) {
36+
state.accountType = "enterprise"
37+
consola.info("Using enterprise plan GitHub account")
3438
}
3539

3640
state.manualApprove = options.manual
@@ -82,6 +86,11 @@ const start = defineCommand({
8286
default: false,
8387
description: "Use a business plan GitHub Account",
8488
},
89+
enterprise: {
90+
type: "boolean",
91+
default: false,
92+
description: "Use a enterprise plan GitHub Account",
93+
},
8594
manual: {
8695
type: "boolean",
8796
default: false,
@@ -118,6 +127,7 @@ const start = defineCommand({
118127
port,
119128
verbose: args.verbose,
120129
business: args.business,
130+
enterprise: args.enterprise,
121131
manual: args.manual,
122132
rateLimit,
123133
rateLimitWait: Boolean(args.wait),

0 commit comments

Comments
 (0)