{"_id":"gitlogplus","_rev":"3518010","name":"gitlogplus","description":"Git log parser for Node.JS","dist-tags":{"latest":"3.1.7"},"maintainers":[{"name":"jonathandown","email":""}],"time":{"modified":"2024-08-27T20:50:34.000Z","created":"2019-03-11T19:27:12.901Z","3.1.7":"2019-03-19T19:10:28.906Z","3.1.6":"2019-03-18T14:38:51.720Z","3.1.5":"2019-03-11T19:37:16.830Z","3.1.4":"2019-03-11T19:28:44.615Z","3.1.3":"2019-03-11T19:27:12.901Z"},"users":{},"author":{"name":"Jonathan Down","email":"jonathan@proposify.com"},"versions":{"3.1.7":{"name":"gitlogplus","version":"3.1.7","description":"Git log parser for Node.JS","main":"index.js","scripts":{"lint":"jshint .","checkStyle":"jscs .","test":"istanbul cover ./node_modules/.bin/_mocha -- -r should","posttest":"istanbul check-coverage --statements 95 --branches 85 --functions 100 --lines 95 && rm -rf coverage"},"publishConfig":{"registry":"http://registry.npmjs.org"},"keywords":["git","log","parser"],"author":{"name":"Jonathan Down","email":"jonathan@proposify.com"},"contributors":[{"name":"Dom Harrington","url":"https://github.com/domharrington/node-gitlog"}],"license":"BSD","engines":{"node":">=0.11.12"},"devDependencies":{"istanbul":"^0.4.5","jscs":"^3.0.7","jshint":"^2.5.6","mocha":"^3.0.2","should":"~11.1.0"},"dependencies":{"debug":"^3.1.0","lodash.assign":"^4.2.0"},"gitHead":"93b571c48ca40297721dbb475b8208524220f812","_id":"gitlogplus@3.1.7","_nodeVersion":"10.13.0","_npmVersion":"6.9.0","dist":{"shasum":"6838390bb21cbdec905a6ac992e421df3220514e","size":8057,"noattachment":false,"key":"/gitlogplus/-/gitlogplus-3.1.7.tgz","tarball":"http://registry.cnpm.dingdandao.com/gitlogplus/download/gitlogplus-3.1.7.tgz"},"maintainers":[{"name":"jonathandown","email":""}],"_npmUser":{"name":"jonathandown","email":"jonathan@proposify.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/gitlogplus_3.1.7_1553022628764_0.2921989205013722"},"_hasShrinkwrap":false,"publish_time":1553022628906,"_cnpm_publish_time":1553022628906,"_cnpmcore_publish_time":"2021-12-16T23:18:08.927Z"},"3.1.6":{"name":"gitlogplus","version":"3.1.6","description":"Git log parser for Node.JS","main":"index.js","scripts":{"lint":"jshint .","checkStyle":"jscs .","test":"istanbul cover ./node_modules/.bin/_mocha -- -r should","posttest":"istanbul check-coverage --statements 95 --branches 85 --functions 100 --lines 95 && rm -rf coverage"},"publishConfig":{"registry":"http://registry.npmjs.org"},"keywords":["git","log","parser"],"author":{"name":"Jonathan Down","email":"jonathan@proposify.com"},"contributors":[{"name":"Dom Harrington","url":"https://github.com/domharrington/node-gitlog"}],"license":"BSD","engines":{"node":">=0.11.12"},"devDependencies":{"istanbul":"^0.4.5","jscs":"^3.0.7","jshint":"^2.5.6","mocha":"^3.0.2","should":"~11.1.0"},"dependencies":{"debug":"^3.1.0","lodash.assign":"^4.2.0"},"gitHead":"628025fa7d1a7a81d2b2c7274c5fbf0da4624934","_id":"gitlogplus@3.1.6","_nodeVersion":"10.13.0","_npmVersion":"6.9.0","dist":{"shasum":"4019fdc45a1604f6389d1fb40c77dab6e308c82a","size":8051,"noattachment":false,"key":"/gitlogplus/-/gitlogplus-3.1.6.tgz","tarball":"http://registry.cnpm.dingdandao.com/gitlogplus/download/gitlogplus-3.1.6.tgz"},"maintainers":[{"name":"jonathandown","email":""}],"_npmUser":{"name":"jonathandown","email":"jonathan@proposify.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/gitlogplus_3.1.6_1552919931550_0.8932676578735823"},"_hasShrinkwrap":false,"publish_time":1552919931720,"_cnpm_publish_time":1552919931720,"_cnpmcore_publish_time":"2021-12-16T23:18:09.148Z"},"3.1.5":{"name":"gitlogplus","version":"3.1.5","description":"Git log parser for Node.JS","main":"index.js","scripts":{"lint":"jshint .","checkStyle":"jscs .","test":"istanbul cover ./node_modules/.bin/_mocha -- -r should","posttest":"istanbul check-coverage --statements 95 --branches 85 --functions 100 --lines 95 && rm -rf coverage"},"publishConfig":{"registry":"http://registry.npmjs.org"},"keywords":["git","log","parser"],"author":{"name":"Jonathan Down","email":"jonathan@proposify.com"},"contributors":[{"name":"Dom Harrington","url":"https://github.com/domharrington/node-gitlog"}],"license":"BSD","engines":{"node":">=0.11.12"},"devDependencies":{"istanbul":"^0.4.5","jscs":"^3.0.7","jshint":"^2.5.6","mocha":"^3.0.2","should":"~11.1.0"},"dependencies":{"debug":"^3.1.0","lodash.assign":"^4.2.0"},"gitHead":"695bc4688e4e6e52c7124a7f2a5f0f552ed365fb","_id":"gitlogplus@3.1.5","_nodeVersion":"10.13.0","_npmVersion":"6.9.0","dist":{"shasum":"5d6739904e960a6c9b4182913b09ac1c6e13b84c","size":8048,"noattachment":false,"key":"/gitlogplus/-/gitlogplus-3.1.5.tgz","tarball":"http://registry.cnpm.dingdandao.com/gitlogplus/download/gitlogplus-3.1.5.tgz"},"maintainers":[{"name":"jonathandown","email":""}],"_npmUser":{"name":"jonathandown","email":"jonathan@proposify.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/gitlogplus_3.1.5_1552333036674_0.03301932045662026"},"_hasShrinkwrap":false,"publish_time":1552333036830,"_cnpm_publish_time":1552333036830,"_cnpmcore_publish_time":"2021-12-16T23:18:09.324Z"},"3.1.4":{"name":"gitlogplus","version":"3.1.4","description":"Git log parser for Node.JS","main":"index.js","scripts":{"lint":"jshint .","checkStyle":"jscs .","test":"istanbul cover ./node_modules/.bin/_mocha -- -r should","posttest":"istanbul check-coverage --statements 95 --branches 85 --functions 100 --lines 95 && rm -rf coverage"},"publishConfig":{"registry":"http://registry.npmjs.org"},"keywords":["git","log","parser"],"author":{"name":"Jonathan Down","email":"jonathan@proposify.com"},"contributors":[{"name":"Dom Harrington","url":"https://github.com/domharrington/node-gitlog"}],"license":"BSD","engines":{"node":">=0.11.12"},"devDependencies":{"istanbul":"^0.4.5","jscs":"^3.0.7","jshint":"^2.5.6","mocha":"^3.0.2","should":"~11.1.0"},"dependencies":{"debug":"^3.1.0","lodash.assign":"^4.2.0"},"gitHead":"9893f3d64ad36b0521bd8c8de20ddd3f4e9c1114","_id":"gitlogplus@3.1.4","_nodeVersion":"10.13.0","_npmVersion":"6.9.0","dist":{"shasum":"af7eb1241bed9fef943ca22220a34a80ff7fc4d3","size":8056,"noattachment":false,"key":"/gitlogplus/-/gitlogplus-3.1.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/gitlogplus/download/gitlogplus-3.1.4.tgz"},"maintainers":[{"name":"jonathandown","email":""}],"_npmUser":{"name":"jonathandown","email":"jonathan@proposify.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/gitlogplus_3.1.4_1552332524287_0.5546793459374377"},"_hasShrinkwrap":false,"publish_time":1552332524615,"_cnpm_publish_time":1552332524615,"_cnpmcore_publish_time":"2021-12-16T23:18:09.906Z"},"3.1.3":{"name":"gitlogplus","version":"3.1.3","description":"Git log parser for Node.JS","main":"index.js","scripts":{"lint":"jshint .","checkStyle":"jscs .","test":"istanbul cover ./node_modules/.bin/_mocha -- -r should","posttest":"istanbul check-coverage --statements 95 --branches 85 --functions 100 --lines 95 && rm -rf coverage"},"publishConfig":{"registry":"http://registry.npmjs.org"},"keywords":["git","log","parser"],"author":{"name":"Jonathan Down","email":"jonathan@proposify.com"},"contributors":[{"name":"Dom Harrington","url":"https://github.com/domharrington/node-gitlog"}],"license":"BSD","engines":{"node":">=0.11.12"},"devDependencies":{"istanbul":"^0.4.5","jscs":"^3.0.7","jshint":"^2.5.6","mocha":"^3.0.2","should":"~11.1.0"},"dependencies":{"debug":"^3.1.0","lodash.assign":"^4.2.0"},"gitHead":"29befe7679f27e0e3fab64c8c43c84e736397f0f","_id":"gitlogplus@3.1.3","_nodeVersion":"10.13.0","_npmVersion":"6.9.0","dist":{"shasum":"2bf93906e4fd893304dfb4a5095e6103400e5d3b","size":8054,"noattachment":false,"key":"/gitlogplus/-/gitlogplus-3.1.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/gitlogplus/download/gitlogplus-3.1.3.tgz"},"maintainers":[{"name":"jonathandown","email":""}],"_npmUser":{"name":"jonathandown","email":"jonathan@proposify.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/gitlogplus_3.1.3_1552332432778_0.47723082171464415"},"_hasShrinkwrap":false,"publish_time":1552332432901,"_cnpm_publish_time":1552332432901,"_cnpmcore_publish_time":"2021-12-16T23:18:10.120Z"}},"readme":"# node-gitlog\n\nGit log parser for Node.JS\n\n[![build status](https://api.travis-ci.org/domharrington/node-gitlog.svg)](http://travis-ci.org/domharrington/node-gitlog)\n[![dependency status](https://david-dm.org/domharrington/node-gitlog.svg)](https://david-dm.org/domharrington/node-gitlog)\n\n## Installation\n\n     npm install gitlog --save\n\n## Usage\n\n```js\nconst gitlog = require('gitlog');\n\nconst options =\n    { repo: __dirname + '/test-repo-folder'\n    , number: 20\n    , author: 'Dom Harrington'\n    , fields:\n      [ 'hash'\n      , 'abbrevHash'\n      , 'subject'\n      , 'authorName'\n      , 'authorDateRel'\n      ]\n    , execOptions:\n      { maxBuffer: 1000 * 1024\n      }\n    };\n\n// Asynchronous (with Callback)\ngitlog(options, function(error, commits) {\n  // Commits is an array of commits in the repo\n  console.log(commits)\n});\n\n// Synchronous\nlet commits = gitlog(options);\nconsole.log(commits);\n```\n\n## Options\n\nSee [git log](http://git-scm.com/docs/git-log)\n\n### repo\nThe location of the repo, required field.\n\n### number\nThe number of commits to return, defaults to 10.\n\n### since/after\nShow commits more recent than a specific date.\n\n### until/before\nShow commits older than a specific date.\n\n### author/committer\nLimit the commits output to ones with author/committer header lines that match the specified pattern.\n\n### nameStatus\nBelow fields was returned from the log:\n\n- files - changed files names (array)\n- status - changed files status (array)\n\nThis option is enabled by default.\n\n### findCopiesHarder\nMuch more likely to set status codes to 'C' if files are exact copies of each other.\n\nThis option is disabled by default.\n\n### all\nFind commits on all branches instead of just on the current one.\n\nThis option is disabled by default.\n\n### branch ([revision range](https://git-scm.com/docs/git-log#git-log-ltrevisionrangegt))\nShow only commits in the specified branch or revision range. \n\nBy default uses the current branch and defaults to `HEAD` (i.e. the whole history leading to the current commit).\n\n### execOptions\n\nType: `Object`\n\nSpecify some options to be passed to the [.exec()](http://nodejs.org/api/child_process.html#child_process_child_process_exec_command_options_callback) method:\n\n- `cwd` String *Current working directory of the child process*\n- `env` Object *Environment key-value pairs*\n- `setsid` Boolean\n- `encoding` String *(Default: 'utf8')*\n- `timeout` Number *(Default: 0)*\n- `maxBuffer` Number *(Default: 200\\*1024)*\n- `killSignal` String *(Default: 'SIGTERM')*\n\n### optional fields\nAn array of fields to return from the log, here are the possible options:\n\n- hash - the long hash of the commit e.g. 7dd0b07625203f69cd55d779d873f1adcffaa84a\n- abbrevHash - the abbreviated commit hash e.g. 7dd0b07\n- treeHash - the tree hash of the commit\n- abbrevTreeHash - the abbreviated commit hash\n- parentHashes - the parent hashes\n- abbrevParentHashes - the abbreviated parent hashes\n- authorName - author name of the commit\n- authorEmail - author email of the commit\n- authorDate - author date of the commit\n- authorDateRel - relative author date of the commit\n- committerName - committer name\n- committerEmail - committer email\n- committerDate - committer date\n- committerDateRel - relative committer date\n- subject - commit message (first line)\n- body - commit body\n- rawBody - raw body (subject + body)\n\nDefaults to 'abbrevHash', 'hash', 'subject' and 'authorName'.\n\n## How it works\n\nThis module works by executing a child process (using `child_process.exec()`) to the `git` executable, then parsing the stdout into commits. This is done using the `--pretty` command line option which allows you to provide a custom formatter to `git log`. To enable easy parsing the format is delimited by a tab (`\\t`) character.\n\n## Example\n```javascript\n  { hash: '6a7ef5e3b3d9c77743140443c8f9e792b0715721',\n    abbrevHash: '6a7ef5e',\n    treeHash: 'f1bf51b15b48a00c33727f364afef695029864c0',\n    abbrevTreeHash: 'f1bf51b',\n    parentHashes: 'cfe06dbdb8d0a193640977e016a04678f8f3b04f',\n    abbrevParentHashes: 'cfe06dbdb8d0a193640977e016a04678f8f3b04f',\n    authorName: 'Dom Harrington',\n    authorEmail: 'dom@harringtonxxxxx',\n    authorDate: '2015-04-09 09:39:23 +0100',\n    authorDateRel: '6 days ago',\n    committerName: 'Dom Harrington',\n    committerEmail: 'dom@harringtonxxxxx',\n    committerDate: 'Thu Apr 9 09:39:23 2015 +0100',\n    committerDateRel: '6 days ago',\n    subject: '1.0.0',\n    status: [ 'M' ],\n    files: [ 'package.json' ] }\n```\n","_attachments":{},"license":"BSD"}