DIN

Docs

The DIN check on a GitHub pull request

din alm pr-check writes what your DIN field's record says about a pull request onto the pull request itself, as one GitHub check run named DIN CTRL. It is the record, not the agent's account of its own work: every line carries the field's own grade or a person's stamp.

What the check does

1. It reads the pull request's commits from GitHub, and refuses (writing nothing) if the commit you name is not one of them. 2. It reads your field over its HTTPS API: the sessions of one project (by default the repository's name) captured from the day of the PR's earliest commit through the day of its newest. 3. It writes one check run on the commit. Running again on the same commit updates that check; it never adds a second one.

The check shows:

The conclusion is neutral: DIN informs and never blocks a merge. Add --fail-on-refuted to conclude failure when a claim is refuted. A field that cannot be read gives a neutral check that says so.

How a PR is matched to records. DIN records do not name a commit yet. The check matches by project and by the PR's commit window, and says so on the check: a session in that project and window is listed whether or not it made these commits. Use --project when the field files the work under another name.

It calls no model and sends nothing to DIN. It reads your field and writes to GitHub, and nothing else.

What it needs

Set it up

Copy integrations/github/din-pr-check.yml into your repository as .github/workflows/din-pr-check.yml, then add the secret and the variable:

gh secret set DIN_FIELD_TOKEN
gh variable set DIN_FIELD_URL --body https://field.example.com

The workflow runs this on every push to a pull request:

din alm pr-check --repo "$REPO" --pr "$PR" --sha "$SHA" --field "$DIN_FIELD_URL"

To see the check without writing it, run the same command with --dry-run on a machine with GITHUB_TOKEN and DIN_FIELD_TOKEN set: it prints the summary and writes nothing.

Exit codes: 0 the check was written, 1 a read or the write failed, 2 refused (an argument, the plan, or a commit that is not the PR's).