blob: d31879a17a9696c031e6656a6da66ff1846813c9 (
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
|
# Maintainer:
# Contributor: Jan Buchar <Teyras@gmail.com>
_gitname="krohnkite"
_pkgname="kwin-scripts-$_gitname"
pkgname="$_pkgname-git"
pkgver=0.9.5.r2.gdd35653
pkgrel=1
pkgdesc="A dynamic tiling extension for KWin"
url="https://github.com/anametologin/krohnkite"
license=('MIT')
arch=('any')
makedepends=(
'git'
'typescript'
)
provides=("$_pkgname")
conflicts=("$_pkgname")
_pkgsrc="anametologin.krohnkite"
source=("$_pkgsrc"::"git+$url.git")
sha256sums=('SKIP')
pkgver() {
cd "$_pkgsrc"
git describe --long --tags --abbrev=7 | sed -E 's/^v//;s/([^-]*-g)/r\1/;s/-/./g'
}
build() {
mkdir -p pkg
cd "$_pkgsrc"
# krohnkite.js
tsc
install -Dm644 krohnkite.js ../pkg/contents/code/script.js
# metadata.json
install -Dm644 res/metadata.json ../pkg/metadata.json
sed -E -e 's&\$VER&'${pkgver}'&' \
-e 's&\$REV&'${pkgver}'&' \
-i ../pkg/metadata.json
# other files
install -Dm644 res/main.js ../pkg/contents/code/main.js
install -Dm644 res/config.xml ../pkg/contents/config/main.xml
install -Dm644 res/config.ui ../pkg/contents/ui/config.ui
install -Dm644 res/main.qml ../pkg/contents/ui/main.qml
install -Dm644 res/popup.qml ../pkg/contents/ui/popup.qml
install -Dm644 res/shortcuts.qml ../pkg/contents/ui/shortcuts.qml
#cd "$srcdir"
#7z a -tzip "$_gitname-$pkgver.kwinscript" pkg/*
}
package() {
depends+=(
'kwin'
)
install -dm755 "$pkgdir/usr/share/kwin/scripts/$_gitname"
cp -ra "pkg/." "$pkgdir/usr/share/kwin/scripts/$_gitname/"
install -Dm644 "$_pkgsrc/res/metadata.desktop" "$pkgdir/usr/share/kservices6/$_gitname.desktop"
install -Dm644 "$srcdir/$_pkgsrc/LICENSE" -t "$pkgdir/usr/share/licenses/$pkgname/"
}
|