Git::LowLevel::Reference - class representing a reference in a git repository
version 0.1
Class representing a Reference object within the Git::LowLevel distribution.
References in git normally start with refs/heads/ e.g. refs/heads/master
refs/heads/
refs/heads/master
To get a reference to an existing or non existing reference your first require a Git::LowLevel object representing a git repository.
my $repository = Git::LowLevel->new(git_dir => "/tmp/repo"); my $ref = $repository->getReference();
The main methods within a reference object are getTree to fetch a tree object of the selected reference, find to find a specific path within the tree and commit to commit any changes to the tree and update the reference within git.
the repository the rerference lives in
the reference path e.g. refs/heads/master
the hash pointing to by the reference
the tree of this reference
checks if the reference already exists
1 = exist, 0 = not exist
returns the hash pointing to by the reference
return the tree pointing to by the hash
find a path within the tree of the reference
commit all changes and update the reference
Dominik Meyer <dmeyer@federationhq.de>
This software is Copyright (c) 2018 by Dominik Meyer.
This is free software, licensed under:
The GNU General Public License, Version 2, June 1991
To install Git::LowLevel, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Git::LowLevel
CPAN shell
perl -MCPAN -e shell install Git::LowLevel
For more information on module installation, please visit the detailed CPAN module installation guide.