upgpkg: python-inputs-1:0.5-1: initial upload

This commit is contained in:
Christian Schendel 2025-12-25 16:54:54 +01:00
commit 83787ff805
Signed by: doppelhelix
GPG key ID: 5874D2437CD5BBB3
9 changed files with 164 additions and 0 deletions

19
.SRCINFO Normal file
View file

@ -0,0 +1,19 @@
pkgbase = python-inputs
pkgdesc = Cross-platform Python support for keyboards, mice and gamepads
pkgver = 0.5
pkgrel = 1
epoch = 1
url = https://github.com/zeth/inputs
arch = any
license = BSD-3-Clause
makedepends = python-build
makedepends = python-installer
makedepends = python-setuptools
makedepends = python-wheel
depends = python
source = inputs-0.5.tar.gz::https://github.com/zeth/inputs/archive/refs/tags/v0.5.tar.gz
source = 3203c9e25f1e14c4316d85d59c536b4e407f569f.patch
b2sums = 64e36aee9ce576924c77cc5b0bd89b3bc657fbd9a89ac0407db143c05066828c5a09b6c0e6c3bfb457b5fc4f9cefd81d4b0bf949ac06b69314997b444050d5ab
b2sums = 337cf613a41876e4d1ce38ec14befdfe739db171238a318de8a0a42cba96baeaee888e405754a2432792f82f6f341a0a315be3a0f375cbe4c4a735e48e9f5534
pkgname = python-inputs

17
.gitignore vendored Normal file
View file

@ -0,0 +1,17 @@
# Ignore everything
*
# But not these files...
!.gitignore
!PKGBUILD
!.SRCINFO
!LICENSE
!chroot-build
!.nvchecker.toml
!/keys
!/keys/pgp
!/keys/pgp/*.asc
!/LICENSES
!/LICENSES/*.txt
!REUSE.toml
!*.patch

4
.nvchecker.toml Normal file
View file

@ -0,0 +1,4 @@
[python-inputs]
source = "git"
git = "https://github.com/zeth/inputs.git"
prefix = "v"

View file

@ -0,0 +1,22 @@
From 3203c9e25f1e14c4316d85d59c536b4e407f569f Mon Sep 17 00:00:00 2001
From: Jonathan spyreas <jspyreas@root-ai.com>
Date: Thu, 16 Apr 2020 11:43:36 -0400
Subject: [PATCH] fix for dumb bug around leds and docker
---
inputs.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/inputs.py b/inputs.py
index b1f8fb1..36cc3e1 100644
--- a/inputs.py
+++ b/inputs.py
@@ -3134,7 +3134,7 @@ def __init__(self, manager, path, name):
def _post_init(self):
self._match_device()
- self._character_device_path = self.gamepad.get_char_device_path()
+ self._character_device_path = self.gamepad.get_char_device_path() if self.gamepad else None
def _match_device(self):
number = int(self.name.split('xpad')[1])

12
LICENSE Normal file
View file

@ -0,0 +1,12 @@
Copyright Arch Linux Contributors
Permission to use, copy, modify, and/or distribute this software for
any purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED “AS IS” AND THE AUTHOR DISCLAIMS ALL
WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE
FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY
DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

1
LICENSES/0BSD.txt Symbolic link
View file

@ -0,0 +1 @@
../LICENSE

11
LICENSES/BSD-3-Clause.txt Normal file
View file

@ -0,0 +1,11 @@
Copyright (c) <year> <owner>.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

48
PKGBUILD Normal file
View file

@ -0,0 +1,48 @@
# Maintainer: Mark Wagie <mark dot wagie at proton dot me>
# Contributor: Major <majorx234@googlemail.com>
pkgname=python-inputs
_name=${pkgname#python-}
pkgver=0.5
epoch=1
pkgrel=1
pkgdesc="Cross-platform Python support for keyboards, mice and gamepads"
arch=('any')
url="https://github.com/zeth/inputs"
license=(
BSD-3-Clause
)
depends=(
python
)
makedepends=(
python-build
python-installer
python-setuptools
python-wheel
)
source=(
"${_name}-${pkgver}.tar.gz::${url}/archive/refs/tags/v${pkgver}.tar.gz"
'3203c9e25f1e14c4316d85d59c536b4e407f569f.patch'
)
b2sums=('64e36aee9ce576924c77cc5b0bd89b3bc657fbd9a89ac0407db143c05066828c5a09b6c0e6c3bfb457b5fc4f9cefd81d4b0bf949ac06b69314997b444050d5ab'
'337cf613a41876e4d1ce38ec14befdfe739db171238a318de8a0a42cba96baeaee888e405754a2432792f82f6f341a0a315be3a0f375cbe4c4a735e48e9f5534')
prepare() {
cd "${_name}-${pkgver}"
# https://github.com/zeth/inputs/issues/72
# https://github.com/zeth/inputs/pull/90
patch -Np1 -i ../3203c9e25f1e14c4316d85d59c536b4e407f569f.patch
}
build() {
cd "${_name}-${pkgver}"
python -m build --wheel --no-isolation
}
package() {
cd "${_name}-${pkgver}"
python -m installer --destdir="${pkgdir}" dist/*.whl
install -Dm644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}/"
}

30
REUSE.toml Normal file
View file

@ -0,0 +1,30 @@
version = 1
[[annotations]]
path = [
"PKGBUILD",
"README.md",
"keys/**",
".SRCINFO",
".nvchecker.toml",
".gitignore",
"*.install",
"*.sysusers",
"*.tmpfiles",
"*.logrotate",
"*.pam",
"*.service",
"*.socket",
"*.timer",
"*.desktop",
"*.hook",
]
SPDX-FileCopyrightText = "Arch Linux contributors"
SPDX-License-Identifier = "0BSD"
[[annotations]]
path = [
"*.patch",
]
SPDX-FileCopyrightText = "python-inputs contributors"
SPDX-License-Identifier = "BSD-3-Clause"