node

package
v0.3.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 23, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Node

type Node struct {
	Name     string
	Path     string
	IsFile   bool
	Children []*Node
}

Node - tree structure to record directory contents for a git branch This is used so that we can reconcile renames, deletes and copies and for example filter out a delete of a renamed file or similar. The tree is updated after every commit is processed.

func (*Node) AddFile

func (n *Node) AddFile(path string)

func (*Node) AddSubFile

func (n *Node) AddSubFile(fullPath string, subPath string)

func (*Node) DeleteFile

func (n *Node) DeleteFile(path string)

func (*Node) DeleteSubFile

func (n *Node) DeleteSubFile(fullPath string, subPath string)

func (*Node) FindFile

func (n *Node) FindFile(fileName string) bool

Returns true if it finds a single file with specified name

func (*Node) GetFiles

func (n *Node) GetFiles(dirName string) []string

Return a list of all files in a directory

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL