Rebase.init Async

Rebase.init(repo, branch, upstream, onto, options).then(function(remote) {
  // Use remote
});

Initializes a rebase

Parameters Type  
repo Repository The repository to perform the rebase
branch AnnotatedCommit The terminal commit to rebase, or NULL to rebase the current branch
upstream AnnotatedCommit The commit to begin rebasing from, or NULL to rebase all reachable commits
onto AnnotatedCommit The branch to rebase onto, or NULL to rebase onto the given upstream
options RebaseOptions Options to specify how rebase is performed, or NULL
Returns  
Remote  

Rebase.open Async

Rebase.open(repo, options).then(function(remote) {
  // Use remote
});

Opens an existing rebase that was previously started by either an invocation of Rebase.open or by another client.

Parameters Type  
repo Repository The repository that has a rebase in-progress
options RebaseOptions Options to specify how rebase is performed
Returns  
Remote  

Rebase#abort Async

rebase.abort().then(function(result) {
  // Use result
});
Returns  
Number Zero on success; GIT_ENOTFOUND if a rebase is not in progress,
-1 on other errors.  

Rebase#commit Async

rebase.commit(author, committer, message_encoding, message).then(function(oid) {
  // Use oid
});
Parameters Type  
author Signature The author of the updated commit, or NULL to keep the author from the original commit
committer Signature The committer of the rebase
message_encoding String The encoding for the message in the commit, represented with a standard encoding name. If message is NULL, this should also be NULL, and the encoding from the original commit will be maintained. If message is specified, this may be NULL to indicate that “UTF-8” is to be used.
message String The message for this commit, or NULL to use the message from the original commit.
Returns  
Oid  

Rebase#finish Sync

var result = rebase.finish(signature);
Parameters Type  
signature Signature The identity that is finishing the rebase (optional)
Returns  
Number Zero on success; -1 on error

Rebase#inmemoryIndex Sync

var result = rebase.inmemoryIndex(index);
Parameters Type  
index Index  
Returns  
Number  

Rebase#next Async

rebase.next().then(function(rebaseOperation) {
  // Use rebaseOperation
});
Returns  
RebaseOperation  

Rebase#ontoId Sync

var oid = rebase.ontoId();
Returns  
Oid The onto id

Rebase#ontoName Sync

var string = rebase.ontoName();
Returns  
String The onto ref name

Rebase#operationByIndex Sync

var rebaseOperation = rebase.operationByIndex(idx);
Parameters Type  
idx Number The index of the rebase operation to retrieve
Returns  
RebaseOperation The rebase operation or NULL if idx was out of bounds

Rebase#operationCurrent Sync

var result = rebase.operationCurrent();
Returns  
Number The index of the rebase operation currently being applied.

Rebase#operationEntrycount Sync

var result = rebase.operationEntrycount();
Returns  
Number The number of rebase operations in total

Rebase#origHeadId Sync

var oid = rebase.origHeadId();
Returns  
Oid The original HEAD id

Rebase#origHeadName Sync

var string = rebase.origHeadName();
Returns  
String The original HEAD ref name