@signetai/connector-gemini 0.219.6 → 0.220.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/dist/index.js +27 -27
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
writeFileSync as writeFileSync2
|
|
12
12
|
} from "node:fs";
|
|
13
13
|
import { homedir as homedir3 } from "node:os";
|
|
14
|
-
import { dirname as
|
|
14
|
+
import { dirname as dirname8, join as join6, resolve as resolve6 } from "node:path";
|
|
15
15
|
|
|
16
16
|
// ../../../libs/connector-base/dist/index.js
|
|
17
17
|
import { randomBytes } from "node:crypto";
|
|
@@ -53,9 +53,9 @@ import { homedir as homedir5 } from "node:os";
|
|
|
53
53
|
import { dirname as dirname4, join as join8, resolve as resolve3 } from "node:path";
|
|
54
54
|
import { homedir as homedir6, platform as platform2 } from "node:os";
|
|
55
55
|
import { basename, dirname as dirname5, resolve as resolve5 } from "node:path";
|
|
56
|
-
import { homedir as
|
|
57
|
-
import { existsSync as
|
|
58
|
-
import { join as
|
|
56
|
+
import { homedir as homedir8 } from "node:os";
|
|
57
|
+
import { existsSync as existsSync13, lstatSync, mkdirSync as mkdirSync8, readdirSync as readdirSync6, symlinkSync, unlinkSync as unlinkSync2 } from "node:fs";
|
|
58
|
+
import { join as join13 } from "node:path";
|
|
59
59
|
var __create2 = Object.create;
|
|
60
60
|
var __getProtoOf2 = Object.getPrototypeOf;
|
|
61
61
|
var __defProp2 = Object.defineProperty;
|
|
@@ -18073,19 +18073,19 @@ function symlinkSkills(sourceDir, targetDir, options = {}) {
|
|
|
18073
18073
|
skipped: [],
|
|
18074
18074
|
errors: []
|
|
18075
18075
|
};
|
|
18076
|
-
if (!
|
|
18076
|
+
if (!existsSync13(sourceDir)) {
|
|
18077
18077
|
return result;
|
|
18078
18078
|
}
|
|
18079
|
-
const targetParent =
|
|
18080
|
-
if (!
|
|
18081
|
-
|
|
18079
|
+
const targetParent = join13(targetDir, "..");
|
|
18080
|
+
if (!existsSync13(targetParent)) {
|
|
18081
|
+
mkdirSync8(targetParent, { recursive: true });
|
|
18082
18082
|
}
|
|
18083
|
-
if (!
|
|
18084
|
-
|
|
18083
|
+
if (!existsSync13(targetDir)) {
|
|
18084
|
+
mkdirSync8(targetDir, { recursive: true });
|
|
18085
18085
|
}
|
|
18086
18086
|
let entries;
|
|
18087
18087
|
try {
|
|
18088
|
-
entries =
|
|
18088
|
+
entries = readdirSync6(sourceDir);
|
|
18089
18089
|
} catch (e) {
|
|
18090
18090
|
result.errors.push({
|
|
18091
18091
|
path: sourceDir,
|
|
@@ -18094,8 +18094,8 @@ function symlinkSkills(sourceDir, targetDir, options = {}) {
|
|
|
18094
18094
|
return result;
|
|
18095
18095
|
}
|
|
18096
18096
|
for (const entry of entries) {
|
|
18097
|
-
const srcPath =
|
|
18098
|
-
const destPath =
|
|
18097
|
+
const srcPath = join13(sourceDir, entry);
|
|
18098
|
+
const destPath = join13(targetDir, entry);
|
|
18099
18099
|
try {
|
|
18100
18100
|
const src = lstatSync(srcPath);
|
|
18101
18101
|
if (src.isSymbolicLink() || !src.isDirectory()) {
|
|
@@ -18136,7 +18136,7 @@ function symlinkSkills(sourceDir, targetDir, options = {}) {
|
|
|
18136
18136
|
}
|
|
18137
18137
|
return result;
|
|
18138
18138
|
}
|
|
18139
|
-
var home =
|
|
18139
|
+
var home = homedir8();
|
|
18140
18140
|
var SIGNET_BLOCK_START = "<!-- SIGNET:START -->";
|
|
18141
18141
|
var SIGNET_BLOCK_END = "<!-- SIGNET:END -->";
|
|
18142
18142
|
function stripSignetBlock(content) {
|
|
@@ -18277,9 +18277,9 @@ import { homedir as homedir52 } from "node:os";
|
|
|
18277
18277
|
import { dirname as dirname42, join as join82, resolve as resolve32 } from "node:path";
|
|
18278
18278
|
import { homedir as homedir62, platform as platform22 } from "node:os";
|
|
18279
18279
|
import { basename as basename2, dirname as dirname52, resolve as resolve52 } from "node:path";
|
|
18280
|
-
import { existsSync as
|
|
18281
|
-
import { dirname as
|
|
18282
|
-
import { homedir as
|
|
18280
|
+
import { existsSync as existsSync11, readFileSync as readFileSync9, realpathSync as realpathSync2, statSync as statSync7 } from "node:fs";
|
|
18281
|
+
import { dirname as dirname62, join as join11 } from "node:path";
|
|
18282
|
+
import { homedir as homedir82 } from "node:os";
|
|
18283
18283
|
var __create = Object.create;
|
|
18284
18284
|
var __getProtoOf = Object.getPrototypeOf;
|
|
18285
18285
|
var __defProp = Object.defineProperty;
|
|
@@ -36238,7 +36238,7 @@ function hasValidIdentity(basePath) {
|
|
|
36238
36238
|
if (mode !== "managed")
|
|
36239
36239
|
return true;
|
|
36240
36240
|
for (const path of resolveRequiredIdentityPaths(basePath)) {
|
|
36241
|
-
if (!
|
|
36241
|
+
if (!existsSync11(join11(basePath, path))) {
|
|
36242
36242
|
return false;
|
|
36243
36243
|
}
|
|
36244
36244
|
}
|
|
@@ -36246,11 +36246,11 @@ function hasValidIdentity(basePath) {
|
|
|
36246
36246
|
}
|
|
36247
36247
|
function resolveRequiredIdentityPaths(basePath) {
|
|
36248
36248
|
const legacyRequired = () => REQUIRED_IDENTITY_KEYS2.map((key) => IDENTITY_FILES2[key].path);
|
|
36249
|
-
const agentYaml =
|
|
36250
|
-
if (!
|
|
36249
|
+
const agentYaml = join11(basePath, "agent.yaml");
|
|
36250
|
+
if (!existsSync11(agentYaml))
|
|
36251
36251
|
return legacyRequired();
|
|
36252
36252
|
try {
|
|
36253
|
-
const config = parseSimpleYaml(
|
|
36253
|
+
const config = parseSimpleYaml(readFileSync9(agentYaml, "utf-8"));
|
|
36254
36254
|
const identity = readRecord(readRecord(config).identity);
|
|
36255
36255
|
const configured = readIdentityEntryList(readRecord(identity.startup).load);
|
|
36256
36256
|
if (configured.length > 0)
|
|
@@ -36293,11 +36293,11 @@ function resolveIdentityModeFromConfig(config) {
|
|
|
36293
36293
|
return "managed";
|
|
36294
36294
|
}
|
|
36295
36295
|
function loadIdentityMode(agentsDir) {
|
|
36296
|
-
const agentYaml =
|
|
36297
|
-
if (!
|
|
36296
|
+
const agentYaml = join11(agentsDir, "agent.yaml");
|
|
36297
|
+
if (!existsSync11(agentYaml))
|
|
36298
36298
|
return "managed";
|
|
36299
36299
|
try {
|
|
36300
|
-
return resolveIdentityModeFromConfig(parseSimpleYaml(
|
|
36300
|
+
return resolveIdentityModeFromConfig(parseSimpleYaml(readFileSync9(agentYaml, "utf-8")));
|
|
36301
36301
|
} catch {
|
|
36302
36302
|
return "managed";
|
|
36303
36303
|
}
|
|
@@ -36322,7 +36322,7 @@ function readIdentityEntryList(value) {
|
|
|
36322
36322
|
return [];
|
|
36323
36323
|
return value.map(readIdentityEntry).filter((entry) => entry !== null);
|
|
36324
36324
|
}
|
|
36325
|
-
var home2 =
|
|
36325
|
+
var home2 = homedir82();
|
|
36326
36326
|
|
|
36327
36327
|
// src/index.ts
|
|
36328
36328
|
function readGeminiSettings(settingsPath) {
|
|
@@ -36467,7 +36467,7 @@ class GeminiConnector extends BaseConnector {
|
|
|
36467
36467
|
if (stat?.isSymbolicLink()) {
|
|
36468
36468
|
try {
|
|
36469
36469
|
const rawTarget = readlinkSync(entryPath);
|
|
36470
|
-
const target = resolve6(
|
|
36470
|
+
const target = resolve6(dirname8(entryPath), rawTarget);
|
|
36471
36471
|
if (isChildOf(target, signetSkillsSource)) {
|
|
36472
36472
|
unlinkSync3(entryPath);
|
|
36473
36473
|
}
|
|
@@ -36542,7 +36542,7 @@ class GeminiConnector extends BaseConnector {
|
|
|
36542
36542
|
].join(`
|
|
36543
36543
|
`);
|
|
36544
36544
|
const destPath = this.getGeminiMdPath();
|
|
36545
|
-
mkdirSync(
|
|
36545
|
+
mkdirSync(dirname8(destPath), { recursive: true });
|
|
36546
36546
|
writeFileSync2(destPath, header + userContent + extras + notificationPolling);
|
|
36547
36547
|
return destPath;
|
|
36548
36548
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@signetai/connector-gemini",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.220.0",
|
|
4
4
|
"description": "Signet connector for Gemini 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.
|
|
28
|
-
"@signetai/core": "0.
|
|
27
|
+
"@signetai/connector-base": "0.220.0",
|
|
28
|
+
"@signetai/core": "0.220.0"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@types/node": "^22.0.0",
|