Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scaffolding command for new built-in and custom rules #206

Closed
anderseknert opened this issue Jul 19, 2023 · 0 comments · Fixed by #219
Closed

Scaffolding command for new built-in and custom rules #206

anderseknert opened this issue Jul 19, 2023 · 0 comments · Fixed by #219
Labels

Comments

@anderseknert
Copy link
Member

Something like:

regal new rule --type custom --category naming --title lower-case

Which would:

  1. Create a .regal directory if none exists.
  2. Create a .regal/rules directory if none exists.
  3. Create a .regal/rules/category/title.rego file pre-populated with the basic required policy structure.
  4. Create a .regal/rules/category/title_test.rego file pre-populated with the basic required policy test structure.

And something similar to the above for creating new built-in rules as well, where the new files are added to the Regal bundle instead, and where there's also an entry added for documentation in the docs directory.

@bdjgs bdjgs mentioned this issue Jul 26, 2023
anderseknert added a commit that referenced this issue Aug 2, 2023
Add `regal new rule` command to allow quickly getting started working
with custom rules, or builtin rules for Regal itself. See added docs for
more details.

Fixes #206

Signed-off-by: Anders Eknert <anders@styra.com>
anderseknert added a commit that referenced this issue Aug 2, 2023
Add `regal new rule` command to allow quickly getting started working
with custom rules, or builtin rules for Regal itself. See added docs for
more details.

Fixes #206

Signed-off-by: Anders Eknert <anders@styra.com>
anderseknert added a commit that referenced this issue Aug 2, 2023
Add `regal new rule` command to allow quickly getting started working
with custom rules, or builtin rules for Regal itself. See added docs for
more details.

Fixes #206

Signed-off-by: Anders Eknert <anders@styra.com>
anderseknert added a commit that referenced this issue Aug 2, 2023
Add `regal new rule` command to allow quickly getting started working
with custom rules, or builtin rules for Regal itself. See added docs for
more details.

Fixes #206

Signed-off-by: Anders Eknert <anders@styra.com>
anderseknert added a commit that referenced this issue Aug 8, 2023
Add `regal new rule` command to allow quickly getting started working
with custom rules, or builtin rules for Regal itself. See added docs for
more details.

Fixes #206

Signed-off-by: Anders Eknert <anders@styra.com>
anderseknert added a commit that referenced this issue Aug 8, 2023
Add `regal new rule` command to allow quickly getting started working
with custom rules, or builtin rules for Regal itself. See added docs for
more details.

Fixes #206

Signed-off-by: Anders Eknert <anders@styra.com>
anderseknert added a commit that referenced this issue Aug 8, 2023
Add `regal new rule` command to allow quickly getting started working
with custom rules, or builtin rules for Regal itself. See added docs for
more details.

Fixes #206

Signed-off-by: Anders Eknert <anders@styra.com>
srenatus pushed a commit to srenatus/regal that referenced this issue Oct 1, 2024
Add `regal new rule` command to allow quickly getting started working
with custom rules, or builtin rules for Regal itself. See added docs for
more details.

Fixes StyraInc#206

Signed-off-by: Anders Eknert <anders@styra.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant