2024-06-19 07:53:27 +02:00
|
|
|
<!-- @format -->
|
|
|
|
|
2023-03-16 18:53:28 +01:00
|
|
|
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
|
|
|
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
|
|
|
|
|
|
|
- [Random git files](#random-git-files)
|
|
|
|
- [Tracking GitHub pull requests with `git`](#tracking-github-pull-requests-with-git)
|
2023-03-24 10:28:07 +01:00
|
|
|
- [Debugging git](#debugging-git)
|
2023-03-16 18:53:28 +01:00
|
|
|
|
|
|
|
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
|
|
|
|
2022-05-26 11:43:21 +02:00
|
|
|
# Random git files
|
|
|
|
|
2023-02-26 18:01:13 +01:00
|
|
|
- `gitignore` - `.gitignore` templates I may or may not use
|
|
|
|
- `etc/gitconfig` - a `/etc/gitconfig` for accepting signed pushes
|
2022-05-26 11:43:21 +02:00
|
|
|
|
|
|
|
## Tracking GitHub pull requests with `git`
|
|
|
|
|
|
|
|
```bash
|
|
|
|
git config --add remote.GITHUB.fetch '+refs/pull/*/head:refs/remotes/GITHUB/pr/*'
|
|
|
|
```
|
|
|
|
|
2024-06-19 07:53:27 +02:00
|
|
|
Replace `GITHUB` with the `git remote` name. I have picked this up from a dead
|
|
|
|
`git.io` link.
|
2022-05-26 11:43:21 +02:00
|
|
|
|
2024-06-19 07:53:27 +02:00
|
|
|
- TODO: Figure out if this also works for GitLab or what is the GitLab
|
|
|
|
version? Gitea too.
|
2023-02-26 18:01:13 +01:00
|
|
|
- https://gitea.blesmrt.net/mikaela/gist/issues/39
|
2023-03-24 10:28:07 +01:00
|
|
|
|
|
|
|
## Debugging git
|
|
|
|
|
|
|
|
Git obeys some environment variables that may be helpful for troubleshooting
|
|
|
|
|
|
|
|
- `GIT_CURL_VERBOSE=1` results to more information what git is doing e.g.
|
|
|
|
during cloning.
|
|
|
|
- [Verbose Output from git](https://wrightturn.wordpress.com/2016/08/16/verbose-output-from-git/)
|
|
|
|
- `GIT_TRACE=1` & `GIT_TRACE2=1` give very deep debug information
|
|
|
|
- [StackOverflow](https://stackoverflow.com/a/47561300)
|