I am attempting to add this to my `pants.toml`, bu...
# general
e
I am attempting to add this to my
pants.toml
, but it seems
$HOME
is not expanded. Halp?
Copy code
[docker]
run_args = [
  "-v $HOME/.config/gcloud:/gcp/config:ro",
  "--env GOOGLE_APPLICATION_CREDENTIALS=/gcp/config/application_default_credentials.json",
]
1
Copy code
docker: Error response from daemon: create $HOME/.config/gcloud: "$HOME/.config/gcloud" includes invalid characters for a local volume name, only "[a-zA-Z0-9][a-zA-Z0-9_.-]" are allowed. If you intended to pass a host directory, use absolute path.
but obviously I don't want to use an absolute path if this will work for my teammates...
~
doesn't work either, for the record
a
Try
%(env.HOME)s
• `%(homedir)s`: equivalent to
$HOME
or
~
e
ah, awesome. Works! thanks very much.
a
That will also work
You're welcome, it's not obvious at all, though makes sense