require-forgejo-actions-workflow-file
Require at least one Forgejo or Codeberg Actions workflow file.
Targeted pattern scopeâ
This rule checks .forgejo/workflows/ for at least one workflow file with an
accepted extension:
.yml.yaml
What this rule reportsâ
This rule reports repositories that enable Codeberg or Forgejo-oriented presets
without any workflow files under .forgejo/workflows/.
Why this rule existsâ
Forgejo and Codeberg workflow policy only matters when the repository actually declares workflows.
This rule enforces the baseline expectation that a Forgejo/Codeberg repository using those presets has at least one workflow entry point for CI or governance automation.
â Incorrectâ
// Repository files
// .
// âââ README.md
// âââ package.json
// âââ .forgejo/
//
// Missing: .forgejo/workflows/*.yml or *.yaml
â Correctâ
// Repository files
// .
// âââ .forgejo/
// âââ workflows/
// âââ ci.yml
ESLint flat config exampleâ
import repoPlugin from "eslint-plugin-repo";
export default [
repoPlugin.configs.codeberg,
{
plugins: { "repo-compliance": repoPlugin },
rules: {
"repo-compliance/require-forgejo-actions-workflow-file": "error",
},
},
];
When not to use itâ
Disable this rule only if the repository does not use Forgejo or Codeberg Actions for automation.
Rule catalog ID: R016