Porytiles
Loading...
Searching...
No Matches
CompletionCommand Class Referencefinal

Command that outputs shell completion scripts. More...

#include <command_completion.hpp>

Inheritance diagram for CompletionCommand:
[legend]
Collaboration diagram for CompletionCommand:
[legend]

Public Member Functions

 CompletionCommand (CLI::App &parent_app)
 
- Public Member Functions inherited from Command
virtual ~Command ()=default
 
 Command (CLI::App &parent_app, const std::string &name, const std::string &desc, const std::string &group)
 
 Command (const Command &)=delete
 
Commandoperator= (const Command &)=delete
 
 Command (Command &&)=delete
 
Commandoperator= (Command &&)=delete
 
CLI::App & get_app () const
 

Detailed Description

Command that outputs shell completion scripts.

CompletionCommand generates shell completion scripts for bash, zsh, and fish. It uses the generated CLI option metadata to provide completions for all config options, including enum choices.

The generated scripts also support dynamic tileset name completion by calling the list-tilesets subcommand. This provides context-sensitive filtering:

  • compile-tileset: shows only managed tilesets
  • decompile-tileset: shows only managed tilesets
  • import-tileset: shows only unmanaged tilesets
  • create-tileset: no completion (user provides new name)

Definition at line 25 of file command_completion.hpp.

Constructor & Destructor Documentation

◆ CompletionCommand()

CompletionCommand::CompletionCommand ( CLI::App &  parent_app)
inlineexplicit

Definition at line 27 of file command_completion.hpp.


The documentation for this class was generated from the following file: