-
-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Remove all unnecessary install modes #159
Merged
gabyx
merged 23 commits into
feature/v3
from
feature/remove-all-unnecessary-install-modes
Apr 17, 2024
Merged
feat: Remove all unnecessary install modes #159
gabyx
merged 23 commits into
feature/v3
from
feature/remove-all-unnecessary-install-modes
Apr 17, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Use `core.hooksPath` and install run-wrappers only when `githooks.useRunWrappers` is set.
gabyx
force-pushed
the
feature/remove-all-unnecessary-install-modes
branch
from
April 9, 2024 15:54
67a8ae1
to
9491434
Compare
gabyx
force-pushed
the
feature/remove-all-unnecessary-install-modes
branch
from
April 9, 2024 22:16
a3e84b0
to
2d12996
Compare
gabyx
force-pushed
the
feature/remove-all-unnecessary-install-modes
branch
from
April 10, 2024 18:19
2d12996
to
db23da5
Compare
gabyx
force-pushed
the
feature/remove-all-unnecessary-install-modes
branch
from
April 16, 2024 18:09
3a21e8e
to
9b672c9
Compare
gabyx
force-pushed
the
feature/remove-all-unnecessary-install-modes
branch
from
April 16, 2024 20:12
ac720a8
to
6118ae0
Compare
- Update go to 1.21 - Add test to comply with all hooks in Git - Add warning if hooks are existin on InstallRunWrapperLink - Remove all EXTRA_INSTALL_ARGS modification in dockerfile, but instead use explicit parameter to `exec-steps.sh`
gabyx
force-pushed
the
feature/remove-all-unnecessary-install-modes
branch
5 times, most recently
from
April 17, 2024 21:11
cb4a237
to
319785d
Compare
- Disable 064 because it stucks in the windows build
gabyx
force-pushed
the
feature/remove-all-unnecessary-install-modes
branch
from
April 17, 2024 21:30
319785d
to
f24599f
Compare
4 tasks
gabyx
added a commit
that referenced
this pull request
Apr 21, 2024
**Two modes:**: - The normal mode sets **local** `core.hooksPath` on `git hooks install` in a repository and will not do any automatic installation on clone/init. - The centralized mode sets this globally and will work by default for all clone/init repos. **More changes**: - Run-wrappers can still be installed in local repos, **`init.templateDir` is not used and controlled by Githooks anymore**. - Run-wrapper will use by default `githooks-runner` and as fallback use `git config githooks.runner`. Package manager builds `tag: package_manager_enabled` will not set this. - The installer has an option `--hooks-dir` which specifies the directory to place the maintained hooks. - The installer has an option `--hooks-dir-use-template-dir` in non-`--centralized` mode which looks for a set `GIT_TEMPLATE_DIR` or `init.templateDir` or the Git default directory. This option is not encouraged, and will install templates on each init/clone as before. - The installer warns if the chosen hooks dir during install is pointing to a template directory used by Git. - User wanting to install run-wrappers instead of setting `core.hooksPath` should either use `git hooks install --maintained-hooks` or place a file `<template-dir>/hooks/githooks-contains-run-wrappers` to let Githooks know that this repo maintains run-wrappers (for updates etc, that no `core.hooksPath` is used but run-wrappers installed directly). - Registering is now done for all repositories (also in centralized mode). - `git hook uninstall --full` and `git hooks uninstaller --full-uninstall-from-repos` will clean all Git config and cached settings (checksums) in registered repositories, by default `git hooks uninstall` will not remove locally set `githooks.*` Git config variables, this is to make `reinstallation` more easy, e.g. `githooks.maintainedHooks` stays and will be read on reinstall. **CI**: - Go 1.22 - Remove `EXTRA_INSTALL_ARGS` sed modifications and pass explicitly. - Disabled hanging test 064 (build from source) on windows. - Coverage also runs `--centralized` tests too.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes: #152.
Two modes::
core.hooksPath
ongit hooks install
in a repository and will not do any automatic installation on clone/init.More changes:
Run-wrappers can still be installed in local repos,
init.templateDir
is not used and controlled by Githooks anymore.Run-wrapper will use by default
githooks-runner
and as fallback usegit config githooks.runner
. Package manager buildstag: package_manager_enabled
will not set this.The installer has an option
--hooks-dir
which specifies the directory to place the maintained hooks.The installer has an option
--hooks-dir-use-template-dir
in non---centralized
mode which looks for a setGIT_TEMPLATE_DIR
orinit.templateDir
or the Git default directory. This option is not encouraged, and will install templates on each init/clone as before.The installer warns if the chosen hooks dir during install is pointing to a template directory used by Git.
User wanting to install run-wrappers instead of setting
core.hooksPath
should either usegit hooks install --maintained-hooks
or place a file<template-dir>/hooks/githooks-contains-run-wrappers
to let Githooks know that this repo maintains run-wrappers (for updates etc, that nocore.hooksPath
is used but run-wrappers installed directly).Registering is now done for all repositories (also in centralized mode).
git hook uninstall --full
andgit hooks uninstaller --full-uninstall-from-repos
will clean all Git config and cached settings (checksums) in registered repositories, by defaultgit hooks uninstall
will not remove locally setgithooks.*
Git config variables, this is to makereinstallation
more easy, e.g.githooks.maintainedHooks
stays and will be read on reinstall.