GitIgnore

object GitIgnore
Companion
class
trait Product
trait Mirror
class Object
trait Matchable
class Any

Type members

Classlikes

case object Abstain extends Vote
final case class AnyDirectoryPattern(gitPattern: String) extends Pattern

Matches any directories chain of the path.

Matches any directories chain of the path.

final case class AnyNamePattern(gitPattern: String) extends Pattern

Matches any single segment of the path.

Matches any single segment of the path.

final case class AnyPathPattern(gitPattern: String) extends Pattern

Matches any segments chain of the path.

Matches any segments chain of the path.

final case class AnyPrefixPattern(gitPattern: String) extends Pattern

Matches any initial segments prefix of the path.

Matches any initial segments prefix of the path.

final case class DirectoryPrefixPattern(gitPattern: String) extends Pattern

Matches initial directories prefix of the path.

Matches initial directories prefix of the path.

final case class GlobMatcher(gitPattern: String) extends Matcher

Matches path using a Git pattern compiled as a Glob.Pattern.

Matches path using a Git pattern compiled as a Glob.Pattern.

case class Ignore(position: Int) extends Vote
final case class LiteralMatcher(gitPattern: String) extends Matcher

Matches path literally with Git pattern.

Matches path literally with Git pattern.

sealed trait Matcher

Matches path against the Git pattern.

Matches path against the Git pattern.

Each method returns the furthest matched position, or -1 if not matched at all.

Companion
object
object Matcher

Re-usable matcher instance.

Re-usable matcher instance.

Companion
class
final case class Negate(nestedPattern: Pattern) extends Pattern

Reverts match, if any, of the nested pattern.

Reverts match, if any, of the nested pattern.

sealed trait Pattern

Internal model of the path pattern.

Internal model of the path pattern.

case class Unignore(position: Int) extends Vote
sealed trait Vote
Companion
object
object Vote
Companion
class

Inherited types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Inherited from
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Inherited from
Mirror

Value members

Concrete methods

final def apply(gitPattern: String): GitIgnore

Create GitIgnore from a single well-formed pattern.

Create GitIgnore from a single well-formed pattern.

final def parse(gitIgnore: String): GitIgnore

Parse .gitignore file content into GitIgnore instance.

Parse .gitignore file content into GitIgnore instance.

final def parseGitIgnore(gitIgnore: String): List[String]

Parse .gitignore file content and return sequence of patterns.

Parse .gitignore file content and return sequence of patterns.

final def parseGitPattern(p: String): Pattern

Parse single Git pattern into internal representation.

Parse single Git pattern into internal representation.