{"version":"2.1.287","anchor":"cloud-sessions-run-hooks-in-an-empty-folder-hooks-can-opt-i","canonical_anchor":"cloud-sessions-run-hooks-in-an-empty-folder-hooks-can-opt-i","heading":"Hooks in cloud sessions start in an empty folder unless marked to run on your device","tier":"use","area":"Hooks","url":"https:\/\/changelogs.core-directive.com\/v\/2.1.287\/e\/cloud-sessions-run-hooks-in-an-empty-folder-hooks-can-opt-i","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.287","markdown":"### Hooks in cloud sessions start in an empty folder unless marked to run on your device\n\nIn cloud sessions hooks start in an empty folder; mark one \"cloud\": \"device\" in your user settings to run it in the project\n\n**Unclear.** It is not clear whether this behaviour is switched on for everyone yet.\n\n**What**\n\nHooks are commands you configure to run automatically at certain moments. For cloud sessions (sessions running on Anthropic's servers, started with `--cloud`), Claude Code now says that hooks start in an empty folder rather than in your project. To have a hook run in the project, mark it `\"cloud\": \"device\"` in your user settings.\n\nIf your machine does not answer, or is not recognized as a trusted device, Claude Code says it is not running this machine's hooks for the cloud session and points you to `claude --cloud`. A shorter version of the empty-folder hint also appears next to a hook.\n\n**Why**\n\nA hook that needs your project files will not find them in a cloud session unless you mark it to run on your own device.\n\n- Area: Hooks\n- Names: `cloud`\n- Tier: Use it now\n- Useful: 3\/5\n- Signal: 3\/5"}