@raidiant/notifai 1.0.0 → 1.0.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/CHANGELOG.md +9 -1
- package/dist/commands.js +14 -1
- package/dist/commands.js.map +1 -1
- package/dist/install-hooks.d.ts +12 -9
- package/dist/install-hooks.js +15 -30
- package/dist/install-hooks.js.map +1 -1
- package/package.json +1 -1
- package/src/commands.test.ts +49 -13
- package/src/commands.ts +18 -1
- package/src/install-hooks.test.ts +27 -7
- package/src/install-hooks.ts +19 -26
package/CHANGELOG.md
CHANGED
|
@@ -10,6 +10,13 @@ and [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/).
|
|
|
10
10
|
|
|
11
11
|
## [Unreleased]
|
|
12
12
|
|
|
13
|
+
## [1.0.1] - 2026-08-13
|
|
14
|
+
|
|
15
|
+
### Fixed
|
|
16
|
+
|
|
17
|
+
- Codex hook installation writes inline `[hooks]` in `config.toml`. It does not create the legacy `hooks.json`.
|
|
18
|
+
- Hook installation is one scope: project or machine-global, not both. A project install is a no-op when global already covers the machine.
|
|
19
|
+
|
|
13
20
|
## [1.0.0] - 2026-08-13
|
|
14
21
|
|
|
15
22
|
### Removed
|
|
@@ -146,7 +153,8 @@ and [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/).
|
|
|
146
153
|
|
|
147
154
|
- First public release of the `notifai` CLI under Apache-2.0.
|
|
148
155
|
|
|
149
|
-
[unreleased]: https://github.com/Raidiant-io/notifai/compare/v1.0.
|
|
156
|
+
[unreleased]: https://github.com/Raidiant-io/notifai/compare/v1.0.1...HEAD
|
|
157
|
+
[1.0.1]: https://github.com/Raidiant-io/notifai/compare/v1.0.0...v1.0.1
|
|
150
158
|
[1.0.0]: https://github.com/Raidiant-io/notifai/compare/v0.5.1...v1.0.0
|
|
151
159
|
[0.5.1]: https://github.com/Raidiant-io/notifai/compare/v0.5.0...v0.5.1
|
|
152
160
|
[0.5.0]: https://github.com/Raidiant-io/notifai/compare/v0.4.0...v0.5.0
|
package/dist/commands.js
CHANGED
|
@@ -1695,7 +1695,20 @@ export function hooksInstallCommand(deps, flags) {
|
|
|
1695
1695
|
deps.io.err(`Could not prepare the stable hook adapter: ${String(err)}`);
|
|
1696
1696
|
return EXIT.failed;
|
|
1697
1697
|
}
|
|
1698
|
-
const
|
|
1698
|
+
const wantGlobal = flags.global === true;
|
|
1699
|
+
const existing = findInstallations(deps.cwd, deps.env, deps.hookAdapterHome).filter((installation) => installation.harness === harness);
|
|
1700
|
+
const otherScope = existing.filter((installation) => installation.global !== wantGlobal);
|
|
1701
|
+
if (!wantGlobal && otherScope.some((installation) => installation.global)) {
|
|
1702
|
+
const globalFile = otherScope.find((installation) => installation.global)?.file;
|
|
1703
|
+
deps.io.out(`${HARNESS_LABELS[harness]} hooks already cover this machine (${globalFile}). This project does not need its own copy. To wire only this project: notifai hooks uninstall --harness ${harness} --global && notifai hooks install --harness ${harness}`);
|
|
1704
|
+
return EXIT.ok;
|
|
1705
|
+
}
|
|
1706
|
+
if (wantGlobal && otherScope.some((installation) => !installation.global)) {
|
|
1707
|
+
if (hooksUninstallCommand(deps, { ...flags, global: false, harness }) !== EXIT.ok) {
|
|
1708
|
+
return EXIT.failed;
|
|
1709
|
+
}
|
|
1710
|
+
}
|
|
1711
|
+
const file = settingsFile(harness, wantGlobal, deps.cwd, deps.env);
|
|
1699
1712
|
// OpenCode's adapter is a generated plugin module rather than a handler
|
|
1700
1713
|
// merged into a settings document, so it owns the whole file.
|
|
1701
1714
|
if (harness === 'opencode') {
|