Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateAuthenticatedURL ¶ added in v1.70.0
CreateAuthenticatedURL creates an authenticated GitHub URL with token
func ExtractHostname ¶ added in v1.70.0
ExtractHostname extracts hostname from GitHub URL
func GetAPIBase ¶ added in v1.70.0
func GetAPIBase() string
GetAPIBase returns the GitHub API base URL (supports enterprise)
func GetGitHubURL ¶ added in v1.70.0
func GetGitHubURL() string
GetGitHubURL returns the GitHub URL (supports enterprise)
func GetRepositoryFromGitRemote ¶ added in v1.70.0
func GetRepositoryFromGitRemote() string
GetRepositoryFromGitRemote extracts repository full name from git remote
func ParseRepositoryURL ¶ added in v1.70.0
ParseRepositoryURL extracts owner/repo from various Git URL formats
Types ¶
type InstallationCache ¶
type InstallationCache struct {
// contains filtered or unexported fields
}
InstallationCache provides caching for GitHub App installation IDs
func NewInstallationCache ¶
func NewInstallationCache() *InstallationCache
NewInstallationCache creates a new installation ID cache with 24-hour TTL
func NewInstallationCacheWithTTL ¶
func NewInstallationCacheWithTTL(ttl time.Duration) *InstallationCache
NewInstallationCacheWithTTL creates a new installation ID cache with custom TTL
func (*InstallationCache) ClearCache ¶
func (c *InstallationCache) ClearCache()
ClearCache clears all cached entries
func (*InstallationCache) GetCacheStats ¶
func (c *InstallationCache) GetCacheStats() (repoCount, orgCount int)
GetCacheStats returns cache statistics for debugging
func (*InstallationCache) GetInstallationID ¶
func (c *InstallationCache) GetInstallationID(ctx context.Context, appID int64, pemData []byte, repoFullName, apiBase string) (int64, error)
GetInstallationID retrieves installation ID for a repository with caching