pi-notifi 0.1.2 → 0.1.4
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/README.md +1 -6
- package/index.ts +6 -1
- package/package.json +1 -2
- package/examples/notifi.json +0 -7
package/README.md
CHANGED
|
@@ -111,6 +111,7 @@ Configuration is read from the first valid JSON file that exists:
|
|
|
111
111
|
|
|
112
112
|
1. `<project>/.pi/notifi.json`
|
|
113
113
|
2. `~/.pi/agent/notifi.json`
|
|
114
|
+
3. `~/.pi/agent/extensions/notifi.json`
|
|
114
115
|
|
|
115
116
|
Example:
|
|
116
117
|
|
|
@@ -124,12 +125,6 @@ Example:
|
|
|
124
125
|
}
|
|
125
126
|
```
|
|
126
127
|
|
|
127
|
-
An example file is included at:
|
|
128
|
-
|
|
129
|
-
```text
|
|
130
|
-
examples/notifi.json
|
|
131
|
-
```
|
|
132
|
-
|
|
133
128
|
Available JSON fields:
|
|
134
129
|
|
|
135
130
|
| Field | Default | Description |
|
package/index.ts
CHANGED
|
@@ -103,7 +103,12 @@ const cacheHome = (): string => process.env.XDG_CACHE_HOME ?? join(process.env.H
|
|
|
103
103
|
const targetFile = (targetId: string): string => join(cacheHome(), "notifi", "targets", `${targetId}.json`);
|
|
104
104
|
|
|
105
105
|
const readConfigFile = async (cwd: string): Promise<NotifiFileConfig> => {
|
|
106
|
-
const
|
|
106
|
+
const home = process.env.HOME ?? "";
|
|
107
|
+
const paths = [
|
|
108
|
+
join(cwd, ".pi", "notifi.json"),
|
|
109
|
+
join(home, ".pi", "agent", "notifi.json"),
|
|
110
|
+
join(home, ".pi", "agent", "extensions", "notifi.json"),
|
|
111
|
+
];
|
|
107
112
|
|
|
108
113
|
for (const path of paths) {
|
|
109
114
|
if (!path || !(await fileExists(path))) continue;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-notifi",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.4",
|
|
4
4
|
"description": "Pi extension that sends focus-aware desktop notifications when pi finishes a task.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pi-package",
|
|
@@ -22,7 +22,6 @@
|
|
|
22
22
|
"files": [
|
|
23
23
|
"index.ts",
|
|
24
24
|
"scripts/",
|
|
25
|
-
"examples/",
|
|
26
25
|
"README.md"
|
|
27
26
|
],
|
|
28
27
|
"scripts": {
|