Generating CLI completions - Amazon Q Developer

Generating CLI completions

You can use Amazon Q Developer to add IDE-style completions to hundreds of popular CLIs like git, npm, docker, and aws. Start typing, and Amazon Q will pop up contextually relevant subcommands, options and arguments.

An example of a CodeWhisperer for command line CLI completion.

The default settings provided by Amazon Q for command line may not "feel right," and may disrupt your existing workflow. You can customize your settings at any time by running q to open the settings dashboard. Here are a few popular settings:

  • Keybindings – Changing the tab keybinding to "Insert common prefix or navigate" may make CLI Completions feel more like traditional shell completions while "Insert common prefix or insert" will feel more like an IDE.

  • Theme – You know what this is. Choose your favorite.

  • Instant execute after space – A lot developers habitually type a space character just before they execute it. Enable this setting to avoid Amazon Q blocking you.

  • First token completion – Enable this setting to get completions for CLIs themselves, not just the subcommands, options, and arguments.

Screenshot of Amazon Q for command line settings.