GitRepository class

Available Extensions

Properties

config Config
getter/setter pair
fs ↔ FileSystem
getter/setter pair
gitDir String
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
indexStorage IndexStorage
getter/setter pair
objStorage ObjectStorage
getter/setter pair
refStorage ReferenceStorage
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
workTree String
getter/setter pair

Methods

add(String pathSpec) Future<void>
addDirectoryToIndex(GitIndex index, String dirPath, {bool recursive = false}) Future<void>
addFileToIndex(GitIndex index, String filePath) Future<GitIndexEntry?>
addOrUpdateRemote(String name, String url) Future<GitRemoteConfig>
addRemote(String name, String url) Future<GitRemoteConfig>
branches() Future<List<String>>
canPush() Future<bool>
countTillAncestor(GitHash from, GitHash ancestor) Future<int?>
createBranch(String name, {GitHash? hash, bool overwrite = false}) Future<GitHash?>
currentBranch() Future<String?>
deleteBranch(String branchName) Future<GitHash?>
guessRemoteHead(String remoteName) Future<Reference?>
headCommit() Future<GitCommit?>
headHash() Future<GitHash?>
headTree() Future<GitTree?>
normalizePath(String path) String
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
numChangesToPush() Future<int?>
remoteBranch(String remoteName, String branchName) Future<Reference?>
remoteBranches(String remoteName) Future<List<Reference>>
removeRemote(String name) Future<GitRemoteConfig?>
resolveReference(Reference ref, {bool recursive = true}) Future<Reference?>
resolveReferenceName(ReferenceName refName) Future<Reference?>
rm(String pathSpec, {bool rmFromFs = true}) Future<void>
rmDirectoryFromIndex(GitIndex index, String dirPath, {bool recursive = false}) Future<void>
rmFileFromIndex(GitIndex index, String filePath) Future<GitHash?>
saveConfig() Future<void>
setBranchUpstreamTo(String branchName, GitRemoteConfig remote, String remoteBranchName) Future<BranchConfig>
setUpstreamTo(GitRemoteConfig remote, String remoteBranchName) Future<BranchConfig?>
toPathSpec(String path) String
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

findRootDir(String path, {FileSystem? fs}) String?
init(String path, {FileSystem? fs}) Future<void>
isValidRepo(String gitRootDir, {FileSystem? fs}) Future<bool>
load(String gitRootDir, {FileSystem? fs}) Future<GitRepository>