cli-whatsapp 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/src/config/index.ts +5 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cli-whatsapp",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "A lightweight, fast, terminal-first WhatsApp client. Read, search, send, media, groups, and live notifications — from your terminal.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -45,4 +45,4 @@
|
|
|
45
45
|
"@types/qrcode-terminal": "^0.12.2",
|
|
46
46
|
"typescript": "^5.6.0"
|
|
47
47
|
}
|
|
48
|
-
}
|
|
48
|
+
}
|
package/src/config/index.ts
CHANGED
|
@@ -3,12 +3,13 @@ import { join, resolve } from 'node:path';
|
|
|
3
3
|
import { existsSync, mkdirSync, readFileSync, writeFileSync } from 'node:fs';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
* All persistent state lives under a single base directory so
|
|
7
|
-
*
|
|
8
|
-
*
|
|
6
|
+
* All persistent state lives under a single base directory so it's easy to back
|
|
7
|
+
* up or wipe. Defaults to ~/.cli-whatsapp in the user's home — a stable location
|
|
8
|
+
* that survives package updates (never inside node_modules). Override with
|
|
9
|
+
* WA_HOME (e.g. for tests or a portable install).
|
|
9
10
|
*/
|
|
10
11
|
export const BASE_DIR = resolve(
|
|
11
|
-
process.env.WA_HOME ?? join(
|
|
12
|
+
process.env.WA_HOME ?? join(homedir(), '.cli-whatsapp'),
|
|
12
13
|
);
|
|
13
14
|
|
|
14
15
|
export const PATHS = {
|