1
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-10-16 19:50:09 +00:00

Compare commits

...

7 commits

Author SHA1 Message Date
Pandu E POLUAN
274d43ce03
Merge branch 'ohmyzsh:master' into omz-subexecutor 2024-03-18 15:43:55 +07:00
Colin Barnabas
0fed36688f
fix(docker-compose): completion regression (#12288) 2024-03-16 11:26:48 +07:00
ohmyzsh[bot]
d0bddee6e3
feat(gradle): update completion to version 25da917c (#12287)
Co-authored-by: ohmyzsh[bot] <54982679+ohmyzsh[bot]@users.noreply.github.com>
2024-03-15 19:55:43 +07:00
Carlo Sala
8940fa2913
fix(dependencies): copy gradle LICENSE 2024-03-15 19:53:43 +07:00
Carlo Sala
fff9ab7619
feat(dependencies): enable gradle plugin 2024-03-15 19:49:24 +07:00
shuangcui
c8ba08581d
docs: fix typos (#12284) 2024-03-14 23:07:39 +07:00
guangwu
6780b19329
docs(pyenv): fix typo (#12283) 2024-03-14 17:37:06 +07:00
13 changed files with 39 additions and 37 deletions

View file

@ -29,3 +29,10 @@ dependencies:
postcopy: |
set -e
test -e dependencies/OMZ-README.md && cat dependencies/OMZ-README.md >> README.md
plugins/gradle:
repo: gradle/gradle-completion
branch: master
version: 25da917cf5a88f3e58f05be3868a7b2748c8afe6
precopy: |
set -e
find . ! -name _gradle ! -name LICENSE -delete

View file

@ -448,7 +448,7 @@ function _omz::plugin::load {
if [[ ! -f "$base/_$plugin" && ! -f "$base/$plugin.plugin.zsh" ]]; then
_omz::log warn "'$plugin' is not a valid plugin"
continue
# It it is a valid plugin, add its directory to $fpath unless it is already there
# It is a valid plugin, add its directory to $fpath unless it is already there
elif (( ! ${fpath[(Ie)$base]} )); then
fpath=("$base" $fpath)
fi

View file

@ -1,6 +1,6 @@
# catimg
Plugin for displaying images on the terminal using the the `catimg.sh` script provided by [posva](https://github.com/posva/catimg)
Plugin for displaying images on the terminal using the `catimg.sh` script provided by [posva](https://github.com/posva/catimg)
To use it, add `catimg` to the plugins array in your zshrc file:

View file

@ -128,7 +128,7 @@ __docker-compose_subcommand() {
'--resolve-image-digests[Pin image tags to digests.]' \
'--services[Print the service names, one per line.]' \
'--volumes[Print the volume names, one per line.]' \
'--hash[Print the service config hash, one per line. Set "service1,service2" for a list of specified services.]' \ && ret=0
'--hash[Print the service config hash, one per line. Set "service1,service2" for a list of specified services.]' && ret=0
;;
(create)
_arguments \

View file

@ -27,4 +27,4 @@ The plugin uses a custom launcher (which we'll call here `$EMACS_LAUNCHER`) that
| eeval | `$EMACS_LAUNCHER --eval` | Same as `M-x eval` but from outside Emacs |
| eframe | `emacsclient --alternate-editor="" --create-frame` | Create new X frame |
| efile | - | Print the path to the file open in the current buffer |
| ecd | - | Print the directory of the file open in the the current buffer |
| ecd | - | Print the directory of the file open in the current buffer |

View file

@ -60,7 +60,7 @@ function efile {
}
# Write to standard output the directory of the file
# opened in the the current buffer
# opened in the current buffer
function ecd {
local file
file="$(efile)" || return $?

19
plugins/gradle/LICENSE Normal file
View file

@ -0,0 +1,19 @@
Copyright (c) 2017 Eric Wendelin
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View file

@ -1,28 +1,4 @@
#compdef gradle gradlew gw
# THE LINE ABOVE MUST BE THE FIRST LINE OF THIS FILE IN ORDER FOR COMPLETION TO WORK
#
# Taken from https://github.com/gradle/gradle-completion
# Copyright (c) 2017 Eric Wendelin
#
# Permission is hereby granted, free of charge, to any person obtaining a copy of
# this software and associated documentation files (the "Software"), to deal in
# the Software without restriction, including without limitation the rights to
# use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
# of the Software, and to permit persons to whom the Software is furnished to do
# so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
# Terms
__gradle-set-project-root-dir() {
local dir=`pwd`
@ -38,7 +14,7 @@ __gradle-set-project-root-dir() {
}
__gradle-init-cache-dir() {
cache_dir="$HOME/.gradle/completion"
cache_dir="${GRADLE_USER_HOME:-$HOME/.gradle}/completion"
mkdir -p $cache_dir
}
@ -98,7 +74,7 @@ __gradle-generate-script-cache() {
zle -R "Generating Gradle build script cache"
# Cache all Gradle scripts
local -a gradle_build_scripts
gradle_build_scripts=( $(find $project_root_dir -type f -name "*.gradle" -o -name "*.gradle.kts" 2>/dev/null | egrep -v "$script_exclude_pattern") )
gradle_build_scripts=( $(find $project_root_dir -type f -name "*.gradle" -o -name "*.gradle.kts" 2>/dev/null | grep -E -v "$script_exclude_pattern") )
printf "%s\n" "${gradle_build_scripts[@]}" >| $cache_dir/$cache_name
fi
}
@ -125,7 +101,7 @@ __gradle-generate-tasks-cache() {
local gradle_all_tasks="" root_tasks="" subproject_tasks="" output_line
local -a match
for output_line in ${(f)"$(printf "%s\n" "${gradle_tasks_output[@]}")"}; do
if [[ $output_line =~ ^([[:lower:]][[:alnum:][:punct:]]*)([[:space:]]-[[:space:]]([[:print:]]*))? ]]; then
if [[ $output_line =~ ^([[:alpha:]][[:alnum:][:punct:]]*)([[:space:]]-[[:space:]]([[:print:]]*))? ]]; then
local task_name="${match[1]}"
local task_description="${match[3]}"
# Completion for subproject tasks with ':' prefix

View file

@ -202,7 +202,7 @@ _ipfs_subcommand(){
_arguments \
'--resolve[Check if the given path can be resolved before publishing. Default: true.]' \
'(-t --lifetime)'{-t,--lifetime}'[Time duration that the record will be valid for. Default: 24h.]' \
'--allow-offline[When offline, save the IPNS record to the the local datastore without broadcasting to the network instead of simply failing.]' \
'--allow-offline[When offline, save the IPNS record to the local datastore without broadcasting to the network instead of simply failing.]' \
'--ttl[Time duration this record should be cached for. Uses the same syntax as the lifetime option. (caution: experimental).]' \
'(-k --key)'{-k,--key}"[Name of the key to be used or a valid PeerID, as listed by 'ipfs key list -l'. Default: self.]" \
'(-Q --quieter)'{-Q,--quieter}'[Write only final hash.]' \

View file

@ -97,7 +97,7 @@ __run() {
'-address=[(addr) The address of the Nomad server. Overrides the NOMAD_ADDR environment variable if set. Default = http://127.0.0.1:4646]' \
'-region=[(region) The region of the Nomad servers to forward commands to. Overrides the NOMAD_REGION environment variable if set. Defaults to the Agent s local region.]' \
'-no-color[Disables colored command output.]' \
'-check-index[If set, the job is only registered or updated if the the passed job modify index matches the server side version. If a check-index value of zero is passed, the job is only registered if it does not yet exist. If a non-zero value is passed, it ensures that the job is being updated from a known state. The use of this flag is most common in conjunction with plan command.]' \
'-check-index[If set, the job is only registered or updated if the passed job modify index matches the server side version. If a check-index value of zero is passed, the job is only registered if it does not yet exist. If a non-zero value is passed, it ensures that the job is being updated from a known state. The use of this flag is most common in conjunction with plan command.]' \
'-detach[Return immediately instead of entering monitor mode. After job submission, the evaluation ID will be printed to the screen, which can be used to examine the evaluation using the eval-status command.]' \
'-output[Output the JSON that would be submitted to the HTTP API without submitting the job.]' \
'-verbose[Show full information.]'

View file

@ -21,7 +21,7 @@
#-------------------------------------------------------------------------------
#
# The idea/inspiration for a per directory history is from Stewart MacArthur[1]
# and Dieter[2], the implementation idea is from Bart Schaefer on the the zsh
# and Dieter[2], the implementation idea is from Bart Schaefer on the zsh
# mailing list[3]. The implementation is by Jim Hester in September 2012.
#
# [1]: http://www.compbiome.com/2010/07/bash-per-directory-bash-history.html

View file

@ -10,7 +10,7 @@ To use it, add `pyenv` to the plugins array in your zshrc file:
plugins=(... pyenv)
```
If you receive a `Found pyenv, but it is badly configured.` error on startup, you may need to ensure that `pyenv` is initialized before the oh-my-zsh pyenv plugin is loaded. This can be achived by adding the following earlier in the `.zshrc` file than the `plugins=(...)` line:
If you receive a `Found pyenv, but it is badly configured.` error on startup, you may need to ensure that `pyenv` is initialized before the oh-my-zsh pyenv plugin is loaded. This can be achieved by adding the following earlier in the `.zshrc` file than the `plugins=(...)` line:
```zsh
export PYENV_ROOT="$HOME/.pyenv"

View file

@ -90,7 +90,7 @@ use the `ssh-add-args` setting. You can pass multiple arguments separated by spa
zstyle :omz:plugins:ssh-agent ssh-add-args -K -c -a /run/user/1000/ssh-auth
```
These will then be passed the the `ssh-add` call as if written directly. The example
These will then be passed the `ssh-add` call as if written directly. The example
above will turn into:
```zsh