mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-12 11:10:43 +00:00
build: exclude private QA from npm package
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { isQaLabCliAvailable } from "../../plugin-sdk/qa-lab.js";
|
||||
import { defineCommandDescriptorCatalog } from "./command-descriptor-utils.js";
|
||||
import type { NamedCommandDescriptor } from "./command-group-descriptors.js";
|
||||
import { isPrivateQaCliEnabled } from "./private-qa-cli.js";
|
||||
|
||||
export type SubCliDescriptor = NamedCommandDescriptor;
|
||||
|
||||
@@ -164,7 +164,7 @@ export const SUB_CLI_DESCRIPTORS = subCliCommandCatalog.descriptors;
|
||||
|
||||
export function getSubCliEntries(): ReadonlyArray<SubCliDescriptor> {
|
||||
const descriptors = subCliCommandCatalog.getDescriptors();
|
||||
if (isQaLabCliAvailable()) {
|
||||
if (isPrivateQaCliEnabled()) {
|
||||
return descriptors;
|
||||
}
|
||||
return descriptors.filter((descriptor) => descriptor.name !== "qa");
|
||||
@@ -172,7 +172,7 @@ export function getSubCliEntries(): ReadonlyArray<SubCliDescriptor> {
|
||||
|
||||
export function getSubCliCommandsWithSubcommands(): string[] {
|
||||
const commands = subCliCommandCatalog.getCommandsWithSubcommands();
|
||||
if (isQaLabCliAvailable()) {
|
||||
if (isPrivateQaCliEnabled()) {
|
||||
return commands;
|
||||
}
|
||||
return commands.filter((command) => command !== "qa");
|
||||
|
||||
Reference in New Issue
Block a user