Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] update of anki
@ 2022-01-25 22:26 danjenson
  2022-01-25 23:09 ` paper42
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: danjenson @ 2022-01-25 22:26 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1358 bytes --]

There is a new pull request by danjenson against master on the void-packages repository

https://github.com/danjenson/void-packages master
https://github.com/void-linux/void-packages/pull/35238

update of anki
tl;dr, the build system seems to have switched to bazel, but I don't see this as a `build_style` option. This is my first attempt at updating a package. Anki has had a great many releases since the current void version, and appears to host it's source files on github now.

#### Testing the changes
- I tested the changes in this PR: NO, I could not figure out how to get the bazel build system to function on void

<!--
#### New package
- This new package conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements): TBD, will check once I can get it compiled
-->

<!-- Note: If the build is likely to take more than 2 hours, please [skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration)
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!-- 
#### Local build testing
- I built this PR locally for my native architecture, x86-64
-->


A patch file from https://github.com/void-linux/void-packages/pull/35238.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-master-35238.patch --]
[-- Type: text/x-diff, Size: 6995 bytes --]

From f14a979b71c76ef9fb0a73b955488efc3c5c18b7 Mon Sep 17 00:00:00 2001
From: Daniel Jenson <daniel.a.jenson@gmail.com>
Date: Tue, 25 Jan 2022 14:21:41 -0800
Subject: [PATCH] starting update of anki

---
 srcpkgs/anki/patches/disable_popup.patch    | 10 -----
 srcpkgs/anki/patches/fix_float.patch        | 42 ---------------------
 srcpkgs/anki/patches/fix_mpv_args.patch     | 29 --------------
 srcpkgs/anki/patches/fix_profile_save.patch | 15 --------
 srcpkgs/anki/patches/fix_unescape.patch     | 11 ------
 srcpkgs/anki/template                       | 10 ++---
 6 files changed, 5 insertions(+), 112 deletions(-)
 delete mode 100644 srcpkgs/anki/patches/disable_popup.patch
 delete mode 100644 srcpkgs/anki/patches/fix_float.patch
 delete mode 100644 srcpkgs/anki/patches/fix_mpv_args.patch
 delete mode 100644 srcpkgs/anki/patches/fix_profile_save.patch
 delete mode 100644 srcpkgs/anki/patches/fix_unescape.patch

diff --git a/srcpkgs/anki/patches/disable_popup.patch b/srcpkgs/anki/patches/disable_popup.patch
deleted file mode 100644
index 8b7a041fc656..000000000000
--- a/srcpkgs/anki/patches/disable_popup.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/aqt/update.py
-+++ b/aqt/update.py
-@@ -31,6 +31,7 @@ class LatestVersionFinder(QThread):
-         return d
- 
-     def run(self):
-+        return
-         if not self.config['updates']:
-             return
-         d = self._data()
diff --git a/srcpkgs/anki/patches/fix_float.patch b/srcpkgs/anki/patches/fix_float.patch
deleted file mode 100644
index 333d76c8efd7..000000000000
--- a/srcpkgs/anki/patches/fix_float.patch
+++ /dev/null
@@ -1,42 +0,0 @@
---- a/aqt/deckconf.py
-+++ b/aqt/deckconf.py
-@@ -172,7 +172,7 @@ class DeckConf(QDialog):
-         f.lrnGradInt.setValue(c['ints'][0])
-         f.lrnEasyInt.setValue(c['ints'][1])
-         f.lrnEasyInt.setValue(c['ints'][1])
--        f.lrnFactor.setValue(c['initialFactor']/10.0)
-+        f.lrnFactor.setValue(c['initialFactor']//10)
-         f.newOrder.setCurrentIndex(c['order'])
-         f.newPerDay.setValue(c['perDay'])
-         f.bury.setChecked(c.get("bury", True))
-@@ -180,7 +180,7 @@ class DeckConf(QDialog):
-         # rev
-         c = self.conf['rev']
-         f.revPerDay.setValue(c['perDay'])
--        f.easyBonus.setValue(c['ease4']*100)
-+        f.easyBonus.setValue(int(c['ease4'])*100)
-         f.fi1.setValue(c['ivlFct']*100)
-         f.maxIvl.setValue(c['maxIvl'])
-         f.revplim.setText(self.parentLimText('rev'))
-@@ -192,7 +192,7 @@ class DeckConf(QDialog):
-         # lapse
-         c = self.conf['lapse']
-         f.lapSteps.setText(self.listToUser(c['delays']))
--        f.lapMult.setValue(c['mult']*100)
-+        f.lapMult.setValue(int(c['mult'])*100)
-         f.lapMinInt.setValue(c['minInt'])
-         f.leechThreshold.setValue(c['leechFails'])
-         f.leechAction.setCurrentIndex(c['leechAction'])
---- a/aqt/preferences.py
-+++ b/aqt/preferences.py
-@@ -77,8 +77,8 @@ class Preferences(QDialog):
-             f.hwAccel.setVisible(False)
-         else:
-             f.hwAccel.setChecked(self.mw.pm.glMode() != "software")
--        f.lrnCutoff.setValue(qc['collapseTime']/60.0)
--        f.timeLimit.setValue(qc['timeLim']/60.0)
-+        f.lrnCutoff.setValue(qc['collapseTime']//60)
-+        f.timeLimit.setValue(qc['timeLim']//60)
-         f.showEstimates.setChecked(qc['estTimes'])
-         f.showProgress.setChecked(qc['dueCounts'])
-         f.nightMode.setChecked(qc.get("nightMode", False))
diff --git a/srcpkgs/anki/patches/fix_mpv_args.patch b/srcpkgs/anki/patches/fix_mpv_args.patch
deleted file mode 100644
index 0b99dd8fe856..000000000000
--- a/srcpkgs/anki/patches/fix_mpv_args.patch
+++ /dev/null
@@ -1,29 +0,0 @@
---- a/anki/mpv.py
-+++ b/anki/mpv.py
-@@ -104,9 +104,9 @@
-         """
-         self.argv = [self.executable]
-         self.argv += self.default_argv
--        self.argv += ["--input-ipc-server", self._sock_filename]
-+        self.argv += ["--input-ipc-server="+self._sock_filename]
-         if self.window_id is not None:
--            self.argv += ["--wid", str(self.window_id)]
-+            self.argv += ["--wid="+str(self.window_id)]
- 
-     def _start_process(self):
-         """Start the mpv process.
-
---- a/anki/sound.py
-+++ b/anki/sound.py
-@@ -123,10 +123,7 @@
- 
- def setMpvConfigBase(base):
-     mpvConfPath = os.path.join(base, "mpv.conf")
--    MpvManager.default_argv += [
--        "--no-config",
--        "--include="+mpvConfPath,
--    ]
-+    MpvManager.default_argv += ["--include="+mpvConfPath]
- 
- mpvManager = None
- 
diff --git a/srcpkgs/anki/patches/fix_profile_save.patch b/srcpkgs/anki/patches/fix_profile_save.patch
deleted file mode 100644
index 9d72a1a20e82..000000000000
--- a/srcpkgs/anki/patches/fix_profile_save.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Fixes crash related to saving profile data on exit.
---- a/aqt/profiles.py
-+++ b/aqt/profiles.py
-@@ -160,7 +160,10 @@ a flash drive.""" % self.base)
-         return up.load()
- 
-     def _pickle(self, obj):
--        return pickle.dumps(obj, protocol=0)
-+        for key, val in obj.items():
-+            if isinstance(val, QByteArray):
-+                obj[key] = bytes(val)  # type: ignore
-+        return pickle.dumps(obj, protocol=4)
- 
-     def load(self, name):
-         assert name != "_global"
diff --git a/srcpkgs/anki/patches/fix_unescape.patch b/srcpkgs/anki/patches/fix_unescape.patch
deleted file mode 100644
index f7024bc7bf15..000000000000
--- a/srcpkgs/anki/patches/fix_unescape.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/aqt/reviewer.py
-+++ b/aqt/reviewer.py
-@@ -359,7 +359,7 @@
-         cor = stripHTML(cor)
-         # ensure we don't chomp multiple whitespace
-         cor = cor.replace(" ", "&nbsp;")
--        cor = parser.unescape(cor)
-+        cor = html.unescape(cor)
-         cor = cor.replace("\xa0", " ")
-         cor = cor.strip()
-         given = self.typedAnswer
diff --git a/srcpkgs/anki/template b/srcpkgs/anki/template
index 3cb3155760ea..eb4b8586c98c 100644
--- a/srcpkgs/anki/template
+++ b/srcpkgs/anki/template
@@ -1,7 +1,7 @@
 # Template file for 'anki'
 pkgname=anki
-version=2.1.15
-revision=6
+version=2.1.49
+revision=1
 build_style=gnu-makefile
 depends="python3-PyQt5-webengine python3-requests python3-SQLAlchemy
  python3-PyAudio python3-mpv python3-Markdown python3-send2trash
@@ -10,9 +10,9 @@ short_desc="Spaced repetition flashcard program"
 maintainer="Steve Prybylski <sa.prybylx@gmail.com>"
 license="AGPL-3.0-or-later"
 homepage="https://apps.ankiweb.net"
-changelog="https://apps.ankiweb.net/docs/changes.html"
-distfiles="https://apps.ankiweb.net/downloads/archive/anki-$version-source.tgz"
-checksum=5a53760164c77d619f55107a13099cffe620566a7f610b61b6c4b52487f3bb89
+changelog="https://github.com/ankitects/anki/releases"
+distfiles="https://github.com/ankitects/anki/archive/refs/tags/$version.tar.gz"
+checksum=0a072f9a2babdde67b233104c73450e297c7feff41e0a43b76dd590bafcef5d5
 
 python_version=3
 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-01-26  1:02 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-25 22:26 [PR PATCH] update of anki danjenson
2022-01-25 23:09 ` paper42
2022-01-26  1:02 ` danjenson
2022-01-26  1:02 ` [PR PATCH] [Closed]: " danjenson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).