Hoc workflows

From openreachtech/hora-skills-ort-core · View interactive version

Hoc workflows is an AI agent skill from the GitHub repository openreachtech/hora-skills-ort-core. Development workflow conventions for carrying an implementation from its start to its completion. Use when starting implementation work, when the surrounding code disagrees with a convention, before committing, and before declaring the work complete. What a commit holds and how it is worded belongs

How to use this skill

Skill file

Workflows

Procedural rules related to the development workflow.

How to proceed with implementation

  1. Design the class composition of the feature as a whole
  2. Design the member composition of each class
  3. Write the tests
  4. Implement the class members
  5. Commit, in the order /hoc-git-commit-order sets

The existing code is not a template

A convention outranks the code already in the repository. Where a skill states

how something is written and the files around it are written another way, the new

code follows the skill. Those files record what the convention was before it was

written down, and matching them propagates the very thing the convention exists to

stop.

broken by sixty are the same rule. A majority in the repository is evidence of

when the code was written, never of what is correct.

the code exists starts at zero occurrences of the spelling it prescribes, so the

tally is guaranteed to argue against every rule on the day it is adopted.

Reaching for grep -c to settle which spelling is right asks a question whose

answer was fixed before the rule was written, and reading a count of 441 to 0 as

"the repository says otherwise" inverts what the numbers mean.

it" is the whole justification, and 441 to 1 is what a convention looks like on

its first day rather than evidence against it. The spelling that is about to be

written is the one the count is missing.

convention has already answered, and what the files around you happen to do adds

nothing to that answer.

show what has been done, which is not the same as what may be done. Code that is

worse than what you already know how to write does not become acceptable by being

nearby, and matching it writes the flaw a second time — leaving the next reader

two examples of it instead of one, and a majority where there had been an

exception. What stands in where nothing is written is the coding charter and the

QA stance the tests are held to, never the nearest file.

nothing is written it sends a reviewer to the baseline and the charter too, and

it raises a departure from the surrounding code only where the departure is the

worse of the two. Code written to this rule is therefore not a finding under

that one.

file, or to leave a module's style alone, is that instruction. Being asked to add

something to a file is not.

licence to rewrite what is already there. Bringing existing files up to a

convention is work of its own, and it is asked for separately.

Before committing

Every commit leaves the tree lint-clean. Lint the files, not the repository — npm run lint

walks the whole tree and is too slow to sit in front of every commit.

goes first, and why, belongs to /hoc-git-commit-order — so staging the implementation

alongside the tests to keep the suite green destroys the split. The suite is held to green

where the branch is offered for merge, below.

failure**: it must fail on the behavior the tests assert, not on a typo, a bad import or a

missing fixture. A test commit that is red for the wrong reason is a defect; one in which

nothing fails asserts nothing. Note that jest reads those arguments as regular expressions

matched against the whole test path, not as literal paths, so a pattern selects every file it

matches — unlike the eslint arguments above, which are paths.

Before completing implementation

the whole suite, before completing the implementation. Narrowing the run to the files just

changed here would hide the tests this work broke elsewhere. Do not consider the

implementation complete while either one is failing.

than before it starts; see the git branch convention.

Before offering a branch for merge

before it is merged locally into a trunk.** This is the one point the suite is held to green:

the red commits a branch carries on purpose have been cleared by then, and a red still standing

is unfinished work, cleared before the branch goes on.

not before. A rebase brings in the trunk's latest commits, and a suite that passed against the

old base says nothing about the new one.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.