4c73584025d0d70fde4a8e5c17d8a1d42a2a72ff
- Author
- B YI <uuuuuu@protonmail.com>
- Committer
- GitHub <noreply@github.com>
- Date
Message
aws: fix awscli completion path on NixOS (#8707)
Diff
1diff --git a/plugins/aws/aws.plugin.zsh b/plugins/aws/aws.plugin.zsh
2index eab3dc76b23124096ef7164b7c39dc72fbd8f9e7..6fa8362ca944931ac5ef007afa1a8ad8a7930bc2 100644
3--- a/plugins/aws/aws.plugin.zsh
4+++ b/plugins/aws/aws.plugin.zsh
5@@ -92,6 +92,9 @@ else
6 # Ubuntu
7 elif [[ -e /usr/share/zsh/vendor-completions/_awscli ]]; then
8 _aws_zsh_completer_path=/usr/share/zsh/vendor-completions/_awscli
9+ # NixOS
10+ elif [[ -e "${commands[aws]:P:h:h}/share/zsh/site-functions/aws_zsh_completer.sh" ]]; then
11+ _aws_zsh_completer_path="${commands[aws]:P:h:h}/share/zsh/site-functions/aws_zsh_completer.sh"
12 # RPM
13 else
14 _aws_zsh_completer_path=/usr/share/zsh/site-functions/aws_zsh_completer.sh