@oss-autopilot/core - v3.7.0
    Preparing search index...

    Function parseGitHubUrl

    • Parses a GitHub pull request or issue URL into its components.

      Only accepts HTTPS GitHub URLs (https://github.com/...). Returns null for invalid URLs, non-GitHub URLs, or URLs with invalid owner/repo characters.

      Parameters

      • url: string

      Returns ParsedGitHubUrl | null

      parseGitHubUrl('https://github.com/facebook/react/pull/123')
      // { owner: "facebook", repo: "react", number: 123, type: "pull" }
      parseGitHubUrl('https://example.com/not-github')
      // null