1.0.0 • Published 10 years ago

git-object-commit v1.0.0

Weekly downloads
6
License
MIT
Repository
github
Last release
10 years ago

git-object-commit

git commit objects as javascript objects.

commit objects are immutable once created.

var Buffer = require('buffer').Buffer
  , commit = require('git-object-commit')

var b = commit.create(new Buffer(...))

b = commit.read(<some git buffer>)

API

commit.read() -> Commit

read a commit from some git buffer data.

commit.create(author, tree, message, parent, committer) -> Commit

create a commit from some source data.

all fields (save for message) may be arrays.

Commit methods

  • author() -> string | undefined
  • authors() -> string, ... | []
  • committer() -> string | undefined
  • committers() -> string, ... | []
  • parent() -> string | undefined
  • parents() -> string, ... | []
  • tree() -> string | undefined
  • trees() -> string, ... | []
  • message() -> string
  • attr(attribute) -> string, ... | []

License

MIT

1.0.0

10 years ago

0.0.7

10 years ago

0.0.6

11 years ago

0.0.5

11 years ago

0.0.4

11 years ago

0.0.3

11 years ago

0.0.2

11 years ago

0.0.1

11 years ago