Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

parse-github-repo-url

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

parse-github-repo-url

Parse a GitHub URL for user/project@version

  • 1.0.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
477K
increased by4.3%
Maintainers
1
Weekly downloads
 
Created

What is parse-github-repo-url?

The parse-github-repo-url npm package is a utility for parsing GitHub repository URLs into their constituent parts, such as the owner, repository name, and branch. This can be useful for applications that need to handle GitHub URLs and extract meaningful information from them.

What are parse-github-repo-url's main functionalities?

Parse GitHub Repository URL

This feature allows you to parse a GitHub repository URL and extract the owner and repository name. If a branch is specified in the URL, it will also be extracted.

const parse = require('parse-github-repo-url');
const result = parse('https://github.com/user/repo');
console.log(result); // ['user', 'repo', '']

Parse GitHub Repository URL with Branch

This feature allows you to parse a GitHub repository URL that includes a branch. The owner, repository name, and branch will be extracted.

const parse = require('parse-github-repo-url');
const result = parse('https://github.com/user/repo/tree/branch');
console.log(result); // ['user', 'repo', 'branch']

Other packages similar to parse-github-repo-url

FAQs

Package last updated on 23 Apr 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc