mirror of
https://github.com/opdavies/build-configs.git
synced 2025-03-26 06:12:11 +00:00
fix(git-hooks): always create the commit msg hook
This commit is contained in:
parent
acd73bcb4f
commit
ec494d934f
|
@ -113,6 +113,12 @@ final class CreateListOfFilesToGenerate
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$filesToGenerate[] = new TemplateFile(
|
||||||
|
data: 'git-hooks/prepare-commit-msg',
|
||||||
|
name: 'prepare-commit-msg',
|
||||||
|
path: '.githooks',
|
||||||
|
);
|
||||||
|
|
||||||
if (Arr::get($configurationData, 'experimental.runGitHooksBeforePush', false) === true) {
|
if (Arr::get($configurationData, 'experimental.runGitHooksBeforePush', false) === true) {
|
||||||
$filesToGenerate[] = new TemplateFile(
|
$filesToGenerate[] = new TemplateFile(
|
||||||
data: 'git-hooks/pre-push',
|
data: 'git-hooks/pre-push',
|
||||||
|
|
|
@ -71,7 +71,6 @@ artisan *args:
|
||||||
{{ "just _run artisan {{ args }}" | raw }}
|
{{ "just _run artisan {{ args }}" | raw }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if experimental.runGitHooksBeforePush %}
|
|
||||||
# Enable or disable Git hooks
|
# Enable or disable Git hooks
|
||||||
git-hooks command:
|
git-hooks command:
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
@ -91,6 +90,7 @@ git-hooks command:
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
{% if experimental.runGitHooksBeforePush %}
|
||||||
test-commit:
|
test-commit:
|
||||||
{% if "phpcs" in php|keys -%}
|
{% if "phpcs" in php|keys -%}
|
||||||
just _run php phpcs
|
just _run php phpcs
|
||||||
|
|
Loading…
Reference in a new issue