blob: d8c9dc496b96c805d37a8d5a5060dc9c8c2f93ae (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
|
# Maintainer: Valery Kartel <valery.kartel@gmail.com>
# Contributor: Valery Kartel <valery.kartel@gmail.com>
pkgname=aws-cli
pkgver=1.17.10
pkgrel=0
pkgdesc="Universal Command Line Interface for Amazon Web Services"
url="https://github.com/aws/aws-cli"
arch="noarch"
license="Apache-2.0"
depends="python3 groff py3-botocore py3-jmespath py3-s3transfer py3-docutils
py3-colorama py3-yaml py3-rsa"
makedepends="python3-dev py3-setuptools"
subpackages="
$pkgname-doc
$pkgname-zsh-completion:zshcomp
$pkgname-bash-completion:bashcomp
$pkgname-completer
"
source="aws-cli-$pkgver.tar.gz::https://github.com/aws/aws-cli/archive/$pkgver.tar.gz"
build() {
python3 setup.py build
}
check() {
python3 setup.py check
}
package() {
python3 setup.py install --prefix=/usr --root="$pkgdir"
rm -fr "$pkgdir"/usr/bin/aws.cmd \
$(find "$pkgdir" -name "*.egg-info")
}
bashcomp() {
depends="$pkgname-completer"
pkgdesc="$pkgdesc (bash completions)"
install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
mkdir -p "$subpkgdir"/usr/share/bash-completion/completions
mv "$pkgdir"/usr/bin/aws_bash_completer \
"$subpkgdir"/usr/share/bash-completion/completions
}
zshcomp() {
depends="$pkgname-completer"
pkgdesc="$pkgdesc (zsh completions)"
install_if="$pkgname=$pkgver-r$pkgrel zsh"
mkdir -p "$subpkgdir"/usr/share/zsh/site-functions
mv "$pkgdir"/usr/bin/aws_zsh_completer.sh \
"$subpkgdir"/usr/share/zsh/site-functions
}
completer() {
depends=""
pkgdesc="$pkgdesc (completions helper)"
cd "$pkgdir"
local file; for file in $(find . -name "*completer*"); do
echo $(dirname $file)
mkdir -p "$subpkgdir"/$(dirname $file)
mv "$pkgdir"/$file "$subpkgdir"/$file
done
}
doc() {
default_doc
local path=$(python3 -c "import sys;print(sys.path[-1])")/awscli
mkdir -p "$subpkgdir"/$path
mv "$pkgdir"/$path/examples "$pkgdir"/$path/topics \
"$subpkgdir"/$path/
}
sha512sums="8c8c0cd03f1916b2780b35380c60b748162c759da9346b379c13f4ff5afbacb6d95d3ffebe8fe4929fb601c5c5fe416fc6d296ca71c034162b3042525af8e87f aws-cli-1.17.10.tar.gz"
|