October 17, 2025

AWS Q CLI Zsh setting

 

If you want to pull in your local .zshrc settings for each shell launch, you can follow the following steps:
  1. copy the following content to a new file named "myzsh" and put it somewhere in your local bin folder. I put it under ~/bin/myzsh
#!/bin/zsh # More robust wrapper that handles -c flag properly if [[ "$1" == "-c" ]]; then source ~/.zshrc eval "$2" else # Fallback to regular zsh behavior exec zsh "$@" fi
2.
chmod +x ~/bin/myzsh export AMAZON_Q_CHAT_SHELL="$HOME/bin/myzsh"
And use q chat as you normally do. in my case, it was able to see all the aliases I defined in my .zshrc file while before doing this it couldn't see them.

No comments:

Post a Comment