nixpkgs/pkgs/by-name/zo/zotero/avoid-git.patch
Mynacol e0cd136659 zotero: Use release channel
Our zotero build had the version string 9.0.2.SOURCE.000000000, while
upstream releases of course only have 9.0.2. This leaks in HTTP headers
and JavaScript functions, which is used e.g. by Better BibTeX. This
add-on actually partially fails due to the unexpected version string.

This commit switches to the release channel. This also would enable
updates, which fail/hang because the firefox updater is not included in
our firefox builds.

Instead of patching app/scripts/dir_build, I opt to call
app/scripts/prepare_build and app/build.sh directly. This also brings us
closer to cross-compile support (as we now select the build system and
architecture from targetHost).

(cherry picked from commit e12e834060)
2026-06-14 07:17:46 +00:00

42 lines
1.7 KiB
Diff

diff --git a/js-build/note-editor.js b/js-build/note-editor.js
index 1435730342..6eebb10c50 100644
--- a/js-build/note-editor.js
+++ b/js-build/note-editor.js
@@ -12,8 +12,7 @@ async function getZoteroNoteEditor(signatures) {
const modulePath = path.join(__dirname, '..', 'note-editor');
- const { stdout } = await exec('git rev-parse HEAD', { cwd: modulePath });
- const hash = stdout.trim();
+ const hash = '';
if (!('note-editor' in signatures) || signatures['note-editor'].hash !== hash) {
const targetDir = path.join(__dirname, '..', 'build', 'resource', 'note-editor');
diff --git a/js-build/pdf-worker.js b/js-build/pdf-worker.js
index b820304f3a..6bbd0708c9 100644
--- a/js-build/pdf-worker.js
+++ b/js-build/pdf-worker.js
@@ -12,8 +12,7 @@ async function getPDFWorker(signatures) {
const modulePath = path.join(__dirname, '..', 'pdf-worker');
- const { stdout } = await exec('git rev-parse HEAD', { cwd: modulePath });
- const hash = stdout.trim();
+ const hash = '';
if (!('pdf-worker' in signatures) || signatures['pdf-worker'].hash !== hash) {
const targetDir = path.join(__dirname, '..', 'build', 'chrome', 'content', 'zotero', 'xpcom', 'pdfWorker');
diff --git a/js-build/reader.js b/js-build/reader.js
index 67a02a3ad2..2127f680df 100644
--- a/js-build/reader.js
+++ b/js-build/reader.js
@@ -12,8 +12,7 @@ async function getReader(signatures) {
const modulePath = path.join(__dirname, '..', 'reader');
- const { stdout } = await exec('git rev-parse HEAD', { cwd: modulePath });
- const hash = stdout.trim();
+ const hash = '';
if (!('reader' in signatures) || signatures['reader'].hash !== hash) {
const targetDir = path.join(__dirname, '..', 'build', 'resource', 'reader');