From 12dfced5dfde458e6ee8f5756cfeed3683f93655 Mon Sep 17 00:00:00 2001 From: jlp-craigmorten Date: Sun, 19 Nov 2023 22:19:50 +0000 Subject: [PATCH] fix: don't try to write db file if already exists --- package.json | 2 +- src/macOS/setup.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 20d30d2..5a25bbd 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@guidepup/setup", - "version": "0.11.1", + "version": "0.11.2", "description": "Setup your environment for screen-reader automation.", "main": "lib/index.js", "typings": "lib/index.d.ts", diff --git a/src/macOS/setup.ts b/src/macOS/setup.ts index fba16d5..8a669af 100644 --- a/src/macOS/setup.ts +++ b/src/macOS/setup.ts @@ -12,6 +12,7 @@ import { logInfo } from "../logging"; import { ERR_MACOS_REQUIRES_MANUAL_USER_INTERACTION } from "../errors"; import { enableDoNotDisturb } from "./enableDoNotDisturb"; import { record } from "./record"; +import { enabledDbFile } from "./isAppleScriptControlEnabled/enabledDbFile"; const isCi = process.argv.includes("--ci"); const isRecorded = process.argv.includes("--record"); @@ -39,7 +40,7 @@ export async function setup(): Promise { await enableDoNotDisturb(); } - if (!isSipEnabled()) { + if (!isSipEnabled() && !(await enabledDbFile())) { writeDatabaseFile(); return;