Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
oh-my-zsh
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
github
oh-my-zsh
Commits
d16adb6a
Commit
d16adb6a
authored
Apr 29, 2019
by
dorons
Committed by
Marc Cornellà
Apr 29, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
aws: fix path resolution of aws completion for Ubuntu (#7812)
parent
f5b2d9c7
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
5 deletions
+12
-5
aws.plugin.zsh
plugins/aws/aws.plugin.zsh
+12
-5
No files found.
plugins/aws/aws.plugin.zsh
View file @
d16adb6a
...
@@ -67,11 +67,18 @@ _awscli-homebrew-installed() {
...
@@ -67,11 +67,18 @@ _awscli-homebrew-installed() {
# get aws_zsh_completer.sh location from $PATH
# get aws_zsh_completer.sh location from $PATH
_aws_zsh_completer_path
=
"
$commands
[aws_zsh_completer.sh]"
_aws_zsh_completer_path
=
"
$commands
[aws_zsh_completer.sh]"
# otherwise check if installed via Homebrew
# otherwise check common locations
if
[[
-z
$_aws_zsh_completer_path
]]
&&
_awscli-homebrew-installed
;
then
if
[[
-z
$_aws_zsh_completer_path
]]
;
then
# Homebrew
if
_awscli-homebrew-installed
;
then
_aws_zsh_completer_path
=
$_brew_prefix
/libexec/bin/aws_zsh_completer.sh
_aws_zsh_completer_path
=
$_brew_prefix
/libexec/bin/aws_zsh_completer.sh
else
# Ubuntu
elif
[[
-e
/usr/share/zsh/vendor-completions/_awscli
]]
;
then
_aws_zsh_completer_path
=
/usr/share/zsh/vendor-completions/_awscli
# RPM
else
_aws_zsh_completer_path
=
/usr/share/zsh/site-functions/aws_zsh_completer.sh
_aws_zsh_completer_path
=
/usr/share/zsh/site-functions/aws_zsh_completer.sh
fi
fi
fi
[[
-r
$_aws_zsh_completer_path
]]
&&
source
$_aws_zsh_completer_path
[[
-r
$_aws_zsh_completer_path
]]
&&
source
$_aws_zsh_completer_path
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment