Files
haikuports/dev-util/gertty/gertty-1.6.0.recipe
2023-03-13 07:00:38 +01:00

96 lines
2.8 KiB
Bash

SUMMARY="A console-based interface to the Gerrit Code Review system"
DESCRIPTION="Gertty is a console-based interface to the Gerrit Code Review system.
As compared to the web interface, the main advantages are:
* Workflow -- the interface is designed to support a workflow similar to reading network news or \
mail. In particular, it is designed to deal with a large number of review requests across a \
large number of projects.
* Offline Use -- Gertty syncs information about changes in subscribed projects to a local \
database and local git repos. All review operations are performed against that database and then \
synced back to Gerrit.
* Speed -- user actions modify locally cached content and need not wait for server interaction.
* Convenience -- because Gertty downloads all changes to local git repos, a single command \
instructs it to checkout a change into that repo for detailed examination or testing of larger \
changes."
HOMEPAGE="https://pypi.org/project/gertty/"
COPYRIGHT="2022 The TTY Group"
LICENSE="Apache v2"
REVISION="7"
pypiVersion="13/fa/67165ece7a08f7142bcfda2e5cee145dbda78e003c11924098bfc6efaf0e"
SOURCE_URI="https://files.pythonhosted.org/packages/$pypiVersion/gertty-$portVersion.tar.gz"
CHECKSUM_SHA256="1c3593d2e6ce53bd84b27d6ac92df4a86d8923afd18b4f4f8e2c979f8a6277df"
PATCHES="gertty-$portVersion.patchset"
ARCHITECTURES="any"
PROVIDES="
$portName = $portVersion
"
REQUIRES="
haiku
"
BUILD_REQUIRES="
haiku_devel
"
PYTHON_PACKAGES=(python39 python310)
PYTHON_VERSIONS=(3.9 3.10)
for i in "${!PYTHON_PACKAGES[@]}"; do
pythonPackage=${PYTHON_PACKAGES[i]}
pythonVersion=${PYTHON_VERSIONS[$i]}
eval "PROVIDES_${pythonPackage}=\"\
${portName}_$pythonPackage = $portVersion\n\
cmd:gertty\
\"; \
REQUIRES_$pythonPackage=\"\
haiku\n\
cmd:python$pythonVersion\n\
alembic_py_$pythonPackage\n\
dateutil_$pythonPackage\n\
gitpython_$pythonPackage\n\
mako_$pythonPackage\n\
pbr_$pythonPackage\n\
ply_$pythonPackage\n\
pyyaml_$pythonPackage\n\
requests_$pythonPackage\n\
sqlalchemy_$pythonPackage\n\
typing_extensions_$pythonPackage\n\
urwid_$pythonPackage\n\
voluptuous_$pythonPackage\
\""
BUILD_REQUIRES="$BUILD_REQUIRES
pbr_$pythonPackage
requests_$pythonPackage
setuptools_$pythonPackage
wheel_$pythonPackage"
BUILD_PREREQUIRES="$BUILD_PREREQUIRES
cmd:python$pythonVersion
"
done
INSTALL()
{
for i in "${!PYTHON_PACKAGES[@]}"; do
pythonPackage=${PYTHON_PACKAGES[i]}
pythonVersion=${PYTHON_VERSIONS[$i]}
python=python$pythonVersion
installLocation=$prefix/lib/$python/vendor-packages/
export PYTHONPATH=$installLocation:$PYTHONPATH
mkdir -p $installLocation
rm -rf build
$python setup.py build install \
--root=/ --prefix=$prefix
packageEntries $pythonPackage \
$prefix/lib/python* \
$prefix/bin \
$docDir
done
}