I almost certainly missed it, but how does one inv...
# general
p
I almost certainly missed it, but how does one invoke pants on the commandline? That is to say
Copy code
pants test ::
What does
::
represent?
w
That quote may not be precise, as it's more like, run test on all test-able targets, I guess....
As an example of running on a specific target, this is how I test my REST api
./pants test apigateway:tests
p
I see. So it is kind of like
Copy code
pants test src/root/some/path/in/root/:target
?
e
Yes.
*
->
:
, and
**
->
::
p
Pardon my ignorance... I don't exactly follow that. Any chance you could explain that?
e
Since
*
is taken by shells and
:
should feel natural
These are globs for target addresses
p
should feel natural
It doesn't.
e
a/b:c pick an address
p
What is a shell equivalent with
*
?
e
a/b: picks all addresses in that dir
a/b:: picks all addresses in that dir and descendants
The easiest way to see is using
pants list
That will list the target address verbatim if literal or else expand for globs.
p
Oh! Okay.
Copy code
:: - Everything:ReallyEverything
foo: - ONLY thing in foo like no targets in sub-directories
foo:: - Every target in foo/ no limit of depth
Kind of similar to
*
in a gitignore format.
e
Just like * and ** in most shells
p
I see.
Thank you.
h
We can't use * because the shell would expand it, so we had to pick something shell-neutral, hence :