git-hooks.nix icon indicating copy to clipboard operation
git-hooks.nix copied to clipboard

feat: add woodpecker-cli lint hook

Open acid-bong opened this issue 5 months ago • 0 comments

I only implemented the args for the workflow config path (positional), strict mode (lint-specific) and disabled network-dependent update check (global option; same page, at the top -- the headings don't have anchors). ~~The only args, whose syntax I don't quite understand (yet), are plugin-related ones~~ Already implemented, they are supposed to be comma-separated:

--plugins-privileged="": allow plugins to run in privileged mode, if set empty, there is no (default: [])

--plugins-trusted-clone="": plugins that are trusted to handle Git credentials in cloning steps (default: [docker.io/woodpeckerci/plugin-git:2.6.3 docker.io/woodpeckerci/plugin-git quay.io/woodpeckerci/plugin-git])

The rest of the global flags are network-dependent and require authorization to the necessary Woodpecker server, and the lint subcommand works offline, hence I didn't bother to implement those.

A tip I'd like to ask you for: is woodpecker-cli-lint a good name for the hook? On one hand, it's more accurate that just woodpecker-cli, cuz I'm only implementing one subcommand, and woodpecker-lint, cuz the hook runs specifically woodpecker-cli, and the woodpecker executable (without -cli) is getting deprecated. On the other hand, those two options (or a simple woodpecker) are shorter.

acid-bong avatar May 11 '25 11:05 acid-bong