skiller 0.9.13 → 0.9.14
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.
|
@@ -42,9 +42,7 @@ const AgentSourceCompatibility_1 = require("./AgentSourceCompatibility");
|
|
|
42
42
|
const ConfigLoader_1 = require("./ConfigLoader");
|
|
43
43
|
const FileSystemUtils_1 = require("./FileSystemUtils");
|
|
44
44
|
const project_paths_1 = require("./project-paths");
|
|
45
|
-
const
|
|
46
|
-
.join(project_paths_1.CANONICAL_SKILLER_DIR, 'preset.toml')
|
|
47
|
-
.replace(/\\/g, '/');
|
|
45
|
+
const PRESET_CONFIG_FILENAME = 'preset.toml';
|
|
48
46
|
const PRESET_MANIFEST_RELATIVE_PATH = path
|
|
49
47
|
.join(project_paths_1.CANONICAL_SKILLER_DIR, '.skiller-preset-manifest.json')
|
|
50
48
|
.replace(/\\/g, '/');
|
|
@@ -163,16 +161,16 @@ async function readRawTomlFile(filePath) {
|
|
|
163
161
|
}
|
|
164
162
|
}
|
|
165
163
|
async function readPresetConfig(presetRoot) {
|
|
166
|
-
const configPath = path.join(presetRoot,
|
|
164
|
+
const configPath = path.join(presetRoot, PRESET_CONFIG_FILENAME);
|
|
167
165
|
const raw = await readRawTomlFile(configPath);
|
|
168
166
|
if (Object.keys(raw).length === 0) {
|
|
169
167
|
return { include: [] };
|
|
170
168
|
}
|
|
171
169
|
if (raw.version !== undefined && raw.version !== 1) {
|
|
172
|
-
throw new Error(`[skiller] ${
|
|
170
|
+
throw new Error(`[skiller] ${PRESET_CONFIG_FILENAME} in '${presetRoot}' must use version = 1.`);
|
|
173
171
|
}
|
|
174
172
|
if (raw.include !== undefined && !Array.isArray(raw.include)) {
|
|
175
|
-
throw new Error(`[skiller] ${
|
|
173
|
+
throw new Error(`[skiller] ${PRESET_CONFIG_FILENAME} in '${presetRoot}' must set include = ["path", ...].`);
|
|
176
174
|
}
|
|
177
175
|
return {
|
|
178
176
|
include: Array.isArray(raw.include)
|
|
@@ -295,7 +293,7 @@ async function installPresetIntoProject(projectRoot, options) {
|
|
|
295
293
|
const sourcePath = await collectFileFromPath(resolvedIncludePath);
|
|
296
294
|
const targetRelativePath = deriveTargetRelativePath(sourcePath);
|
|
297
295
|
if (!targetRelativePath) {
|
|
298
|
-
throw new Error(`[skiller] Included path '${includePath}' in '${preset}/${
|
|
296
|
+
throw new Error(`[skiller] Included path '${includePath}' in '${preset}/${PRESET_CONFIG_FILENAME}' must resolve under .agents, .claude, .codex, skills-lock.json, or skiller-lock.json.`);
|
|
299
297
|
}
|
|
300
298
|
if (isHardDenied(targetRelativePath)) {
|
|
301
299
|
throw new Error(`[skiller] Included path '${includePath}' resolves to denied target '${targetRelativePath}'.`);
|
|
@@ -309,7 +307,7 @@ async function installPresetIntoProject(projectRoot, options) {
|
|
|
309
307
|
}
|
|
310
308
|
nextSources.set(targetRelativePath, sourcePath);
|
|
311
309
|
}
|
|
312
|
-
const selectedFiles = (await collectPresetFiles(presetRoot)).filter((relativePath) => relativePath !==
|
|
310
|
+
const selectedFiles = (await collectPresetFiles(presetRoot)).filter((relativePath) => relativePath !== PRESET_CONFIG_FILENAME &&
|
|
313
311
|
!isHardDenied(relativePath) &&
|
|
314
312
|
isPresetAllowlisted(relativePath));
|
|
315
313
|
if (selectedFiles.includes(path
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "skiller",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.14",
|
|
4
4
|
"description": "Skiller — apply the same rules to all coding agents",
|
|
5
5
|
"main": "dist/lib.js",
|
|
6
6
|
"publishConfig": {
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
"lint": "eslint \"src/**/*.{ts,tsx}\"",
|
|
11
11
|
"lint:fix": "eslint \"src/**/*.{ts,tsx}\" --fix",
|
|
12
12
|
"format": "prettier --write \"src/**/*.{ts,tsx,json,md}\"",
|
|
13
|
+
"prepack": "pnpm build",
|
|
13
14
|
"refresh:skills-catalog": "node scripts/refresh-skills-agent-catalog.mjs",
|
|
14
15
|
"test": "jest",
|
|
15
16
|
"test:watch": "jest --watch",
|