haansi 0.1.123 → 0.1.124

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/dist/haansi.js +26 -8
  2. package/package.json +1 -1
package/dist/haansi.js CHANGED
@@ -95,7 +95,7 @@ var require_package = __commonJS({
95
95
  "package.json"(exports2, module2) {
96
96
  module2.exports = {
97
97
  name: "haansi",
98
- version: "0.1.123",
98
+ version: "0.1.124",
99
99
  description: "Haansi CLI - Session collector and MCP server for Claude Code & OpenAI Codex",
100
100
  bin: {
101
101
  haansi: "./dist/haansi.js"
@@ -19508,6 +19508,10 @@ var init_exclusions = __esm({
19508
19508
  diff_state: [
19509
19509
  "operational",
19510
19510
  "Closed CHECK vocabulary (full, clipped, no_patch, unavailable)."
19511
+ ],
19512
+ diff_reason: [
19513
+ "operational",
19514
+ "Closed CHECK vocabulary (no_source, no_token, not_in_change, refused)."
19511
19515
  ]
19512
19516
  }),
19513
19517
  ...exchangeExclusions(INTEL, "stored_replay_tasks", {
@@ -28707,6 +28711,22 @@ var init_entrypoint = __esm({
28707
28711
  }
28708
28712
  });
28709
28713
 
28714
+ // ../service-capture/agent-sessions/session-branch.ts
28715
+ function sessionGitBranch(sessionBranch, readHead) {
28716
+ const own = sessionBranch?.trim();
28717
+ if (own && own !== "HEAD") return own;
28718
+ try {
28719
+ return readHead() || null;
28720
+ } catch {
28721
+ return null;
28722
+ }
28723
+ }
28724
+ var init_session_branch = __esm({
28725
+ "../service-capture/agent-sessions/session-branch.ts"() {
28726
+ "use strict";
28727
+ }
28728
+ });
28729
+
28710
28730
  // ../service-capture/agent-sessions/collector.ts
28711
28731
  var collector_exports = {};
28712
28732
  __export(collector_exports, {
@@ -28867,13 +28887,10 @@ function extractGitInfo(projectDir, sessionTimestamp, sessionBranch) {
28867
28887
  } catch {
28868
28888
  }
28869
28889
  }
28870
- try {
28871
- result.gitBranch = git(["rev-parse", "--abbrev-ref", "HEAD"]) || null;
28872
- } catch {
28873
- }
28874
- if (!result.gitBranch && sessionBranch) {
28875
- result.gitBranch = sessionBranch;
28876
- }
28890
+ result.gitBranch = sessionGitBranch(
28891
+ sessionBranch,
28892
+ () => git(["rev-parse", "--abbrev-ref", "HEAD"])
28893
+ );
28877
28894
  return result;
28878
28895
  }
28879
28896
  function resolveToken2() {
@@ -29281,6 +29298,7 @@ var init_collector = __esm({
29281
29298
  init_agents();
29282
29299
  init_session_parts();
29283
29300
  init_entrypoint();
29301
+ init_session_branch();
29284
29302
  (0, import_dotenv.config)({ path: (0, import_path3.resolve)(__dirname, "../../../.env") });
29285
29303
  logger5 = createLogger("session-collector");
29286
29304
  DEFAULT_API_URL2 = SERVICE_URL_DEFAULTS.haansiApiBaseUrl;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "haansi",
3
- "version": "0.1.123",
3
+ "version": "0.1.124",
4
4
  "description": "Haansi CLI - Session collector and MCP server for Claude Code & OpenAI Codex",
5
5
  "bin": {
6
6
  "haansi": "./dist/haansi.js"