@topolo/cli 0.1.25 → 0.1.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.
- package/dist/index.js +14 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -8593,14 +8593,15 @@ function buildRows(catalog, overrides, environment = selectedEnvironment()) {
|
|
|
8593
8593
|
return catalog.map((entry) => {
|
|
8594
8594
|
const id = displayServiceId(entry);
|
|
8595
8595
|
const defaultUrl = defaultServiceUrl(id, entry.baseUrl);
|
|
8596
|
-
const
|
|
8596
|
+
const configuredUrl = configuredServiceUrl(id, resolvedOverrides);
|
|
8597
|
+
const effectiveUrl = configuredUrl || defaultUrl;
|
|
8597
8598
|
return {
|
|
8598
8599
|
id,
|
|
8599
8600
|
serviceId: entry.serviceId,
|
|
8600
8601
|
slug: entry.slug,
|
|
8601
8602
|
defaultUrl,
|
|
8602
8603
|
effectiveUrl,
|
|
8603
|
-
overridden:
|
|
8604
|
+
overridden: Boolean(configuredUrl && configuredUrl !== defaultUrl),
|
|
8604
8605
|
environmentSafe: environment !== "staging" || isStagingUrl(effectiveUrl),
|
|
8605
8606
|
permissions: [...entry.permissions]
|
|
8606
8607
|
};
|
|
@@ -8637,7 +8638,17 @@ function displayServiceId(entry) {
|
|
|
8637
8638
|
return serviceIdCandidates(entry.slug || entry.serviceId)[0] || entry.serviceId;
|
|
8638
8639
|
}
|
|
8639
8640
|
function defaultServiceUrl(id, fallback) {
|
|
8640
|
-
return DEFAULT_SERVICE_URLS[id] ??
|
|
8641
|
+
return fallback ?? DEFAULT_SERVICE_URLS[id] ?? "";
|
|
8642
|
+
}
|
|
8643
|
+
function configuredServiceUrl(id, overrides) {
|
|
8644
|
+
if (!overrides) return null;
|
|
8645
|
+
for (const candidate of serviceIdCandidates(id)) {
|
|
8646
|
+
const direct = overrides[candidate];
|
|
8647
|
+
if (direct) return direct;
|
|
8648
|
+
const envStyle = overrides[candidate.replace(/\./g, "_")];
|
|
8649
|
+
if (envStyle) return envStyle;
|
|
8650
|
+
}
|
|
8651
|
+
return null;
|
|
8641
8652
|
}
|
|
8642
8653
|
function serviceIdCandidates(value) {
|
|
8643
8654
|
const normalized = value.trim().toLowerCase().replace(/\s+/g, "-");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@topolo/cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.26",
|
|
4
4
|
"description": "Command-line interface for Topolo developers, operators, and agents, with internal first-party scaffolding available under the topolo platform namespace.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|