# Last Window Quits

一款 macOS 实用工具，可在应用的最后一个窗口关闭后退出应用，并提供排除列表、延迟、活动日志和后台应用检测。

> 这是 OpenNavo 上 Last Window Quits 页面的 Markdown 版本，内容与网页相同： <https://opennavo.com/zh/apps/last-window-quits>

- **最新版本**: `1.1.6,2026,10`
- **开发者**: Lawand Dalatieh
- **主页**: <https://lawand.io/last-window-quits/>
- **分类**: [系统工具](https://opennavo.com/zh/categories/utilities)
- **安装**: `brew install --cask last-window-quits`
- **近 30 天安装**: 60
- **Homebrew**: 可以安装，应用会自行更新
- **下载地址**: <https://lawand.io/wp-content/uploads/2026/10/last-window-quits-1.1.6.zip>
- **SHA-256**: `56aaf1efcc3b3a9f10c6cf2ca7fdaccf4ae30deabe049b4f2012fc7293d06127`

SHA-256 只用来核对下载的文件是否完整，不代表安全认证。

## 安装与卸载内容

```json
[
  {
    "declaration": {
      "app": [
        "Last Window Quits.app"
      ],
      "target": "/Applications/Last Window Quits.app"
    },
    "phase": "install",
    "sources": [
      "Last Window Quits.app"
    ],
    "target": "/Applications/Last Window Quits.app",
    "type": "app"
  },
  {
    "declaration": {
      "zap": [
        {
          "trash": [
            "~/Library/Application Support/io.lawand.last-window-quits",
            "~/Library/HTTPStorages/io.lawand.last-window-quits",
            "~/Library/LaunchAgents/io.lawand.last-window-quits.plist",
            "~/Library/Preferences/io.lawand.last-window-quits.plist",
            "~/LWQ Debug Logs"
          ]
        }
      ]
    },
    "phase": "cleanup",
    "sources": [],
    "type": "zap"
  }
]
```

## 介绍

Last Window Quits 是一款 macOS 实用工具，会在应用最后一个窗口关闭时退出该应用，而不是让它继续运行。它适合希望窗口关闭后应用也自动退出的用户。

- 它可响应多种关闭窗口的方式，包括关闭按钮、`⌘W` 和菜单命令。
- 排除列表可指定应保持打开的应用。该工具也会检测 VPN 等后台应用，并让它们继续运行。
- 退出前会短暂等待，以免误关刚关闭启动画面的应用；默认延迟为 2 秒。
- 文本日志会记录窗口关闭和应用退出。该应用可设置为登录时启动、在后台运行，也可以暂停。

使用 `brew install --cask last-window-quits` 安装。Homebrew cask 会将 `Last Window Quits.app` 安装到 `/Applications`。开发者列出的支持范围为 macOS 10.13 或更高版本，并说明该应用免费。

在 macOS 15 Sequoia 上，系统偶尔可能无法通知应用窗口已关闭，因此应用有时仍会保持打开。开发者将此描述为罕见的 macOS 问题，并表示计划修复。

来源：[官方产品页面](https://lawand.io/last-window-quits/) · [Homebrew cask](https://raw.githubusercontent.com/Homebrew/homebrew-cask/HEAD/Casks/l/last-window-quits.rb)

## 系统要求

- 适用于 macOS 27, 26, 15, 14, 13, 12, 11 的版本 · 应用版本: 1.1.6,2026,10 · Intel · <https://github.com/homebrew/homebrew-cask/blob/HEAD/Casks/l/last-window-quits.rb> · 核查于 2026-12-02
  - <https://lawand.io/wp-content/uploads/2026/10/last-window-quits-1.1.6.zip>
  - SHA-256: `56aaf1efcc3b3a9f10c6cf2ca7fdaccf4ae30deabe049b4f2012fc7293d06127`
- 适用于 macOS 27, 26, 15, 14, 13, 12, 11 的版本 · 应用版本: 1.1.6,2026,10 · Apple 芯片 · <https://github.com/homebrew/homebrew-cask/blob/HEAD/Casks/l/last-window-quits.rb> · 核查于 2026-12-02
  - <https://lawand.io/wp-content/uploads/2026/10/last-window-quits-1.1.6.zip>
  - SHA-256: `56aaf1efcc3b3a9f10c6cf2ca7fdaccf4ae30deabe049b4f2012fc7293d06127`

## 卸载

- `brew uninstall --cask last-window-quits`

普通卸载会删除应用本身，设置和缓存会保留。

### 深度清理（可选）

- `brew uninstall --zap --cask last-window-quits`

`--zap` 还会删除 Homebrew 定义里列出的设置、缓存等文件，其中可能有其他应用共用的数据，删除后无法恢复；它也不保证没有任何残留。请先备份需要保留的数据；如要保留设置和缓存，请不要加 `--zap`。

普通卸载会删除应用本身，设置和缓存会保留。

- 文件和文件夹: `~/Library/Application Support/io.lawand.last-window-quits` — <https://github.com/homebrew/homebrew-cask/blob/HEAD/Casks/l/last-window-quits.rb> · 以上条目来自 Homebrew 定义，核查于 2026-12-02；它们只说明定义声明会删除什么，不代表你的 Mac 上都有。
- 文件和文件夹: `~/Library/HTTPStorages/io.lawand.last-window-quits` — <https://github.com/homebrew/homebrew-cask/blob/HEAD/Casks/l/last-window-quits.rb> · 以上条目来自 Homebrew 定义，核查于 2026-12-02；它们只说明定义声明会删除什么，不代表你的 Mac 上都有。
- 文件和文件夹: `~/Library/LaunchAgents/io.lawand.last-window-quits.plist` — <https://github.com/homebrew/homebrew-cask/blob/HEAD/Casks/l/last-window-quits.rb> · 以上条目来自 Homebrew 定义，核查于 2026-12-02；它们只说明定义声明会删除什么，不代表你的 Mac 上都有。
- 文件和文件夹: `~/Library/Preferences/io.lawand.last-window-quits.plist` — <https://github.com/homebrew/homebrew-cask/blob/HEAD/Casks/l/last-window-quits.rb> · 以上条目来自 Homebrew 定义，核查于 2026-12-02；它们只说明定义声明会删除什么，不代表你的 Mac 上都有。
- 文件和文件夹: `~/LWQ Debug Logs` — <https://github.com/homebrew/homebrew-cask/blob/HEAD/Casks/l/last-window-quits.rb> · 以上条目来自 Homebrew 定义，核查于 2026-12-02；它们只说明定义声明会删除什么，不代表你的 Mac 上都有。

## 资料与来源

- <https://opennavo.com/zh/apps/last-window-quits>
- <https://opennavo.com/zh/apps/last-window-quits/versions>
- <https://github.com/homebrew/homebrew-cask/blob/HEAD/Casks/l/last-window-quits.rb> · 核查于 2026-12-02
- <https://formulae.brew.sh/cask/last-window-quits>
