https://github.com/figadore/keyring
A simple cross-platform keychain command line utility
https://github.com/figadore/keyring
Last synced: over 1 year ago
JSON representation
A simple cross-platform keychain command line utility
- Host: GitHub
- URL: https://github.com/figadore/keyring
- Owner: figadore
- Created: 2022-02-09T17:51:38.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2022-02-25T18:18:47.000Z (over 4 years ago)
- Last Synced: 2025-04-10T05:12:27.681Z (over 1 year ago)
- Language: Go
- Size: 4.88 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Keyring
A simple cross-platform keychain command line utility based on [zalando/go-keyring](https://github.com/zalando/go-keyring)
## Installation
### Global
go get github.com/figadore/keyring
### From source
go install
## Usage
### Example
The following example shows how to use `kr` in a curl command to access the GitHub API. If the `github-pat` secret does not exist yet, it will prompt for populating its value. Once populated, the secret is read out on subsequent calls without any additional action needed.
```
curl -u octocat:$(kr github-pat) https://api.github.com/users/octocat
```
### Help
kr -h
```
Usage of kr:
-c If set, show text while typing (for non-secrets only)
-d Delete
-e If set, just check for existence of key
-prompt string
Prompt string for secret, if it doesn't exist
-s If set, do not print value (useful for input-only scenarios)
```