Use password-store (aka pass) with forge and github-review
We can use pass
as an emacs auth-source
backend to access credentials.
Add auth-source-pass
(included with emacs 26) to your emacs config:
(require 'auth-source-pass)
(auth-source-pass-enable)
This prepends password-store
to the variable auth-sources
.
Add the GitHub access token to pass
with auth info.
pass insert -m api.github.com
<API_TOKEN>
<GH_USERNAME>^github-review
<GH_USERNAME>^forge
This allows forge
and github-review
to access the same token under a single pass
entry.
Done
To view what other pass
entries forge/github-review
access, enable debug and check the Messages buffer with an operation that requires authentication such as forge-add-repository
:
(setq auth-source-debug t)