From 6e4c38e741af6b837307ae89d6346bfd42f8eb96 Mon Sep 17 00:00:00 2001 From: noraj Date: Sun, 1 Dec 2024 18:48:13 +0100 Subject: [PATCH] add rdwatool --- packages/rdwatool/PKGBUILD | 41 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 packages/rdwatool/PKGBUILD diff --git a/packages/rdwatool/PKGBUILD b/packages/rdwatool/PKGBUILD new file mode 100644 index 00000000000..91065c7dc9d --- /dev/null +++ b/packages/rdwatool/PKGBUILD @@ -0,0 +1,41 @@ +# This file is part of BlackArch Linux ( https://www.blackarch.org/ ). +# See COPYING for license details. + +pkgname=rdwatool +pkgver=1.2.r12.g6c47a21 +pkgrel=1 +pkgdesc='Python script to extract information from a Microsoft Remote Desktop Web Access (RDWA) application' +arch=('any') +groups=('blackarch' 'blackarch-windows') +url='https://github.com/p0dalirius/rdwatool' +license=('custom:unknown') +depends=('python' 'python-beautifulsoup4' 'python-requests' 'python-urllib3' 'python-xlsxwriter') +makedepends=('git' 'python-build' 'python-installer' 'python-setuptools' 'python-wheel') +source=("git+$url.git") +sha512sums=('SKIP') + +pkgver() { + cd $pkgname + + ( set -o pipefail + git describe --long --tags --abbrev=7 2>/dev/null | + sed 's/\([^-]*-g\)/r\1/;s/-/./g' || + printf "%s.%s" "$(git rev-list --count HEAD)" \ + "$(git rev-parse --short=7 HEAD)" + ) +} + +build() { + cd $pkgname + + python -m build --wheel --no-isolation +} + +package() { + cd $pkgname + + install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" README.md + + python -m installer --destdir="$pkgdir" dist/*.whl +} +