Have you ever kicked off an agent task that you suspect will be long running, and gotten up to get a cup of coffee, stopped to peer through the curtains and marvel at the sun, and gotten a snack, only to find out that when you get back to your computer, your agent task has been finished for many minutes, leaving you far behind the output of your friendly neighborhood 10x developer? Never fear, agent hooks are here! New in version 1.109.3 in VSCode, there are a number of triggers you can make use of to do some pretty cool things.

I’ll let you figure out what the cool things are, I’m going to show you a dumb thing! Presenting the humble stop trigger that fires when an agent session ends and can run a command in the terminal.

Go ahead and create a new file in .github/hooks/stop.json and download your favorite sound file, and voila!

{
  "hooks": {
    "Stop": [
      {
        "type":"command",
        "command": "afplay ~/Downloads/im-tired-of-this-grandpa-thats-too-damn-bad.mp3"
      }
    ],
  }
}

And for your viewing consideration.


<
Blog Archive
Archive of all previous blog posts
>
Next Post
Copilot plugins!