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

SE: refinements for redefining identifiers #3

Open
3 tasks
ma-ilsi opened this issue Oct 9, 2023 · 0 comments
Open
3 tasks

SE: refinements for redefining identifiers #3

ma-ilsi opened this issue Oct 9, 2023 · 0 comments
Assignees
Labels
Sophie Standard development-track and engineering.
Milestone

Comments

@ma-ilsi
Copy link
Owner

ma-ilsi commented Oct 9, 2023

Background

Motivation for a problem or that which needs to be built.

From the flexibility sketched in the early drafts of Sophie was the idea of "refining" a notice or filecabinet identifier's definition to take represent a different set of files later in the config than what may have been the definition earlier in the config. This can mean adding files to the previous group of files, or refining them with stricter conditions, thereby resulting in a fewer number than the original definition. In the context of notices, the idea is similar an identifier can redefine it's location or generalise its pattern.

This opens the door to dynamic re-definitions of identifiers, removes noise, makes config files concise, dense, meaningful. It will later play a huge role in conditional effects/compliance checks (if ever implemented).

This scheme is now called refinements.

Proposal

Blueprint to resolve or implement.

  • Implement chaining multiple [ ] (definitions) to refine a previous definition.
filecabinet:
    net_code["pattern="net_.*\.[ch]$";][size="+1k";]
    ...
    net_code["pattern="net_.*\.sh$";]
  • Implement special empty [ ] that represents resetting or emptying the previous definition.
filecabinet:
    net_code[ ]
  • Add syntax to represent additive refinements (think OR operation), and subtractive refinements (think ADD operation).
@ma-ilsi ma-ilsi added the Sophie Standard development-track and engineering. label Oct 9, 2023
@ma-ilsi ma-ilsi added this to the Road to V1 milestone Oct 9, 2023
@ma-ilsi ma-ilsi self-assigned this Oct 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Sophie Standard development-track and engineering.
Projects
None yet
Development

No branches or pull requests

1 participant