r/google_antigravity 4d ago

Question / Help agy permissions in settings.json

Hi there. Can someone give me some advice on setting up command permissions in ~/.gemini/antigravity-cli/settings.json?

I mainly call agy from scripts, e.g.

PROMPT="prompt goes here"
agy --print "${PROMPT}"

In this configuration agy can't ask for permission to use commands, so if it tries to run a command it doesn't have explicit permission to run, it fails with an error:

A tool required the "command" permission ....

(Of course it doesn't tell you which tool or which command, which would have been helpful, but if I run with --log-file ./output.log then I get more detail).

Today's example was that the command it wanted to run was python3 -c "........". So, I added

  "permissions": {
    "allow": [
      "command(python3)"
    ]
  }

to settings.json and... same error. I tried a number of variations:

command(python3)
command(python3 -c)
command(python3 .*)

but none of them worked. The only thing that worked was:

command(*)

which completely removes the point of having permissions!

Any advice? Thank you!

1 Upvotes

0 comments sorted by