uncompact 0.45.9 → 0.46.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.
Files changed (2) hide show
  1. package/npm/install.js +15 -9
  2. package/package.json +1 -1
package/npm/install.js CHANGED
@@ -188,21 +188,27 @@ async function main() {
188
188
 
189
189
  // Automatically install Claude Code hooks
190
190
  log("[uncompact] Configuring Claude Code hooks...\n");
191
+ let installSuccessful = false;
191
192
  try {
192
193
  // The 'install' command now automatically shows the help menu upon completion
193
194
  execFileSync(destPath, ["install", "--yes"], { stdio: "inherit" });
194
-
195
- // Also show status to verify API key detection
196
- console.log();
197
- execFileSync(destPath, ["status"], { stdio: "inherit" });
195
+ installSuccessful = true;
198
196
  } catch (err) {
199
197
  log("[uncompact] Note: Automatic hook configuration skipped or failed. Run manually if needed:\n");
200
198
  log(" uncompact install\n");
201
-
202
- // Fallback: Show help if the install command failed
203
- try {
204
- execFileSync(destPath, [], { stdio: "inherit" });
205
- } catch (e) {}
199
+ }
200
+
201
+ // Always show status to verify API key detection, regardless of install success
202
+ try {
203
+ console.log();
204
+ execFileSync(destPath, ["status"], { stdio: "inherit" });
205
+ } catch (err) {
206
+ // If status fails, show help as a fallback if we haven't shown anything yet
207
+ if (!installSuccessful) {
208
+ try {
209
+ execFileSync(destPath, [], { stdio: "inherit" });
210
+ } catch (e) {}
211
+ }
206
212
  }
207
213
  log("\n");
208
214
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "uncompact",
3
- "version": "0.45.9",
3
+ "version": "0.46.1",
4
4
  "description": "Stop Claude Code compaction from making your AI stupid. Re-inject project context after compaction via the Supermodel API.",
5
5
  "author": "Supermodel <abe@supermodel.software>",
6
6
  "license": "MIT",