@lifeaitools/rdc-skills 0.35.25 → 0.35.26
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.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rdc",
|
|
3
|
-
"version": "0.35.
|
|
3
|
+
"version": "0.35.26",
|
|
4
4
|
"description": "RDC typed-agent dispatch skill suite for Claude Code — plan, build, review, overnight unattended builds with work-item tracking and TDD enforcement.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "LIFEAI",
|
package/git-sha.json
ADDED
package/package.json
CHANGED
|
@@ -1277,7 +1277,14 @@ async function main() {
|
|
|
1277
1277
|
const pkg = readJson(path.join(repoRoot, 'package.json'));
|
|
1278
1278
|
const version = pkg.version || '0.7.0';
|
|
1279
1279
|
let gitSha = '';
|
|
1280
|
-
|
|
1280
|
+
if (fs.existsSync(path.join(repoRoot, '.git'))) {
|
|
1281
|
+
try { gitSha = execSync('git rev-parse HEAD', { cwd: repoRoot, encoding: 'utf8', stdio: 'pipe' }).trim(); } catch {}
|
|
1282
|
+
} else {
|
|
1283
|
+
// An npm-installed package has no .git — and `git rev-parse` would walk up into
|
|
1284
|
+
// whatever repository encloses it. The commit is the pack-time stamp instead.
|
|
1285
|
+
gitSha = String(readJson(path.join(repoRoot, 'git-sha.json'))?.sha || '');
|
|
1286
|
+
if (gitSha === 'unknown') gitSha = '';
|
|
1287
|
+
}
|
|
1281
1288
|
|
|
1282
1289
|
// 0.5a. User-skills cleanup — remove any rdc: skills from ~/.claude/skills/user/
|
|
1283
1290
|
// (older installer versions wrote there; plugin cache is the only authoritative source)
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
// .npmignore replaces .gitignore for npm. It must carry every .gitignore rule except
|
|
2
|
+
// git-sha.json — the pack-time commit stamp that is untracked in git and exists to be
|
|
3
|
+
// shipped — or the package either loses the stamp or starts shipping what git ignores.
|
|
4
|
+
import { test } from 'node:test';
|
|
5
|
+
import assert from 'node:assert/strict';
|
|
6
|
+
import fs from 'node:fs';
|
|
7
|
+
import path from 'node:path';
|
|
8
|
+
import { fileURLToPath } from 'node:url';
|
|
9
|
+
|
|
10
|
+
const ROOT = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
|
|
11
|
+
const rules = (file) => new Set(fs.readFileSync(path.join(ROOT, file), 'utf8')
|
|
12
|
+
.split(/\r?\n/).map((l) => l.trim()).filter((l) => l && !l.startsWith('#')));
|
|
13
|
+
|
|
14
|
+
test('.npmignore is .gitignore without the commit stamp', () => {
|
|
15
|
+
const git = rules('.gitignore');
|
|
16
|
+
const npm = rules('.npmignore');
|
|
17
|
+
assert.ok(git.has('git-sha.json'), 'the stamp stays out of git');
|
|
18
|
+
assert.ok(!npm.has('git-sha.json'), 'and stays IN the package');
|
|
19
|
+
const expected = [...git].filter((r) => r !== 'git-sha.json').sort();
|
|
20
|
+
assert.deepEqual([...npm].sort(), expected);
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
test('the installer records the stamped commit when it runs from a package with no .git', () => {
|
|
24
|
+
const installer = fs.readFileSync(path.join(ROOT, 'scripts', 'install-rdc-skills.js'), 'utf8');
|
|
25
|
+
assert.match(installer, /git-sha\.json/);
|
|
26
|
+
});
|