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

git-common-ancestor

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

git-common-ancestor

Get the common ancestor of a sha and a branch

  • 1.0.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

git-common-ancestor

Build Status devDependency Status devDependency Status

Installation

$ npm install git-common-ancestor --save-dev

Usage

Git Graph

#ofShaAndBranch(string sha, string branch) -> Promise(string sha)

var gitCommonAncestor = require('git-common-ancestor');
var sha = '70d708aacad0dcc40346cb15fd05ddb14e8e5f29';

gitCommonAncestor.ofShaAndBranch(sha, 'master')
.then(function(branchPoint) {
  assert.strictEqual(branchPoint, '0b256cbf19f306e4fc4090b0b4bec096d1bfd5eb')
});

FAQs

Package last updated on 02 Sep 2015

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