src/github/index.js
function parseGithubURL(url) {
  var githubUrlRe = /github\.com\/([^/]+)\/([^/]+)\/pull\/([0-9]+)/;
  var match = url.match(githubUrlRe);

  if (!match) {
    return null;
  }

  return {
    owner: match[1],
    repo: match[2],
    number: match[3]
  };
}
function parseGithubURL(url) {
  var githubUrlRe = /github\.com\/([^/]+)\/([^/]+)\/pull\/([0-9]+)/;
  var match = url.match(githubUrlRe);

  if (!match) {
    return null;
  }

  return {
    owner: match[1],
    repo: match[2],
    number: match[3]
  };
}
function parseGithubURL ( url ) { var githubUrlRe = / github\.com\/([^/]+)\/([^/]+)\/pull\/([0-9]+) / ; var match = url . match ( githubUrlRe ) ; if ( ! match ) { return null ; } return { owner : match [ 1 ] , repo : match [ 2 ] , number : match [ 3 ] } ; }
Helper that converts URLs into GitHub resource objects
compatible with node-github
@param  {String} url - A GitHub resource URL
@return {Object} GitHub resource parsed from URL
Helper that converts URLs into GitHub resource objects compatible with node - github