Separate personal config files from source code
This rule provides a safety check to verify that any personal config files (e.g. local configuration / history / preference) that you wish to remain private are not committed to your source control.
Including personal config files is unnecessary, could be counterproductive, and might have security implications if you expose details about your machine’s setup.
- Ensure appropriate commits and source control additions
- Prevent a potential security breach by exposing information regarding your machine / server
When does this rule fail?
When one of the commits in the pull request contains a personal file pattern.
How to fix?
- Remove the personal config files (listed in the failure message)
- Push the new code to your branch:
$ git rm <personal-config-file-path> $ git commit -m "removed personal config files from code" $ git push
- Datree's policy check automatically ensures no personal config file are removed from the pull request
|Activate a policy|