Open
Description
When authenticating with github app creds, we need to attach a tokensource to the http.Client
, and provide it to the github.NewClient
. However, a github app needs to switch between app cred, app install cred and perhaps user cred. Which means we need to call github.NewClient
repeatedly with different http.Client
when switching between creds.
This is very painful when using github enterprise, as we need a follow up call c.WithEnterpriseURLs
at each callsite. It would be nice if we can add a method to do the necessary config copying when just changing the underlying http.Client
.