// Create a blob object to insert into a tree
ObjectId blobId = odi.insert(Constants.OBJ_BLOB,
message.getBytes(Constants.CHARACTER_ENCODING));
// Create a tree object to reference from a commit
TreeFormatter tree = new TreeFormatter();
tree.append("NEWBRANCH", FileMode.REGULAR_FILE, blobId);
ObjectId treeId = odi.insert(tree);
// Create a commit object
CommitBuilder commit = new CommitBuilder();
commit.setAuthor(author);