stirling-pdf: 2.4.5 -> 2.6.0; nixos/stirling-pdf: add timhae as maintainer (#496929)

This commit is contained in:
Sandro
2026-03-08 20:48:54 +00:00
committed by GitHub
4 changed files with 1442 additions and 1097 deletions
@@ -51,7 +51,7 @@ in
with pkgs;
[
# `which` is used to test command availability
# See https://github.com/Stirling-Tools/Stirling-PDF/blob/main/src/main/java/stirling/software/SPDF/config/ExternalAppDepConfig.java#L42
# See https://github.com/Stirling-Tools/Stirling-PDF/blob/main/app/core/src/main/java/stirling/software/SPDF/config/ExternalAppDepConfig.java#L262
which
unpaper
libreoffice
@@ -117,5 +117,8 @@ in
};
};
meta.maintainers = with lib.maintainers; [ DCsunset ];
meta.maintainers = with lib.maintainers; [
DCsunset
timhae
];
}
+1396 -1088
View File
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,22 @@
diff --git a/frontend/src-tauri/stirling-pdf.desktop b/frontend/src-tauri/stirling-pdf.desktop
index 45db59c..8068696 100644
--- a/frontend/src-tauri/stirling-pdf.desktop
+++ b/frontend/src-tauri/stirling-pdf.desktop
@@ -3,13 +3,13 @@ Version=1.0
Type=Application
Name=Stirling-PDF
Comment=Locally hosted web application that allows you to perform various operations on PDF files
-Exec=/usr/bin/stirling-pdf
+Exec=stirling-pdf
Icon={{icon}}
Terminal=false
-MimeType=application/pdf;
+MimeType=application/pdf;x-scheme-handler/stirlingpdf;
Categories=Office;Graphics;Utility;
Actions=open-file;
[Desktop Action open-file]
Name=Open PDF File
-Exec=/usr/bin/stirling-pdf %F
\ No newline at end of file
+Exec=stirling-pdf %F
+19 -7
View File
@@ -15,7 +15,7 @@
wrapGAppsHook3,
glib-networking,
jre,
jdk25,
libsoup_3,
openssl,
webkitgtk_4_1,
@@ -31,21 +31,27 @@ assert isDesktopVariant -> !buildWithFrontend;
let
gradle = gradle_8;
jre = jdk25;
in
stdenv.mkDerivation (finalAttrs: {
pname = "stirling-pdf" + lib.optionalString isDesktopVariant "-desktop";
version = "2.4.5";
version = "2.6.0";
src = fetchFromGitHub {
owner = "Stirling-Tools";
repo = "Stirling-PDF";
tag = "v${finalAttrs.version}";
hash = "sha256-Fk6tuuoTI5ziZ6GjbrRdlvNdToEPb3f155T1OL47XQs=";
hash = "sha256-nsC/U+9kJo0i5Sh2u+OrjzDO6YREKjVAe+1KBKgtybY=";
};
patches = [
# remove timestamp from the header of a generated .properties file
./remove-props-file-timestamp.patch
# Note: only affects the desktop variant
# fix path to the stirling-pdf binary
# and add support for the stirlingpdf:// protocol
./fix-desktop-file.patch
];
npmRoot = "frontend";
@@ -54,7 +60,7 @@ stdenv.mkDerivation (finalAttrs: {
name = "${finalAttrs.pname}-${finalAttrs.version}-npm-deps";
inherit (finalAttrs) src patches;
postPatch = "cd ${finalAttrs.npmRoot}";
hash = "sha256-cVVxbkXD5sz6YmHOwbXj1GYRa2s9PmRFtuNsz2tLRhI=";
hash = "sha256-uMWc/yoOWFtP2JTMr69V/nRPu9YfrGxqvBnOw2DZkQQ=";
};
cargoRoot = "frontend/src-tauri";
@@ -68,7 +74,7 @@ stdenv.mkDerivation (finalAttrs: {
patches
cargoRoot
;
hash = "sha256-lO2IdJUAnhpSnF4vTEn4EdnyrxIXyEUvpNl0VWd2fFs=";
hash = "sha256-JvrZKgTmPGP6m95GBr/UJo1FLaR86KSmJ9LzLlzQhfE=";
};
mitmCache = gradle.fetchDeps {
@@ -81,7 +87,13 @@ stdenv.mkDerivation (finalAttrs: {
# we'll trigger it manually in postBuild
dontTauriBuild = true;
env.PUPPETEER_SKIP_DOWNLOAD = "1";
env = {
PUPPETEER_SKIP_DOWNLOAD = "1";
# taken from here https://github.com/Stirling-Tools/Stirling-PDF/blob/main/.github/workflows/tauri-build.yml#L346-L348
VITE_SUPABASE_PUBLISHABLE_DEFAULT_KEY = "sb_publishable_UHz2SVRF5mvdrPHWkRteyA_yNlZTkYb";
VITE_SAAS_SERVER_URL = "https://app.stirlingpdf.com";
VITE_SAAS_BACKEND_API_URL = "https://api.stirlingpdf.com";
};
# disable spotless because it tries to fetch files not in deps.json
# and also because it slows down the build process
@@ -96,7 +108,7 @@ stdenv.mkDerivation (finalAttrs: {
nativeBuildInputs = [
gradle
gradle.jdk # one of the tests also require that the `java` command is available on the command line
jre # one of the tests also require that the `java` command is available on the command line
makeBinaryWrapper
]
++ lib.optionals (buildWithFrontend || isDesktopVariant) [