Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/commit.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ Commit.prototype.getParents = function(limit, callback) {
* Retrieve the commit"s parent shas.
*
* @param {Function} callback
* @return {Array<Oids>} array of oids
* @return {Array<Oid>} array of oids
*/
Commit.prototype.parents = function() {
var result = [];
Expand Down
2 changes: 1 addition & 1 deletion lib/convenient_hunks.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,4 @@ var oldStart = ConvenientHunk.prototype.oldStart;
*/
ConvenientHunk.prototype.oldStart = oldStart;

exports.module = ConvenientHunk;
module.exports = ConvenientHunk;
12 changes: 6 additions & 6 deletions lib/convenient_patch.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ var ConvenientPatch = NodeGit.ConvenientPatch;

var oldFile = ConvenientPatch.prototype.oldFile;
/**
* Old name of the file
* @return {String}
* Old attributes of the file
* @return {DiffFile}
*/
ConvenientPatch.prototype.oldFile = oldFile;

var newFile = ConvenientPatch.prototype.newFile;
/**
* New name of the file
* @return {String}
* New attributes of the file
* @return {DiffFile}
*/
ConvenientPatch.prototype.newFile = newFile;

Expand Down Expand Up @@ -129,6 +129,6 @@ var isConflicted = ConvenientPatch.prototype.isConflicted;
* Is this a conflicted patch?
* @return {Boolean}
*/
ConvenientPatch.prototype.isConflicted = isConflicted;
ConvenientPatch.prototype.isConflicted = isConflicted;

exports.module = ConvenientPatch;
module.exports = ConvenientPatch;
40 changes: 40 additions & 0 deletions lib/diff_file.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
var NodeGit = require("../");

var DiffFile = NodeGit.DiffFile;

var flags = DiffFile.prototype.flags;
/**
* Returns the file's flags
* @return {Number}
*/
DiffFile.prototype.flags = flags;

var id = DiffFile.prototype.id;
/**
* Returns the file's Oid
* @return {Oid}
*/
DiffFile.prototype.id = id;

var mode = DiffFile.prototype.mode;
/**
* Returns the file's mode
* @return {Number}
*/
DiffFile.prototype.mode = mode;

var path = DiffFile.prototype.path;
/**
* Returns the file's path
* @return {String}
*/
DiffFile.prototype.path = path;

var size = DiffFile.prototype.size;
/**
* Returns the file's size
* @return {Number}
*/
DiffFile.prototype.size = size;

module.exports = DiffFile;
22 changes: 11 additions & 11 deletions lib/repository.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Object.defineProperty(Repository.prototype, "openIndex", {
* @param {bool} force Overwrite branch if it exists
* @param {Signature} signature Identity to use to populate reflog
* @param {String} logMessage One line message to be appended to the reflog
* @return {Ref}
* @return {Reference}
*/
Repository.prototype.createBranch =
function(name, commit, force) {
Expand Down Expand Up @@ -86,8 +86,8 @@ Repository.discover = function(startPath, acrossFs, ceilingDirs, callback) {
* Look up a refs's commit.
*
* @async
* @param {String|Ref} name Ref name, e.g. "master", "refs/heads/master"
* or Branch Ref
* @param {String|Reference} name Ref name, e.g. "master", "refs/heads/master"
* or Branch Ref
* @return {Commit}
*/
Repository.prototype.getReferenceCommit = function(name, callback) {
Expand All @@ -108,9 +108,9 @@ Repository.prototype.getReferenceCommit = function(name, callback) {
* Look up a branch. Alias for `getReference`
*
* @async
* @param {String|Ref} name Ref name, e.g. "master", "refs/heads/master"
* or Branch Ref
* @return {Ref}
* @param {String|Reference} name Ref name, e.g. "master", "refs/heads/master"
* or Branch Ref
* @return {Reference}
*/
Repository.prototype.getBranch = function(name, callback) {
return this.getReference(name, callback);
Expand All @@ -120,7 +120,7 @@ Repository.prototype.getBranch = function(name, callback) {
* Look up a branch's most recent commit. Alias to `getReferenceCommit`
*
* @async
* @param {String|Ref} name Ref name, e.g. "master", "refs/heads/master"
* @param {String|Reference} name Ref name, e.g. "master", "refs/heads/master"
* or Branch Ref
* @return {Commit}
*/
Expand All @@ -142,8 +142,8 @@ Repository.prototype.getCurrentBranch = function() {
* Lookup the reference with the given name.
*
* @async
* @param {String|Ref} name Ref name, e.g. "master", "refs/heads/master"
* or Branch Ref
* @param {String|Reference} name Ref name, e.g. "master", "refs/heads/master"
* or Branch Ref
* @return {Reference}
*/
Repository.prototype.getReference = function(name, callback) {
Expand Down Expand Up @@ -728,8 +728,8 @@ Repository.prototype.fetchAll = function(
/**
* Merge a branch onto another branch
*
* @param {String|Ref} to
* @param {String|Ref} from
* @param {String|Reference} to
* @param {String|Reference} from
* @param {Signature} signature
* @param {Merge.PREFERENCE} mergePreference
* @param {MergeOptions} mergeOptions
Expand Down