Date: Tuesday, April 18, 2023 @ 15:57:39
  Author: jelle
Revision: 1447242

archrelease: copy trunk to community-staging-any

Added:
  python-pyu2f/repos/community-staging-any/PKGBUILD
    (from rev 1447241, python-pyu2f/trunk/PKGBUILD)
  python-pyu2f/repos/community-staging-any/pyfakefs-compat.patch
    (from rev 1447241, python-pyu2f/trunk/pyfakefs-compat.patch)
Deleted:
  python-pyu2f/repos/community-staging-any/PKGBUILD

-----------------------+
 PKGBUILD              |   64 ++++++++++++++++++++++++++----------------------
 pyfakefs-compat.patch |   35 ++++++++++++++++++++++++++
 2 files changed, 70 insertions(+), 29 deletions(-)

Deleted: PKGBUILD
===================================================================
--- PKGBUILD    2023-04-18 15:57:28 UTC (rev 1447241)
+++ PKGBUILD    2023-04-18 15:57:39 UTC (rev 1447242)
@@ -1,29 +0,0 @@
-# Maintainer: Felix Yan <[email protected]>
-
-pkgname=python-pyu2f
-pkgver=0.1.5
-pkgrel=4
-pkgdesc="U2F host library for interacting with a U2F device over USB"
-url="https://github.com/google/pyu2f";
-license=('Apache')
-arch=('any')
-depends=('python-six')
-makedepends=('python-setuptools')
-checkdepends=('python-mock' 'python-pyfakefs' 'python-pytest')
-source=("https://github.com/google/pyu2f/archive/$pkgver/$pkgname-$pkgver.tar.gz";)
-sha512sums=('ddb15bb1d917117a2b19ad169ac0f8b8c7667d7ef8ee4c266cc30326429bb3627d41d84dc390ce0036d0b0f110e1d2da47d06d4e4d03a8be98cedb5ea3112246')
-
-build() {
-  cd pyu2f-$pkgver
-  python setup.py build
-}
-
-check() {
-  cd pyu2f-$pkgver
-  pytest
-}
-
-package() {
-  cd pyu2f-$pkgver
-  python setup.py install --root="$pkgdir" --optimize=1
-}

Copied: python-pyu2f/repos/community-staging-any/PKGBUILD (from rev 1447241, 
python-pyu2f/trunk/PKGBUILD)
===================================================================
--- PKGBUILD                            (rev 0)
+++ PKGBUILD    2023-04-18 15:57:39 UTC (rev 1447242)
@@ -0,0 +1,35 @@
+# Maintainer: Felix Yan <[email protected]>
+
+pkgname=python-pyu2f
+pkgver=0.1.5
+pkgrel=5
+pkgdesc="U2F host library for interacting with a U2F device over USB"
+url="https://github.com/google/pyu2f";
+license=('Apache')
+arch=('any')
+depends=('python-six')
+makedepends=('python-setuptools')
+checkdepends=('python-mock' 'python-pyfakefs' 'python-pytest')
+source=("https://github.com/google/pyu2f/archive/$pkgver/$pkgname-$pkgver.tar.gz";
 "pyfakefs-compat.patch")
+sha512sums=('ddb15bb1d917117a2b19ad169ac0f8b8c7667d7ef8ee4c266cc30326429bb3627d41d84dc390ce0036d0b0f110e1d2da47d06d4e4d03a8be98cedb5ea3112246'
+            
'ef12d29114292918d5820ff129cfcfa820637464e1945252c5fca80be40cfb8d5df5d57efc8dac748d1b952acca177c953a69a3a16d096c92bd8a61687b80fe0')
+
+prepare() {
+  cd pyu2f-$pkgver
+  patch -Np1 -i ${srcdir}/pyfakefs-compat.patch
+}
+
+build() {
+  cd pyu2f-$pkgver
+  python setup.py build
+}
+
+check() {
+  cd pyu2f-$pkgver
+  pytest
+}
+
+package() {
+  cd pyu2f-$pkgver
+  python setup.py install --root="$pkgdir" --optimize=1
+}

Copied: python-pyu2f/repos/community-staging-any/pyfakefs-compat.patch (from 
rev 1447241, python-pyu2f/trunk/pyfakefs-compat.patch)
===================================================================
--- pyfakefs-compat.patch                               (rev 0)
+++ pyfakefs-compat.patch       2023-04-18 15:57:39 UTC (rev 1447242)
@@ -0,0 +1,35 @@
+diff -aur pyu2f-0.1.5/pyu2f/tests/hid/linux_test.py 
pyu2f-0.1.5.new/pyu2f/tests/hid/linux_test.py
+--- pyu2f-0.1.5/pyu2f/tests/hid/linux_test.py  2020-10-30 19:51:37.000000000 
+0100
++++ pyu2f-0.1.5.new/pyu2f/tests/hid/linux_test.py      2023-04-18 
17:52:58.947902388 +0200
+@@ -49,14 +49,14 @@
+ 
+ def AddDevice(fs, dev_name, product_name,
+               vendor_id, product_id, report_descriptor_b64):
+-  uevent = fs.CreateFile('/sys/class/hidraw/%s/device/uevent' % dev_name)
+-  rd = fs.CreateFile('/sys/class/hidraw/%s/device/report_descriptor' % 
dev_name)
++  uevent = fs.create_file('/sys/class/hidraw/%s/device/uevent' % dev_name)
++  rd = fs.create_file('/sys/class/hidraw/%s/device/report_descriptor' % 
dev_name)
+   report_descriptor = base64.b64decode(report_descriptor_b64)
+-  rd.SetContents(report_descriptor)
++  rd.set_contents(report_descriptor)
+ 
+   buf = 'HID_NAME=%s\n' % product_name.encode('utf8')
+   buf += 'HID_ID=0001:%08X:%08X\n' % (vendor_id, product_id)
+-  uevent.SetContents(buf)
++  uevent.set_contents(buf)
+ 
+ 
+ class FakeDeviceOsModule(object):
+@@ -79,10 +79,10 @@
+ class LinuxTest(unittest.TestCase):
+   def setUp(self):
+     self.fs = fake_filesystem.FakeFilesystem()
+-    self.fs.CreateDirectory('/sys/class/hidraw')
++    self.fs.create_dir('/sys/class/hidraw')
+ 
+   def tearDown(self):
+-    self.fs.RemoveObject('/sys/class/hidraw')
++    self.fs.remove_object('/sys/class/hidraw')
+ 
+   def testCallEnumerate(self):
+     AddDevice(self.fs, 'hidraw1', 'Logitech USB Keyboard',

Reply via email to