Skip to content
This repository was archived by the owner on Mar 6, 2024. It is now read-only.

Commit c826d63

Browse files
authored
print options (#98)
<!-- This is an auto-generated comment: release notes by openai --> ### Summary by OpenAI Release Notes: - New Feature: Adds a `print()` method to the `Options` class to print all options using `core.info()`. - Bug fix: None. > "Printing options with ease, no more guessing what's in these. With `core.info()` we can see, all the options that used to be unseen." <!-- end of auto-generated comment: release notes by openai -->
1 parent 78352df commit c826d63

File tree

3 files changed

+39
-0
lines changed

3 files changed

+39
-0
lines changed

dist/index.js

Lines changed: 17 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ async function run(): Promise<void> {
1818
core.getInput('openai_timeout_ms'),
1919
core.getInput('openai_concurrency_limit')
2020
)
21+
22+
// print options
23+
options.print()
24+
2125
const prompts: Prompts = new Prompts(
2226
core.getInput('review_beginning'),
2327
core.getInput('review_file'),

src/options.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,24 @@ export class Options {
241241
}
242242
}
243243

244+
// print all options using core.info
245+
print(): void {
246+
core.info(`debug: ${this.debug}`)
247+
core.info(`max_files_to_summarize: ${this.max_files_to_summarize}`)
248+
core.info(`max_files_to_review: ${this.max_files_to_review}`)
249+
core.info(`review_comment_lgtm: ${this.review_comment_lgtm}`)
250+
core.info(`path_filters: ${this.path_filters}`)
251+
core.info(`system_message: ${this.system_message}`)
252+
core.info(`openai_model: ${this.openai_model}`)
253+
core.info(`openai_model_temperature: ${this.openai_model_temperature}`)
254+
core.info(`openai_retries: ${this.openai_retries}`)
255+
core.info(`openai_timeout_ms: ${this.openai_timeout_ms}`)
256+
core.info(`openai_concurrency_limit: ${this.openai_concurrency_limit}`)
257+
core.info(
258+
`max_tokens_for_extra_content: ${this.max_tokens_for_extra_content}`
259+
)
260+
}
261+
244262
check_path(path: string): boolean {
245263
const ok = this.path_filters.check(path)
246264
core.info(`checking path: ${path} => ${ok}`)

0 commit comments

Comments
 (0)