Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/songmu/gitconfig
https://github.com/songmu/gitconfig
Last synced: 28 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/songmu/gitconfig
- Owner: Songmu
- License: mit
- Created: 2019-05-13T13:31:13.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2022-09-03T13:15:49.000Z (about 2 years ago)
- Last Synced: 2024-06-20T03:44:24.859Z (5 months ago)
- Language: Go
- Homepage:
- Size: 42 KB
- Stars: 6
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
gitconfig
=======[![Test Status](https://github.com/Songmu/gitconfig/workflows/test/badge.svg?branch=main)][actions]
[![codecov.io](https://codecov.io/github/Songmu/gitconfig/coverage.svg?branch=main)][codecov]
[![MIT License](https://img.shields.io/github/license/Songmu/gitconfig)][license]
[![PkgGoDev](https://pkg.go.dev/badge/github.com/Songmu/gitconfig)][PkgGoDev][actions]: https://github.com/Songmu/gitconfig/actions?workflow=test
[codecov]: https://codecov.io/github/Songmu/gitconfig?branch=main
[license]: https://github.com/Songmu/gitconfig/blob/main/LICENSE
[PkgGoDev]: https://pkg.go.dev/github.com/Songmu/gitconfiggitconfig is a package to get configuration values from gitconfig.
## Synopsis
```go
val, err := gitconfig.Get("section.value")
if err != nil && !gitconfig.IsNotFound(err) {
return err
}// detect GitHub username from various informations
u, err := gitconfig.GitHubUser("")
```## Description
## Installation
```console
% go get github.com/Songmu/gitconfig
```## Author
[Songmu](https://github.com/Songmu)