snowfs
snowfs copied to clipboard
Adding support for Snow hooks
Similar to git, SnowFS offers a default directory for adding custom hooks to be executed upon calling repository commands. This directory is located at $PROJECTDIR/.snow/hooks.
Typical git hooks are scripts, named and titularly executed as:
- applypatch-msg
- commit-msg
- fsmotir-watchman
- post-commit
- post-update
- pre-applypatch
- pre-commit
- pre-merge
- pre-merge-commit
- prepare-commit-msg
- pre-push
- pre-rebase
- pre-receive
- update
Currently these files are not executed when performing the matched action.
At least a subset of the above directives could be implemented to be called when the appropriate action is executed. Example implementations can be existing git hooks.
I just leave the following comments and ideas here. For Unix-based systems, it seems to be a no-brainer to implement it. A platform-independent solution is a little bit more tricky. Things to clarify:
- platform-independent she-bang support
- I never liked, that Git hooks are not part of the cloning process and must be separately installed.
If
SnowFSwill support remote clone/push, I would like to plan ahead for this feature