summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorBlair Bonnett2019-03-02 14:17:13 +0100
committerBlair Bonnett2019-03-02 14:17:13 +0100
commit7d411a2c96b50a7872caa22b886a58c9cbdb8d58 (patch)
treeba2e916a27493537c536f8cd04e7e6b45c7dc3b4
downloadaur-7d411a2c96b50a7872caa22b886a58c9cbdb8d58.tar.gz
Initial package.
-rw-r--r--.SRCINFO30
-rw-r--r--.gitignore4
-rw-r--r--PKGBUILD52
3 files changed, 86 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..c63aeeffc477
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,30 @@
+pkgbase = mlbstreamer-git
+ pkgdesc = Enables real-time and time-shifted viewing of MLB.tv streams
+ pkgver = v0.0.10.r23.g92eb0ad
+ pkgrel = 1
+ url = https://github.com/tonycpsu/mlbstreamer
+ arch = any
+ license = GPL2
+ makedepends = git
+ depends = python
+ depends = python-six
+ depends = python-requests
+ depends = python-lxml
+ depends = python-pytz
+ depends = python-tzlocal
+ depends = python-pymemoize
+ depends = python-orderedattrdict
+ depends = python-yaml
+ depends = python-dateutil
+ depends = streamlink>=0.11.0
+ depends = python-prompt_toolkit
+ depends = python-urwid
+ depends = python-urwid_utils>=0.1.2
+ depends = python-panwid>=0.2.5
+ provides = mlbstreamer
+ conflicts = mlbstreamer
+ source = git+https://github.com/tonycpsu/mlbstreamer.git
+ sha256sums = SKIP
+
+pkgname = mlbstreamer-git
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000000..a4601bd6f0bd
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,4 @@
+src
+pkg
+mlbstreamer
+*.pkg.tar.xz
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..1df86e6738c8
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,52 @@
+# Maintainer: Blair Bonnett <blair dot bonnett at gmail dot com>
+
+pkgname=mlbstreamer-git
+pkgver=v0.0.10.r23.g92eb0ad
+pkgrel=1
+pkgdesc="Enables real-time and time-shifted viewing of MLB.tv streams"
+url="https://github.com/tonycpsu/mlbstreamer"
+arch=('any')
+license=('GPL2')
+conflicts=('mlbstreamer')
+provides=('mlbstreamer')
+depends=(
+ 'python' 'python-six' 'python-requests' 'python-lxml' 'python-pytz'
+ 'python-tzlocal' 'python-pymemoize' 'python-orderedattrdict' 'python-yaml'
+ 'python-dateutil' 'streamlink>=0.11.0' 'python-prompt_toolkit' 'python-urwid'
+ 'python-urwid_utils>=0.1.2' 'python-panwid>=0.2.5'
+)
+makedepends=('git')
+source=(
+ 'git+https://github.com/tonycpsu/mlbstreamer.git'
+)
+sha256sums=(
+ 'SKIP'
+)
+
+pkgver() {
+ cd "mlbstreamer"
+ git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+# The dateutil module is provided through the python-dateutil dependency.
+# However, setuptools doesn't pick this up and so raises a fatal error
+# when the command-line executables start. Removing it from setup.py doesn't
+# affect the build and packaging, but prevents this error.
+prepare() {
+ cd "mlbstreamer"
+ sed -i -e "/py-dateutil/d" setup.py
+}
+
+# Make the setup.py version match the PKGBUILD version so the .egg-info
+# metadata also matches. Not entirely sure this is needed but it seems cleaner.
+build() {
+ cd "mlbstreamer"
+ sed -i -e "s/version=\"[0-9a-z\.]\+\"/version=\"${pkgver:1}\"/" setup.py
+ python setup.py build
+}
+
+package() {
+ cd "mlbstreamer"
+ python setup.py install --root="$pkgdir/" --optimize=1 --skip-build
+ rm -r "$pkgdir/usr/lib/python3.7/site-packages/test"
+}