git-commit-info

Get the info of an specific commit hash

MIT 8 个版本
安装
npm install git-commit-info
yarn add git-commit-info
pnpm add git-commit-info
bun add git-commit-info
README

git-commit-info

Get all information about a specific commit.

Build Status Build status Coverage Status

Installation

$ npm i git-commit-info --save

or

$ yarn add git-commit-info

Usage

Available parameters:

  • cwd: Specify the path. Default: process.cwd()
  • commit: The hash of the commit. Default: latest
const gitCommitInfo = require('git-commit-info');

// information of process.cwd() and the latest commit
gitCommitInfo();

// information of the latest commit in ./my_repo
gitCommitInfo({
  cwd: './my_repo',
});

// information of the specified commit in process.cwd()
gitCommitInfo({
  commit: '82442c2405804d7aa44e7bedbc0b93bb17707626', // any hash
});

// information of the specified commit in ./my_repo
gitCommitInfo({
  cwd: './my_repo',
  commit: '82442c2405804d7aa44e7bedbc0b93bb17707626', // any hash
});

LICENSE

MIT © Jan Peer Stöcklmair

版本列表
2.0.2 2023-06-08
2.0.1 2022-01-12
2.0.0 2020-07-12
1.1.0 2020-07-02
1.0.0 2017-06-11
0.2.0 2012-04-14
0.1.0 2012-04-14
0.0.2 2012-04-14