nestjs-shell
nestjs-shell copied to clipboard
Interface completer
Hey, can you allow us more control over the behaviour of the interface? Passing Partial<ReadLineOptions> through shellFacade.bootstrap or have it return the readline interface?
My end goal is the implemented the following which would allow for an auto complete functionality
completer: (line: string) => {
const commands = this.shellFacade.getAllCommands();
const filteredCommands = commands
.map((command) => command.name)
.filter((command) => command.startsWith(line));
return [filteredCommands, line];
},
Hi @lukemovement , thanks for the issue. Sadly I don't have enough free time to commit to this, but I will gladly review & accept a PR if you decide to create one