Usage
TLDR
npx codefather-init
npm run codefatherCommands
codefather: checks if your access rules are respected in your repository.codefather-init: creates a default config at the root of your repository and adds acodefathercommand to yourpackage.json.If a
.github/CODEOWNERSfile is present, it will be used to generate the config.Accepts two optional flags:
json: generates a json config file instead of atsone.overwrite: overwrite an existing codefather config.example:
npm run codefather-init json overwrite
codefather-github: similar tocodefather, but designed to run in a GitHub Action environment
You can either add a script shortcut in your package.json:
"scripts": {
"codefather": "codefather",
}Or directly run the commands with npx.
👉 The CLI mode only checks files that are staged, unstaged, newly created, or deleted. Once a file is committed, it won’t be rechecked unless modified again. For full enforcement across all commits, use Codefather in a GitHub Action.
Last updated