Voice-to-text dictation app with local (Nvidia Parakeet/Whisper) and cloud models (BYOK). Privacy-first and available cross-platform.
JavaScript aianthropiccross-platformgeminigroqlinuxmacosnvidiaopen-sourceopenaiparakeetspeech-to-texttranscribewhisperwindows
cleanup: added cleanup script (npm run clean)
Gabriel Stein116ed643f37a
diff --git a/cleanup.js b/cleanup.jsnew file mode 100644index 000000000..d69f04864--- /dev/null+++ b/cleanup.js@@ -0,0 +1,51 @@+const path = require("path");+const fs = require("fs");+const os = require("os");++// Clean build directories+console.log("🧹 Cleaning build directories...");+const dirsToClean = ["dist/", "src/dist/", "node_modules/.cache/"];++dirsToClean.forEach((dir) => {+ if (fs.existsSync(dir)) {+ fs.rmSync(dir, { recursive: true, force: true });+ console.log(`✅ Cleaned: ${dir}`);+ } else {+ console.log(`ℹ️ Directory not found: ${dir}`);+ }+});++// Clean development database+console.log("🗄️ Cleaning development database...");+try {+ // Use the same logic as the database.js file to determine the user data path+ const userDataPath =+ process.platform === "darwin"+ ? path.join(os.homedir(), "Library", "Application Support", "open-wispr")+ : process.platform === "win32"+ ? path.join(process.env.APPDATA || os.homedir(), "open-wispr")+ : path.join(os.homedir(), ".config", "open-wispr");++ const devDbPath = path.join(userDataPath, "transcriptions-dev.db");+ const prodDbPath = path.join(userDataPath, "transcriptions.db");++ // Clean development database+ if (fs.existsSync(devDbPath)) {+ fs.unlinkSync(devDbPath);+ console.log(`✅ Development database cleaned: ${devDbPath}`);+ } else {+ console.log("ℹ️ No development database found to clean");+ }++ // Clean production database+ if (fs.existsSync(prodDbPath)) {+ fs.unlinkSync(prodDbPath);+ console.log(`✅ Production database cleaned: ${prodDbPath}`);+ } else {+ console.log("ℹ️ No production database found to clean");+ }+} catch (error) {+ console.error("❌ Error cleaning database files:", error.message);+}++console.log("✨ Cleanup completed successfully!");diff --git a/package.json b/package.jsonindex 9e0e9d560..fc1532836 100644--- a/package.json+++ b/package.json@@ -19,7 +19,8 @@"pack": "npm run build:renderer && electron-builder --dir","dist": "npm run build:renderer && electron-builder","lint": "cd src && eslint .",- "preview": "cd src && vite preview"+ "preview": "cd src && vite preview",+ "clean": "node cleanup.js"},"keywords": ["dictation",