Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: RENOVATE_X_HARD_EXIT #9152

Merged
merged 4 commits into from
Mar 16, 2021
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions docs/usage/self-hosted-experimental.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,8 @@ If set to "false" (string), Renovate will remove any existing `package-lock.json
## RENOVATE_USER_AGENT

Configures the `user-agent` string to be sent with HTTP requests.

## RENOVATE_X_HARD_EXIT

If set to any value, Renovate will use a "hard" `process.exit()` once all work is done, even if a sub-process is otherwise delaying Node.js from exiting.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of the time you need to use a specific number/string/boolean to get things configured properly.

Are you sure literally any value will work to enable RENOVATE_X_HARD_EXIT?
I think it's clearer to say: "Set to x", where x is a specific value.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any value will do - true, yes, y, no, never, HonkingGoose. Basically it just needs to be "set"

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah okay, we can keep the text as-is then. 😄

See https://github.com/renovatebot/renovate/issues/8660 for background on why this was created.
4 changes: 4 additions & 0 deletions lib/renovate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,8 @@ proxy.bootstrap();
// eslint-disable-next-line @typescript-eslint/no-floating-promises
(async (): Promise<void> => {
process.exitCode = await globalWorker.start();
// istanbul ignore if
if (process.env.RENOVATE_X_HARD_EXIT) {
viceice marked this conversation as resolved.
Show resolved Hide resolved
process.exit(process.exitCode);
}
})();