Add pre-commit hook

This is something we can use to check formatting before
any commits are pushed.
This commit is contained in:
Christopher Davis 2021-09-29 00:48:00 -07:00
parent 8361c3a7d4
commit 80502064ce
2 changed files with 63 additions and 0 deletions

View file

@ -53,4 +53,10 @@ subdir('help')
subdir('src')
subdir('po')
# Pre-commit hook for rust formatting
if get_option('profile') == 'development'
message('Setting up git pre-commit hook..')
run_command('cp', '-f', 'hooks/pre-commit.hook', '.git/hooks/pre-commit')
endif
meson.add_install_script('build-aux/meson/postinstall.py')