summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e79c5f0d39e92513e8b71c8cfd59bcc253fd6e93 (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
# Maintainer: Brody <archfan at brodix dot de>
# Contributor: Zhang.j.k <zhangjk67 at gmail dian com>
# vim: ts=2 sw=2 et:

pkgname=konsave
pkgver=2.1.1
pkgrel=1
pkgdesc="Save and apply your KDE Plasma customizations with just one command!"
url="https://github.com/Prayag2/${pkgname}"
depends=('python' 'python-pyaml')
makedepends=('python-setuptools-scm')
license=('GPL3')
arch=('any')
source=("${pkgname}-${pkgver}.tar.gz::${url}/archive/v${pkgver}.tar.gz")
sha512sums=('291d33e12b9e038257a44015948f8c823872888b12b37f3a2f388cc28d9374bff81f7316098a98f1b460cd8efe7d1f3521999939315487ff0033bac9eb47caea')

build() {
  export SETUPTOOLS_SCM_PRETEND_VERSION="${pkgver}"
  cd "${pkgname}-${pkgver}"
  python setup.py build
}

package() {
  cd "${pkgname}-${pkgver}"
  python setup.py install \
    --root="${pkgdir}" \
    --optimize=1 \
    --skip-build

  # Copying configuration files
  _python_folder=$(python -c "import site; print(site.getsitepackages()[0])")
  install -Dm644 konsave/conf_kde.yaml "${pkgdir}/${_python_folder}/${pkgname}/conf_kde.yaml"
  install -Dm644 konsave/conf_other.yaml "${pkgdir}/${_python_folder}/${pkgname}/conf_other.yaml"
}