Software factory / Start
Set the rules for all agents
Some settings hold for every agent of the factory: auto-merge, checks that start after a clean audit, the daily runs of an author, review rounds, the ban policy and the dependency updates. You want to change one of them for a repository or an organization.
4 min read
The card Rules for all agents has these settings of the whole factory. You need admin access to the repository, or to be an owner of the organization.
1. Open the rules
- On a repository, open Agents, then click Rules under Software factory in the sidebar.
- On an organization, open the Software factory tab, and go to the card Rules for all agents.
2. Change the values
Change each value that you want. The rules and Dependency updates give the default and the range of each value.
3. Save
Click Save rules.
Done
The factory of the repository follows the new rules. On an organization, each repository follows them, except the values that a repository set for itself.
Set one dependency policy for every repository
You own an organization, and you want each repository to update its dependencies the same way.
- Open
/organizations/<org>/factory, the Software factory tab. - To let an agent fix the update pull requests whose CI fails, turn on the switch of Dependencies. It saves at once.
- In the card Rules for all agents, go to Dependency updates.
- Turn on Update on a schedule. Set How often, Days before a version counts and Major update pull requests.
- Click Save rules.
Each repository of the organization now inherits the agent switch and the four values. A repository admin can change each value for the repository. A value that the admin does not change stays inherited.
With Update on a schedule on, each repository checks its dependencies on the schedule, and opens or updates its update pull requests. Code changes the versions and installs, with no model. With the Dependencies agent on, the agent fixes the code of an update pull request when its CI fails.
The rules
| Setting | Default | Range |
|---|---|---|
| Monthly spend cap in dollars | The maximum of the forge | 1 dollar up to the maximum of the forge, or up to 100,000 dollars while billing is on for the organization. Organizations only. See Cap the monthly model spend. |
| Auto-merge | Off | On or off. See Ready to merge. |
| Start checks after a clean audit | Off | On or off. When it is on, a clean security audit of the head of a pull request starts its CI runs that wait for an approval. The runs stay untrusted. See Start checks after a clean audit. |
| Runs per author each day | 20 | 1 to 1,000. For authors without write access. |
| Review rounds | 3 | 1 to 10. How many times Push fixes runs for one push. Fix failing CI has its own count, with the same limit. |
| Days to wait on needs-info | 7 | 1 to 365. See Close duplicate issues with triage. |
| Lines for medium to merge | 300 | 1 to 999,999, below the hard limit. A pull request that changes this many lines or more is medium to merge. See Find the pull requests to handle first. |
| Lines for hard to merge | 1000 | Above the medium limit, up to 1,000,000. A pull request that changes more lines than this is hard to merge. |
| Ban policy, A ban applies to | Ban only on hard proof, the repository only | See Spam and bans. |
| Custom agents come from | The vault | See Custom agents. |
| Secrets for the package install | None | The CI secrets that the install of .source/factory.ts can use, for a private package registry. See A private package registry. |
Dependency updates
These four settings are under Dependency updates in the card. They apply to the Dependencies tab, with the Dependencies agent on or off. See Keep dependencies up to date.
| Setting | Default | Range |
|---|---|---|
| Update on a schedule | Off | On or off. When it is on, the schedule checks the dependencies and opens or updates the update pull requests. When it is off, nothing runs on a schedule. |
| How often | Every week | Every day or Every week. How often the schedule checks and updates. |
| Days before a version counts | 3 | 0 to 30. A new version counts only when it is this many days old. 0 takes any age. |
| Major update pull requests | 3 | 0 to 10. The most pull requests for major updates in one check. 0 opens none. |