Skip to content

Commit 1a639e4

Browse files
committed
[ci skip] zsh-completion
1 parent 624ab93 commit 1a639e4

File tree

3 files changed

+50
-2
lines changed

3 files changed

+50
-2
lines changed

release.sh

+11-2
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,24 @@ set -eux
44

55
find build/ -mindepth 1 -delete
66

7-
mkdir -p build/bin/ build/share/man/man1/ build/share/licenses/git-get/ build/arch/
87
VERSION="$(git describe --always --dirty | sed 's/-/_/g')"
98
DATE="$(date -Id)"
109

11-
cp LICENSE build/share/licenses/git-get/
10+
mkdir -p build/bin/
1211
sed "s|GIT_GET_VERSION=|GIT_GET_VERSION=$VERSION|" git-get >build/bin/git-get
1312
sed "s|GIT_GET_VERSION=|GIT_GET_VERSION=$VERSION|" git-gets >build/bin/git-gets
13+
14+
mkdir -p build/share/man/man1/
1415
sed "s|GIT_GET_VERSION|$VERSION|; s|GIT_GET_DATE|$DATE|" man/git-get.1 >build/share/man/man1/git-get.1
1516
sed "s|GIT_GET_VERSION|$VERSION|; s|GIT_GET_DATE|$DATE|" man/git-gets.1 >build/share/man/man1/git-gets.1
1617

18+
mkdir -p build/share/licenses/git-get/
19+
cp LICENSE build/share/licenses/git-get/
20+
21+
mkdir -p build/share/zsh/site-functions/
22+
cp zsh/_git-get build/share/zsh/site-functions/_git-get
23+
cp zsh/_git-gets build/share/zsh/site-functions/_git-gets
24+
1725
chmod +x build/bin/git-get build/bin/git-gets
1826

1927
(
@@ -29,6 +37,7 @@ gpg --detach-sign build/git-get.tar.gz
2937
gpg --detach-sign build/git-get.tar.xz
3038
gpg --detach-sign build/git-get.zip
3139

40+
mkdir -p build/arch/
3241
cat - <<EOF >build/arch/PKGBUILD
3342
# Maintainer: b1f6c1c4 <[email protected]>
3443
pkgname=git-get

zsh/_git-get

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#compdef git-get
2+
3+
_arguments -s -S -A "-*" \
4+
'(*)'{-V,--version}'[Show git-get version]' \
5+
'(*)'{-h,--help}'[Show documentation]' \
6+
'(-v --verbose)'{-v,--verbose}'[Show intermediate steps]' \
7+
'(-q --quiet)'{-q,--quiet}'[Hide every intermediate information but errors]' \
8+
'(--color --colour)'{--color=,--colour=}'[Display steps in color]:when:(never always auto)' \
9+
'(-s --ssh -H --https)'{-s,--ssh}'[Enforce SSH protocol]' \
10+
'(-H --https -s --ssh)'{-H,--https}'[Enforce HTTPS protocol]' \
11+
'(-o --output)'{-o+,--output=}'[Put the download file or directory here]:directory:_files' \
12+
'(-f --force)'{-f,--force}'[Override an existing file]' \
13+
'(-F --rm-rf)'{-F,--rm-rf}'[Override an existing folder]' \
14+
'(-g --preserve-git -t --tag-file)-x[Preserve and enhance the .git directory]' \
15+
'(-B --single-branch)'{-B,--single-branch}'[Cleanup unnecessary branches]' \
16+
'(-T --no-tags)'{-T,--no-tags}'[Cleanup all tags]' \
17+
'(-g --preserve-git -x -t --tag-file)'{-g,--preserve-git}'[Preserve the .git directory]' \
18+
'(-t --tag-file)'{-t+,--tag-file=}'[Generate a tag file (default=VERSION)]:file:_files'

zsh/_git-gets

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#compdef git-gets
2+
3+
_arguments -s -S -A "-*" \
4+
'(*)'{-V,--version}'[Show git-gets version]' \
5+
'(*)'{-h,--help}'[Show documentation]' \
6+
'(-v --verbose)'{-v,--verbose}'[Show intermediate steps]' \
7+
'(-q --quiet)'{-q,--quiet}'[Hide every intermediate information but errors]' \
8+
'(--color --colour)'{--color=,--colour=}'[Display steps in color]:when:(never always auto)' \
9+
'(-s --ssh -H --https)'{-s,--ssh}'[Enforce SSH protocol]' \
10+
'(-H --https -s --ssh)'{-H,--https}'[Enforce HTTPS protocol]' \
11+
'--no-recursive[Only top-level submodules]' \
12+
'(-o --output)'{-o+,--output=}'[Put the download file or directory here]:directory:_files' \
13+
'(-F --rm-rf)'{-F,--rm-rf}'[Override an existing folder]' \
14+
'(-g --preserve-git -t --tag-file)-x[Preserve and enhance the .git directory]' \
15+
'(-B --single-branch)'{-B,--single-branch}'[Cleanup unnecessary branches]' \
16+
'(-T --no-tags)'{-T,--no-tags}'[Cleanup all tags]' \
17+
'(-g --preserve-git -x -t --tag-file)'{-g,--preserve-git}'[Preserve the .git directory]' \
18+
'(-t --tag-file)'{-t+,--tag-file=}'[Generate a tag file (default=VERSION)]:file:_files' \
19+
'(-P --parallel)'{-P,--parallel}'[Launch multiple instances of git-clone]' \
20+
'(-c --confirm)'{-c,--confirm}'[Prompt the user before downloading]' \
21+
'--no-init[Only download already inited top-level submodules]'

0 commit comments

Comments
 (0)