pants
scalable build system for monorepos
TLDR
SYNOPSIS
pants [options] goal [targets...]
DESCRIPTION
pants is a scalable build system for monorepos. It supports Python, Go, Java, Scala, Shell, and Docker.Target notation uses colons to separate path and target name. Double colons (::) match all targets recursively.Caching and memoization make repeated builds fast. Remote caching enables team-wide build sharing.Dependency inference automatically discovers imports. Explicit dependencies can be declared in BUILD files.Fine-grained invalidation rebuilds only affected targets. Concurrent execution uses available cores.
PARAMETERS
list
List matching targets.test
Run tests.fmt
Format source files.lint
Run linters.check
Type check.package
Build package.run
Run executable target.dependencies
Show dependencies.repl
Start interactive REPL.--changed-since REF
Only changed files.-l, --level LEVEL
Log level.
CAVEATS
Requires BUILD files defining targets. Initial setup has learning curve. Large codebase initial run can be slow.
HISTORY
Pants was originally developed at Twitter around 2011. Version 2.x was a ground-up rewrite focusing on Python ergonomics. Now maintained by Toolchain as an open-source project.
