@signetai/connector-codex 0.200.3 → 0.200.4
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/dist/index.js +34 -34
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
// src/index.ts
|
|
2
2
|
import { spawnSync } from "node:child_process";
|
|
3
3
|
import { createHash as createHash3 } from "node:crypto";
|
|
4
|
-
import { existsSync as existsSync2, mkdirSync, readFileSync as readFileSync2, readdirSync, rmSync, statSync, writeFileSync as writeFileSync2 } from "node:fs";
|
|
4
|
+
import { existsSync as existsSync2, mkdirSync, readFileSync as readFileSync2, readdirSync, rmSync, statSync as statSync2, writeFileSync as writeFileSync2 } from "node:fs";
|
|
5
5
|
import { homedir } from "node:os";
|
|
6
6
|
import { basename as basename3, dirname as dirname6, join as join4 } from "node:path";
|
|
7
7
|
|
|
8
8
|
// ../../../libs/connector-base/dist/index.js
|
|
9
9
|
import { randomBytes } from "node:crypto";
|
|
10
|
-
import { existsSync, readFileSync, renameSync as renameSync2, statSync
|
|
11
|
-
import { dirname as
|
|
10
|
+
import { existsSync, readFileSync, renameSync as renameSync2, statSync, unlinkSync as unlinkSync2, writeFileSync } from "node:fs";
|
|
11
|
+
import { dirname as dirname2, isAbsolute, join as join3, relative, sep } from "node:path";
|
|
12
12
|
import { createRequire } from "node:module";
|
|
13
13
|
import { dirname, join } from "node:path";
|
|
14
14
|
import { fileURLToPath } from "node:url";
|
|
15
15
|
import { createHash } from "node:crypto";
|
|
16
16
|
import { createRequire as createRequire2 } from "node:module";
|
|
17
|
-
import { homedir as
|
|
18
|
-
import { dirname as
|
|
19
|
-
import { homedir as
|
|
20
|
-
import { basename, dirname as
|
|
21
|
-
import { homedir as
|
|
17
|
+
import { homedir as homedir5 } from "node:os";
|
|
18
|
+
import { dirname as dirname4, join as join7, resolve as resolve2 } from "node:path";
|
|
19
|
+
import { homedir as homedir6, platform as platform2 } from "node:os";
|
|
20
|
+
import { basename, dirname as dirname5, resolve as resolve4 } from "node:path";
|
|
21
|
+
import { homedir as homedir10 } from "node:os";
|
|
22
22
|
import { existsSync as existsSync13, lstatSync, mkdirSync as mkdirSync9, readdirSync as readdirSync6, symlinkSync, unlinkSync } from "node:fs";
|
|
23
|
-
import { join as
|
|
23
|
+
import { join as join14 } from "node:path";
|
|
24
24
|
var __create2 = Object.create;
|
|
25
25
|
var __getProtoOf2 = Object.getPrototypeOf;
|
|
26
26
|
var __defProp2 = Object.defineProperty;
|
|
@@ -12435,7 +12435,7 @@ try {
|
|
|
12435
12435
|
const esmRequire = createRequire2(import.meta.url);
|
|
12436
12436
|
native = esmRequire("@signet/native");
|
|
12437
12437
|
} catch {}
|
|
12438
|
-
var GRAPHIQ_DEFAULT_INSTALL_DIR =
|
|
12438
|
+
var GRAPHIQ_DEFAULT_INSTALL_DIR = join7(homedir5(), ".local", "bin");
|
|
12439
12439
|
var SIGNET_SOURCE_CHECKOUT_DIRNAME = "signetai";
|
|
12440
12440
|
var SIGNET_GIT_ALLOWED_DIRECTORIES = ["skills", "tools", "dreaming"];
|
|
12441
12441
|
var SIGNET_GIT_PROTECTED_PATHS = [
|
|
@@ -12505,11 +12505,11 @@ var VALID_GITHUB_RESOURCE_TYPES = new Set(DEFAULT_GITHUB_RESOURCE_TYPES);
|
|
|
12505
12505
|
function defaultDiscordDesktopCachePath() {
|
|
12506
12506
|
switch (platform2()) {
|
|
12507
12507
|
case "darwin":
|
|
12508
|
-
return resolve4(
|
|
12508
|
+
return resolve4(homedir6(), "Library", "Application Support", "discord");
|
|
12509
12509
|
case "win32":
|
|
12510
|
-
return resolve4(process.env.APPDATA || resolve4(
|
|
12510
|
+
return resolve4(process.env.APPDATA || resolve4(homedir6(), "AppData", "Roaming"), "discord");
|
|
12511
12511
|
default:
|
|
12512
|
-
return resolve4(process.env.XDG_CONFIG_HOME || resolve4(
|
|
12512
|
+
return resolve4(process.env.XDG_CONFIG_HOME || resolve4(homedir6(), ".config"), "discord");
|
|
12513
12513
|
}
|
|
12514
12514
|
}
|
|
12515
12515
|
var IDENTITY_FILES = {
|
|
@@ -12580,7 +12580,7 @@ function symlinkSkills(sourceDir, targetDir, options = {}) {
|
|
|
12580
12580
|
if (!existsSync13(sourceDir)) {
|
|
12581
12581
|
return result;
|
|
12582
12582
|
}
|
|
12583
|
-
const targetParent =
|
|
12583
|
+
const targetParent = join14(targetDir, "..");
|
|
12584
12584
|
if (!existsSync13(targetParent)) {
|
|
12585
12585
|
mkdirSync9(targetParent, { recursive: true });
|
|
12586
12586
|
}
|
|
@@ -12598,8 +12598,8 @@ function symlinkSkills(sourceDir, targetDir, options = {}) {
|
|
|
12598
12598
|
return result;
|
|
12599
12599
|
}
|
|
12600
12600
|
for (const entry of entries) {
|
|
12601
|
-
const srcPath =
|
|
12602
|
-
const destPath =
|
|
12601
|
+
const srcPath = join14(sourceDir, entry);
|
|
12602
|
+
const destPath = join14(targetDir, entry);
|
|
12603
12603
|
try {
|
|
12604
12604
|
const src = lstatSync(srcPath);
|
|
12605
12605
|
if (src.isSymbolicLink() || !src.isDirectory()) {
|
|
@@ -12640,7 +12640,7 @@ function symlinkSkills(sourceDir, targetDir, options = {}) {
|
|
|
12640
12640
|
}
|
|
12641
12641
|
return result;
|
|
12642
12642
|
}
|
|
12643
|
-
var home =
|
|
12643
|
+
var home = homedir10();
|
|
12644
12644
|
var SIGNET_BLOCK_START = "<!-- SIGNET:START -->";
|
|
12645
12645
|
var SIGNET_BLOCK_END = "<!-- SIGNET:END -->";
|
|
12646
12646
|
function stripSignetBlock(content) {
|
|
@@ -12681,7 +12681,7 @@ class BaseConnector {
|
|
|
12681
12681
|
generateHeader(sourcePath, targetName) {
|
|
12682
12682
|
const name = targetName || this.name;
|
|
12683
12683
|
const safe = (p) => p.replace(/[\n\r]/g, "");
|
|
12684
|
-
const root =
|
|
12684
|
+
const root = dirname2(sourcePath);
|
|
12685
12685
|
return `# Auto-generated from ${safe(sourcePath)}
|
|
12686
12686
|
# Source: ${safe(sourcePath)}
|
|
12687
12687
|
# Generated: ${new Date().toISOString()}
|
|
@@ -12713,11 +12713,11 @@ ${content}`);
|
|
|
12713
12713
|
}
|
|
12714
12714
|
}
|
|
12715
12715
|
function atomicWriteText(path, content, mode) {
|
|
12716
|
-
const tmp = join3(
|
|
12716
|
+
const tmp = join3(dirname2(path), `.${randomBytes(6).toString("hex")}.tmp`);
|
|
12717
12717
|
let writeMode = mode;
|
|
12718
12718
|
if (writeMode === undefined) {
|
|
12719
12719
|
try {
|
|
12720
|
-
writeMode =
|
|
12720
|
+
writeMode = statSync(path).mode & 511;
|
|
12721
12721
|
} catch {}
|
|
12722
12722
|
}
|
|
12723
12723
|
try {
|
|
@@ -12774,17 +12774,17 @@ function resolveRemoteDaemonUrl() {
|
|
|
12774
12774
|
|
|
12775
12775
|
// ../../../platform/core/dist/index.js
|
|
12776
12776
|
import { createRequire as createRequire3 } from "node:module";
|
|
12777
|
-
import { dirname as
|
|
12777
|
+
import { dirname as dirname3, join as join2 } from "node:path";
|
|
12778
12778
|
import { fileURLToPath as fileURLToPath2 } from "node:url";
|
|
12779
12779
|
import { createHash as createHash2 } from "node:crypto";
|
|
12780
12780
|
import { homedir as homedir2 } from "os";
|
|
12781
12781
|
import { join as join22 } from "path";
|
|
12782
12782
|
import { createRequire as createRequire22 } from "node:module";
|
|
12783
|
-
import { homedir as
|
|
12784
|
-
import { dirname as
|
|
12785
|
-
import { homedir as
|
|
12786
|
-
import { basename as basename2, dirname as
|
|
12787
|
-
import { homedir as
|
|
12783
|
+
import { homedir as homedir52 } from "node:os";
|
|
12784
|
+
import { dirname as dirname42, join as join72, resolve as resolve22 } from "node:path";
|
|
12785
|
+
import { homedir as homedir62, platform as platform22 } from "node:os";
|
|
12786
|
+
import { basename as basename2, dirname as dirname52, resolve as resolve42 } from "node:path";
|
|
12787
|
+
import { homedir as homedir102 } from "node:os";
|
|
12788
12788
|
var __create = Object.create;
|
|
12789
12789
|
var __getProtoOf = Object.getPrototypeOf;
|
|
12790
12790
|
var __defProp = Object.defineProperty;
|
|
@@ -25117,7 +25117,7 @@ var MIGRATIONS2 = [
|
|
|
25117
25117
|
var LATEST_SCHEMA_VERSION2 = MIGRATIONS2[MIGRATIONS2.length - 1]?.version ?? 0;
|
|
25118
25118
|
var NETWORK_FILESYSTEM_TYPES2 = new Set(["afpfs", "nfs", "smbfs", "webdav"]);
|
|
25119
25119
|
var __filename22 = fileURLToPath2(import.meta.url);
|
|
25120
|
-
var __dirname22 =
|
|
25120
|
+
var __dirname22 = dirname3(__filename22);
|
|
25121
25121
|
var import_yaml3 = __toESM(require_dist2(), 1);
|
|
25122
25122
|
function expandHome(p, home2 = homedir2()) {
|
|
25123
25123
|
if (p === "~")
|
|
@@ -25133,7 +25133,7 @@ try {
|
|
|
25133
25133
|
const esmRequire = createRequire22(import.meta.url);
|
|
25134
25134
|
native2 = esmRequire("@signet/native");
|
|
25135
25135
|
} catch {}
|
|
25136
|
-
var GRAPHIQ_DEFAULT_INSTALL_DIR2 =
|
|
25136
|
+
var GRAPHIQ_DEFAULT_INSTALL_DIR2 = join72(homedir52(), ".local", "bin");
|
|
25137
25137
|
var SIGNET_SOURCE_CHECKOUT_DIRNAME2 = "signetai";
|
|
25138
25138
|
var SIGNET_GIT_ALLOWED_DIRECTORIES2 = ["skills", "tools", "dreaming"];
|
|
25139
25139
|
var SIGNET_GIT_PROTECTED_PATHS2 = [
|
|
@@ -25203,11 +25203,11 @@ var VALID_GITHUB_RESOURCE_TYPES2 = new Set(DEFAULT_GITHUB_RESOURCE_TYPES2);
|
|
|
25203
25203
|
function defaultDiscordDesktopCachePath2() {
|
|
25204
25204
|
switch (platform22()) {
|
|
25205
25205
|
case "darwin":
|
|
25206
|
-
return resolve42(
|
|
25206
|
+
return resolve42(homedir62(), "Library", "Application Support", "discord");
|
|
25207
25207
|
case "win32":
|
|
25208
|
-
return resolve42(process.env.APPDATA || resolve42(
|
|
25208
|
+
return resolve42(process.env.APPDATA || resolve42(homedir62(), "AppData", "Roaming"), "discord");
|
|
25209
25209
|
default:
|
|
25210
|
-
return resolve42(process.env.XDG_CONFIG_HOME || resolve42(
|
|
25210
|
+
return resolve42(process.env.XDG_CONFIG_HOME || resolve42(homedir62(), ".config"), "discord");
|
|
25211
25211
|
}
|
|
25212
25212
|
}
|
|
25213
25213
|
var IDENTITY_FILES2 = {
|
|
@@ -25285,7 +25285,7 @@ function resolvePromptSubmitTimeoutMs(raw) {
|
|
|
25285
25285
|
return 120000;
|
|
25286
25286
|
return ms;
|
|
25287
25287
|
}
|
|
25288
|
-
var home2 =
|
|
25288
|
+
var home2 = homedir102();
|
|
25289
25289
|
|
|
25290
25290
|
// src/index.ts
|
|
25291
25291
|
var CODEX_PLUGIN_MARKETPLACE_NAME = "signet-local";
|
|
@@ -25339,7 +25339,7 @@ function codexDesktopNodeCandidates(root, depth = 0) {
|
|
|
25339
25339
|
if ((entry.isFile() || entry.isSymbolicLink()) && entry.name === "node")
|
|
25340
25340
|
candidates.push(path);
|
|
25341
25341
|
try {
|
|
25342
|
-
if (!
|
|
25342
|
+
if (!statSync2(path).isDirectory())
|
|
25343
25343
|
continue;
|
|
25344
25344
|
candidates.push(...codexDesktopNodeCandidates(path, depth + 1));
|
|
25345
25345
|
} catch {}
|
|
@@ -25348,7 +25348,7 @@ function codexDesktopNodeCandidates(root, depth = 0) {
|
|
|
25348
25348
|
}
|
|
25349
25349
|
function isUsableNodeRuntime(path) {
|
|
25350
25350
|
try {
|
|
25351
|
-
if (!
|
|
25351
|
+
if (!statSync2(path).isFile())
|
|
25352
25352
|
return false;
|
|
25353
25353
|
const result = spawnSync(path, ["--version"], { encoding: "utf-8", timeout: 5000 });
|
|
25354
25354
|
return result.status === 0 && /^v\d+\.\d+\.\d+/.test(result.stdout.trim());
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@signetai/connector-codex",
|
|
3
|
-
"version": "0.200.
|
|
3
|
+
"version": "0.200.4",
|
|
4
4
|
"description": "Signet connector for Codex CLI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -24,8 +24,8 @@
|
|
|
24
24
|
"typecheck": "tsc --noEmit"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@signetai/connector-base": "0.200.
|
|
28
|
-
"@signetai/core": "0.200.
|
|
27
|
+
"@signetai/connector-base": "0.200.4",
|
|
28
|
+
"@signetai/core": "0.200.4"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@types/node": "^22.0.0",
|