Skip to content

stgit not finding user information #438

@immae

Description

@immae

Hello,

I’m running stgit version 2.4.5 . Since a recent change in the way I’m handling my git config, stgit became unable to get my user.name and user.email information:

repo $ stg new                                                                                                                                                            
error: author identity unknown; please configure `user.name` and `user.email`.
repo $ git config --get user.email                                                                                                                                        
[email protected]
repo $ git config --get user.name
Immae

The change is as follows: my global git config used to have a [user] section.
Now I’m making use of a git feature to include conditional configuration:

[includeIf "hasconfig:remote.*.url:[email protected]:*/**"]
        path = ~/.config/git/perso.gitconfig
[includeIf "hasconfig:remote.*.url:[email protected]:*/**"]
        path = ~/.config/git/work.gitconfig

and the work.gitconfig / perso.gitconfig paths now contain the [user] section instead of the global git config.

This works just fine with normal git commands, but not with stgit. I suppose that stgit is doing a separate parsing of the git config file and misses that information. Is there any way to get that working?

Thanks in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions