LoginSignup
1
1

More than 3 years have passed since last update.

Mac OS (zsh) で awscli の補完機能を使いたい

Posted at

AWS CLI インストール手順

1. Homebrew で awscli インストール

% brew install awscli
(----省略----)
zsh completions and functions have been installed to:
  /usr/local/share/zsh/site-functions
#^^^^^ここに補完機能のパスが表示される^^^^^^
% aws --version
aws-cli/2.1.10 Python/3.9.1 Darwin/20.1.0 source/x86_64 prompt/off

2.補完機能を有効にする

2.1 .zshenv を編集する

% echo "autoload -Uz compinit && compinit -u" >> .zshenv

2.2 .zshrc を編集する

%  echo "source /usr/local/share/zsh/site-functions/aws_zsh_completer.sh" >> .zshrc

3.補完機能を確認する

 % aws ec2 (ここでtabを押す) 
zsh: do you wish to see all 436 possibilities (436 lines)? 

よし。でけた。

参考文献

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1