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
d2269180
Unverified
Commit
d2269180
authored
Sep 15, 2021
by
Marc Cornellà
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(core): move plugin-generated completion files to `$ZSH_CACHE_DIR/completions`
Fixes #10183
parent
4e6e4965
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
24 additions
and
5 deletions
+24
-5
oh-my-zsh.sh
oh-my-zsh.sh
+4
-0
cargo.plugin.zsh
plugins/cargo/cargo.plugin.zsh
+4
-1
deno.plugin.zsh
plugins/deno/deno.plugin.zsh
+4
-1
fnm.plugin.zsh
plugins/fnm/fnm.plugin.zsh
+4
-1
gh.plugin.zsh
plugins/gh/gh.plugin.zsh
+4
-1
rustup.plugin.zsh
plugins/rustup/rustup.plugin.zsh
+4
-1
No files found.
oh-my-zsh.sh
View file @
d2269180
...
@@ -7,6 +7,10 @@ if [[ -z "$ZSH_CACHE_DIR" ]]; then
...
@@ -7,6 +7,10 @@ if [[ -z "$ZSH_CACHE_DIR" ]]; then
ZSH_CACHE_DIR
=
"
$ZSH
/cache"
ZSH_CACHE_DIR
=
"
$ZSH
/cache"
fi
fi
# Create completions cache dir and add to $fpath
mkdir
-p
"
$ZSH_CACHE_DIR
/completions"
((
${
fpath
[(Ie)
$ZSH_CACHE_DIR
/completions]
}
))
||
fpath
=(
"
$ZSH_CACHE_DIR
/completions"
$fpath
)
# Check for updates on initial load...
# Check for updates on initial load...
if
[
"
$DISABLE_AUTO_UPDATE
"
!=
"true"
]
;
then
if
[
"
$DISABLE_AUTO_UPDATE
"
!=
"true"
]
;
then
source
$ZSH
/tools/check_for_upgrade.sh
source
$ZSH
/tools/check_for_upgrade.sh
...
...
plugins/cargo/cargo.plugin.zsh
View file @
d2269180
if
((
$+
commands[rustup]
&&
$+
commands[cargo]
))
;
then
if
((
$+
commands[rustup]
&&
$+
commands[cargo]
))
;
then
ver
=
"
$(
cargo
--version
)
"
ver
=
"
$(
cargo
--version
)
"
ver_file
=
"
$ZSH_CACHE_DIR
/cargo_version"
ver_file
=
"
$ZSH_CACHE_DIR
/cargo_version"
comp_file
=
"
$ZSH
/plugins/cargo/_cargo"
comp_file
=
"
$ZSH_CACHE_DIR
/completions/_cargo"
mkdir
-p
"
${
comp_file
:h
}
"
((
${
fpath
[(Ie)
${
comp_file
:h
}
]
}
))
||
fpath
=(
"
${
comp_file
:h
}
"
$fpath
)
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
rustup completions zsh cargo
>
|
"
$comp_file
"
rustup completions zsh cargo
>
|
"
$comp_file
"
...
...
plugins/deno/deno.plugin.zsh
View file @
d2269180
...
@@ -14,7 +14,10 @@ alias dup='deno upgrade'
...
@@ -14,7 +14,10 @@ alias dup='deno upgrade'
if
((
$+
commands[deno]
))
;
then
if
((
$+
commands[deno]
))
;
then
ver
=
"
$(
deno
--version
)
"
ver
=
"
$(
deno
--version
)
"
ver_file
=
"
$ZSH_CACHE_DIR
/deno_version"
ver_file
=
"
$ZSH_CACHE_DIR
/deno_version"
comp_file
=
"
$ZSH
/plugins/deno/_deno"
comp_file
=
"
$ZSH_CACHE_DIR
/completions/_deno"
mkdir
-p
"
${
comp_file
:h
}
"
((
${
fpath
[(Ie)
${
comp_file
:h
}
]
}
))
||
fpath
=(
"
${
comp_file
:h
}
"
$fpath
)
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
deno completions zsh
>
|
"
$comp_file
"
deno completions zsh
>
|
"
$comp_file
"
...
...
plugins/fnm/fnm.plugin.zsh
View file @
d2269180
if
((
$+
commands[fnm]
))
;
then
if
((
$+
commands[fnm]
))
;
then
ver
=
"
$(
fnm
--version
)
"
ver
=
"
$(
fnm
--version
)
"
ver_file
=
"
$ZSH_CACHE_DIR
/fnm_version"
ver_file
=
"
$ZSH_CACHE_DIR
/fnm_version"
comp_file
=
"
$ZSH
/plugins/fnm/_fnm"
comp_file
=
"
$ZSH_CACHE_DIR
/completions/_fnm"
mkdir
-p
"
${
comp_file
:h
}
"
((
${
fpath
[(Ie)
${
comp_file
:h
}
]
}
))
||
fpath
=(
"
${
comp_file
:h
}
"
$fpath
)
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
fnm completions
--shell
=
zsh
>
|
"
$comp_file
"
fnm completions
--shell
=
zsh
>
|
"
$comp_file
"
...
...
plugins/gh/gh.plugin.zsh
View file @
d2269180
...
@@ -2,7 +2,10 @@
...
@@ -2,7 +2,10 @@
if
((
$+
commands[gh]
))
;
then
if
((
$+
commands[gh]
))
;
then
ver
=
"
$(
gh
--version
)
"
ver
=
"
$(
gh
--version
)
"
ver_file
=
"
$ZSH_CACHE_DIR
/gh_version"
ver_file
=
"
$ZSH_CACHE_DIR
/gh_version"
comp_file
=
"
$ZSH
/plugins/gh/_gh"
comp_file
=
"
$ZSH_CACHE_DIR
/completions/_gh"
mkdir
-p
"
${
comp_file
:h
}
"
((
${
fpath
[(Ie)
${
comp_file
:h
}
]
}
))
||
fpath
=(
"
${
comp_file
:h
}
"
$fpath
)
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
gh completion
--shell
zsh
>
|
"
$comp_file
"
gh completion
--shell
zsh
>
|
"
$comp_file
"
...
...
plugins/rustup/rustup.plugin.zsh
View file @
d2269180
if
((
$+
commands[rustup]
))
;
then
if
((
$+
commands[rustup]
))
;
then
ver
=
"
$(
rustup
--version
2>/dev/null
)
"
ver
=
"
$(
rustup
--version
2>/dev/null
)
"
ver_file
=
"
$ZSH_CACHE_DIR
/rustup_version"
ver_file
=
"
$ZSH_CACHE_DIR
/rustup_version"
comp_file
=
"
$ZSH
/plugins/rustup/_rustup"
comp_file
=
"
$ZSH_CACHE_DIR
/completions/_rustup"
mkdir
-p
"
${
comp_file
:h
}
"
((
${
fpath
[(Ie)
${
comp_file
:h
}
]
}
))
||
fpath
=(
"
${
comp_file
:h
}
"
$fpath
)
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
if
[[
!
-f
"
$comp_file
"
||
!
-f
"
$ver_file
"
||
"
$ver
"
!=
"
$(
<
"
$ver_file
"
)
"
]]
;
then
rustup completions zsh
>
|
"
$comp_file
"
rustup completions zsh
>
|
"
$comp_file
"
...
...
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