apostrophe: 3.1 -> 3.2

Changelog: https://gitlab.gnome.org/World/apostrophe/-/releases/v3.2
This commit is contained in:
aleksana 2024-11-03 17:55:30 +08:00
parent 85dfb8e12c
commit 39c8fd647f

View File

@ -19,36 +19,24 @@
}:
let
version = "3.1";
version = "3.2";
src = fetchFromGitLab {
owner = "World";
repo = "apostrophe";
domain = "gitlab.gnome.org";
rev = "v${version}";
hash = "sha256-rXaz0EtLuKOBJLF81K/4qoTZtG6B8Wn+KwSiqYvxAVc=";
rev = "refs/tags/v${version}";
hash = "sha256-NPpBu6Wmd8z99vzVQ394CyHRV2RQBtkbuqcaFqKqlkQ=";
};
# Patches are required by upstream. Without the patches
# typing `- aaa`, newline, `- bbb` the program crashes
gtksourceview5-patched = gtksourceview5.overrideAttrs (prev: {
patches = (prev.patches or [ ]) ++ [ "${src}/build-aux/flatpak/sourceview_text_commits.patch" ];
});
libspelling-patched =
(libspelling.override { gtksourceview5 = gtksourceview5-patched; }).overrideAttrs
(prev: {
patches = (prev.patches or [ ]) ++ [ "${src}/build-aux/flatpak/libspelling_text_commits.patch" ];
});
reveal-js = fetchFromGitHub {
owner = "hakimel";
repo = "reveal.js";
# keep in sync with upstream shipped version
# in build-aux/flatpak/org.gnome.gitlab.somas.Apostrophe.json
rev = "4.6.0";
hash = "sha256-a+J+GasFmRvu5cJ1GLXscoJ+owzFXsLhCbeDbYChkyQ=";
rev = "refs/tags/5.1.0";
hash = "sha256-L6KVBw20K67lHT07Ws+ZC2DwdURahqyuyjAaK0kTgN0=";
};
in
python3Packages.buildPythonApplication {
@ -67,9 +55,10 @@ python3Packages.buildPythonApplication {
+ ''
substituteInPlace apostrophe/preview_converter.py \
--replace-fail "--mathjax" "--mathjax=file://${nodePackages.mathjax}/lib/node_modules/mathjax/es5/tex-chtml-full.js"
''
'';
# Should be done in postInstall, but meson checks this eagerly before build
+ ''
preConfigure = ''
install -d $out/share/apostrophe/libs
cp -r ${reveal-js} $out/share/apostrophe/libs/reveal.js
'';
@ -85,8 +74,8 @@ python3Packages.buildPythonApplication {
buildInputs = [
libadwaita
gtksourceview5-patched
libspelling-patched
gtksourceview5
libspelling
webkitgtk_6_0
];
@ -94,6 +83,7 @@ python3Packages.buildPythonApplication {
pygobject3
pypandoc
chardet
levenshtein
];
dontWrapGApps = true;
@ -107,7 +97,7 @@ python3Packages.buildPythonApplication {
'';
passthru = {
inherit gtksourceview5-patched libspelling-patched reveal-js;
inherit reveal-js;
};
meta = {