@gitkraken/core-gitlens 0.3.1 → 0.4.100
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +83 -1
- package/README.md +22 -12
- package/dist/git/cache.d.ts +29 -2
- package/dist/git/cache.d.ts.map +1 -1
- package/dist/git/cache.js +67 -7
- package/dist/git/cache.js.map +1 -1
- package/dist/git/context.d.ts +4 -3
- package/dist/git/context.d.ts.map +1 -1
- package/dist/git/context.js.map +1 -1
- package/dist/git/errors.d.ts +31 -1
- package/dist/git/errors.d.ts.map +1 -1
- package/dist/git/errors.js +29 -0
- package/dist/git/errors.js.map +1 -1
- package/dist/git/models/author.d.ts.map +1 -1
- package/dist/git/models/author.js.map +1 -1
- package/dist/git/models/autolink.d.ts.map +1 -1
- package/dist/git/models/autolink.js.map +1 -1
- package/dist/git/models/blame.d.ts.map +1 -1
- package/dist/git/models/blame.js.map +1 -1
- package/dist/git/models/branch.d.ts.map +1 -1
- package/dist/git/models/branch.js.map +1 -1
- package/dist/git/models/commit.d.ts.map +1 -1
- package/dist/git/models/commit.js +1 -1
- package/dist/git/models/commit.js.map +1 -1
- package/dist/git/models/contributor.d.ts.map +1 -1
- package/dist/git/models/contributor.js.map +1 -1
- package/dist/git/models/defaultBranch.d.ts.map +1 -1
- package/dist/git/models/defaultBranch.js.map +1 -1
- package/dist/git/models/diff.d.ts.map +1 -1
- package/dist/git/models/diff.js.map +1 -1
- package/dist/git/models/file.d.ts.map +1 -1
- package/dist/git/models/file.js.map +1 -1
- package/dist/git/models/fileChange.d.ts.map +1 -1
- package/dist/git/models/fileChange.js.map +1 -1
- package/dist/git/models/fileStatus.d.ts +22 -22
- package/dist/git/models/fileStatus.d.ts.map +1 -1
- package/dist/git/models/fileStatus.js.map +1 -1
- package/dist/git/models/graph.d.ts +122 -1
- package/dist/git/models/graph.d.ts.map +1 -1
- package/dist/git/models/graph.js +4 -0
- package/dist/git/models/graph.js.map +1 -1
- package/dist/git/models/graphSearch.d.ts.map +1 -1
- package/dist/git/models/graphSearch.js.map +1 -1
- package/dist/git/models/graphSession.d.ts +177 -0
- package/dist/git/models/graphSession.d.ts.map +1 -0
- package/dist/git/models/graphSession.js +7 -0
- package/dist/git/models/graphSession.js.map +1 -0
- package/dist/git/models/issue.d.ts +12 -2
- package/dist/git/models/issue.d.ts.map +1 -1
- package/dist/git/models/issue.js +3 -1
- package/dist/git/models/issue.js.map +1 -1
- package/dist/git/models/issueOrPullRequest.d.ts.map +1 -1
- package/dist/git/models/issueOrPullRequest.js.map +1 -1
- package/dist/git/models/lineRange.d.ts.map +1 -1
- package/dist/git/models/lineRange.js.map +1 -1
- package/dist/git/models/log.d.ts.map +1 -1
- package/dist/git/models/log.js.map +1 -1
- package/dist/git/models/mergeConflicts.d.ts.map +1 -1
- package/dist/git/models/mergeConflicts.js.map +1 -1
- package/dist/git/models/patch.d.ts.map +1 -1
- package/dist/git/models/patch.js.map +1 -1
- package/dist/git/models/pausedOperationStatus.d.ts.map +1 -1
- package/dist/git/models/pausedOperationStatus.js.map +1 -1
- package/dist/git/models/pullRequest.d.ts +27 -2
- package/dist/git/models/pullRequest.d.ts.map +1 -1
- package/dist/git/models/pullRequest.js +7 -1
- package/dist/git/models/pullRequest.js.map +1 -1
- package/dist/git/models/rebase.d.ts.map +1 -1
- package/dist/git/models/rebase.js.map +1 -1
- package/dist/git/models/reference.d.ts.map +1 -1
- package/dist/git/models/reference.js.map +1 -1
- package/dist/git/models/reflog.d.ts.map +1 -1
- package/dist/git/models/reflog.js.map +1 -1
- package/dist/git/models/remote.d.ts.map +1 -1
- package/dist/git/models/remote.js.map +1 -1
- package/dist/git/models/remoteProvider.d.ts.map +1 -1
- package/dist/git/models/remoteProvider.js.map +1 -1
- package/dist/git/models/remoteResource.d.ts.map +1 -1
- package/dist/git/models/remoteResource.js.map +1 -1
- package/dist/git/models/repository.d.ts +20 -2
- package/dist/git/models/repository.d.ts.map +1 -1
- package/dist/git/models/repository.js +19 -0
- package/dist/git/models/repository.js.map +1 -1
- package/dist/git/models/repositoryChangeEvent.d.ts.map +1 -1
- package/dist/git/models/repositoryChangeEvent.js.map +1 -1
- package/dist/git/models/repositoryIdentities.d.ts.map +1 -1
- package/dist/git/models/repositoryIdentities.js.map +1 -1
- package/dist/git/models/repositoryMetadata.d.ts.map +1 -1
- package/dist/git/models/repositoryMetadata.js.map +1 -1
- package/dist/git/models/resourceDescriptor.d.ts +16 -0
- package/dist/git/models/resourceDescriptor.d.ts.map +1 -1
- package/dist/git/models/resourceDescriptor.js.map +1 -1
- package/dist/git/models/revision.d.ts.map +1 -1
- package/dist/git/models/revision.js.map +1 -1
- package/dist/git/models/search.d.ts.map +1 -1
- package/dist/git/models/search.js.map +1 -1
- package/dist/git/models/shortlog.d.ts.map +1 -1
- package/dist/git/models/shortlog.js.map +1 -1
- package/dist/git/models/signature.d.ts +14 -0
- package/dist/git/models/signature.d.ts.map +1 -1
- package/dist/git/models/signature.js.map +1 -1
- package/dist/git/models/staging.d.ts.map +1 -1
- package/dist/git/models/staging.js.map +1 -1
- package/dist/git/models/stash.d.ts.map +1 -1
- package/dist/git/models/stash.js.map +1 -1
- package/dist/git/models/status.d.ts.map +1 -1
- package/dist/git/models/status.js.map +1 -1
- package/dist/git/models/statusFile.d.ts.map +1 -1
- package/dist/git/models/statusFile.js.map +1 -1
- package/dist/git/models/tag.d.ts +11 -1
- package/dist/git/models/tag.d.ts.map +1 -1
- package/dist/git/models/tag.js +9 -2
- package/dist/git/models/tag.js.map +1 -1
- package/dist/git/models/tree.d.ts.map +1 -1
- package/dist/git/models/tree.js.map +1 -1
- package/dist/git/models/user.d.ts.map +1 -1
- package/dist/git/models/user.js.map +1 -1
- package/dist/git/models/worktree.d.ts.map +1 -1
- package/dist/git/models/worktree.js.map +1 -1
- package/dist/git/parsers/diffParser.d.ts.map +1 -1
- package/dist/git/parsers/diffParser.js +1 -1
- package/dist/git/parsers/diffParser.js.map +1 -1
- package/dist/git/parsers/rebaseTodoParser.d.ts.map +1 -1
- package/dist/git/parsers/rebaseTodoParser.js.map +1 -1
- package/dist/git/providers/blame.d.ts.map +1 -1
- package/dist/git/providers/blame.js.map +1 -1
- package/dist/git/providers/branches.d.ts +8 -1
- package/dist/git/providers/branches.d.ts.map +1 -1
- package/dist/git/providers/branches.js.map +1 -1
- package/dist/git/providers/commits.d.ts +6 -1
- package/dist/git/providers/commits.d.ts.map +1 -1
- package/dist/git/providers/commits.js.map +1 -1
- package/dist/git/providers/config.d.ts +6 -2
- package/dist/git/providers/config.d.ts.map +1 -1
- package/dist/git/providers/config.js.map +1 -1
- package/dist/git/providers/contributors.d.ts.map +1 -1
- package/dist/git/providers/contributors.js.map +1 -1
- package/dist/git/providers/diff.d.ts.map +1 -1
- package/dist/git/providers/diff.js.map +1 -1
- package/dist/git/providers/graph.d.ts +55 -1
- package/dist/git/providers/graph.d.ts.map +1 -1
- package/dist/git/providers/graph.js.map +1 -1
- package/dist/git/providers/operations.d.ts +1 -0
- package/dist/git/providers/operations.d.ts.map +1 -1
- package/dist/git/providers/operations.js.map +1 -1
- package/dist/git/providers/patch.d.ts.map +1 -1
- package/dist/git/providers/patch.js.map +1 -1
- package/dist/git/providers/pausedOperations.d.ts.map +1 -1
- package/dist/git/providers/pausedOperations.js.map +1 -1
- package/dist/git/providers/provider.d.ts.map +1 -1
- package/dist/git/providers/provider.js.map +1 -1
- package/dist/git/providers/refs.d.ts.map +1 -1
- package/dist/git/providers/refs.js.map +1 -1
- package/dist/git/providers/remotes.d.ts.map +1 -1
- package/dist/git/providers/remotes.js.map +1 -1
- package/dist/git/providers/revision.d.ts.map +1 -1
- package/dist/git/providers/revision.js.map +1 -1
- package/dist/git/providers/shared/remotes.d.ts.map +1 -1
- package/dist/git/providers/shared/remotes.js.map +1 -1
- package/dist/git/providers/staging.d.ts.map +1 -1
- package/dist/git/providers/staging.js.map +1 -1
- package/dist/git/providers/stash.d.ts.map +1 -1
- package/dist/git/providers/stash.js.map +1 -1
- package/dist/git/providers/status.d.ts +1 -0
- package/dist/git/providers/status.d.ts.map +1 -1
- package/dist/git/providers/status.js.map +1 -1
- package/dist/git/providers/tags.d.ts.map +1 -1
- package/dist/git/providers/tags.js.map +1 -1
- package/dist/git/providers/types.d.ts.map +1 -1
- package/dist/git/providers/types.js.map +1 -1
- package/dist/git/providers/worktrees.d.ts +5 -1
- package/dist/git/providers/worktrees.d.ts.map +1 -1
- package/dist/git/providers/worktrees.js.map +1 -1
- package/dist/git/remotes/azure-devops.d.ts.map +1 -1
- package/dist/git/remotes/azure-devops.js +27 -31
- package/dist/git/remotes/azure-devops.js.map +1 -1
- package/dist/git/remotes/bitbucket-server.d.ts.map +1 -1
- package/dist/git/remotes/bitbucket-server.js +21 -23
- package/dist/git/remotes/bitbucket-server.js.map +1 -1
- package/dist/git/remotes/bitbucket.d.ts.map +1 -1
- package/dist/git/remotes/bitbucket.js +21 -23
- package/dist/git/remotes/bitbucket.js.map +1 -1
- package/dist/git/remotes/custom.d.ts.map +1 -1
- package/dist/git/remotes/custom.js.map +1 -1
- package/dist/git/remotes/gerrit.d.ts.map +1 -1
- package/dist/git/remotes/gerrit.js +11 -13
- package/dist/git/remotes/gerrit.js.map +1 -1
- package/dist/git/remotes/gitea.d.ts.map +1 -1
- package/dist/git/remotes/gitea.js +12 -14
- package/dist/git/remotes/gitea.js.map +1 -1
- package/dist/git/remotes/github.d.ts.map +1 -1
- package/dist/git/remotes/github.js +54 -56
- package/dist/git/remotes/github.js.map +1 -1
- package/dist/git/remotes/gitlab.d.ts.map +1 -1
- package/dist/git/remotes/gitlab.js +93 -95
- package/dist/git/remotes/gitlab.js.map +1 -1
- package/dist/git/remotes/google-source.d.ts.map +1 -1
- package/dist/git/remotes/google-source.js.map +1 -1
- package/dist/git/remotes/matcher.d.ts.map +1 -1
- package/dist/git/remotes/matcher.js.map +1 -1
- package/dist/git/run.types.d.ts +62 -3
- package/dist/git/run.types.d.ts.map +1 -1
- package/dist/git/service.d.ts.map +1 -1
- package/dist/git/utils/autolink.utils.d.ts.map +1 -1
- package/dist/git/utils/autolink.utils.js.map +1 -1
- package/dist/git/utils/blame.utils.d.ts.map +1 -1
- package/dist/git/utils/blame.utils.js.map +1 -1
- package/dist/git/utils/branch.utils.d.ts.map +1 -1
- package/dist/git/utils/branch.utils.js +12 -1
- package/dist/git/utils/branch.utils.js.map +1 -1
- package/dist/git/utils/commit.utils.d.ts.map +1 -1
- package/dist/git/utils/commit.utils.js.map +1 -1
- package/dist/git/utils/conflictResolution.utils.d.ts +32 -0
- package/dist/git/utils/conflictResolution.utils.d.ts.map +1 -1
- package/dist/git/utils/conflictResolution.utils.js +95 -0
- package/dist/git/utils/conflictResolution.utils.js.map +1 -1
- package/dist/git/utils/contributor.utils.d.ts +1 -1
- package/dist/git/utils/contributor.utils.d.ts.map +1 -1
- package/dist/git/utils/contributor.utils.js +1 -2
- package/dist/git/utils/contributor.utils.js.map +1 -1
- package/dist/git/utils/fetch.utils.d.ts.map +1 -1
- package/dist/git/utils/fetch.utils.js.map +1 -1
- package/dist/git/utils/fileStatus.utils.d.ts +7 -0
- package/dist/git/utils/fileStatus.utils.d.ts.map +1 -1
- package/dist/git/utils/fileStatus.utils.js +6 -0
- package/dist/git/utils/fileStatus.utils.js.map +1 -1
- package/dist/git/utils/graph.utils.d.ts +20 -0
- package/dist/git/utils/graph.utils.d.ts.map +1 -0
- package/dist/git/utils/graph.utils.js +40 -0
- package/dist/git/utils/graph.utils.js.map +1 -0
- package/dist/git/utils/issue.utils.d.ts.map +1 -1
- package/dist/git/utils/issue.utils.js +1 -0
- package/dist/git/utils/issue.utils.js.map +1 -1
- package/dist/git/utils/issueOrPullRequest.utils.d.ts.map +1 -1
- package/dist/git/utils/issueOrPullRequest.utils.js.map +1 -1
- package/dist/git/utils/mergeConflicts.utils.d.ts.map +1 -1
- package/dist/git/utils/mergeConflicts.utils.js.map +1 -1
- package/dist/git/utils/pausedOperationStatus.utils.d.ts +13 -13
- package/dist/git/utils/pausedOperationStatus.utils.d.ts.map +1 -1
- package/dist/git/utils/pausedOperationStatus.utils.js.map +1 -1
- package/dist/git/utils/pullRequest.utils.d.ts.map +1 -1
- package/dist/git/utils/pullRequest.utils.js +9 -0
- package/dist/git/utils/pullRequest.utils.js.map +1 -1
- package/dist/git/utils/reachability.utils.d.ts +20 -2
- package/dist/git/utils/reachability.utils.d.ts.map +1 -1
- package/dist/git/utils/reachability.utils.js +68 -7
- package/dist/git/utils/reachability.utils.js.map +1 -1
- package/dist/git/utils/rebase.utils.d.ts.map +1 -1
- package/dist/git/utils/rebase.utils.js.map +1 -1
- package/dist/git/utils/reference.utils.d.ts.map +1 -1
- package/dist/git/utils/reference.utils.js.map +1 -1
- package/dist/git/utils/remote.utils.d.ts.map +1 -1
- package/dist/git/utils/remote.utils.js.map +1 -1
- package/dist/git/utils/repository.utils.d.ts.map +1 -1
- package/dist/git/utils/repository.utils.js.map +1 -1
- package/dist/git/utils/resourceDescriptor.utils.d.ts.map +1 -1
- package/dist/git/utils/resourceDescriptor.utils.js.map +1 -1
- package/dist/git/utils/revision.utils.d.ts.map +1 -1
- package/dist/git/utils/revision.utils.js.map +1 -1
- package/dist/git/utils/search.utils.d.ts.map +1 -1
- package/dist/git/utils/search.utils.js.map +1 -1
- package/dist/git/utils/sorting.d.ts.map +1 -1
- package/dist/git/utils/sorting.js.map +1 -1
- package/dist/git/utils/sshKey.utils.d.ts +7 -0
- package/dist/git/utils/sshKey.utils.d.ts.map +1 -0
- package/dist/git/utils/sshKey.utils.js +25 -0
- package/dist/git/utils/sshKey.utils.js.map +1 -0
- package/dist/git/utils/status.utils.d.ts.map +1 -1
- package/dist/git/utils/status.utils.js.map +1 -1
- package/dist/git/utils/statusFile.utils.d.ts.map +1 -1
- package/dist/git/utils/statusFile.utils.js.map +1 -1
- package/dist/git/utils/tag.utils.d.ts.map +1 -1
- package/dist/git/utils/tag.utils.js.map +1 -1
- package/dist/git/utils/tooltip.utils.d.ts.map +1 -1
- package/dist/git/utils/tooltip.utils.js.map +1 -1
- package/dist/git/utils/uriAuthority.d.ts.map +1 -1
- package/dist/git/utils/uriAuthority.js.map +1 -1
- package/dist/git/utils/user.utils.d.ts.map +1 -1
- package/dist/git/utils/user.utils.js.map +1 -1
- package/dist/git/utils/worktree.utils.d.ts.map +1 -1
- package/dist/git/utils/worktree.utils.js.map +1 -1
- package/dist/git/watching/changeEvent.d.ts.map +1 -1
- package/dist/git/watching/changeEvent.js.map +1 -1
- package/dist/git/watching/classifyChange.d.ts.map +1 -1
- package/dist/git/watching/classifyChange.js.map +1 -1
- package/dist/git/watching/gitIgnoreFilter.d.ts.map +1 -1
- package/dist/git/watching/gitIgnoreFilter.js.map +1 -1
- package/dist/git/watching/initWatcher.d.ts.map +1 -1
- package/dist/git/watching/initWatcher.js.map +1 -1
- package/dist/git/watching/provider.d.ts.map +1 -1
- package/dist/git/watching/provider.js.map +1 -1
- package/dist/git/watching/watchGroup.d.ts.map +1 -1
- package/dist/git/watching/watchGroup.js.map +1 -1
- package/dist/git/watching/watchService.d.ts +4 -0
- package/dist/git/watching/watchService.d.ts.map +1 -1
- package/dist/git/watching/watchService.js +15 -1
- package/dist/git/watching/watchService.js.map +1 -1
- package/dist/git/watching/watchSession.d.ts +7 -0
- package/dist/git/watching/watchSession.d.ts.map +1 -1
- package/dist/git/watching/watchSession.js +14 -2
- package/dist/git/watching/watchSession.js.map +1 -1
- package/dist/git/watching/watcherPatterns.d.ts.map +1 -1
- package/dist/git/watching/watcherPatterns.js.map +1 -1
- package/dist/git-cli/cliGitProvider.d.ts.map +1 -1
- package/dist/git-cli/exec/exec.d.ts.map +1 -1
- package/dist/git-cli/exec/exec.errors.d.ts.map +1 -1
- package/dist/git-cli/exec/exec.errors.js.map +1 -1
- package/dist/git-cli/exec/exec.js.map +1 -1
- package/dist/git-cli/exec/exec.types.d.ts.map +1 -1
- package/dist/git-cli/exec/exec.types.js.map +1 -1
- package/dist/git-cli/exec/features.d.ts.map +1 -1
- package/dist/git-cli/exec/features.js.map +1 -1
- package/dist/git-cli/exec/git.d.ts +19 -27
- package/dist/git-cli/exec/git.d.ts.map +1 -1
- package/dist/git-cli/exec/git.js +126 -34
- package/dist/git-cli/exec/git.js.map +1 -1
- package/dist/git-cli/exec/gitQueue.d.ts.map +1 -1
- package/dist/git-cli/exec/gitQueue.js.map +1 -1
- package/dist/git-cli/exec/locator.d.ts.map +1 -1
- package/dist/git-cli/exec/locator.js.map +1 -1
- package/dist/git-cli/parsers/blameParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/blameParser.js.map +1 -1
- package/dist/git-cli/parsers/indexParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/indexParser.js.map +1 -1
- package/dist/git-cli/parsers/logParser.d.ts +9 -1
- package/dist/git-cli/parsers/logParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/logParser.js +141 -60
- package/dist/git-cli/parsers/logParser.js.map +1 -1
- package/dist/git-cli/parsers/mergeTreeParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/mergeTreeParser.js.map +1 -1
- package/dist/git-cli/parsers/refParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/refParser.js.map +1 -1
- package/dist/git-cli/parsers/reflogParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/reflogParser.js.map +1 -1
- package/dist/git-cli/parsers/remoteParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/remoteParser.js.map +1 -1
- package/dist/git-cli/parsers/shortlogParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/shortlogParser.js.map +1 -1
- package/dist/git-cli/parsers/signatureParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/signatureParser.js.map +1 -1
- package/dist/git-cli/parsers/sshSignatureParser.d.ts +21 -0
- package/dist/git-cli/parsers/sshSignatureParser.d.ts.map +1 -0
- package/dist/git-cli/parsers/sshSignatureParser.js +78 -0
- package/dist/git-cli/parsers/sshSignatureParser.js.map +1 -0
- package/dist/git-cli/parsers/statusParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/statusParser.js.map +1 -1
- package/dist/git-cli/parsers/treeParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/treeParser.js.map +1 -1
- package/dist/git-cli/parsers/worktreeParser.d.ts.map +1 -1
- package/dist/git-cli/parsers/worktreeParser.js +5 -7
- package/dist/git-cli/parsers/worktreeParser.js.map +1 -1
- package/dist/git-cli/providers/blame.d.ts.map +1 -1
- package/dist/git-cli/providers/blame.js.map +1 -1
- package/dist/git-cli/providers/branches.d.ts +1 -0
- package/dist/git-cli/providers/branches.d.ts.map +1 -1
- package/dist/git-cli/providers/branches.js +51 -32
- package/dist/git-cli/providers/branches.js.map +1 -1
- package/dist/git-cli/providers/commitFilesetUtils.d.ts.map +1 -1
- package/dist/git-cli/providers/commitFilesetUtils.js.map +1 -1
- package/dist/git-cli/providers/commits.d.ts +12 -1
- package/dist/git-cli/providers/commits.d.ts.map +1 -1
- package/dist/git-cli/providers/commits.js +89 -8
- package/dist/git-cli/providers/commits.js.map +1 -1
- package/dist/git-cli/providers/config.d.ts.map +1 -1
- package/dist/git-cli/providers/config.js.map +1 -1
- package/dist/git-cli/providers/contributors.d.ts.map +1 -1
- package/dist/git-cli/providers/contributors.js.map +1 -1
- package/dist/git-cli/providers/diff.d.ts.map +1 -1
- package/dist/git-cli/providers/diff.js.map +1 -1
- package/dist/git-cli/providers/graph.d.ts +35 -1
- package/dist/git-cli/providers/graph.d.ts.map +1 -1
- package/dist/git-cli/providers/graph.js +1434 -330
- package/dist/git-cli/providers/graph.js.map +1 -1
- package/dist/git-cli/providers/operations.d.ts +1 -0
- package/dist/git-cli/providers/operations.d.ts.map +1 -1
- package/dist/git-cli/providers/operations.js +22 -1
- package/dist/git-cli/providers/operations.js.map +1 -1
- package/dist/git-cli/providers/patch.d.ts.map +1 -1
- package/dist/git-cli/providers/patch.js.map +1 -1
- package/dist/git-cli/providers/pausedOperations.d.ts.map +1 -1
- package/dist/git-cli/providers/pausedOperations.js +3 -3
- package/dist/git-cli/providers/pausedOperations.js.map +1 -1
- package/dist/git-cli/providers/refs.d.ts.map +1 -1
- package/dist/git-cli/providers/refs.js.map +1 -1
- package/dist/git-cli/providers/remotes.d.ts.map +1 -1
- package/dist/git-cli/providers/remotes.js.map +1 -1
- package/dist/git-cli/providers/revision.d.ts +1 -0
- package/dist/git-cli/providers/revision.d.ts.map +1 -1
- package/dist/git-cli/providers/revision.js +33 -0
- package/dist/git-cli/providers/revision.js.map +1 -1
- package/dist/git-cli/providers/staging.d.ts.map +1 -1
- package/dist/git-cli/providers/staging.js.map +1 -1
- package/dist/git-cli/providers/stash.d.ts.map +1 -1
- package/dist/git-cli/providers/stash.js.map +1 -1
- package/dist/git-cli/providers/status.d.ts +28 -0
- package/dist/git-cli/providers/status.d.ts.map +1 -1
- package/dist/git-cli/providers/status.js +240 -154
- package/dist/git-cli/providers/status.js.map +1 -1
- package/dist/git-cli/providers/tags.d.ts.map +1 -1
- package/dist/git-cli/providers/tags.js +2 -1
- package/dist/git-cli/providers/tags.js.map +1 -1
- package/dist/git-cli/providers/worktrees.d.ts +4 -1
- package/dist/git-cli/providers/worktrees.d.ts.map +1 -1
- package/dist/git-cli/providers/worktrees.js +31 -3
- package/dist/git-cli/providers/worktrees.js.map +1 -1
- package/dist/git-cli/service.d.ts.map +1 -1
- package/dist/git-cli/service.js +8 -0
- package/dist/git-cli/service.js.map +1 -1
- package/dist/ipc/ipcServer.d.ts.map +1 -1
- package/dist/ipc/ipcServer.js +1 -1
- package/dist/ipc/ipcServer.js.map +1 -1
- package/dist/plus/agents/providers/claudeCodeProvider.d.ts +6 -1
- package/dist/plus/agents/providers/claudeCodeProvider.d.ts.map +1 -1
- package/dist/plus/agents/providers/claudeCodeProvider.js +19 -0
- package/dist/plus/agents/providers/claudeCodeProvider.js.map +1 -1
- package/dist/plus/agents/providers/claudeCodeTranscript.d.ts +68 -0
- package/dist/plus/agents/providers/claudeCodeTranscript.d.ts.map +1 -1
- package/dist/plus/agents/providers/claudeCodeTranscript.js +262 -8
- package/dist/plus/agents/providers/claudeCodeTranscript.js.map +1 -1
- package/dist/plus/agents/types.d.ts +36 -2
- package/dist/plus/agents/types.d.ts.map +1 -1
- package/dist/plus/ai/constants.d.ts +1 -2
- package/dist/plus/ai/constants.d.ts.map +1 -1
- package/dist/plus/ai/constants.js +1 -8
- package/dist/plus/ai/constants.js.map +1 -1
- package/dist/plus/ai/errors.d.ts.map +1 -1
- package/dist/plus/ai/errors.js.map +1 -1
- package/dist/plus/ai/models/conversation.d.ts.map +1 -1
- package/dist/plus/ai/models/conversation.js.map +1 -1
- package/dist/plus/ai/models/model.d.ts +2 -1
- package/dist/plus/ai/models/model.d.ts.map +1 -1
- package/dist/plus/ai/models/model.js +50 -1
- package/dist/plus/ai/models/model.js.map +1 -1
- package/dist/plus/ai/models/promptTemplates.d.ts +5 -2
- package/dist/plus/ai/models/promptTemplates.d.ts.map +1 -1
- package/dist/plus/ai/models/promptTemplates.js.map +1 -1
- package/dist/plus/ai/models/provider.d.ts.map +1 -1
- package/dist/plus/ai/models/provider.js.map +1 -1
- package/dist/plus/ai/models/results.d.ts.map +1 -1
- package/dist/plus/ai/models/results.js.map +1 -1
- package/dist/plus/ai/prompts.d.ts +1 -1
- package/dist/plus/ai/prompts.d.ts.map +1 -1
- package/dist/plus/ai/prompts.js +15 -47
- package/dist/plus/ai/prompts.js.map +1 -1
- package/dist/plus/ai/providers/anthropicProvider.d.ts +5 -0
- package/dist/plus/ai/providers/anthropicProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/anthropicProvider.js +40 -3
- package/dist/plus/ai/providers/anthropicProvider.js.map +1 -1
- package/dist/plus/ai/providers/azureProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/azureProvider.js.map +1 -1
- package/dist/plus/ai/providers/context.d.ts.map +1 -1
- package/dist/plus/ai/providers/context.js.map +1 -1
- package/dist/plus/ai/providers/deepSeekProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/deepSeekProvider.js +17 -1
- package/dist/plus/ai/providers/deepSeekProvider.js.map +1 -1
- package/dist/plus/ai/providers/geminiProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/geminiProvider.js +25 -6
- package/dist/plus/ai/providers/geminiProvider.js.map +1 -1
- package/dist/plus/ai/providers/gitkrakenProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/gitkrakenProvider.js +1 -0
- package/dist/plus/ai/providers/gitkrakenProvider.js.map +1 -1
- package/dist/plus/ai/providers/huggingFaceProvider.d.ts +1 -1
- package/dist/plus/ai/providers/huggingFaceProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/huggingFaceProvider.js +21 -18
- package/dist/plus/ai/providers/huggingFaceProvider.js.map +1 -1
- package/dist/plus/ai/providers/mistralProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/mistralProvider.js.map +1 -1
- package/dist/plus/ai/providers/ollamaProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/ollamaProvider.js.map +1 -1
- package/dist/plus/ai/providers/openAICompatibleProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/openAICompatibleProvider.js.map +1 -1
- package/dist/plus/ai/providers/openAICompatibleProviderBase.d.ts +10 -1
- package/dist/plus/ai/providers/openAICompatibleProviderBase.d.ts.map +1 -1
- package/dist/plus/ai/providers/openAICompatibleProviderBase.js +9 -1
- package/dist/plus/ai/providers/openAICompatibleProviderBase.js.map +1 -1
- package/dist/plus/ai/providers/openRouterProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/openRouterProvider.js.map +1 -1
- package/dist/plus/ai/providers/openaiProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/openaiProvider.js.map +1 -1
- package/dist/plus/ai/providers/xaiProvider.d.ts.map +1 -1
- package/dist/plus/ai/providers/xaiProvider.js +14 -1
- package/dist/plus/ai/providers/xaiProvider.js.map +1 -1
- package/dist/plus/ai/utils/ai.utils.d.ts.map +1 -1
- package/dist/plus/ai/utils/ai.utils.js +5 -7
- package/dist/plus/ai/utils/ai.utils.js.map +1 -1
- package/dist/plus/ai/utils/results.utils.d.ts +3 -0
- package/dist/plus/ai/utils/results.utils.d.ts.map +1 -1
- package/dist/plus/ai/utils/results.utils.js +26 -0
- package/dist/plus/ai/utils/results.utils.js.map +1 -1
- package/dist/plus/ai/utils/truncation.utils.d.ts +1 -1
- package/dist/plus/ai/utils/truncation.utils.d.ts.map +1 -1
- package/dist/plus/ai/utils/truncation.utils.js.map +1 -1
- package/dist/plus/git-github/api/config.d.ts.map +1 -1
- package/dist/plus/git-github/api/config.js.map +1 -1
- package/dist/plus/git-github/api/github.d.ts +71 -15
- package/dist/plus/git-github/api/github.d.ts.map +1 -1
- package/dist/plus/git-github/api/github.js +350 -84
- package/dist/plus/git-github/api/github.js.map +1 -1
- package/dist/plus/git-github/api/github.utils.d.ts.map +1 -1
- package/dist/plus/git-github/api/github.utils.js.map +1 -1
- package/dist/plus/git-github/api/token.d.ts.map +1 -1
- package/dist/plus/git-github/api/token.js.map +1 -1
- package/dist/plus/git-github/api/tokenUtils.d.ts.map +1 -1
- package/dist/plus/git-github/api/tokenUtils.js.map +1 -1
- package/dist/plus/git-github/api/types.d.ts.map +1 -1
- package/dist/plus/git-github/api/types.js.map +1 -1
- package/dist/plus/git-github/context.d.ts.map +1 -1
- package/dist/plus/git-github/models.d.ts +5 -0
- package/dist/plus/git-github/models.d.ts.map +1 -1
- package/dist/plus/git-github/models.js +27 -2
- package/dist/plus/git-github/models.js.map +1 -1
- package/dist/plus/git-github/providers/github/blame.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/blame.js.map +1 -1
- package/dist/plus/git-github/providers/github/branches.d.ts +2 -1
- package/dist/plus/git-github/providers/github/branches.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/branches.js +7 -3
- package/dist/plus/git-github/providers/github/branches.js.map +1 -1
- package/dist/plus/git-github/providers/github/commits.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/commits.js.map +1 -1
- package/dist/plus/git-github/providers/github/config.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/config.js.map +1 -1
- package/dist/plus/git-github/providers/github/contributors.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/contributors.js.map +1 -1
- package/dist/plus/git-github/providers/github/diff.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/diff.js +2 -2
- package/dist/plus/git-github/providers/github/diff.js.map +1 -1
- package/dist/plus/git-github/providers/github/graph.d.ts +12 -1
- package/dist/plus/git-github/providers/github/graph.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/graph.js +85 -0
- package/dist/plus/git-github/providers/github/graph.js.map +1 -1
- package/dist/plus/git-github/providers/github/refs.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/refs.js.map +1 -1
- package/dist/plus/git-github/providers/github/remotes.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/remotes.js.map +1 -1
- package/dist/plus/git-github/providers/github/revision.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/revision.js.map +1 -1
- package/dist/plus/git-github/providers/github/status.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/status.js.map +1 -1
- package/dist/plus/git-github/providers/github/tags.d.ts.map +1 -1
- package/dist/plus/git-github/providers/github/tags.js +3 -1
- package/dist/plus/git-github/providers/github/tags.js.map +1 -1
- package/dist/plus/git-github/providers/githubGitProvider.d.ts.map +1 -1
- package/dist/plus/git-github/providers/githubGitProvider.js.map +1 -1
- package/dist/plus/git-github/providers/githubProvider.d.ts.map +1 -1
- package/dist/plus/git-github/providers/githubProvider.js.map +1 -1
- package/dist/plus/integrations/authentication/cloudIntegrationService.d.ts +30 -0
- package/dist/plus/integrations/authentication/cloudIntegrationService.d.ts.map +1 -0
- package/dist/plus/integrations/authentication/cloudIntegrationService.js +214 -0
- package/dist/plus/integrations/authentication/cloudIntegrationService.js.map +1 -0
- package/dist/plus/integrations/authentication/configuredIntegrationService.d.ts +114 -0
- package/dist/plus/integrations/authentication/configuredIntegrationService.d.ts.map +1 -0
- package/dist/plus/integrations/authentication/configuredIntegrationService.js +497 -0
- package/dist/plus/integrations/authentication/configuredIntegrationService.js.map +1 -0
- package/dist/plus/integrations/authentication/integrationAuthenticationProvider.d.ts +112 -0
- package/dist/plus/integrations/authentication/integrationAuthenticationProvider.d.ts.map +1 -0
- package/dist/plus/integrations/authentication/integrationAuthenticationProvider.js +217 -0
- package/dist/plus/integrations/authentication/integrationAuthenticationProvider.js.map +1 -0
- package/dist/plus/integrations/authentication/integrationAuthenticationService.d.ts +62 -0
- package/dist/plus/integrations/authentication/integrationAuthenticationService.d.ts.map +1 -0
- package/dist/plus/integrations/authentication/integrationAuthenticationService.js +126 -0
- package/dist/plus/integrations/authentication/integrationAuthenticationService.js.map +1 -0
- package/dist/plus/integrations/authentication/manualTokenProvider.d.ts +16 -0
- package/dist/plus/integrations/authentication/manualTokenProvider.d.ts.map +1 -0
- package/dist/plus/integrations/authentication/manualTokenProvider.js +53 -0
- package/dist/plus/integrations/authentication/manualTokenProvider.js.map +1 -0
- package/dist/plus/integrations/authentication/models.d.ts +120 -0
- package/dist/plus/integrations/authentication/models.d.ts.map +1 -0
- package/dist/plus/integrations/authentication/models.js +64 -0
- package/dist/plus/integrations/authentication/models.js.map +1 -0
- package/dist/plus/integrations/collectionMetadata.d.ts +21 -0
- package/dist/plus/integrations/collectionMetadata.d.ts.map +1 -0
- package/dist/plus/integrations/collectionMetadata.js +121 -0
- package/dist/plus/integrations/collectionMetadata.js.map +1 -0
- package/dist/plus/integrations/constants.d.ts +57 -0
- package/dist/plus/integrations/constants.d.ts.map +1 -0
- package/dist/plus/integrations/constants.js +138 -0
- package/dist/plus/integrations/constants.js.map +1 -0
- package/dist/plus/integrations/context.d.ts +358 -0
- package/dist/plus/integrations/context.d.ts.map +1 -0
- package/dist/plus/integrations/context.js +2 -0
- package/dist/plus/integrations/context.js.map +1 -0
- package/dist/plus/integrations/errors.d.ts +79 -0
- package/dist/plus/integrations/errors.d.ts.map +1 -0
- package/dist/plus/integrations/errors.js +150 -0
- package/dist/plus/integrations/errors.js.map +1 -0
- package/dist/plus/integrations/index.d.ts +77 -0
- package/dist/plus/integrations/index.d.ts.map +1 -0
- package/dist/plus/integrations/index.js +64 -0
- package/dist/plus/integrations/index.js.map +1 -0
- package/dist/plus/integrations/integrationService.d.ts +379 -0
- package/dist/plus/integrations/integrationService.d.ts.map +1 -0
- package/dist/plus/integrations/integrationService.js +1895 -0
- package/dist/plus/integrations/integrationService.js.map +1 -0
- package/dist/plus/integrations/lite.d.ts +47 -0
- package/dist/plus/integrations/lite.d.ts.map +1 -0
- package/dist/plus/integrations/lite.js +141 -0
- package/dist/plus/integrations/lite.js.map +1 -0
- package/dist/plus/integrations/manager.d.ts +332 -0
- package/dist/plus/integrations/manager.d.ts.map +1 -0
- package/dist/plus/integrations/manager.js +2 -0
- package/dist/plus/integrations/manager.js.map +1 -0
- package/dist/plus/integrations/models/gitHostIntegration.d.ts +341 -0
- package/dist/plus/integrations/models/gitHostIntegration.d.ts.map +1 -0
- package/dist/plus/integrations/models/gitHostIntegration.js +1146 -0
- package/dist/plus/integrations/models/gitHostIntegration.js.map +1 -0
- package/dist/plus/integrations/models/integration.d.ts +212 -0
- package/dist/plus/integrations/models/integration.d.ts.map +1 -0
- package/dist/plus/integrations/models/integration.js +627 -0
- package/dist/plus/integrations/models/integration.js.map +1 -0
- package/dist/plus/integrations/models/issuesIntegration.d.ts +108 -0
- package/dist/plus/integrations/models/issuesIntegration.d.ts.map +1 -0
- package/dist/plus/integrations/models/issuesIntegration.js +216 -0
- package/dist/plus/integrations/models/issuesIntegration.js.map +1 -0
- package/dist/plus/integrations/providerFilters.d.ts +12 -0
- package/dist/plus/integrations/providerFilters.d.ts.map +1 -0
- package/dist/plus/integrations/providerFilters.js +14 -0
- package/dist/plus/integrations/providerFilters.js.map +1 -0
- package/dist/plus/integrations/providers/apiClients.d.ts +25 -0
- package/dist/plus/integrations/providers/apiClients.d.ts.map +1 -0
- package/dist/plus/integrations/providers/apiClients.js +39 -0
- package/dist/plus/integrations/providers/apiClients.js.map +1 -0
- package/dist/plus/integrations/providers/apiConfig.d.ts +52 -0
- package/dist/plus/integrations/providers/apiConfig.d.ts.map +1 -0
- package/dist/plus/integrations/providers/apiConfig.js +19 -0
- package/dist/plus/integrations/providers/apiConfig.js.map +1 -0
- package/dist/plus/integrations/providers/azure/azure.d.ts +59 -0
- package/dist/plus/integrations/providers/azure/azure.d.ts.map +1 -0
- package/dist/plus/integrations/providers/azure/azure.js +519 -0
- package/dist/plus/integrations/providers/azure/azure.js.map +1 -0
- package/dist/plus/integrations/providers/azure/models.d.ts +302 -0
- package/dist/plus/integrations/providers/azure/models.d.ts.map +1 -0
- package/dist/plus/integrations/providers/azure/models.js +203 -0
- package/dist/plus/integrations/providers/azure/models.js.map +1 -0
- package/dist/plus/integrations/providers/azureDevOps.d.ts +141 -0
- package/dist/plus/integrations/providers/azureDevOps.d.ts.map +1 -0
- package/dist/plus/integrations/providers/azureDevOps.js +925 -0
- package/dist/plus/integrations/providers/azureDevOps.js.map +1 -0
- package/dist/plus/integrations/providers/bitbucket/bitbucket.d.ts +53 -0
- package/dist/plus/integrations/providers/bitbucket/bitbucket.d.ts.map +1 -0
- package/dist/plus/integrations/providers/bitbucket/bitbucket.js +589 -0
- package/dist/plus/integrations/providers/bitbucket/bitbucket.js.map +1 -0
- package/dist/plus/integrations/providers/bitbucket/models.d.ts +222 -0
- package/dist/plus/integrations/providers/bitbucket/models.d.ts.map +1 -0
- package/dist/plus/integrations/providers/bitbucket/models.js +158 -0
- package/dist/plus/integrations/providers/bitbucket/models.js.map +1 -0
- package/dist/plus/integrations/providers/bitbucket-server/models.d.ts +138 -0
- package/dist/plus/integrations/providers/bitbucket-server/models.d.ts.map +1 -0
- package/dist/plus/integrations/providers/bitbucket-server/models.js +130 -0
- package/dist/plus/integrations/providers/bitbucket-server/models.js.map +1 -0
- package/dist/plus/integrations/providers/bitbucket-server.d.ts +84 -0
- package/dist/plus/integrations/providers/bitbucket-server.d.ts.map +1 -0
- package/dist/plus/integrations/providers/bitbucket-server.js +242 -0
- package/dist/plus/integrations/providers/bitbucket-server.js.map +1 -0
- package/dist/plus/integrations/providers/bitbucket.d.ts +84 -0
- package/dist/plus/integrations/providers/bitbucket.d.ts.map +1 -0
- package/dist/plus/integrations/providers/bitbucket.js +477 -0
- package/dist/plus/integrations/providers/bitbucket.js.map +1 -0
- package/dist/plus/integrations/providers/github/github.d.ts +5 -0
- package/dist/plus/integrations/providers/github/github.d.ts.map +1 -0
- package/dist/plus/integrations/providers/github/github.js +47 -0
- package/dist/plus/integrations/providers/github/github.js.map +1 -0
- package/dist/plus/integrations/providers/github/github.utils.d.ts +11 -0
- package/dist/plus/integrations/providers/github/github.utils.d.ts.map +1 -0
- package/dist/plus/integrations/providers/github/github.utils.js +6 -0
- package/dist/plus/integrations/providers/github/github.utils.js.map +1 -0
- package/dist/plus/integrations/providers/github/models.d.ts +3 -0
- package/dist/plus/integrations/providers/github/models.d.ts.map +1 -0
- package/dist/plus/integrations/providers/github/models.js +2 -0
- package/dist/plus/integrations/providers/github/models.js.map +1 -0
- package/dist/plus/integrations/providers/github.d.ts +116 -0
- package/dist/plus/integrations/providers/github.d.ts.map +1 -0
- package/dist/plus/integrations/providers/github.js +445 -0
- package/dist/plus/integrations/providers/github.js.map +1 -0
- package/dist/plus/integrations/providers/gitlab/gitlab.d.ts +71 -0
- package/dist/plus/integrations/providers/gitlab/gitlab.d.ts.map +1 -0
- package/dist/plus/integrations/providers/gitlab/gitlab.js +902 -0
- package/dist/plus/integrations/providers/gitlab/gitlab.js.map +1 -0
- package/dist/plus/integrations/providers/gitlab/gitlab.utils.d.ts +27 -0
- package/dist/plus/integrations/providers/gitlab/gitlab.utils.d.ts.map +1 -0
- package/dist/plus/integrations/providers/gitlab/gitlab.utils.js +53 -0
- package/dist/plus/integrations/providers/gitlab/gitlab.utils.js.map +1 -0
- package/dist/plus/integrations/providers/gitlab/models.d.ts +138 -0
- package/dist/plus/integrations/providers/gitlab/models.d.ts.map +1 -0
- package/dist/plus/integrations/providers/gitlab/models.js +99 -0
- package/dist/plus/integrations/providers/gitlab/models.js.map +1 -0
- package/dist/plus/integrations/providers/gitlab.d.ts +124 -0
- package/dist/plus/integrations/providers/gitlab.d.ts.map +1 -0
- package/dist/plus/integrations/providers/gitlab.js +519 -0
- package/dist/plus/integrations/providers/gitlab.js.map +1 -0
- package/dist/plus/integrations/providers/jira.d.ts +57 -0
- package/dist/plus/integrations/providers/jira.d.ts.map +1 -0
- package/dist/plus/integrations/providers/jira.js +425 -0
- package/dist/plus/integrations/providers/jira.js.map +1 -0
- package/dist/plus/integrations/providers/linear.d.ts +58 -0
- package/dist/plus/integrations/providers/linear.d.ts.map +1 -0
- package/dist/plus/integrations/providers/linear.js +304 -0
- package/dist/plus/integrations/providers/linear.js.map +1 -0
- package/dist/plus/integrations/providers/models.d.ts +712 -0
- package/dist/plus/integrations/providers/models.d.ts.map +1 -0
- package/dist/plus/integrations/providers/models.js +850 -0
- package/dist/plus/integrations/providers/models.js.map +1 -0
- package/dist/plus/integrations/providers/providersApi.d.ts +262 -0
- package/dist/plus/integrations/providers/providersApi.d.ts.map +1 -0
- package/dist/plus/integrations/providers/providersApi.js +1033 -0
- package/dist/plus/integrations/providers/providersApi.js.map +1 -0
- package/dist/plus/integrations/providers/trello.d.ts +47 -0
- package/dist/plus/integrations/providers/trello.d.ts.map +1 -0
- package/dist/plus/integrations/providers/trello.js +141 -0
- package/dist/plus/integrations/providers/trello.js.map +1 -0
- package/dist/plus/integrations/providers/utils/providerPaging.d.ts +29 -0
- package/dist/plus/integrations/providers/utils/providerPaging.d.ts.map +1 -0
- package/dist/plus/integrations/providers/utils/providerPaging.js +154 -0
- package/dist/plus/integrations/providers/utils/providerPaging.js.map +1 -0
- package/dist/plus/integrations/providers/utils.d.ts +75 -0
- package/dist/plus/integrations/providers/utils.d.ts.map +1 -0
- package/dist/plus/integrations/providers/utils.js +313 -0
- package/dist/plus/integrations/providers/utils.js.map +1 -0
- package/dist/plus/integrations/reads/context.d.ts +52 -0
- package/dist/plus/integrations/reads/context.d.ts.map +1 -0
- package/dist/plus/integrations/reads/context.js +2 -0
- package/dist/plus/integrations/reads/context.js.map +1 -0
- package/dist/plus/integrations/reads/cursors.d.ts +66 -0
- package/dist/plus/integrations/reads/cursors.d.ts.map +1 -0
- package/dist/plus/integrations/reads/cursors.js +133 -0
- package/dist/plus/integrations/reads/cursors.js.map +1 -0
- package/dist/plus/integrations/reads/drains.d.ts +60 -0
- package/dist/plus/integrations/reads/drains.d.ts.map +1 -0
- package/dist/plus/integrations/reads/drains.js +255 -0
- package/dist/plus/integrations/reads/drains.js.map +1 -0
- package/dist/plus/integrations/reads/filters.d.ts +81 -0
- package/dist/plus/integrations/reads/filters.d.ts.map +1 -0
- package/dist/plus/integrations/reads/filters.js +87 -0
- package/dist/plus/integrations/reads/filters.js.map +1 -0
- package/dist/plus/integrations/reads/hierarchy.d.ts +17 -0
- package/dist/plus/integrations/reads/hierarchy.d.ts.map +1 -0
- package/dist/plus/integrations/reads/hierarchy.js +348 -0
- package/dist/plus/integrations/reads/hierarchy.js.map +1 -0
- package/dist/plus/integrations/reads/hierarchy.utils.d.ts +53 -0
- package/dist/plus/integrations/reads/hierarchy.utils.d.ts.map +1 -0
- package/dist/plus/integrations/reads/hierarchy.utils.js +85 -0
- package/dist/plus/integrations/reads/hierarchy.utils.js.map +1 -0
- package/dist/plus/integrations/reads/issueTracker.d.ts +19 -0
- package/dist/plus/integrations/reads/issueTracker.d.ts.map +1 -0
- package/dist/plus/integrations/reads/issueTracker.js +346 -0
- package/dist/plus/integrations/reads/issueTracker.js.map +1 -0
- package/dist/plus/integrations/reads/issues.d.ts +34 -0
- package/dist/plus/integrations/reads/issues.d.ts.map +1 -0
- package/dist/plus/integrations/reads/issues.js +244 -0
- package/dist/plus/integrations/reads/issues.js.map +1 -0
- package/dist/plus/integrations/reads/paging.d.ts +136 -0
- package/dist/plus/integrations/reads/paging.d.ts.map +1 -0
- package/dist/plus/integrations/reads/paging.js +221 -0
- package/dist/plus/integrations/reads/paging.js.map +1 -0
- package/dist/plus/integrations/reads/pullRequests.d.ts +32 -0
- package/dist/plus/integrations/reads/pullRequests.d.ts.map +1 -0
- package/dist/plus/integrations/reads/pullRequests.js +151 -0
- package/dist/plus/integrations/reads/pullRequests.js.map +1 -0
- package/dist/plus/integrations/reads/warnings.d.ts +47 -0
- package/dist/plus/integrations/reads/warnings.d.ts.map +1 -0
- package/dist/plus/integrations/reads/warnings.js +81 -0
- package/dist/plus/integrations/reads/warnings.js.map +1 -0
- package/dist/plus/integrations/results.d.ts +189 -0
- package/dist/plus/integrations/results.d.ts.map +1 -0
- package/dist/plus/integrations/results.js +62 -0
- package/dist/plus/integrations/results.js.map +1 -0
- package/dist/plus/integrations/telemetry.d.ts +26 -0
- package/dist/plus/integrations/telemetry.d.ts.map +1 -0
- package/dist/plus/integrations/telemetry.js +11 -0
- package/dist/plus/integrations/telemetry.js.map +1 -0
- package/dist/plus/integrations/utils/domain.utils.d.ts +5 -0
- package/dist/plus/integrations/utils/domain.utils.d.ts.map +1 -0
- package/dist/plus/integrations/utils/domain.utils.js +27 -0
- package/dist/plus/integrations/utils/domain.utils.js.map +1 -0
- package/dist/plus/integrations/utils/integration.utils.d.ts +40 -0
- package/dist/plus/integrations/utils/integration.utils.d.ts.map +1 -0
- package/dist/plus/integrations/utils/integration.utils.js +182 -0
- package/dist/plus/integrations/utils/integration.utils.js.map +1 -0
- package/dist/utils/array.d.ts.map +1 -1
- package/dist/utils/array.js.map +1 -1
- package/dist/utils/brand.d.ts.map +1 -1
- package/dist/utils/cancellation.d.ts +13 -0
- package/dist/utils/cancellation.d.ts.map +1 -1
- package/dist/utils/cancellation.js +52 -7
- package/dist/utils/cancellation.js.map +1 -1
- package/dist/utils/charCode.d.ts.map +1 -1
- package/dist/utils/coalescedRun.d.ts +16 -0
- package/dist/utils/coalescedRun.d.ts.map +1 -0
- package/dist/utils/coalescedRun.js +43 -0
- package/dist/utils/coalescedRun.js.map +1 -0
- package/dist/utils/color.d.ts.map +1 -1
- package/dist/utils/color.js +3 -3
- package/dist/utils/color.js.map +1 -1
- package/dist/utils/date.d.ts +24 -0
- package/dist/utils/date.d.ts.map +1 -1
- package/dist/utils/date.js +62 -0
- package/dist/utils/date.js.map +1 -1
- package/dist/utils/debounce.js +1 -1
- package/dist/utils/debounce.js.map +1 -1
- package/dist/utils/decorators/debounce.d.ts.map +1 -1
- package/dist/utils/decorators/debounce.js.map +1 -1
- package/dist/utils/decorators/gate.d.ts.map +1 -1
- package/dist/utils/decorators/gate.js +2 -2
- package/dist/utils/decorators/gate.js.map +1 -1
- package/dist/utils/decorators/log.d.ts.map +1 -1
- package/dist/utils/decorators/log.js +5 -5
- package/dist/utils/decorators/log.js.map +1 -1
- package/dist/utils/decorators/memoize.d.ts.map +1 -1
- package/dist/utils/decorators/memoize.js +2 -2
- package/dist/utils/decorators/memoize.js.map +1 -1
- package/dist/utils/decorators/resolver.d.ts.map +1 -1
- package/dist/utils/decorators/resolver.js.map +1 -1
- package/dist/utils/decorators/sequentialize.d.ts.map +1 -1
- package/dist/utils/decorators/sequentialize.js +2 -2
- package/dist/utils/decorators/sequentialize.js.map +1 -1
- package/dist/utils/decorators/serializable.d.ts.map +1 -1
- package/dist/utils/decorators/serializable.js +1 -1
- package/dist/utils/decorators/serializable.js.map +1 -1
- package/dist/utils/dedupedAsyncCache.d.ts.map +1 -1
- package/dist/utils/disposable.d.ts +15 -2
- package/dist/utils/disposable.d.ts.map +1 -1
- package/dist/utils/disposable.js.map +1 -1
- package/dist/utils/env/browser/base64.d.ts.map +1 -1
- package/dist/utils/env/browser/base64.js.map +1 -1
- package/dist/utils/env/browser/crypto.d.ts.map +1 -1
- package/dist/utils/env/browser/crypto.js.map +1 -1
- package/dist/utils/env/browser/fs.d.ts.map +1 -1
- package/dist/utils/env/browser/fs.js.map +1 -1
- package/dist/utils/env/browser/hex.d.ts.map +1 -1
- package/dist/utils/env/browser/hex.js.map +1 -1
- package/dist/utils/env/browser/hrtime.d.ts.map +1 -1
- package/dist/utils/env/browser/hrtime.js.map +1 -1
- package/dist/utils/env/browser/logScope.d.ts.map +1 -1
- package/dist/utils/env/browser/logScope.js.map +1 -1
- package/dist/utils/env/browser/md5.d.ts.map +1 -1
- package/dist/utils/env/browser/md5.js.map +1 -1
- package/dist/utils/env/browser/platform.d.ts.map +1 -1
- package/dist/utils/env/browser/platform.js.map +1 -1
- package/dist/utils/env/node/base64.d.ts.map +1 -1
- package/dist/utils/env/node/base64.js.map +1 -1
- package/dist/utils/env/node/crypto.d.ts.map +1 -1
- package/dist/utils/env/node/crypto.js.map +1 -1
- package/dist/utils/env/node/exec.d.ts +9 -1
- package/dist/utils/env/node/exec.d.ts.map +1 -1
- package/dist/utils/env/node/exec.js +11 -4
- package/dist/utils/env/node/exec.js.map +1 -1
- package/dist/utils/env/node/fs.d.ts.map +1 -1
- package/dist/utils/env/node/fs.js.map +1 -1
- package/dist/utils/env/node/hex.d.ts.map +1 -1
- package/dist/utils/env/node/hex.js.map +1 -1
- package/dist/utils/env/node/hrtime.d.ts.map +1 -1
- package/dist/utils/env/node/hrtime.js.map +1 -1
- package/dist/utils/env/node/logScope.d.ts.map +1 -1
- package/dist/utils/env/node/logScope.js.map +1 -1
- package/dist/utils/env/node/platform.d.ts.map +1 -1
- package/dist/utils/env/node/platform.js.map +1 -1
- package/dist/utils/event.d.ts.map +1 -1
- package/dist/utils/event.js +18 -22
- package/dist/utils/event.js.map +1 -1
- package/dist/utils/formatter.d.ts.map +1 -1
- package/dist/utils/formatter.js.map +1 -1
- package/dist/utils/function.d.ts.map +1 -1
- package/dist/utils/function.js +3 -3
- package/dist/utils/function.js.map +1 -1
- package/dist/utils/hash.js.map +1 -1
- package/dist/utils/iterable.d.ts.map +1 -1
- package/dist/utils/iterable.js +2 -6
- package/dist/utils/iterable.js.map +1 -1
- package/dist/utils/lazy.d.ts.map +1 -1
- package/dist/utils/lazy.js.map +1 -1
- package/dist/utils/logger.d.ts.map +1 -1
- package/dist/utils/logger.js +1 -1
- package/dist/utils/logger.js.map +1 -1
- package/dist/utils/logger.scoped.js +1 -1
- package/dist/utils/logger.scoped.js.map +1 -1
- package/dist/utils/lruMap.d.ts.map +1 -1
- package/dist/utils/lruMap.js.map +1 -1
- package/dist/utils/mru.d.ts.map +1 -1
- package/dist/utils/mru.js.map +1 -1
- package/dist/utils/object.js.map +1 -1
- package/dist/utils/paging.d.ts +29 -0
- package/dist/utils/paging.d.ts.map +1 -1
- package/dist/utils/paging.js +18 -0
- package/dist/utils/paging.js.map +1 -1
- package/dist/utils/path.js.map +1 -1
- package/dist/utils/promise.d.ts +10 -0
- package/dist/utils/promise.d.ts.map +1 -1
- package/dist/utils/promise.js +26 -3
- package/dist/utils/promise.js.map +1 -1
- package/dist/utils/promiseCache.d.ts +12 -2
- package/dist/utils/promiseCache.d.ts.map +1 -1
- package/dist/utils/promiseCache.js +80 -50
- package/dist/utils/promiseCache.js.map +1 -1
- package/dist/utils/searchTree.d.ts.map +1 -1
- package/dist/utils/searchTree.js +4 -1
- package/dist/utils/searchTree.js.map +1 -1
- package/dist/utils/stopwatch.d.ts.map +1 -1
- package/dist/utils/string.js +1 -1
- package/dist/utils/string.js.map +1 -1
- package/dist/utils/subscriptionManager.d.ts.map +1 -1
- package/dist/utils/subscriptionManager.js.map +1 -1
- package/dist/utils/trie.d.ts.map +1 -1
- package/dist/utils/trie.js +1 -0
- package/dist/utils/trie.js.map +1 -1
- package/docs/integrations.md +372 -0
- package/docs/kepler-read-api-parity.md +112 -0
- package/package.json +238 -172
- package/src/git/cache.ts +75 -8
- package/src/git/context.ts +4 -3
- package/src/git/errors.ts +36 -1
- package/src/git/models/commit.ts +1 -1
- package/src/git/models/graph.ts +147 -0
- package/src/git/models/graphSession.ts +205 -0
- package/src/git/models/issue.ts +12 -1
- package/src/git/models/pullRequest.ts +27 -1
- package/src/git/models/repository.ts +24 -1
- package/src/git/models/resourceDescriptor.ts +17 -0
- package/src/git/models/signature.ts +16 -0
- package/src/git/models/tag.ts +6 -1
- package/src/git/parsers/diffParser.ts +1 -1
- package/src/git/providers/branches.ts +6 -1
- package/src/git/providers/commits.ts +6 -1
- package/src/git/providers/config.ts +5 -1
- package/src/git/providers/graph.ts +69 -2
- package/src/git/providers/operations.ts +1 -1
- package/src/git/providers/status.ts +1 -1
- package/src/git/providers/worktrees.ts +17 -3
- package/src/git/remotes/azure-devops.ts +29 -33
- package/src/git/remotes/bitbucket-server.ts +23 -25
- package/src/git/remotes/bitbucket.ts +23 -25
- package/src/git/remotes/gerrit.ts +12 -14
- package/src/git/remotes/gitea.ts +13 -15
- package/src/git/remotes/github.ts +56 -58
- package/src/git/remotes/gitlab.ts +102 -104
- package/src/git/run.types.ts +54 -4
- package/src/git/utils/branch.utils.ts +12 -1
- package/src/git/utils/conflictResolution.utils.ts +126 -0
- package/src/git/utils/contributor.utils.ts +1 -1
- package/src/git/utils/fileStatus.utils.ts +7 -0
- package/src/git/utils/graph.utils.ts +46 -0
- package/src/git/utils/issue.utils.ts +1 -0
- package/src/git/utils/pullRequest.utils.ts +9 -0
- package/src/git/utils/reachability.utils.ts +79 -8
- package/src/git/utils/sshKey.utils.ts +30 -0
- package/src/git/watching/watchService.ts +16 -1
- package/src/git/watching/watchSession.ts +20 -2
- package/src/git-cli/exec/git.ts +144 -42
- package/src/git-cli/parsers/logParser.ts +83 -1
- package/src/git-cli/parsers/sshSignatureParser.ts +85 -0
- package/src/git-cli/parsers/worktreeParser.ts +5 -7
- package/src/git-cli/providers/branches.ts +60 -38
- package/src/git-cli/providers/commits.ts +102 -9
- package/src/git-cli/providers/graph.ts +1771 -393
- package/src/git-cli/providers/operations.ts +22 -2
- package/src/git-cli/providers/pausedOperations.ts +3 -3
- package/src/git-cli/providers/revision.ts +42 -0
- package/src/git-cli/providers/status.ts +333 -178
- package/src/git-cli/providers/tags.ts +2 -0
- package/src/git-cli/providers/worktrees.ts +57 -6
- package/src/git-cli/service.ts +9 -0
- package/src/ipc/ipcServer.ts +1 -1
- package/src/plus/agents/providers/claudeCodeProvider.ts +25 -0
- package/src/plus/agents/providers/claudeCodeTranscript.ts +320 -8
- package/src/plus/agents/types.ts +34 -0
- package/src/plus/ai/constants.ts +1 -9
- package/src/plus/ai/models/model.ts +53 -2
- package/src/plus/ai/models/promptTemplates.ts +9 -2
- package/src/plus/ai/prompts.ts +16 -48
- package/src/plus/ai/providers/anthropicProvider.ts +45 -3
- package/src/plus/ai/providers/deepSeekProvider.ts +17 -1
- package/src/plus/ai/providers/geminiProvider.ts +25 -6
- package/src/plus/ai/providers/gitkrakenProvider.ts +2 -0
- package/src/plus/ai/providers/huggingFaceProvider.ts +28 -21
- package/src/plus/ai/providers/openAICompatibleProviderBase.ts +16 -1
- package/src/plus/ai/providers/xaiProvider.ts +14 -1
- package/src/plus/ai/utils/ai.utils.ts +5 -7
- package/src/plus/ai/utils/results.utils.ts +32 -0
- package/src/plus/ai/utils/truncation.utils.ts +0 -1
- package/src/plus/git-github/api/github.ts +497 -129
- package/src/plus/git-github/models.ts +33 -0
- package/src/plus/git-github/providers/github/branches.ts +6 -3
- package/src/plus/git-github/providers/github/diff.ts +1 -1
- package/src/plus/git-github/providers/github/graph.ts +131 -0
- package/src/plus/git-github/providers/github/tags.ts +2 -0
- package/src/plus/integrations/authentication/cloudIntegrationService.ts +292 -0
- package/src/plus/integrations/authentication/configuredIntegrationService.ts +651 -0
- package/src/plus/integrations/authentication/integrationAuthenticationProvider.ts +363 -0
- package/src/plus/integrations/authentication/integrationAuthenticationService.ts +148 -0
- package/src/plus/integrations/authentication/manualTokenProvider.ts +79 -0
- package/src/plus/integrations/authentication/models.ts +202 -0
- package/src/plus/integrations/collectionMetadata.ts +143 -0
- package/src/plus/integrations/constants.ts +190 -0
- package/src/plus/integrations/context.ts +382 -0
- package/src/plus/integrations/errors.ts +184 -0
- package/src/plus/integrations/index.ts +216 -0
- package/src/plus/integrations/integrationService.ts +2589 -0
- package/src/plus/integrations/lite.ts +233 -0
- package/src/plus/integrations/manager.ts +359 -0
- package/src/plus/integrations/models/gitHostIntegration.ts +1631 -0
- package/src/plus/integrations/models/integration.ts +926 -0
- package/src/plus/integrations/models/issuesIntegration.ts +264 -0
- package/src/plus/integrations/providerFilters.ts +12 -0
- package/src/plus/integrations/providers/apiClients.ts +69 -0
- package/src/plus/integrations/providers/apiConfig.ts +71 -0
- package/src/plus/integrations/providers/azure/azure.ts +822 -0
- package/src/plus/integrations/providers/azure/models.ts +618 -0
- package/src/plus/integrations/providers/azureDevOps.ts +1342 -0
- package/src/plus/integrations/providers/bitbucket/bitbucket.ts +904 -0
- package/src/plus/integrations/providers/bitbucket/models.ts +445 -0
- package/src/plus/integrations/providers/bitbucket-server/models.ts +283 -0
- package/src/plus/integrations/providers/bitbucket-server.ts +447 -0
- package/src/plus/integrations/providers/bitbucket.ts +794 -0
- package/src/plus/integrations/providers/github/github.ts +64 -0
- package/src/plus/integrations/providers/github/github.utils.ts +23 -0
- package/src/plus/integrations/providers/github/models.ts +29 -0
- package/src/plus/integrations/providers/github.ts +750 -0
- package/src/plus/integrations/providers/gitlab/gitlab.ts +1320 -0
- package/src/plus/integrations/providers/gitlab/gitlab.utils.ts +80 -0
- package/src/plus/integrations/providers/gitlab/models.ts +271 -0
- package/src/plus/integrations/providers/gitlab.ts +832 -0
- package/src/plus/integrations/providers/jira.ts +564 -0
- package/src/plus/integrations/providers/linear.ts +402 -0
- package/src/plus/integrations/providers/models.ts +1622 -0
- package/src/plus/integrations/providers/providersApi.ts +1889 -0
- package/src/plus/integrations/providers/trello.ts +205 -0
- package/src/plus/integrations/providers/utils/providerPaging.ts +177 -0
- package/src/plus/integrations/providers/utils.ts +419 -0
- package/src/plus/integrations/reads/context.ts +75 -0
- package/src/plus/integrations/reads/cursors.ts +224 -0
- package/src/plus/integrations/reads/drains.ts +343 -0
- package/src/plus/integrations/reads/filters.ts +124 -0
- package/src/plus/integrations/reads/hierarchy.ts +493 -0
- package/src/plus/integrations/reads/hierarchy.utils.ts +106 -0
- package/src/plus/integrations/reads/issueTracker.ts +480 -0
- package/src/plus/integrations/reads/issues.ts +407 -0
- package/src/plus/integrations/reads/paging.ts +277 -0
- package/src/plus/integrations/reads/pullRequests.ts +267 -0
- package/src/plus/integrations/reads/warnings.ts +170 -0
- package/src/plus/integrations/results.ts +275 -0
- package/src/plus/integrations/telemetry.ts +29 -0
- package/src/plus/integrations/utils/domain.utils.ts +26 -0
- package/src/plus/integrations/utils/integration.utils.ts +215 -0
- package/src/utils/brand.ts +0 -2
- package/src/utils/cancellation.ts +56 -7
- package/src/utils/coalescedRun.ts +45 -0
- package/src/utils/color.ts +3 -3
- package/src/utils/date.ts +72 -0
- package/src/utils/debounce.ts +1 -1
- package/src/utils/decorators/gate.ts +2 -2
- package/src/utils/decorators/log.ts +5 -5
- package/src/utils/decorators/memoize.ts +2 -2
- package/src/utils/decorators/sequentialize.ts +2 -2
- package/src/utils/decorators/serializable.ts +1 -1
- package/src/utils/disposable.ts +15 -2
- package/src/utils/env/node/exec.ts +20 -5
- package/src/utils/event.ts +19 -25
- package/src/utils/function.ts +3 -3
- package/src/utils/iterable.ts +2 -6
- package/src/utils/logger.scoped.ts +1 -1
- package/src/utils/logger.ts +1 -1
- package/src/utils/paging.ts +46 -0
- package/src/utils/promise.ts +33 -3
- package/src/utils/promiseCache.ts +81 -51
- package/src/utils/searchTree.ts +4 -2
- package/src/utils/string.ts +1 -1
- package/src/utils/trie.ts +1 -0
- package/dist/plus/ai/providers/githubModelsProvider.d.ts +0 -19
- package/dist/plus/ai/providers/githubModelsProvider.d.ts.map +0 -1
- package/dist/plus/ai/providers/githubModelsProvider.js +0 -51
- package/dist/plus/ai/providers/githubModelsProvider.js.map +0 -1
- package/src/plus/ai/providers/githubModelsProvider.ts +0 -92
|
@@ -0,0 +1,926 @@
|
|
|
1
|
+
import type { CollectionMetadata } from '@gitkraken/provider-apis';
|
|
2
|
+
import type { Account } from '../../../git/models/author.js';
|
|
3
|
+
import type { AutolinkReference, DynamicAutolinkReference } from '../../../git/models/autolink.js';
|
|
4
|
+
import type { Issue, IssueShape } from '../../../git/models/issue.js';
|
|
5
|
+
import type { IssueOrPullRequest, IssueOrPullRequestType } from '../../../git/models/issueOrPullRequest.js';
|
|
6
|
+
import type { PullRequest } from '../../../git/models/pullRequest.js';
|
|
7
|
+
import type { ResourceDescriptor } from '../../../git/models/resourceDescriptor.js';
|
|
8
|
+
import { isCancellationError } from '../../../utils/cancellation.js';
|
|
9
|
+
import { gate } from '../../../utils/decorators/gate.js';
|
|
10
|
+
import { debug, trace } from '../../../utils/decorators/log.js';
|
|
11
|
+
import type { Disposable } from '../../../utils/disposable.js';
|
|
12
|
+
import type { Event } from '../../../utils/event.js';
|
|
13
|
+
import { Emitter } from '../../../utils/event.js';
|
|
14
|
+
import { fnv1aHash64 } from '../../../utils/hash.js';
|
|
15
|
+
import type { ScopedLogger } from '../../../utils/logger.scoped.js';
|
|
16
|
+
import { getScopedLogger } from '../../../utils/logger.scoped.js';
|
|
17
|
+
import type {
|
|
18
|
+
IntegrationAuthenticationProviderDescriptor,
|
|
19
|
+
IntegrationAuthenticationSessionDescriptor,
|
|
20
|
+
} from '../authentication/integrationAuthenticationProvider.js';
|
|
21
|
+
import type { IntegrationAuthenticationService } from '../authentication/integrationAuthenticationService.js';
|
|
22
|
+
import type { ProviderAuthenticationSession } from '../authentication/models.js';
|
|
23
|
+
import type { IntegrationIds, IssuesCloudHostIntegrationId } from '../constants.js';
|
|
24
|
+
import { GitCloudHostIntegrationId } from '../constants.js';
|
|
25
|
+
import type { IntegrationServiceContext } from '../context.js';
|
|
26
|
+
import { AuthenticationError, RequestClientError, toError } from '../errors.js';
|
|
27
|
+
import type { IntegrationConnectionChangeEvent } from '../integrationService.js';
|
|
28
|
+
import type { IssueFilter } from '../providerFilters.js';
|
|
29
|
+
import type { ProvidersApi } from '../providers/providersApi.js';
|
|
30
|
+
import type { Sources } from '../telemetry.js';
|
|
31
|
+
import { areDomainsOnSameHost } from '../utils/domain.utils.js';
|
|
32
|
+
import { isGitSelfManagedHostIntegrationId } from '../utils/integration.utils.js';
|
|
33
|
+
import type { GitHostIntegration } from './gitHostIntegration.js';
|
|
34
|
+
import type { IssuesIntegration } from './issuesIntegration.js';
|
|
35
|
+
|
|
36
|
+
export type Integration = GitHostIntegration | IssuesIntegration;
|
|
37
|
+
export type IntegrationById<T extends IntegrationIds> = T extends IssuesCloudHostIntegrationId
|
|
38
|
+
? IssuesIntegration
|
|
39
|
+
: GitHostIntegration;
|
|
40
|
+
export type IntegrationType = 'git' | 'issues';
|
|
41
|
+
|
|
42
|
+
export type IntegrationKey<T extends IntegrationIds = IntegrationIds> = T extends
|
|
43
|
+
| GitCloudHostIntegrationId
|
|
44
|
+
| IssuesCloudHostIntegrationId
|
|
45
|
+
? `${T}`
|
|
46
|
+
: `${T}:${string}`;
|
|
47
|
+
|
|
48
|
+
export type IntegrationConnectedKey<T extends IntegrationIds = IntegrationIds> = `connected:${IntegrationKey<T>}`;
|
|
49
|
+
|
|
50
|
+
export type IntegrationResult<T> =
|
|
51
|
+
| { value: T; duration?: number; error?: Error }
|
|
52
|
+
| { error: Error; duration?: number; value?: never }
|
|
53
|
+
| undefined;
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Account-wide issue read result. `truncated` is a provider-native incompleteness signal (GitHub's search
|
|
57
|
+
* ceiling, an Azure per-project backstop); cursor-capable providers also expose `cursor`/`hasMore`/`page`.
|
|
58
|
+
* `metadata` optionally carries structured per-scope failures from a fan-out (Azure across projects).
|
|
59
|
+
*/
|
|
60
|
+
export type AccountWideIssuesResult = {
|
|
61
|
+
values: IssueShape[];
|
|
62
|
+
truncated: boolean;
|
|
63
|
+
metadata?: CollectionMetadata;
|
|
64
|
+
cursor?: string;
|
|
65
|
+
hasMore?: boolean;
|
|
66
|
+
page?: number;
|
|
67
|
+
};
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* Options for the account-wide issue read. `includeAllAssignees` drops the "assigned to me" scoping so the
|
|
71
|
+
* read broadens to issues assigned to anyone (the account-wide equivalent of the repo-scoped
|
|
72
|
+
* {@link GitHostIntegration.getMyIssuesForReposResult}'s toggle). Authored/mentioned categories, where a
|
|
73
|
+
* provider has them, stay user-relative — they're meaningless without a user.
|
|
74
|
+
*/
|
|
75
|
+
export type SearchMyIssuesOptions = {
|
|
76
|
+
includeAllAssignees?: boolean;
|
|
77
|
+
/**
|
|
78
|
+
* Narrows the account-wide read to the requested relationship(s) instead of the provider's own definition of
|
|
79
|
+
* "my issues" (GitHub/GHE: authored ∪ assigned ∪ mentioned; Azure: assigned ∪ authored; GitLab:
|
|
80
|
+
* assigned-to-me). Narrowing has to happen HERE, not on the returned page: the excluded items still counted
|
|
81
|
+
* toward the provider's page/cursor, so a client-side filter desynchronizes `items` from `hasMore`.
|
|
82
|
+
*
|
|
83
|
+
* Only filters the provider can express server-side are accepted; the facade validates the set against
|
|
84
|
+
* `ProviderMetadata.supportedAccountWideIssueFilters` (all-or-nothing) and refuses the read rather than
|
|
85
|
+
* serving the unnarrowed union as if it had been filtered. Omitted keeps the provider's definition.
|
|
86
|
+
*/
|
|
87
|
+
filters?: IssueFilter[];
|
|
88
|
+
cursor?: string;
|
|
89
|
+
/**
|
|
90
|
+
* Narrows the account-wide read to one org/account (Azure: the organization) and/or one project within it.
|
|
91
|
+
* Only honored by a host with a project layer (Azure), whose account-wide read otherwise fans out over every
|
|
92
|
+
* project of every org; the caller checks `supportsProjectDiscovery` before asking, so a host without a
|
|
93
|
+
* project layer never silently returns an unscoped list as if it had been narrowed.
|
|
94
|
+
*/
|
|
95
|
+
org?: string;
|
|
96
|
+
project?: string;
|
|
97
|
+
};
|
|
98
|
+
|
|
99
|
+
type SyncReqUsecase = Exclude<
|
|
100
|
+
| 'getAccountForCommit'
|
|
101
|
+
| 'getAccountForEmail'
|
|
102
|
+
| 'getAccountForResource'
|
|
103
|
+
| 'getCurrentAccount'
|
|
104
|
+
| 'getDefaultBranch'
|
|
105
|
+
| 'getIssue'
|
|
106
|
+
| 'getIssueOrPullRequest'
|
|
107
|
+
| 'getIssuesForProject'
|
|
108
|
+
| 'getIssuesForRepos'
|
|
109
|
+
| 'getMyPullRequestsForUser'
|
|
110
|
+
| 'getOrganizationsForUser'
|
|
111
|
+
| 'getProjectsForOrg'
|
|
112
|
+
| 'getProjectsForResources'
|
|
113
|
+
| 'getPullRequest'
|
|
114
|
+
| 'getRepositoriesForOrg'
|
|
115
|
+
| 'getRepositoriesForUser'
|
|
116
|
+
| 'getPullRequestForBranch'
|
|
117
|
+
| 'getPullRequestForCommit'
|
|
118
|
+
| 'getPullRequestsForRepos'
|
|
119
|
+
| 'getRepositoryMetadata'
|
|
120
|
+
| 'getResourcesForUser'
|
|
121
|
+
| 'getSshSigningKeysForEmails'
|
|
122
|
+
| 'mergePullRequest'
|
|
123
|
+
| 'searchMyIssues'
|
|
124
|
+
| 'searchMyPullRequests'
|
|
125
|
+
| 'searchPullRequests',
|
|
126
|
+
// excluding to show explicitly that we don't want to add 'all' key occasionally
|
|
127
|
+
'all'
|
|
128
|
+
>;
|
|
129
|
+
|
|
130
|
+
export abstract class IntegrationBase<
|
|
131
|
+
ID extends IntegrationIds = IntegrationIds,
|
|
132
|
+
T extends ResourceDescriptor = ResourceDescriptor,
|
|
133
|
+
> implements Disposable {
|
|
134
|
+
abstract readonly type: IntegrationType;
|
|
135
|
+
|
|
136
|
+
private readonly _onDidChange = new Emitter<void>();
|
|
137
|
+
get onDidChange(): Event<void> {
|
|
138
|
+
return this._onDidChange.event;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
constructor(
|
|
142
|
+
protected readonly ctx: IntegrationServiceContext,
|
|
143
|
+
protected readonly authenticationService: IntegrationAuthenticationService,
|
|
144
|
+
protected readonly getProvidersApi: () => Promise<ProvidersApi>,
|
|
145
|
+
private readonly didChangeConnection: Emitter<IntegrationConnectionChangeEvent>,
|
|
146
|
+
) {}
|
|
147
|
+
|
|
148
|
+
dispose(): void {
|
|
149
|
+
this._onDidChange.dispose();
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
abstract get authProvider(): IntegrationAuthenticationProviderDescriptor;
|
|
153
|
+
abstract get id(): ID;
|
|
154
|
+
protected abstract get key(): IntegrationKey<ID>;
|
|
155
|
+
abstract get name(): string;
|
|
156
|
+
abstract get domain(): string;
|
|
157
|
+
|
|
158
|
+
get authProviderDescriptor(): IntegrationAuthenticationSessionDescriptor {
|
|
159
|
+
return { domain: this.domain, scopes: this.authProvider.scopes };
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
get icon(): string {
|
|
163
|
+
return this.id;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
access(): Promise<boolean> {
|
|
167
|
+
return this.ctx.account.isTrialOrPaid();
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
autolinks():
|
|
171
|
+
| (AutolinkReference | DynamicAutolinkReference)[]
|
|
172
|
+
| Promise<(AutolinkReference | DynamicAutolinkReference)[]> {
|
|
173
|
+
return [];
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
private get connectedKey(): IntegrationConnectedKey<ID> {
|
|
177
|
+
return `connected:${this.key}`;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
get maybeConnected(): boolean | undefined {
|
|
181
|
+
return this._session === undefined ? undefined : this._session !== null;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
/** Hash of the current session's access token. Changes on any token change (account switch or refresh). */
|
|
185
|
+
private _sessionFingerprint: { session: ProviderAuthenticationSession; hash: string } | undefined;
|
|
186
|
+
get sessionFingerprint(): string | undefined {
|
|
187
|
+
if (this._session == null) return undefined;
|
|
188
|
+
|
|
189
|
+
if (this._sessionFingerprint?.session !== this._session) {
|
|
190
|
+
this._sessionFingerprint = { session: this._session, hash: this.getSessionFingerprint(this._session) };
|
|
191
|
+
}
|
|
192
|
+
return this._sessionFingerprint.hash;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
protected getSessionFingerprint(session: ProviderAuthenticationSession): string {
|
|
196
|
+
return fnv1aHash64(session.accessToken);
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
get connectionExpired(): boolean | undefined {
|
|
200
|
+
if (this._session?.expiresAt == null) return undefined;
|
|
201
|
+
return new Date(this._session.expiresAt) < new Date();
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
protected _session: ProviderAuthenticationSession | null | undefined;
|
|
205
|
+
getSession(
|
|
206
|
+
source: Sources,
|
|
207
|
+
): ProviderAuthenticationSession | Promise<ProviderAuthenticationSession | undefined> | undefined {
|
|
208
|
+
if (this._session === undefined) {
|
|
209
|
+
return this.ensureSession({ createIfNeeded: false, source: source });
|
|
210
|
+
}
|
|
211
|
+
return this._session != null && this.isSessionForIntegrationHost(this._session) ? this._session : undefined;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
private isSessionForIntegrationHost(session: ProviderAuthenticationSession): boolean {
|
|
215
|
+
if (!isGitSelfManagedHostIntegrationId(this.id)) return true;
|
|
216
|
+
|
|
217
|
+
return areDomainsOnSameHost(this.domain, session.domain);
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
/**
|
|
221
|
+
* Resolves the session to read as, for a per-connection (multi-account) read. When `connectionId` is
|
|
222
|
+
* omitted this is the integration's primary session, resolved exactly like the existing read flow
|
|
223
|
+
* (ensure-connected + refresh-if-expired). When set, it resolves THAT connection's session directly
|
|
224
|
+
* from the auth provider — refreshing it if expired — WITHOUT disturbing the cached primary
|
|
225
|
+
* `_session`. Returns undefined when the requested session can't be resolved (e.g. the connection is
|
|
226
|
+
* gone or the provider isn't connected), so callers degrade to "no results".
|
|
227
|
+
*/
|
|
228
|
+
protected async resolveReadSession(
|
|
229
|
+
connectionId: string | undefined,
|
|
230
|
+
scope: ScopedLogger | undefined,
|
|
231
|
+
source?: Sources,
|
|
232
|
+
): Promise<ProviderAuthenticationSession | undefined> {
|
|
233
|
+
if (
|
|
234
|
+
this.ctx.config.isIntegrationsEnabled?.() === false ||
|
|
235
|
+
this.ctx.storage.getWorkspace(this.connectedKey) === false
|
|
236
|
+
) {
|
|
237
|
+
return undefined;
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
// A truthy connectionId targets a specific account; an empty string is not a real target, so it falls
|
|
241
|
+
// through to the primary path below.
|
|
242
|
+
if (connectionId) {
|
|
243
|
+
// Degrade to "no results" on failure, matching the primary path (whose ensureSession/
|
|
244
|
+
// refreshSessionIfExpired swallow errors) so read methods keep their never-throws contract.
|
|
245
|
+
try {
|
|
246
|
+
const authProvider = await this.authenticationService.get(this.authProvider.id);
|
|
247
|
+
const session = await authProvider.getSession(
|
|
248
|
+
{ ...this.authProviderDescriptor, connectionId: connectionId, cloud: true },
|
|
249
|
+
{ source: source },
|
|
250
|
+
);
|
|
251
|
+
return session != null && this.isSessionForIntegrationHost(session) ? session : undefined;
|
|
252
|
+
} catch (ex) {
|
|
253
|
+
scope?.error(ex);
|
|
254
|
+
return undefined;
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
const connected = this.maybeConnected ?? (await this.isConnected());
|
|
259
|
+
if (!connected) return undefined;
|
|
260
|
+
|
|
261
|
+
await this.refreshSessionIfExpired(scope);
|
|
262
|
+
return this._session != null && this.isSessionForIntegrationHost(this._session) ? this._session : undefined;
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
@debug()
|
|
266
|
+
async connect(source: Sources): Promise<boolean> {
|
|
267
|
+
try {
|
|
268
|
+
return Boolean(await this.ensureSession({ createIfNeeded: true, source: source }));
|
|
269
|
+
} catch (_ex) {
|
|
270
|
+
return false;
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
protected providerOnConnect?(): void | Promise<void>;
|
|
275
|
+
|
|
276
|
+
@gate()
|
|
277
|
+
@debug()
|
|
278
|
+
async disconnect(options?: { silent?: boolean; currentSessionOnly?: boolean }): Promise<void> {
|
|
279
|
+
if (options?.currentSessionOnly && this._session === null) return;
|
|
280
|
+
|
|
281
|
+
const connected = this._session != null;
|
|
282
|
+
|
|
283
|
+
let signOut = !options?.currentSessionOnly;
|
|
284
|
+
|
|
285
|
+
if (connected && !options?.currentSessionOnly && !options?.silent) {
|
|
286
|
+
const decision = await this.ctx.hooks?.onConfirmDisconnect?.({
|
|
287
|
+
integrationName: this.name,
|
|
288
|
+
offerSignOut: this.authenticationService.supports(this.authProvider.id),
|
|
289
|
+
});
|
|
290
|
+
if (decision == null) return;
|
|
291
|
+
|
|
292
|
+
signOut = decision.signOut;
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
if (signOut) {
|
|
296
|
+
// Disconnecting a provider signs out of ALL its connected accounts (multi-account), not just the
|
|
297
|
+
// primary — otherwise secondary connections' secrets/config would be orphaned. Removing a single
|
|
298
|
+
// account is done via IntegrationService.deleteConnection instead. Pass this instance's descriptor
|
|
299
|
+
// so self-managed disconnects stay scoped to this host: those group every host under one provider
|
|
300
|
+
// id, so an unscoped clear would sign the user out of unrelated hosts. deleteAllSessions derives an
|
|
301
|
+
// undefined domain for cloud providers, so they still clear every account as intended.
|
|
302
|
+
const authProvider = await this.authenticationService.get(this.authProvider.id);
|
|
303
|
+
void authProvider.deleteAllSessions(this.authProviderDescriptor);
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
this.resetRequestExceptionCount('all');
|
|
307
|
+
this._session = null;
|
|
308
|
+
|
|
309
|
+
if (connected) {
|
|
310
|
+
// Don't store the disconnected flag if silently disconnecting or disconnecting this only for
|
|
311
|
+
// this current VS Code session (will be re-connected on next restart)
|
|
312
|
+
if (!options?.currentSessionOnly && !options?.silent) {
|
|
313
|
+
void this.ctx.storage.storeWorkspace(this.connectedKey, false).catch();
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
this._onDidChange.fire();
|
|
317
|
+
if (!options?.currentSessionOnly) {
|
|
318
|
+
this.didChangeConnection?.fire({ integration: this, key: this.key, reason: 'disconnected' });
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
await this.providerOnDisconnect?.();
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
protected providerOnDisconnect?(): void | Promise<void>;
|
|
326
|
+
|
|
327
|
+
@debug()
|
|
328
|
+
async reauthenticate(): Promise<void> {
|
|
329
|
+
if (this._session === undefined) return;
|
|
330
|
+
|
|
331
|
+
this._session = undefined;
|
|
332
|
+
void (await this.ensureSession({ createIfNeeded: true, forceNewSession: true }));
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
refresh(): void {
|
|
336
|
+
void this.ensureSession({ createIfNeeded: false });
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
private _syncRequestsPerFailedUsecase = new Set<SyncReqUsecase>();
|
|
340
|
+
hasSessionSyncRequests(): boolean {
|
|
341
|
+
return this._syncRequestsPerFailedUsecase.size > 0;
|
|
342
|
+
}
|
|
343
|
+
requestSessionSyncForUsecase(syncReqUsecase: SyncReqUsecase): void {
|
|
344
|
+
this._syncRequestsPerFailedUsecase.add(syncReqUsecase);
|
|
345
|
+
}
|
|
346
|
+
private static readonly requestExceptionLimit = 5;
|
|
347
|
+
private requestExceptionCount = 0;
|
|
348
|
+
|
|
349
|
+
resetRequestExceptionCount(syncReqUsecase: SyncReqUsecase | 'all'): void {
|
|
350
|
+
this.requestExceptionCount = 0;
|
|
351
|
+
if (syncReqUsecase === 'all') {
|
|
352
|
+
this._syncRequestsPerFailedUsecase.clear();
|
|
353
|
+
} else {
|
|
354
|
+
this._syncRequestsPerFailedUsecase.delete(syncReqUsecase);
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
/**
|
|
359
|
+
* Resets request exceptions without resetting the amount of syncs
|
|
360
|
+
*/
|
|
361
|
+
smoothifyRequestExceptionCount(): void {
|
|
362
|
+
// On resync we reset exception count only to avoid infinitive syncs on failure
|
|
363
|
+
this.requestExceptionCount = 0;
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
async reset(): Promise<void> {
|
|
367
|
+
await this.disconnect({ silent: true });
|
|
368
|
+
await this.ctx.storage.deleteWorkspace(this.connectedKey);
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
/**
|
|
372
|
+
* Drops the in-memory session so the next access re-resolves it from storage. Used when the primary
|
|
373
|
+
* connection changed underneath a warm integration (e.g. after `setPrimaryConnection`/
|
|
374
|
+
* `deleteConnection`). Unlike {@link reset}/{@link disconnect}, it deletes nothing from storage.
|
|
375
|
+
*/
|
|
376
|
+
switchConnection(): void {
|
|
377
|
+
if (this._session === undefined) return;
|
|
378
|
+
|
|
379
|
+
const wasConnected = this._session != null;
|
|
380
|
+
this._session = undefined;
|
|
381
|
+
this._onDidChange.fire();
|
|
382
|
+
void this.refreshAfterSwitch(wasConnected);
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
private async refreshAfterSwitch(wasConnected: boolean): Promise<void> {
|
|
386
|
+
const session = await this.ensureSession({ createIfNeeded: false });
|
|
387
|
+
if (session != null || !wasConnected) return;
|
|
388
|
+
|
|
389
|
+
this._onDidChange.fire();
|
|
390
|
+
this.didChangeConnection?.fire({ integration: this, key: this.key, reason: 'disconnected' });
|
|
391
|
+
await this.providerOnDisconnect?.();
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
private skippedNonCloudReported = false;
|
|
395
|
+
@debug()
|
|
396
|
+
async syncCloudConnection(state: 'connected' | 'disconnected', forceSync: boolean): Promise<void> {
|
|
397
|
+
const scope = getScopedLogger();
|
|
398
|
+
// Initially the condition on `this._session.cloud` has been added here: https://github.com/gitkraken/vscode-gitlens/commit/e95e70c430bd162924cc3bd5c1e8ab90e6293449#diff-4213141a45cccaab7aa2e40028b155a87eb913b07388485831403e60ce5555e4R237
|
|
399
|
+
// I'm not sure about reasons, but it seems we want to replace it with the cloud session if it's connected.
|
|
400
|
+
// Gradually we'll stop having non-cloud sessions.
|
|
401
|
+
// However this is needed to be tested with PATs, e.g. with a GitLab PAT.
|
|
402
|
+
if (this._session?.cloud === false && state !== 'connected') {
|
|
403
|
+
if (this.id !== GitCloudHostIntegrationId.GitHub && !this.skippedNonCloudReported) {
|
|
404
|
+
this.ctx.hooks?.session?.onRefreshSkipped?.({
|
|
405
|
+
id: this.id,
|
|
406
|
+
reason: 'skip-non-cloud',
|
|
407
|
+
cloud: false,
|
|
408
|
+
});
|
|
409
|
+
this.skippedNonCloudReported = true;
|
|
410
|
+
}
|
|
411
|
+
return;
|
|
412
|
+
}
|
|
413
|
+
|
|
414
|
+
switch (state) {
|
|
415
|
+
case 'connected': {
|
|
416
|
+
const oldSession = this._session;
|
|
417
|
+
let resyncing = false;
|
|
418
|
+
if (forceSync) {
|
|
419
|
+
// Reset our stored session so that we get a new one from the cloud
|
|
420
|
+
const authProvider = await this.authenticationService.get(this.authProvider.id);
|
|
421
|
+
await authProvider.deleteSession(this.authProviderDescriptor);
|
|
422
|
+
// Reset the session and clear our "stay disconnected" flag
|
|
423
|
+
this._session = undefined;
|
|
424
|
+
await this.ctx.storage.deleteWorkspace(this.connectedKey);
|
|
425
|
+
resyncing = true;
|
|
426
|
+
} else {
|
|
427
|
+
// Only sync if we're not connected and not disabled and don't have pending errors
|
|
428
|
+
if (
|
|
429
|
+
this._session != null ||
|
|
430
|
+
this.requestExceptionCount > 0 ||
|
|
431
|
+
this.ctx.storage.getWorkspace(this.connectedKey) === false
|
|
432
|
+
) {
|
|
433
|
+
return;
|
|
434
|
+
}
|
|
435
|
+
|
|
436
|
+
forceSync = true;
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
// sync option, rather than createIfNeeded, makes sure we don't call connectCloudIntegrations and open a gkdev window
|
|
440
|
+
// if there was no session or some problem fetching/refreshing the existing session from the cloud api
|
|
441
|
+
let newSession: ProviderAuthenticationSession | undefined;
|
|
442
|
+
let refetchFailed = false;
|
|
443
|
+
try {
|
|
444
|
+
newSession = await this.ensureSession({ sync: forceSync });
|
|
445
|
+
} catch (ex) {
|
|
446
|
+
// Not evidence the connection is gone (#5569). Also leaves `_session` as-is rather than
|
|
447
|
+
// latching null, so the next access can re-resolve it.
|
|
448
|
+
if (!isCancellationError(ex)) {
|
|
449
|
+
scope?.error(ex);
|
|
450
|
+
}
|
|
451
|
+
refetchFailed = true;
|
|
452
|
+
}
|
|
453
|
+
|
|
454
|
+
if (oldSession && newSession && newSession.accessToken !== oldSession.accessToken) {
|
|
455
|
+
this.resetRequestExceptionCount('all');
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
// The forced re-sync above deleted the cloud secret but kept the descriptor to avoid UI churn.
|
|
459
|
+
// Drop it only when the replacement fetch came back definitively empty, so a connection whose
|
|
460
|
+
// token is really gone is cleanly disconnected (#5497) while a healthy one survives a blip (#5569).
|
|
461
|
+
if (resyncing && newSession == null && !refetchFailed) {
|
|
462
|
+
const authProvider = await this.authenticationService.get(this.authProvider.id);
|
|
463
|
+
await authProvider.deleteSession(this.authProviderDescriptor, { preserveConfigured: false });
|
|
464
|
+
}
|
|
465
|
+
|
|
466
|
+
break;
|
|
467
|
+
}
|
|
468
|
+
case 'disconnected':
|
|
469
|
+
await this.disconnect({ silent: true });
|
|
470
|
+
break;
|
|
471
|
+
}
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
protected handleProviderException(
|
|
475
|
+
syncReqUsecase: SyncReqUsecase,
|
|
476
|
+
ex: Error,
|
|
477
|
+
options?: { scope?: ScopedLogger | undefined; silent?: boolean },
|
|
478
|
+
): void {
|
|
479
|
+
if (isCancellationError(ex)) return;
|
|
480
|
+
|
|
481
|
+
options?.scope?.error(ex);
|
|
482
|
+
|
|
483
|
+
if (ex instanceof AuthenticationError && this._session?.cloud) {
|
|
484
|
+
if (!this.hasSessionSyncRequests()) {
|
|
485
|
+
this.requestSessionSyncForUsecase(syncReqUsecase);
|
|
486
|
+
this._session = {
|
|
487
|
+
...this._session,
|
|
488
|
+
expiresAt: new Date(Date.now() - 1),
|
|
489
|
+
};
|
|
490
|
+
} else {
|
|
491
|
+
this.trackRequestException(options);
|
|
492
|
+
}
|
|
493
|
+
} else if (ex instanceof AuthenticationError || ex instanceof RequestClientError) {
|
|
494
|
+
this.trackRequestException(options);
|
|
495
|
+
}
|
|
496
|
+
}
|
|
497
|
+
|
|
498
|
+
private missingExpirityReported = false;
|
|
499
|
+
@gate()
|
|
500
|
+
protected async refreshSessionIfExpired(scope?: ScopedLogger): Promise<void> {
|
|
501
|
+
if (this._session?.expiresAt != null && this._session.expiresAt < new Date()) {
|
|
502
|
+
// The current session is expired, so get the latest from the cloud and refresh if needed
|
|
503
|
+
try {
|
|
504
|
+
await this.syncCloudConnection('connected', true);
|
|
505
|
+
} catch (ex) {
|
|
506
|
+
scope?.error(ex);
|
|
507
|
+
}
|
|
508
|
+
} else if (
|
|
509
|
+
this._session?.expiresAt == null &&
|
|
510
|
+
this.id !== GitCloudHostIntegrationId.GitHub &&
|
|
511
|
+
!this.missingExpirityReported
|
|
512
|
+
) {
|
|
513
|
+
this.ctx.hooks?.session?.onRefreshSkipped?.({
|
|
514
|
+
id: this.id,
|
|
515
|
+
reason: 'missing-expiry',
|
|
516
|
+
cloud: this._session?.cloud,
|
|
517
|
+
});
|
|
518
|
+
this.missingExpirityReported = true;
|
|
519
|
+
}
|
|
520
|
+
}
|
|
521
|
+
|
|
522
|
+
@trace()
|
|
523
|
+
trackRequestException(options?: { silent?: boolean }): void {
|
|
524
|
+
this.requestExceptionCount++;
|
|
525
|
+
|
|
526
|
+
if (this.requestExceptionCount >= IntegrationBase.requestExceptionLimit && this._session !== null) {
|
|
527
|
+
if (!options?.silent) {
|
|
528
|
+
this.ctx.hooks?.ui?.onDisconnectedAfterTooManyFailures?.(this.name);
|
|
529
|
+
}
|
|
530
|
+
void this.disconnect({ currentSessionOnly: true });
|
|
531
|
+
}
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
@gate()
|
|
535
|
+
@trace({ exit: true })
|
|
536
|
+
async isConnected(): Promise<boolean> {
|
|
537
|
+
return (await this.getSession('integrations')) != null;
|
|
538
|
+
}
|
|
539
|
+
|
|
540
|
+
@gate()
|
|
541
|
+
private async ensureSession(
|
|
542
|
+
options:
|
|
543
|
+
| {
|
|
544
|
+
createIfNeeded?: boolean;
|
|
545
|
+
forceNewSession?: boolean;
|
|
546
|
+
sync?: never;
|
|
547
|
+
source?: Sources;
|
|
548
|
+
}
|
|
549
|
+
| {
|
|
550
|
+
createIfNeeded?: never;
|
|
551
|
+
forceNewSession?: never;
|
|
552
|
+
sync: boolean;
|
|
553
|
+
source?: Sources;
|
|
554
|
+
},
|
|
555
|
+
): Promise<ProviderAuthenticationSession | undefined> {
|
|
556
|
+
const scope = getScopedLogger();
|
|
557
|
+
|
|
558
|
+
const { createIfNeeded, forceNewSession, source, sync } = options;
|
|
559
|
+
if (this._session != null) {
|
|
560
|
+
if (this.isSessionForIntegrationHost(this._session)) return this._session;
|
|
561
|
+
|
|
562
|
+
this._session = null;
|
|
563
|
+
}
|
|
564
|
+
if (this.ctx.config.isIntegrationsEnabled?.() === false) return undefined;
|
|
565
|
+
|
|
566
|
+
if (createIfNeeded || sync) {
|
|
567
|
+
await this.ctx.storage.deleteWorkspace(this.connectedKey);
|
|
568
|
+
} else if (this.ctx.storage.getWorkspace(this.connectedKey) === false) {
|
|
569
|
+
return undefined;
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
let session: ProviderAuthenticationSession | undefined | null;
|
|
573
|
+
try {
|
|
574
|
+
const authProvider = await this.authenticationService.get(this.authProvider.id);
|
|
575
|
+
session = await authProvider.getSession(
|
|
576
|
+
this.authProviderDescriptor,
|
|
577
|
+
sync
|
|
578
|
+
? { sync: sync, source: source }
|
|
579
|
+
: {
|
|
580
|
+
createIfNeeded: createIfNeeded,
|
|
581
|
+
forceNewSession: forceNewSession,
|
|
582
|
+
source: source,
|
|
583
|
+
},
|
|
584
|
+
);
|
|
585
|
+
|
|
586
|
+
if (session?.expiresAt != null && session.expiresAt < new Date()) {
|
|
587
|
+
session = null;
|
|
588
|
+
}
|
|
589
|
+
if (session != null && !this.isSessionForIntegrationHost(session)) {
|
|
590
|
+
session = undefined;
|
|
591
|
+
}
|
|
592
|
+
} catch (ex) {
|
|
593
|
+
await this.ctx.storage.deleteWorkspace(this.connectedKey);
|
|
594
|
+
|
|
595
|
+
// Only interactive paths can prompt for consent, so a sync failure must reach the rethrow below.
|
|
596
|
+
if (!sync && ex instanceof Error && ex.message.includes('User did not consent')) {
|
|
597
|
+
return undefined;
|
|
598
|
+
}
|
|
599
|
+
|
|
600
|
+
// On a forced re-sync, propagate so syncCloudConnection can tell a failure from a definitive empty
|
|
601
|
+
// result (#5569); other callers keep swallowing to null so reads never throw.
|
|
602
|
+
if (sync) {
|
|
603
|
+
// Throwing skips the reset below, and a lingering count blocks the next non-forced sync.
|
|
604
|
+
this.smoothifyRequestExceptionCount();
|
|
605
|
+
throw ex;
|
|
606
|
+
}
|
|
607
|
+
|
|
608
|
+
session = null;
|
|
609
|
+
}
|
|
610
|
+
|
|
611
|
+
if (session === undefined && !createIfNeeded && !sync) {
|
|
612
|
+
await this.ctx.storage.deleteWorkspace(this.connectedKey);
|
|
613
|
+
}
|
|
614
|
+
|
|
615
|
+
this._session = session ?? null;
|
|
616
|
+
this.smoothifyRequestExceptionCount();
|
|
617
|
+
|
|
618
|
+
if (session != null) {
|
|
619
|
+
await this.ctx.storage.storeWorkspace(this.connectedKey, true);
|
|
620
|
+
|
|
621
|
+
queueMicrotask(() => {
|
|
622
|
+
this._onDidChange.fire();
|
|
623
|
+
this.didChangeConnection?.fire({ integration: this, key: this.key, reason: 'connected' });
|
|
624
|
+
// Fired detached, so there is no caller left to catch anything: every implementor is async, and
|
|
625
|
+
// a rejection would surface as a process-level unhandled rejection in the host. It is a
|
|
626
|
+
// best-effort warm-up, so swallow the failure with a warning instead.
|
|
627
|
+
void (async () => {
|
|
628
|
+
try {
|
|
629
|
+
await this.providerOnConnect?.();
|
|
630
|
+
} catch (ex) {
|
|
631
|
+
scope?.warn(
|
|
632
|
+
`Failed to run providerOnConnect for ${this.key}: ${ex instanceof Error ? ex.message : String(ex)}`,
|
|
633
|
+
);
|
|
634
|
+
}
|
|
635
|
+
})();
|
|
636
|
+
});
|
|
637
|
+
}
|
|
638
|
+
|
|
639
|
+
return session ?? undefined;
|
|
640
|
+
}
|
|
641
|
+
|
|
642
|
+
getIgnoreSSLErrors(): boolean | 'force' {
|
|
643
|
+
return this.authenticationService.ignoreSSLErrors(this);
|
|
644
|
+
}
|
|
645
|
+
|
|
646
|
+
async searchMyIssues(
|
|
647
|
+
resource?: ResourceDescriptor,
|
|
648
|
+
cancellation?: AbortSignal,
|
|
649
|
+
connectionId?: string,
|
|
650
|
+
): Promise<IssueShape[] | undefined>;
|
|
651
|
+
async searchMyIssues(
|
|
652
|
+
resources?: ResourceDescriptor[],
|
|
653
|
+
cancellation?: AbortSignal,
|
|
654
|
+
connectionId?: string,
|
|
655
|
+
): Promise<IssueShape[] | undefined>;
|
|
656
|
+
@trace()
|
|
657
|
+
async searchMyIssues(
|
|
658
|
+
resources?: ResourceDescriptor | ResourceDescriptor[],
|
|
659
|
+
cancellation?: AbortSignal,
|
|
660
|
+
connectionId?: string,
|
|
661
|
+
): Promise<IssueShape[] | undefined> {
|
|
662
|
+
return (await this.searchMyIssuesResult(resources, cancellation, connectionId))?.value;
|
|
663
|
+
}
|
|
664
|
+
|
|
665
|
+
/**
|
|
666
|
+
* Result-returning core of {@link searchMyIssues}. Recovers thrown errors into `{ error }` so callers
|
|
667
|
+
* (e.g. the ProviderBackend account-wide issues read) can surface a per-provider warning instead of a
|
|
668
|
+
* silent empty result. Returns the normalized {@link IssueShape} (there is no raw account-wide issue read).
|
|
669
|
+
*/
|
|
670
|
+
async searchMyIssuesResult(
|
|
671
|
+
resources?: ResourceDescriptor | ResourceDescriptor[],
|
|
672
|
+
cancellation?: AbortSignal,
|
|
673
|
+
connectionId?: string,
|
|
674
|
+
): Promise<IntegrationResult<IssueShape[] | undefined>> {
|
|
675
|
+
const scope = getScopedLogger();
|
|
676
|
+
// `connectionId` targets a specific account (multi-account); omitted reads the primary.
|
|
677
|
+
const session = await this.resolveReadSession(connectionId, scope);
|
|
678
|
+
if (session == null) return undefined;
|
|
679
|
+
|
|
680
|
+
try {
|
|
681
|
+
const issues = await this.searchProviderMyIssues(
|
|
682
|
+
session,
|
|
683
|
+
resources != null ? (Array.isArray(resources) ? resources : [resources]) : undefined,
|
|
684
|
+
cancellation,
|
|
685
|
+
);
|
|
686
|
+
this.resetRequestExceptionCount('searchMyIssues');
|
|
687
|
+
return { value: issues };
|
|
688
|
+
} catch (ex) {
|
|
689
|
+
this.handleProviderException('searchMyIssues', ex, { scope: scope });
|
|
690
|
+
return { error: toError(ex) };
|
|
691
|
+
}
|
|
692
|
+
}
|
|
693
|
+
|
|
694
|
+
protected abstract searchProviderMyIssues(
|
|
695
|
+
session: ProviderAuthenticationSession,
|
|
696
|
+
resources?: ResourceDescriptor[],
|
|
697
|
+
cancellation?: AbortSignal,
|
|
698
|
+
): Promise<IssueShape[] | undefined>;
|
|
699
|
+
|
|
700
|
+
/**
|
|
701
|
+
* Paging/truncation-aware variant of {@link searchProviderMyIssues}. The default wraps the normalized read
|
|
702
|
+
* as a complete single page; providers with native cursors or fan-out metadata override it.
|
|
703
|
+
*/
|
|
704
|
+
protected async searchProviderMyIssuesWithTruncation(
|
|
705
|
+
session: ProviderAuthenticationSession,
|
|
706
|
+
resources?: ResourceDescriptor[],
|
|
707
|
+
cancellation?: AbortSignal,
|
|
708
|
+
_options?: SearchMyIssuesOptions,
|
|
709
|
+
): Promise<AccountWideIssuesResult | undefined> {
|
|
710
|
+
// The default read has no assignee scoping to broaden, so `_options` is inert here; a provider whose
|
|
711
|
+
// account-wide read is user-scoped (GitHub/GitLab/Azure) overrides this and honors `includeAllAssignees`.
|
|
712
|
+
const values = await this.searchProviderMyIssues(session, resources, cancellation);
|
|
713
|
+
if (values == null) return undefined;
|
|
714
|
+
return { values: values, truncated: false };
|
|
715
|
+
}
|
|
716
|
+
|
|
717
|
+
/**
|
|
718
|
+
* Result-returning, truncation-aware account-wide issue read. Recovers thrown errors into `{ error }` and
|
|
719
|
+
* carries the `truncated` flag so the ProviderBackend facade can report an incomplete read honestly.
|
|
720
|
+
*/
|
|
721
|
+
async searchMyIssuesWithTruncationResult(
|
|
722
|
+
resources?: ResourceDescriptor | ResourceDescriptor[],
|
|
723
|
+
cancellation?: AbortSignal,
|
|
724
|
+
connectionId?: string,
|
|
725
|
+
options?: SearchMyIssuesOptions,
|
|
726
|
+
): Promise<IntegrationResult<AccountWideIssuesResult | undefined>> {
|
|
727
|
+
const scope = getScopedLogger();
|
|
728
|
+
const session = await this.resolveReadSession(connectionId, scope);
|
|
729
|
+
if (session == null) return undefined;
|
|
730
|
+
|
|
731
|
+
try {
|
|
732
|
+
const result = await this.searchProviderMyIssuesWithTruncation(
|
|
733
|
+
session,
|
|
734
|
+
resources != null ? (Array.isArray(resources) ? resources : [resources]) : undefined,
|
|
735
|
+
cancellation,
|
|
736
|
+
options,
|
|
737
|
+
);
|
|
738
|
+
this.resetRequestExceptionCount('searchMyIssues');
|
|
739
|
+
return { value: result };
|
|
740
|
+
} catch (ex) {
|
|
741
|
+
this.handleProviderException('searchMyIssues', ex, { scope: scope });
|
|
742
|
+
return { error: toError(ex) };
|
|
743
|
+
}
|
|
744
|
+
}
|
|
745
|
+
|
|
746
|
+
@trace()
|
|
747
|
+
async getLinkedIssueOrPullRequest(
|
|
748
|
+
resource: T,
|
|
749
|
+
link: { id: string; key: string },
|
|
750
|
+
options?: { expiryOverride?: boolean | number; type?: IssueOrPullRequestType },
|
|
751
|
+
): Promise<IssueOrPullRequest | undefined> {
|
|
752
|
+
const scope = getScopedLogger();
|
|
753
|
+
|
|
754
|
+
const connected = this.maybeConnected ?? (await this.isConnected());
|
|
755
|
+
if (!connected) return undefined;
|
|
756
|
+
|
|
757
|
+
await this.refreshSessionIfExpired(scope);
|
|
758
|
+
|
|
759
|
+
const issueOrPR = this.ctx.cache.getIssueOrPullRequest(
|
|
760
|
+
link.key,
|
|
761
|
+
options?.type,
|
|
762
|
+
resource,
|
|
763
|
+
this,
|
|
764
|
+
() => ({
|
|
765
|
+
value: (async () => {
|
|
766
|
+
try {
|
|
767
|
+
const result = await this.getProviderLinkedIssueOrPullRequest(
|
|
768
|
+
this._session!,
|
|
769
|
+
resource,
|
|
770
|
+
link,
|
|
771
|
+
options?.type,
|
|
772
|
+
);
|
|
773
|
+
this.resetRequestExceptionCount('getIssueOrPullRequest');
|
|
774
|
+
return result;
|
|
775
|
+
} catch (ex) {
|
|
776
|
+
this.handleProviderException('getIssueOrPullRequest', ex, { scope: scope });
|
|
777
|
+
return undefined;
|
|
778
|
+
}
|
|
779
|
+
})(),
|
|
780
|
+
}),
|
|
781
|
+
options,
|
|
782
|
+
);
|
|
783
|
+
return issueOrPR;
|
|
784
|
+
}
|
|
785
|
+
|
|
786
|
+
protected abstract getProviderLinkedIssueOrPullRequest(
|
|
787
|
+
session: ProviderAuthenticationSession,
|
|
788
|
+
resource: T,
|
|
789
|
+
link: { id: string; key: string },
|
|
790
|
+
type: undefined | IssueOrPullRequestType,
|
|
791
|
+
): Promise<IssueOrPullRequest | undefined>;
|
|
792
|
+
|
|
793
|
+
@trace()
|
|
794
|
+
async getIssue(
|
|
795
|
+
resource: T,
|
|
796
|
+
id: string,
|
|
797
|
+
options?: { expiryOverride?: boolean | number },
|
|
798
|
+
): Promise<Issue | undefined> {
|
|
799
|
+
const scope = getScopedLogger();
|
|
800
|
+
|
|
801
|
+
const connected = this.maybeConnected ?? (await this.isConnected());
|
|
802
|
+
if (!connected) return undefined;
|
|
803
|
+
|
|
804
|
+
await this.refreshSessionIfExpired(scope);
|
|
805
|
+
|
|
806
|
+
const issue = this.ctx.cache.getIssue(
|
|
807
|
+
id,
|
|
808
|
+
resource,
|
|
809
|
+
this,
|
|
810
|
+
() => ({
|
|
811
|
+
value: (async () => {
|
|
812
|
+
try {
|
|
813
|
+
const result = await this.getProviderIssue(this._session!, resource, id);
|
|
814
|
+
this.resetRequestExceptionCount('getIssue');
|
|
815
|
+
return result;
|
|
816
|
+
} catch (ex) {
|
|
817
|
+
this.handleProviderException('getIssue', ex, { scope: scope });
|
|
818
|
+
return undefined;
|
|
819
|
+
}
|
|
820
|
+
})(),
|
|
821
|
+
}),
|
|
822
|
+
options,
|
|
823
|
+
);
|
|
824
|
+
return issue;
|
|
825
|
+
}
|
|
826
|
+
|
|
827
|
+
protected abstract getProviderIssue(
|
|
828
|
+
session: ProviderAuthenticationSession,
|
|
829
|
+
resource: T,
|
|
830
|
+
id: string,
|
|
831
|
+
): Promise<Issue | undefined>;
|
|
832
|
+
|
|
833
|
+
async getCurrentAccount(options?: {
|
|
834
|
+
avatarSize?: number;
|
|
835
|
+
connectionId?: string;
|
|
836
|
+
expiryOverride?: boolean | number;
|
|
837
|
+
}): Promise<Account | undefined> {
|
|
838
|
+
const scope = getScopedLogger();
|
|
839
|
+
const { connectionId: requestedConnectionId, expiryOverride, ...opts } = options ?? {};
|
|
840
|
+
const connectionId = requestedConnectionId || undefined;
|
|
841
|
+
const session = await this.resolveReadSession(connectionId, scope);
|
|
842
|
+
if (session == null) return undefined;
|
|
843
|
+
|
|
844
|
+
const sessionFingerprint = this.getSessionFingerprint(session);
|
|
845
|
+
|
|
846
|
+
const currentAccount = await this.ctx.cache.getCurrentAccount(
|
|
847
|
+
this,
|
|
848
|
+
|
|
849
|
+
(cacheable: any) => ({
|
|
850
|
+
value: (async () => {
|
|
851
|
+
try {
|
|
852
|
+
const account = await this.getProviderCurrentAccount?.(session, opts);
|
|
853
|
+
this.resetRequestExceptionCount('getCurrentAccount');
|
|
854
|
+
return account;
|
|
855
|
+
} catch (ex) {
|
|
856
|
+
if (isCancellationError(ex)) {
|
|
857
|
+
cacheable.invalidate();
|
|
858
|
+
return undefined;
|
|
859
|
+
}
|
|
860
|
+
|
|
861
|
+
this.handleProviderException('getCurrentAccount', ex, { scope: scope });
|
|
862
|
+
|
|
863
|
+
// Invalidate the cache on error, except for auth errors
|
|
864
|
+
if (!(ex instanceof AuthenticationError)) {
|
|
865
|
+
cacheable.invalidate();
|
|
866
|
+
}
|
|
867
|
+
|
|
868
|
+
// Re-throw to the caller
|
|
869
|
+
throw ex;
|
|
870
|
+
}
|
|
871
|
+
})(),
|
|
872
|
+
}),
|
|
873
|
+
{
|
|
874
|
+
connectionId: connectionId,
|
|
875
|
+
expiryOverride: expiryOverride,
|
|
876
|
+
expireOnError: false,
|
|
877
|
+
etag: `${this.id}:${this.maybeConnected ?? false}:${sessionFingerprint}`,
|
|
878
|
+
},
|
|
879
|
+
);
|
|
880
|
+
return currentAccount;
|
|
881
|
+
}
|
|
882
|
+
|
|
883
|
+
protected getProviderCurrentAccount?(
|
|
884
|
+
session: ProviderAuthenticationSession,
|
|
885
|
+
options?: { avatarSize?: number },
|
|
886
|
+
): Promise<Account | undefined>;
|
|
887
|
+
|
|
888
|
+
/**
|
|
889
|
+
* Resolves the account for a specific session/token — including connections other than the current
|
|
890
|
+
* primary (multi-account) — using this integration's provider API base URL and auth type. Returns
|
|
891
|
+
* undefined when the provider doesn't support account lookup. Uncached (callers cache per connection).
|
|
892
|
+
*/
|
|
893
|
+
getProviderAccountForSession(session: ProviderAuthenticationSession): Promise<Account | undefined> {
|
|
894
|
+
return this.getProviderCurrentAccount?.(session) ?? Promise.resolve(undefined);
|
|
895
|
+
}
|
|
896
|
+
|
|
897
|
+
@trace()
|
|
898
|
+
async getPullRequest(resource: T, id: string): Promise<PullRequest | undefined> {
|
|
899
|
+
const scope = getScopedLogger();
|
|
900
|
+
|
|
901
|
+
const connected = this.maybeConnected ?? (await this.isConnected());
|
|
902
|
+
if (!connected) return undefined;
|
|
903
|
+
|
|
904
|
+
await this.refreshSessionIfExpired(scope);
|
|
905
|
+
|
|
906
|
+
const pr = await this.ctx.cache.getPullRequest(id, resource, this, () => ({
|
|
907
|
+
value: (async () => {
|
|
908
|
+
try {
|
|
909
|
+
const result = await this.getProviderPullRequest?.(this._session!, resource, id);
|
|
910
|
+
this.resetRequestExceptionCount('getPullRequest');
|
|
911
|
+
return result;
|
|
912
|
+
} catch (ex) {
|
|
913
|
+
this.handleProviderException('getPullRequest', ex, { scope: scope });
|
|
914
|
+
return undefined;
|
|
915
|
+
}
|
|
916
|
+
})(),
|
|
917
|
+
}));
|
|
918
|
+
return pr;
|
|
919
|
+
}
|
|
920
|
+
|
|
921
|
+
protected getProviderPullRequest?(
|
|
922
|
+
session: ProviderAuthenticationSession,
|
|
923
|
+
resource: T,
|
|
924
|
+
id: string,
|
|
925
|
+
): Promise<PullRequest | undefined>;
|
|
926
|
+
}
|