Presubmit.Paths (presubmit v0.2.2)

Copy Markdown View Source

Path patterns for the conventional directories, anchored so they work at the repository root and inside umbrella apps or subdirectory projects (apps/foo/lib/, services/bar/test/).

Summary

Functions

Elixir source files under lib/, priv/, or test/ anywhere.

Library source: lib/ at the root or under any directory.

Elixir files Mix would compile from lib/ at the root or under any directory: the stand-in for Presubmit.MixFile.shipped_source/1 in a tree with no mix.exs.

Every mix.lock in the tree, excluding vendored dependencies.

Migration files under any migrations/ directory.

Every mix.exs in the tree, excluding vendored dependencies.

Tests: test/ at the root or under any directory.

Vendored dependency directories, which are never part of the project.

Functions

elixir_source()

@spec elixir_source() :: Regex.t()

Elixir source files under lib/, priv/, or test/ anywhere.

lib()

@spec lib() :: Regex.t()

Library source: lib/ at the root or under any directory.

lib_source()

@spec lib_source() :: Regex.t()

Elixir files Mix would compile from lib/ at the root or under any directory: the stand-in for Presubmit.MixFile.shipped_source/1 in a tree with no mix.exs.

lock_files()

@spec lock_files() :: Regex.t()

Every mix.lock in the tree, excluding vendored dependencies.

migrations()

@spec migrations() :: Regex.t()

Migration files under any migrations/ directory.

mix_files()

@spec mix_files() :: Regex.t()

Every mix.exs in the tree, excluding vendored dependencies.

test()

@spec test() :: Regex.t()

Tests: test/ at the root or under any directory.

vendored?(path)

@spec vendored?(String.t()) :: boolean()

Vendored dependency directories, which are never part of the project.