Welcome to mirror list, hosted at ThFree Co, Russian Federation.

index.js « github-url-from-username-repo « node_modules « npm « deps - github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 8af2c4f83195af2226310221b794863c7b0bb8b1 (plain)
1
2
3
4
5
6
7
8
9
module.exports = getUrl

function getUrl (r) {
  if (!r) return
  if (/^[\w-]+\/[\w-]+$/.test(r))
    return "git://github.com/" + r
  else
    return null
}