https://github.com/xgames123/git-credential-github
A simple git credentials helper for github (Way less bloated than git credentails manager)
https://github.com/xgames123/git-credential-github
gcm gh-login git git-credential git-credential-github git-credential-helper github
Last synced: 10 months ago
JSON representation
A simple git credentials helper for github (Way less bloated than git credentails manager)
- Host: GitHub
- URL: https://github.com/xgames123/git-credential-github
- Owner: Xgames123
- License: mit
- Created: 2023-05-23T14:36:38.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-04-13T13:24:09.000Z (almost 2 years ago)
- Last Synced: 2025-03-21T22:22:23.752Z (10 months ago)
- Topics: gcm, gh-login, git, git-credential, git-credential-github, git-credential-helper, github
- Language: Rust
- Homepage:
- Size: 430 KB
- Stars: 8
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
A simple git [credentials helper](https://git-scm.com/docs/gitcredentials) for GitHub

# Features
* Its way less bloated than [Git Credential Manager](https://github.blog/2022-04-07-git-credential-manager-authentication-for-everyone)
* You can use it together with any other git credential helper of choice
# Install
## Debian/Ubuntu
Download the .deb from the [latest release](https://github.com/xgames123/git-credential-github/releases/latest) and run `dpkg -i file_you_just_downloaded.deb`
## Arch linux
Install git-credential-github form the AUR. [ArchLinux wiki](https://wiki.archlinux.org/title/Arch_User_Repository#Installing_and_upgrading_packages)
# Configuring
NOTE: Configuring changed after v2.2 [pre v2.2 config](PRE_v2_2_CONFIG.md)
```~/.gitconfig```
```ini
[credential "https://github.com"]
helper = cache
helper = github # important that you put it last because we only need to run gcg when other helpers have failed to give credentials
```
This sets the credential helper for github using the cache helper with a timeout of 1 day
## More examples
### Set only for repos owned by you
```~/.gitconfig```
```ini
[credential]
useHttpPath = true # makes git give the whole path instead of just https://github.com
[credential "https://github.com/Xgames123"] # change to your name
username=Xgames123 # change to your name
helper = cache
helper = github
```
### Use pass as the credential helper for everything
```~/.gitconfig```
```ini
[credential]
useHttpPath = true # makes git give the whole path instead of just https://github.com
helper = pass -r 3 -t ~/.config/git-credential-pass/default.template -p git/{protocol}/{host}/main
[credential "https://github.com/Xgames123"] # change to your name
username=Xgames123 # change to your name
helper = github
[credential "https://codeberg.org"]
username=ldev
```
# Bug or Error
If you find a bug, get an error or the docs are wrong.
* [Create an issue](https://github.com/Xgames123/git-credential-github/issues/new/)
* Message me <[ldev@ldev.eu.org](mailto://ldev@ldev.eu.org)>
* Message me on discord [ldev105](https://ldev.eu.org/socials/discord)
# Building debian packages from source
1. install [reltools](https://github.com/Xgames123/reltools)
2. run makepkgx --pkgformat deb inside the packaging directory