pub fn git_username(
kind: IntegrationKind,
account: &str,
login: &str,
) -> Option<String>Expand description
The user name git’s HTTPS transport sends together with token for
kind, or None for a kind that is not a code host (issue trackers, a
folder of notes). Pure, so every host is a table-test row.
| Kind | User name |
|---|---|
| github, github enterprise | x-access-token |
| gitlab* | oauth2 |
| bitbucket cloud | the account, or x-token-auth for an access token (no account) |
| bitbucket data center | the account, else the login |
| azure devops* | any non-empty name: the account, else the login, else gitpoulpi |
| gitea, forgejo | the login, else the account |
| gerrit | the account (HTTP password auth), else the login |
account is the profile’s configured account, login the one the host
reported on the last check. A profile’s own username overrides this.