@wix/ditto-codegen-public 1.0.322 → 1.0.324
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.
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { tool } from "@opencode-ai/plugin";
|
|
2
|
+
|
|
3
|
+
export default tool({
|
|
4
|
+
description:
|
|
5
|
+
"Set the commit message for this codegen run. The message becomes the " +
|
|
6
|
+
"subject of a real `git commit -m` for the run, visible to " +
|
|
7
|
+
"non-technical users in their checkpoint history. Call this once, as " +
|
|
8
|
+
"the first thing you do, before writing any code.",
|
|
9
|
+
args: {
|
|
10
|
+
commitMessage: tool.schema
|
|
11
|
+
.string()
|
|
12
|
+
.min(1)
|
|
13
|
+
.describe(
|
|
14
|
+
"One-line summary of the user's request. " +
|
|
15
|
+
'Imperative mood (e.g. "Add", "Fix", "Update"). ' +
|
|
16
|
+
"No trailing period, no quotes, no prefix. " +
|
|
17
|
+
"Ideally under 150 characters.",
|
|
18
|
+
),
|
|
19
|
+
},
|
|
20
|
+
async execute(args) {
|
|
21
|
+
return `Commit message set: ${args.commitMessage}`;
|
|
22
|
+
},
|
|
23
|
+
});
|
package/dist/out.js
CHANGED
|
@@ -12904,12 +12904,11 @@ var require_environments = __commonJS({
|
|
|
12904
12904
|
Object.defineProperty(exports2, "getActiveHooks", { enumerable: true, get: function() {
|
|
12905
12905
|
return hooks_1.getActiveHooks;
|
|
12906
12906
|
} });
|
|
12907
|
-
function getCodegenEnvironmentConfig(
|
|
12908
|
-
switch (
|
|
12907
|
+
function getCodegenEnvironmentConfig() {
|
|
12908
|
+
switch (process.env.CODEGEN_ENVIRONMENT) {
|
|
12909
12909
|
case types_1.Environment.STUDIO_2:
|
|
12910
12910
|
return studio_2_1.studio2CodegenConfig;
|
|
12911
12911
|
case types_1.Environment.APP_BUILDER:
|
|
12912
|
-
case types_1.Environment.UNKNOWN_ENVIRONMENT:
|
|
12913
12912
|
default:
|
|
12914
12913
|
return app_builder_1.appBuilderCodegenConfig;
|
|
12915
12914
|
}
|
|
@@ -19997,15 +19996,15 @@ var require_tools_writer = __commonJS({
|
|
|
19997
19996
|
var logger_12 = require_logger();
|
|
19998
19997
|
var environments_12 = require_environments();
|
|
19999
19998
|
var GLOBAL_TOOLS_DIR = (0, path_1.join)((0, os_1.homedir)(), ".config", "opencode", "tools");
|
|
20000
|
-
var
|
|
20001
|
-
var ENV_TOOLS_DIR = (0, path_1.join)(
|
|
19999
|
+
var OPENCODE_TOOLS_DIR = (0, path_1.join)(__dirname, "opencode-tools");
|
|
20000
|
+
var ENV_TOOLS_DIR = (0, path_1.join)(OPENCODE_TOOLS_DIR, "env-tools");
|
|
20002
20001
|
async function writeToolFiles() {
|
|
20003
20002
|
await (0, promises_1.mkdir)(GLOBAL_TOOLS_DIR, { recursive: true });
|
|
20004
|
-
const
|
|
20005
|
-
const alwaysOnTools =
|
|
20003
|
+
const entries = await (0, promises_1.readdir)(OPENCODE_TOOLS_DIR);
|
|
20004
|
+
const alwaysOnTools = entries.filter((f) => f.endsWith(".ts"));
|
|
20006
20005
|
const envTools = (0, environments_12.getCodegenEnvironmentConfig)().tools ?? [];
|
|
20007
20006
|
await Promise.all([
|
|
20008
|
-
...alwaysOnTools.map((file) => (0, promises_1.copyFile)((0, path_1.join)(
|
|
20007
|
+
...alwaysOnTools.map((file) => (0, promises_1.copyFile)((0, path_1.join)(OPENCODE_TOOLS_DIR, file), (0, path_1.join)(GLOBAL_TOOLS_DIR, file))),
|
|
20009
20008
|
...envTools.map((file) => (0, promises_1.copyFile)((0, path_1.join)(ENV_TOOLS_DIR, file), (0, path_1.join)(GLOBAL_TOOLS_DIR, file)))
|
|
20010
20009
|
]);
|
|
20011
20010
|
logger_12.logger.info("[OpenCode] Wrote global tool files", {
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/ditto-codegen-public",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.324",
|
|
4
4
|
"description": "AI-powered Wix CLI app generator - standalone executable",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "node build.mjs",
|
|
7
|
-
"test": "
|
|
7
|
+
"test": "vitest run"
|
|
8
8
|
},
|
|
9
9
|
"bin": "dist/out.js",
|
|
10
10
|
"files": [
|
|
@@ -25,7 +25,8 @@
|
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
27
|
"@wix/ditto-codegen": "1.0.0",
|
|
28
|
-
"esbuild": "^0.27.2"
|
|
28
|
+
"esbuild": "^0.27.2",
|
|
29
|
+
"vitest": "^4.0.16"
|
|
29
30
|
},
|
|
30
|
-
"falconPackageHash": "
|
|
31
|
+
"falconPackageHash": "eda53489406fd3a013565a99294dfd07561cab5727c6b511c76bbc2d"
|
|
31
32
|
}
|