Skip to content
This repository was archived by the owner on Nov 4, 2022. It is now read-only.
This repository was archived by the owner on Nov 4, 2022. It is now read-only.

Use git credential fill to securely store token #778

@cspotcode

Description

@cspotcode

Is your feature request related to a problem? Please describe.

I use a git access token stored in git's credential store for both git commands (pull, push) and for CLI scripts which talk to the github API. My scripts can extract the creds via git credential fill, and it's stored in my OS's keychain instead of plain text.

Describe the solution you'd like

some sort of configuration for gh so it can pull my access token from git credential fill

Describe alternatives you've considered

Additional context

This is how git credential fill works. Pipe a request in, it takes care of interactively prompting the user as needed, delegating to the OS-native credential helper. Then it writes a response to stdout.

echo 'url=https://github.com' | git credential fill

If node-gh wants to avoid conflicting with already-stored credentials, you could use a different form of URL. Or make this behavior an opt-in config flag so it doesn't affect everyone.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions