You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Turbogit rely on bare git workflow, enhancing it with some useful high level, highly opinionated commands. In that sense it uses and should keep using the bare git config model. This model is well known and fit every configuration needs of turbogit.
However more and more features rely on some critical configuration keys (like integrations, commit type referenced in #57, and more to come). Making sure every instances of a given repository follow the same configuration is cumbersome and error prone. Sharing the git config itself is highly discouraged due to possible sensitive information leak.
Describe the solution you'd like
We could add a rule system as an init hook call before every turbogit command. This hook would ensure that your current config matches a set of given rules. This set of rules would be defined by some hard-coded rules (to avoid breaking conventions that turbogit is designed to enforce) merged with user-defined rules. The latter would lay in a per-repo file with a simple well known format (toml, yaml, etc...)
To speed up the hook execution, a hash (sum of rules) of last checked rules would be written inside a dedicated key (tug.rules?) in the local git config. This way rules are tested only if this hash doesn't exist or doesn't match the current set of rules.
A command could also be added to manage this ruleset (list,add,remove,update rules).
Is your feature request related to a problem? Please describe.
Turbogit rely on bare git workflow, enhancing it with some useful high level, highly opinionated commands. In that sense it uses and should keep using the bare git config model. This model is well known and fit every configuration needs of turbogit.
However more and more features rely on some critical configuration keys (like integrations, commit type referenced in #57, and more to come). Making sure every instances of a given repository follow the same configuration is cumbersome and error prone. Sharing the git config itself is highly discouraged due to possible sensitive information leak.
Describe the solution you'd like
We could add a rule system as an init hook call before every turbogit command. This hook would ensure that your current config matches a set of given rules. This set of rules would be defined by some hard-coded rules (to avoid breaking conventions that turbogit is designed to enforce) merged with user-defined rules. The latter would lay in a per-repo file with a simple well known format (
toml
,yaml
, etc...)To speed up the hook execution, a hash (sum of rules) of last checked rules would be written inside a dedicated key (
tug.rules
?) in the local git config. This way rules are tested only if this hash doesn't exist or doesn't match the current set of rules.A command could also be added to manage this ruleset (list,add,remove,update rules).
Additional context
The text was updated successfully, but these errors were encountered: