You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When invoking git bug push, in facts two git push are performed. One for bugs (from pushing refspec refs/bugs/) and one for identities (from pushing refspec refs/identities/). This implies the user shall enter its credential twice when working with a remote repository requireing credential.
Consider merging the two git push into a single invoke to make git-bug use more natural and easier.
I didn't check yet how this can be fixed, I just guess making one git push <remote> refs/identities/* refs/bugs/* should do the expected job. Just need to check how git-bug's push command is implemented and how the two current git command are distributed in classes and related implementation files to figure out what is the needed effort to fix this.
Neat ! i tested git push <remote> refs/identities/* refs/bugs/*, it works good and will imply the user to enter credential only once.
To make this work we'll have to change in the repository.Repo interface and all the structures implementing it to have something like PushRefs(remote string, refsSpecs ...string) . Same thing for FetchRefs.
Activity
a-hilaly commentedon Sep 30, 2019
Neat ! i tested
git push <remote> refs/identities/* refs/bugs/*, it works good and will imply the user to enter credential only once.To make this work we'll have to change in the repository.Repo interface and all the structures implementing it to have something like
PushRefs(remote string, refsSpecs ...string). Same thing forFetchRefs.The only thing that is not obvious for me now is how to reuse these functions in the push/pull commands.
One thing we could is to make the pattern strings public and use them like this in https://github.com/MichaelMure/git-bug/blob/master/cache/repo_cache.go#L674: