@@ -2,6 +2,7 @@ import { Command } from "cliffy/command/mod.ts";
22import { quartoConfig } from "../../core/quarto.ts" ;
33import { commands } from "../command.ts" ;
44import { buildJsCommand } from "./build-artifacts/cmd.ts" ;
5+ import { hidden } from "../../core/lib/external/colors.ts" ;
56
67type CommandOptionInfo = {
78 name : string ;
@@ -13,6 +14,7 @@ type CommandOptionInfo = {
1314} ;
1415
1516type CommandInfo = {
17+ hidden : boolean ;
1618 name : string ;
1719 description : string ;
1820 options : CommandOptionInfo [ ] ;
@@ -33,10 +35,19 @@ const generateCliInfoCommand = new Command()
3335 output [ "version" ] = quartoConfig . version ( ) ;
3436 const commandsInfo : CommandInfo [ ] = [ ] ;
3537 output [ "commands" ] = commandsInfo ;
38+
39+ // Cliffy doesn't export the "hidden" property, so we maintain our own list
40+ // here
41+ const hiddenCommands = [
42+ "dev-call" ,
43+ "editor-support" ,
44+ "create-project" ,
45+ ] ;
3646 // deno-lint-ignore no-explicit-any
3747 const cmdAsJson = ( cmd : any ) : CommandInfo => {
3848 return {
3949 name : cmd . getName ( ) ,
50+ hidden : hiddenCommands . includes ( cmd . getName ( ) ) ,
4051 description : cmd . getDescription ( ) ,
4152 options : cmd . getOptions ( ) ,
4253 usage : cmd . getUsage ( ) ,
@@ -50,6 +61,7 @@ const generateCliInfoCommand = new Command()
5061
5162export const devCallCommand = new Command ( )
5263 . name ( "dev-call" )
64+ . hidden ( )
5365 . description (
5466 "Access internals of Quarto - this command is not intended for general use." ,
5567 )
0 commit comments