patches. Also have a look at our [Contribution Guidelines](CONTRIBUTING).
To start, run the following commands in the systemd git repository to set up
-git correctly:
+git correctly (running `meson` will run these commands for you automatically):
```shell
$ git config submodule.recurse true
#####################################################################
# Try to install the git pre-commit hook
-add_git_hook_sh = find_program('tools/add-git-hook.sh', required : false)
-if add_git_hook_sh.found()
- git_hook = run_command(add_git_hook_sh, check : false)
+git_setup_sh = find_program('tools/git-setup.sh', required : false)
+if git_setup_sh.found()
+ git_hook = run_command(git_setup_sh, check : false)
if git_hook.returncode() == 0
message(git_hook.stdout().strip())
endif
cd "${MESON_SOURCE_ROOT:?}"
+if [ -e .git ]; then
+ git config submodule.recurse true
+ git config fetch.recurseSubmodules on-demand
+fi
+
if [ ! -f .git/hooks/pre-commit.sample ] || [ -f .git/hooks/pre-commit ]; then
exit 2 # not needed
fi