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

Suggestion: implement "rules" #275

Open
Sami32 opened this issue Aug 28, 2018 · 1 comment
Open

Suggestion: implement "rules" #275

Sami32 opened this issue Aug 28, 2018 · 1 comment
Milestone

Comments

@Sami32
Copy link

Sami32 commented Aug 28, 2018

That should make the code much simpler and shorter on complex packages IMO.

<rulesets>
  <ruleset>
    <id>Default-settings</id>
    <rules>
      <rule>
        <user>root</user>
        <group>root</group>
      </rule>
      <rule>
        <when>
          <type>directory</type>
        </when>
        <mode>0755</mode>
      </rule>
      <rule>
        <when>
          <type>file</type>
        </when>
        <mode>0644</mode>
      </rule>
      <rule>
        <when>
          <type>directory</type>
          <suffix>documentation</suffix>
        </when>
        <documentation>true</documentation>
      </rule>
      <file>
        <when>
          <suffix>README.txt</suffix>
        </when>
        <readme>true</readme>
      </file>
      <file>
        <when>
          <type>file</type>
          <suffix>.sh</suffix>
        </when>
        <mode>0755</mode>
      </file>
    </rules>
  </ruleset>
</rulesets>
@tcurdt
Copy link
Owner

tcurdt commented Aug 28, 2018

Which code?

I fear this new approach is out of scope for the 1.x branch.
And I am not such a great fan of adding a rules engine to approach this - but have a look at #195.

@tcurdt tcurdt added this to the 2.0 milestone Aug 28, 2018
@Sami32 Sami32 mentioned this issue Aug 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants