Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

dev/bazel command

equivalent non-bazel command

./dev build

make build

./dev build short

make buildshort

./dev build pkg/sql/...

make build PKG=./pkg/sql/...

./dev test

make test

./dev test pkg/sql/parser --filter TestParse

make test PKG=./pkg/sql/parser TESTS=TestParse

./dev bench pkg/sql/parser --filter BenchmarkParse

make bench PKG=./pkg/sql/parser BENCHES=BenchmarkParse

./dev builder

build/builder.sh

./dev testlogic base --files=fk --subtests=20042 --config=local

make testbaselogic FILES=fk SUBTESTS=20042 TESTCONFIG=local

Add build --define gotags=bazel,gss,X,Y to .bazelrc.user, then running dev

make ... TAGS=X,Y

General dev tips

  • Since ./dev always builds dev unconditionally before doing anything else, that means there will be a slight delay before your build or test actually begins. Due to caching this pause should never be too long, but if it’s annoying you or you’ve found a way to thrash the cache, you can do:

    Code Block
    ./dev build dev

    This will place a binary at bin/dev and if bin is in your PATH, you can then omit the leading ./. In this document we’ll always spell ./dev with the leading ./ to squash ambiguity and for ease of copy-pasting.

...