@julong/mono-rele2-core 1.5.0 → 1.6.0
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 -1
- package/dist/index.js +3 -12
- package/dist/server.js +7 -12
- package/dist/skills/{mono-rele2-core → mono-rele2-core-cli}/skill.md +10 -10
- package/package.json +3 -3
package/README.md
CHANGED
package/dist/index.js
CHANGED
|
@@ -13,20 +13,16 @@ function text(content) {
|
|
|
13
13
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
14
14
|
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
15
15
|
function createMcpServer(config, tools2) {
|
|
16
|
-
const
|
|
16
|
+
const server = new McpServer(config);
|
|
17
17
|
for (const tool of tools2) {
|
|
18
|
-
|
|
18
|
+
server.registerTool(
|
|
19
19
|
tool.name,
|
|
20
20
|
{ description: tool.description, inputSchema: tool.inputSchema },
|
|
21
21
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
22
22
|
tool.handler
|
|
23
23
|
);
|
|
24
24
|
}
|
|
25
|
-
return
|
|
26
|
-
}
|
|
27
|
-
async function startServer(server2) {
|
|
28
|
-
const transport = new StdioServerTransport();
|
|
29
|
-
await server2.connect(transport);
|
|
25
|
+
return server;
|
|
30
26
|
}
|
|
31
27
|
|
|
32
28
|
// ../common/kit/cli.ts
|
|
@@ -273,11 +269,6 @@ function createCoreServer() {
|
|
|
273
269
|
[echoTool, timestampTool, envTool, uuidTool]
|
|
274
270
|
);
|
|
275
271
|
}
|
|
276
|
-
var server = createCoreServer();
|
|
277
|
-
startServer(server).catch((err) => {
|
|
278
|
-
console.error("[core] server error:", err);
|
|
279
|
-
process.exit(1);
|
|
280
|
-
});
|
|
281
272
|
export {
|
|
282
273
|
createCoreServer,
|
|
283
274
|
generateReadmeSkills,
|
package/dist/server.js
CHANGED
|
@@ -15,20 +15,20 @@ function text(content) {
|
|
|
15
15
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
16
16
|
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
17
17
|
function createMcpServer(config, tools2) {
|
|
18
|
-
const
|
|
18
|
+
const server2 = new McpServer(config);
|
|
19
19
|
for (const tool of tools2) {
|
|
20
|
-
|
|
20
|
+
server2.registerTool(
|
|
21
21
|
tool.name,
|
|
22
22
|
{ description: tool.description, inputSchema: tool.inputSchema },
|
|
23
23
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
24
24
|
tool.handler
|
|
25
25
|
);
|
|
26
26
|
}
|
|
27
|
-
return
|
|
27
|
+
return server2;
|
|
28
28
|
}
|
|
29
|
-
async function startServer(
|
|
29
|
+
async function startServer(server2) {
|
|
30
30
|
const transport = new StdioServerTransport();
|
|
31
|
-
await
|
|
31
|
+
await server2.connect(transport);
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
// ../common/kit/cli.ts
|
|
@@ -98,15 +98,10 @@ function createCoreServer() {
|
|
|
98
98
|
[echoTool, timestampTool, envTool, uuidTool]
|
|
99
99
|
);
|
|
100
100
|
}
|
|
101
|
-
var server = createCoreServer();
|
|
102
|
-
startServer(server).catch((err) => {
|
|
103
|
-
console.error("[core] server error:", err);
|
|
104
|
-
process.exit(1);
|
|
105
|
-
});
|
|
106
101
|
|
|
107
102
|
// src/server.ts
|
|
108
|
-
var
|
|
109
|
-
startServer(
|
|
103
|
+
var server = createCoreServer();
|
|
104
|
+
startServer(server).catch((err) => {
|
|
110
105
|
console.error("[core] server error:", err);
|
|
111
106
|
process.exit(1);
|
|
112
107
|
});
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
---
|
|
2
|
-
name: mono-rele2-core
|
|
2
|
+
name: mono-rele2-core-cli
|
|
3
3
|
description: Use this skill to invoke core system utility functions via the mono-rele2-core CLI. Handles message echo, UTC timestamp generation, and environment variable lookup.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# mono-rele2-core
|
|
6
|
+
# mono-rele2-core-cli
|
|
7
7
|
|
|
8
8
|
```sh
|
|
9
|
-
mono-rele2-core <skillName> [...args]
|
|
9
|
+
mono-rele2-core-cli <skillName> [...args]
|
|
10
10
|
```
|
|
11
11
|
|
|
12
12
|
## Skills
|
|
@@ -45,16 +45,16 @@ Generates a random UUID v4
|
|
|
45
45
|
|
|
46
46
|
## Examples
|
|
47
47
|
|
|
48
|
-
- `mono-rele2-core echoTool "hello world"` => `hello world`
|
|
49
|
-
- `mono-rele2-core timestampTool` => `2026-05-02T00:00:00.000Z`
|
|
50
|
-
- `mono-rele2-core timestampTool unix` => `1746144000000`
|
|
51
|
-
- `mono-rele2-core envTool HOME` => `/Users/julong`
|
|
52
|
-
- `mono-rele2-core envTool NODE_ENV` => `development`
|
|
53
|
-
- `mono-rele2-core uuidTool` => `550e8400-e29b-41d4-a716-446655440000`
|
|
48
|
+
- `mono-rele2-core-cli echoTool "hello world"` => `hello world`
|
|
49
|
+
- `mono-rele2-core-cli timestampTool` => `2026-05-02T00:00:00.000Z`
|
|
50
|
+
- `mono-rele2-core-cli timestampTool unix` => `1746144000000`
|
|
51
|
+
- `mono-rele2-core-cli envTool HOME` => `/Users/julong`
|
|
52
|
+
- `mono-rele2-core-cli envTool NODE_ENV` => `development`
|
|
53
|
+
- `mono-rele2-core-cli uuidTool` => `550e8400-e29b-41d4-a716-446655440000`
|
|
54
54
|
|
|
55
55
|
## Guidelines
|
|
56
56
|
|
|
57
57
|
- Arguments are positional — pass them in the order listed in each skill's table
|
|
58
58
|
- Optional args with defaults may be omitted
|
|
59
59
|
- `envTool` returns an empty string when the variable is not set
|
|
60
|
-
- Run `mono-rele2-core` with no args to list all available skills
|
|
60
|
+
- Run `mono-rele2-core-cli` with no args to list all available skills
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@julong/mono-rele2-core",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "Use this skill to invoke core system utility functions via the mono-rele2-core CLI. Handles message echo, UTC timestamp generation, and environment variable lookup.",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"type": "module",
|
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
}
|
|
12
12
|
},
|
|
13
13
|
"bin": {
|
|
14
|
-
"
|
|
15
|
-
"mono-rele2-core": "./dist/cli.js"
|
|
14
|
+
"mono-rele2-core": "./dist/server.js",
|
|
15
|
+
"mono-rele2-core-cli": "./dist/cli.js"
|
|
16
16
|
},
|
|
17
17
|
"files": [
|
|
18
18
|
"dist"
|