Xgit v0.1.3 Xgit.Plumbing.LsFiles.Stage View Source
Show information about files in the index.
Analogous to
git ls-files --stage
.
Link to this section Summary
Functions
Retrieves information about files in the working tree as described by the index file.
Link to this section Types
reason()
View Source
reason() ::
:invalid_repository
| Xgit.Repository.WorkingTree.ParseIndexFile.from_iodevice_reason()
reason() :: :invalid_repository | Xgit.Repository.WorkingTree.ParseIndexFile.from_iodevice_reason()
Reason codes that can be returned by run/1
.
Link to this section Functions
run(repository)
View Source
run(repository :: Xgit.Repository.t()) ::
{:ok, entries :: [Xgit.Core.DirCache.Entry.t()]}
| {:error, reason :: reason()}
run(repository :: Xgit.Repository.t()) :: {:ok, entries :: [Xgit.Core.DirCache.Entry.t()]} | {:error, reason :: reason()}
Retrieves information about files in the working tree as described by the index file.
Parameters
repository
is the Xgit.Repository
(PID) to search for the object.
Return Value
{:ok, entries}
. entries
will be a list of Xgit.Core.DirCache.Entry
structs
in sorted order.
{:error, :invalid_repository}
if repository
doesn't represent a valid
Xgit.Repository
process.
{:error, :bare}
if repository
doesn't have a working tree.
{:error, reason}
if the index file for repository
isn't valid. (See
Xgit.Repository.WorkingTree.ParseIndexFile.from_iodevice/1
for possible
reason codes.)