Skip to content

Commit

Permalink
Merge pull request #20 from lunny/lunny/islink_for_treeentry
Browse files Browse the repository at this point in the history
Check if files are a symlink (#20)
  • Loading branch information
tboerger committed Dec 22, 2016
2 parents 06ee0cf + d97cb0f commit 43c086d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tree_entry.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ func (te *TreeEntry) IsDir() bool {
return te.mode == EntryModeTree
}

// IsLink if the entry is a symlink
func (te *TreeEntry) IsLink() bool {
return te.mode == EntryModeSymlink
}

// Blob retrun the blob object the entry
func (te *TreeEntry) Blob() *Blob {
return &Blob{
Expand Down

0 comments on commit 43c086d

Please sign in to comment.