mcp-for-i 0.1.5 → 0.1.6

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 CHANGED
@@ -104,6 +104,44 @@ npm test
104
104
  npm run start:controlplane
105
105
  ```
106
106
 
107
+ ## Automated Release (No Manual Version Bump)
108
+
109
+ Use the release script instead of raw `npm publish`.
110
+
111
+ Patch release:
112
+
113
+ ```bash
114
+ npm run release:patch
115
+ ```
116
+
117
+ Minor release:
118
+
119
+ ```bash
120
+ npm run release:minor
121
+ ```
122
+
123
+ Major release:
124
+
125
+ ```bash
126
+ npm run release:major
127
+ ```
128
+
129
+ What it does:
130
+ - Verifies git working tree is clean.
131
+ - Runs `npm test` (unless `--skip-tests` is passed).
132
+ - Checks npm published version.
133
+ - Auto-bumps version only when local version is not ahead.
134
+ - Publishes to npm.
135
+ - Pushes commit/tag to GitHub.
136
+
137
+ Optional flags:
138
+
139
+ ```bash
140
+ npm run release:patch -- --skip-tests
141
+ npm run release:patch -- --otp=123456
142
+ npm run release:patch -- --no-push
143
+ ```
144
+
107
145
  ## Security Model
108
146
 
109
147
  - Credential-bearing direct tool arguments are blocked for connection creation/update flows.
@@ -29,7 +29,9 @@ export var Tools;
29
29
  const trimmed = line.trim();
30
30
  if (trimmed.length === 0 && iiErrorMessage)
31
31
  iiErrorMessage = false;
32
- if (trimmed.length === 0 || index === data.length - 1)
32
+ if (trimmed.length === 0)
33
+ return;
34
+ if (/^\d+\s+RECORD\(S\)\s+SELECTED\.$/i.test(trimmed))
33
35
  return;
34
36
  if (trimmed === `**** CLI ERROR *****`) {
35
37
  iiErrorMessage = true;
@@ -57,12 +59,31 @@ export var Tools;
57
59
  gotHeaders = true;
58
60
  }
59
61
  else if (!figuredLengths) {
60
- let base = 0;
61
- line.split(` `).forEach((header, idx) => {
62
- headers[idx].from = base;
63
- headers[idx].length = header.length;
64
- base += header.length + 1;
65
- });
62
+ const segments = [];
63
+ const re = /-+/g;
64
+ let match = re.exec(line);
65
+ while (match) {
66
+ segments.push({ from: match.index, length: match[0].length });
67
+ match = re.exec(line);
68
+ }
69
+ if (segments.length > 0) {
70
+ segments.forEach((segment, idx) => {
71
+ if (!headers[idx])
72
+ return;
73
+ headers[idx].from = segment.from;
74
+ headers[idx].length = segment.length;
75
+ });
76
+ }
77
+ else {
78
+ let base = 0;
79
+ line.split(` `).forEach((header, idx) => {
80
+ if (!headers[idx])
81
+ return;
82
+ headers[idx].from = base;
83
+ headers[idx].length = header.length;
84
+ base += header.length + 1;
85
+ });
86
+ }
66
87
  figuredLengths = true;
67
88
  }
68
89
  else {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mcp-for-i",
3
- "version": "0.1.5",
3
+ "version": "0.1.6",
4
4
  "private": false,
5
5
  "description": "Local MCP server and control plane for IBM i workflows",
6
6
  "type": "module",
@@ -31,7 +31,11 @@
31
31
  "test": "npm run build && node --test test/tools.test.mjs test/variables.test.mjs test/validation.test.mjs test/config.migration.test.mjs test/sql.parse.test.mjs",
32
32
  "test:all": "npm run build && node --test test/*.mjs",
33
33
  "test:ibmi": "npm run build && node --test test/ibmi.integration.test.mjs",
34
- "test:mcp": "npm run build && node --test test/mcp.integration.test.mjs"
34
+ "test:mcp": "npm run build && node --test test/mcp.integration.test.mjs",
35
+ "release:auto": "node scripts/release-auto.mjs patch",
36
+ "release:patch": "node scripts/release-auto.mjs patch",
37
+ "release:minor": "node scripts/release-auto.mjs minor",
38
+ "release:major": "node scripts/release-auto.mjs major"
35
39
  },
36
40
  "dependencies": {
37
41
  "@modelcontextprotocol/sdk": "^1.25.3",