Skip to content

New common mistake: gitlab host for unix password-store #529

@gabor-braun

Description

@gabor-braun

I had troubles setting up forge to use Unix password store for a private GitLab instance. What was unclear to me is to where to put the path (e.g., /api/v4) of the gitlab host in the password store. What works for me: omitting it altogether.

Please add this to the page on common mistakes. Perhaps also to the documentation of ghub.

Just to clarify, a working example (with private information replaced):

Init file:

(require 'auth-source-pass)
(require 'forge

(setq auth-sources '(password-store))

(push
   '("git.example.com" "git.example.com/api/v4" "git.example.com" forge-gitlab-repository)
   forge-alist)

~/.password-store/git.example.com/ziggy^forge.gpg decrypted:

012345abcdef...

This is the analogue an example form ghub's documetation,
except that /api/v4 is omitted. It only appears in forge-alist.

Init file:

  (setq auth-sources '("~/.authinfo"))

~/.authinfo:

 machine gitlab.com/api/v4 login ziggy^forge password 012345abcdef...

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