DEDUPED Hot AI repos, turned into use cases Get 5 a day

How to run the built-in selftest in CI before publishing a release with Setup Gateway

Check the Setup Gateway pure functions in CI without touching real config files.

Who it is forA maintainer or contributor of Setup Gateway who wants a fast pass or fail signal on every change before a release.

The problemChanges to config writing or flag parsing can break setup for all three tools, and manual testing on real config is risky.

The outcomeCI gets an exit code of 0 or 1 from the selftest, and no real config file is modified during the check.

What you need first

  • Node.js 18 or newer installed
  • A gateway base URL that exposes /v1 and an API key for it
  • A model id the gateway serves, or access to GET /v1/models so the picker can list them
  • For Codex: a gateway that serves the Responses API (/v1/responses)

Steps

  1. Clone the repo and make sure Node 18 or newer is available.
  2. Run node setup-gateway.mjs --selftest (or npm run selftest).
  3. Check that the process exits with code 0.
  4. Add the same command as a step in your CI workflow so it runs on every pull request. (inferred, check the README)

Prompt for your agent

In the repo Sinholms/setup-gateway, run `node setup-gateway.mjs --selftest` and report the number of assertions and the exit code. Expect exit code 0 with no real config files changed. Verify that the exit code is 0 before approving any release step.

Caveat. The README describes the selftest as running dozens of assertions, so treat the exit code as the pass signal, not a specific count.

Share: X LinkedIn Hacker News Email Copy link

Disclaimer

Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked "Seen in the wild", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email [email protected] and we will look at it promptly. Full disclaimer page