summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: a38cc726467e147ddab0b9f089e6a7e92889dd33 (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: Modelmat <modelmat@outlook.com.au>

pkgname=python-frccontrol-git
pkgver=2024.23
pkgrel=1
pkgdesc="Provides SciPy wrappers that ease development of state-space models for the FIRST Robotics Competition."
arch=("x86_64")
url="https://github.com/calcmogul/frccontrol.git"
license=("BSD")
depends=("python-matplotlib" "python-numpy" "python-scipy")
makedepends=('python-build' 'python-installer' 'python-pytest')
source=(git+https://github.com/calcmogul/frccontrol.git)
md5sums=('SKIP')

pkgver() {
  cd "${srcdir}/frccontrol"
  year=$(date +%Y)
  echo $year.$(git rev-list --count --after="main@{$(($year - 1))-01-01}" main)
}

build() {
  cd "${srcdir}/frccontrol"
  python -m build --wheel
}

check() {
  cd "${srcdir}/frccontrol"
  pytest
}

package() {
  cd "${srcdir}/frccontrol"
  pip install dist/frccontrol-*.whl --no-deps --root ${pkgdir} --ignore-installed
}