@scheduler-systems/gal-run 0.0.275 → 0.0.277
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.cjs +75 -6
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3970,7 +3970,7 @@ var cliVersion, defaultApiUrl, BUILD_CONSTANTS, constants_default;
|
|
|
3970
3970
|
var init_constants = __esm({
|
|
3971
3971
|
"src/constants.ts"() {
|
|
3972
3972
|
"use strict";
|
|
3973
|
-
cliVersion = true ? "0.0.
|
|
3973
|
+
cliVersion = true ? "0.0.277" : "0.0.0-dev";
|
|
3974
3974
|
defaultApiUrl = true ? "https://api.gal.run" : "http://localhost:3000";
|
|
3975
3975
|
BUILD_CONSTANTS = Object.freeze([cliVersion, defaultApiUrl]);
|
|
3976
3976
|
constants_default = BUILD_CONSTANTS;
|
|
@@ -4812,7 +4812,7 @@ function detectEnvironment() {
|
|
|
4812
4812
|
return "dev";
|
|
4813
4813
|
}
|
|
4814
4814
|
try {
|
|
4815
|
-
const version = true ? "0.0.
|
|
4815
|
+
const version = true ? "0.0.277" : void 0;
|
|
4816
4816
|
if (version && version.includes("-local")) {
|
|
4817
4817
|
return "dev";
|
|
4818
4818
|
}
|
|
@@ -5181,7 +5181,7 @@ function getId() {
|
|
|
5181
5181
|
}
|
|
5182
5182
|
function getCliVersion() {
|
|
5183
5183
|
try {
|
|
5184
|
-
return true ? "0.0.
|
|
5184
|
+
return true ? "0.0.277" : "0.0.0-dev";
|
|
5185
5185
|
} catch {
|
|
5186
5186
|
return "0.0.0-dev";
|
|
5187
5187
|
}
|
|
@@ -7731,7 +7731,7 @@ var init_feature_flags2 = __esm({
|
|
|
7731
7731
|
init_src();
|
|
7732
7732
|
COMMAND_CATEGORIES = {
|
|
7733
7733
|
// Core convenience package (always visible)
|
|
7734
|
-
core: ["auth", "sync", "mcp", "feedback", "update", "hooks", "status", "discover", "approve", "approved-config", "propose", "workspace", "fetch", "join", "scan", "memory"],
|
|
7734
|
+
core: ["auth", "sync", "mcp", "feedback", "update", "hooks", "status", "discover", "approve", "approved-config", "propose", "workspace", "fetch", "join", "scan", "memory", "policy"],
|
|
7735
7735
|
// Internal development commands (requires admin org membership or GAL_INTERNAL=true)
|
|
7736
7736
|
internal: [
|
|
7737
7737
|
"admin",
|
|
@@ -7764,7 +7764,6 @@ var init_feature_flags2 = __esm({
|
|
|
7764
7764
|
"workflow",
|
|
7765
7765
|
"work",
|
|
7766
7766
|
"queue",
|
|
7767
|
-
"policy",
|
|
7768
7767
|
"automations"
|
|
7769
7768
|
]
|
|
7770
7769
|
};
|
|
@@ -29970,6 +29969,76 @@ Content hash: ${hash}`));
|
|
|
29970
29969
|
console.log(source_default.yellow("\n\u2713 Dry run complete. No changes made.\n"));
|
|
29971
29970
|
process.exit(0);
|
|
29972
29971
|
}
|
|
29972
|
+
if (options.diff) {
|
|
29973
|
+
const diffSpinner = ora("Fetching current approved config for diff...").start();
|
|
29974
|
+
try {
|
|
29975
|
+
const approved = await configRepo.getApprovedConfig(orgName, approvedPlatform);
|
|
29976
|
+
diffSpinner.stop();
|
|
29977
|
+
const localCommandNames = new Set(commands.map((c) => c.name));
|
|
29978
|
+
const localAgentNames = new Set(subagents.map((s) => s.name));
|
|
29979
|
+
const localSkillNames = new Set(skills.map((s) => s.name));
|
|
29980
|
+
const localRuleNames = new Set(rules.map((r) => r.name));
|
|
29981
|
+
const approvedCommandNames = new Set((approved?.commands ?? []).map((c) => c.name));
|
|
29982
|
+
const approvedAgentNames = new Set((approved?.subagents ?? []).map((s) => s.name));
|
|
29983
|
+
const approvedSkillNames = new Set((approved?.skills ?? []).map((s) => s.name));
|
|
29984
|
+
const approvedRuleNames = new Set((approved?.rules ?? []).map((r) => r.name));
|
|
29985
|
+
const addedCommands = commands.filter((c) => !approvedCommandNames.has(c.name)).map((c) => c.name);
|
|
29986
|
+
const removedCommands = [...approvedCommandNames].filter((n) => !localCommandNames.has(n));
|
|
29987
|
+
const addedAgents = subagents.filter((s) => !approvedAgentNames.has(s.name)).map((s) => s.name);
|
|
29988
|
+
const removedAgents = [...approvedAgentNames].filter((n) => !localAgentNames.has(n));
|
|
29989
|
+
const addedSkills = skills.filter((s) => !approvedSkillNames.has(s.name)).map((s) => s.name);
|
|
29990
|
+
const removedSkills = [...approvedSkillNames].filter((n) => !localSkillNames.has(n));
|
|
29991
|
+
const addedRules = rules.filter((r) => !approvedRuleNames.has(r.name)).map((r) => r.name);
|
|
29992
|
+
const removedRules = [...approvedRuleNames].filter((n) => !localRuleNames.has(n));
|
|
29993
|
+
const hasChanges = addedCommands.length || removedCommands.length || addedAgents.length || removedAgents.length || addedSkills.length || removedSkills.length || addedRules.length || removedRules.length;
|
|
29994
|
+
if (!hasChanges) {
|
|
29995
|
+
console.log(source_default.green("\n\u2713 Local configs match the current approved config. No diff.\n"));
|
|
29996
|
+
process.exit(0);
|
|
29997
|
+
}
|
|
29998
|
+
console.log();
|
|
29999
|
+
console.log(source_default.bold(`Diff: local \u2192 approved config for "${orgName}" (${approvedPlatform})`));
|
|
30000
|
+
console.log();
|
|
30001
|
+
if (addedCommands.length) {
|
|
30002
|
+
console.log(source_default.bold(" Commands to add:"));
|
|
30003
|
+
addedCommands.forEach((n) => console.log(source_default.green(` + /${n}`)));
|
|
30004
|
+
}
|
|
30005
|
+
if (removedCommands.length) {
|
|
30006
|
+
console.log(source_default.bold(" Commands to remove:"));
|
|
30007
|
+
removedCommands.forEach((n) => console.log(source_default.red(` - /${n}`)));
|
|
30008
|
+
}
|
|
30009
|
+
if (addedAgents.length) {
|
|
30010
|
+
console.log(source_default.bold(" Agents to add:"));
|
|
30011
|
+
addedAgents.forEach((n) => console.log(source_default.green(` + ${n}`)));
|
|
30012
|
+
}
|
|
30013
|
+
if (removedAgents.length) {
|
|
30014
|
+
console.log(source_default.bold(" Agents to remove:"));
|
|
30015
|
+
removedAgents.forEach((n) => console.log(source_default.red(` - ${n}`)));
|
|
30016
|
+
}
|
|
30017
|
+
if (addedSkills.length) {
|
|
30018
|
+
console.log(source_default.bold(" Skills to add:"));
|
|
30019
|
+
addedSkills.forEach((n) => console.log(source_default.green(` + ${n}`)));
|
|
30020
|
+
}
|
|
30021
|
+
if (removedSkills.length) {
|
|
30022
|
+
console.log(source_default.bold(" Skills to remove:"));
|
|
30023
|
+
removedSkills.forEach((n) => console.log(source_default.red(` - ${n}`)));
|
|
30024
|
+
}
|
|
30025
|
+
if (addedRules.length) {
|
|
30026
|
+
console.log(source_default.bold(" Rules to add:"));
|
|
30027
|
+
addedRules.forEach((n) => console.log(source_default.green(` + ${n}`)));
|
|
30028
|
+
}
|
|
30029
|
+
if (removedRules.length) {
|
|
30030
|
+
console.log(source_default.bold(" Rules to remove:"));
|
|
30031
|
+
removedRules.forEach((n) => console.log(source_default.red(` - ${n}`)));
|
|
30032
|
+
}
|
|
30033
|
+
console.log();
|
|
30034
|
+
console.log(source_default.dim("Run `gal approve` (without --diff) to apply these changes."));
|
|
30035
|
+
console.log();
|
|
30036
|
+
process.exit(0);
|
|
30037
|
+
} catch (diffError) {
|
|
30038
|
+
diffSpinner.stop();
|
|
30039
|
+
console.log(source_default.yellow("Could not fetch current approved config for diff. Proceeding with upload."));
|
|
30040
|
+
}
|
|
30041
|
+
}
|
|
29973
30042
|
const uploadSpinner = ora("Uploading to approved config...").start();
|
|
29974
30043
|
const hashItem = (content) => (0, import_crypto4.createHash)("sha256").update(content).digest("hex").slice(0, 12);
|
|
29975
30044
|
await configRepo.setApprovedConfig(orgName, {
|
|
@@ -54021,7 +54090,7 @@ var init_index = __esm({
|
|
|
54021
54090
|
});
|
|
54022
54091
|
|
|
54023
54092
|
// src/bootstrap.ts
|
|
54024
|
-
var cliVersion10 = true ? "0.0.
|
|
54093
|
+
var cliVersion10 = true ? "0.0.277" : "0.0.0-dev";
|
|
54025
54094
|
var args = process.argv.slice(2);
|
|
54026
54095
|
var requestedGlobalHelp = args.length === 1 && (args[0] === "--help" || args[0] === "-h");
|
|
54027
54096
|
var requestedVersion = args.length === 1 && (args[0] === "--version" || args[0] === "-V");
|
package/package.json
CHANGED