---
title: "Discussion on \"Run AI coding agents overnight on a MacBook\" | Hashnode"
description: "Discussion on \"Run AI coding agents overnight on a MacBook\". A checklist for one night alone: the closed lid, power, network, the allow rules each agent needs, and how the agent ends the session."
url: "https://hashnode.com/posts/run-ai-coding-agents-overnight-on-a-macbook/6b05b2c16e35475ffbb6a737"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Run AI coding agents overnight on a MacBook](https://keepmacawake.hashnode.dev/run-ai-coding-agents-overnight-on-a-macbook?utm_source=hashnode&utm_medium=feed)

A checklist for one night alone: the closed lid, power, network, the allow rules each agent needs, and how the agent ends the session.

17h ago · 10 min read · keepmacawake.hashnode.dev  
Read the article

-   [#macos](https://hashnode.com/tag/macos)
-   [#ai](https://hashnode.com/tag/ai)
-   [#developer-tools](https://hashnode.com/tag/developer-tools)
-   [#claude-code](https://hashnode.com/tag/claude-code)
-   [#productivity](https://hashnode.com/tag/productivity)

## Written by

[Keep Mac Awake](https://hashnode.com/@keepmacawake)

@keepmacawake

  
[View profile](https://hashnode.com/@keepmacawake)

Guides to keeping a MacBook awake with the lid closed: pmset, sleep, agents and long jobs.

Keep Mac Awake is a Mac menu bar app and command line tool that keeps a MacBook awake with the lid closed for a session you start. These guides explain Mac sleep, pmset and long jobs with the lid closed, and first appear on keepmacawake.com.

## Responses 2

Markdown supported · ⌘↵ to post

[Halfcycle](https://hashnode.com/@halfcycle)

[8h ago](https://hashnode.com/posts/run-ai-coding-agents-overnight-on-a-macbook/6b05b2c16e35475ffbb6a737/comment/6b062aec42ba5140abe03ad3)

Good checklist. The step that decides whether the night was worth it is what the agent does when it reaches a decision only a person should make. In Halfcycle the build waits at the phase a person signs off rather than guessing, so you wake up to work waiting for approval, not work to undo. Does your agent guide cover how to handle a question that comes up at 3am?

[Keep Mac Awake](https://hashnode.com/@keepmacawake)

[1h ago](https://hashnode.com/posts/run-ai-coding-agents-overnight-on-a-macbook/6b05b2c16e35475ffbb6a737/comment/6b062aec42ba5140abe03ad3#reply-6b0699483797c3da91d9a51d)

Partly, in step 3. A prompt nobody answers stops a run without an error, so the guide says to allow only what the task needs in advance (`--allowedTools` or `permissions.allow` in Claude Code, narrowed where you can, such as `Bash(npm test *)`; `workspace-write` in Codex) and to keep the broad modes for machines that can take the damage. It covers the permission side, not a design where the build waits at a sign-off phase. We make Keep Mac Awake, so the rest of the guide is about keeping the Mac itself awake through the night.
