diff options
author | FliegendeWurst <2012gdwu+github@posteo.de> | 2022-02-04 10:59:09 +0100 |
---|---|---|
committer | FliegendeWurst <2012gdwu+github@posteo.de> | 2022-02-04 16:04:33 +0100 |
commit | 0d737162783a4f5bdc03575a062f674d5bb2e80d (patch) | |
tree | 17621290745959cd705c72c214ebdb19bbeafdc3 /pkgs/applications/office | |
parent | ab936fb123ceb98048ccc3ba750d27468b89edd5 (diff) |
trilium: 0.49.5 -> 0.50.1
Diffstat (limited to 'pkgs/applications/office')
-rw-r--r-- | pkgs/applications/office/trilium/0001-Use-console-logger-instead-of-rolling-files.patch | 53 | ||||
-rw-r--r-- | pkgs/applications/office/trilium/default.nix | 6 |
2 files changed, 14 insertions, 45 deletions
diff --git a/pkgs/applications/office/trilium/0001-Use-console-logger-instead-of-rolling-files.patch b/pkgs/applications/office/trilium/0001-Use-console-logger-instead-of-rolling-files.patch index 0cb26afe82964..7b2635cfe121a 100644 --- a/pkgs/applications/office/trilium/0001-Use-console-logger-instead-of-rolling-files.patch +++ b/pkgs/applications/office/trilium/0001-Use-console-logger-instead-of-rolling-files.patch @@ -1,13 +1,14 @@ diff --git a/src/services/log.js b/src/services/log.js -index 4f29994..1e89e0a 100644 +index 0fcd9812..dcbff070 100644 --- a/src/services/log.js +++ b/src/services/log.js -@@ -1,14 +1,5 @@ +@@ -1,15 +1,7 @@ "use strict"; -const fs = require('fs'); -const dataDir = require('./data_dir'); -- + const cls = require('./cls'); + -if (!fs.existsSync(dataDir.LOG_DIR)) { - fs.mkdirSync(dataDir.LOG_DIR, 0o700); -} @@ -17,7 +18,7 @@ index 4f29994..1e89e0a 100644 const SECOND = 1000; const MINUTE = 60 * SECOND; const HOUR = 60 * MINUTE; -@@ -16,45 +7,7 @@ const DAY = 24 * HOUR; +@@ -17,38 +9,6 @@ const DAY = 24 * HOUR; const NEW_LINE = process.platform === "win32" ? '\r\n' : '\n'; @@ -54,6 +55,12 @@ index 4f29994..1e89e0a 100644 -} - function log(str) { + const bundleNoteId = cls.get("bundleNoteId"); + +@@ -56,12 +16,6 @@ function log(str) { + str = `[Script ${bundleNoteId}] ${str}`; + } + - let millisSinceMidnight = Date.now() - todaysMidnight.getTime(); - - millisSinceMidnight = checkDate(millisSinceMidnight); @@ -63,41 +70,3 @@ index 4f29994..1e89e0a 100644 console.log(str); } -@@ -83,37 +36,6 @@ function request(req, res, timeMs, responseLength = "?") { - `${res.statusCode} ${req.method} ${req.url} with ${responseLength} bytes took ${timeMs}ms`); - } - --function pad(num) { -- num = Math.floor(num); -- -- return num < 10 ? ("0" + num) : num.toString(); --} -- --function padMilli(num) { -- if (num < 10) { -- return "00" + num; -- } -- else if (num < 100) { -- return "0" + num; -- } -- else { -- return num.toString(); -- } --} -- --function formatTime(millisSinceMidnight) { -- return pad(millisSinceMidnight / HOUR) -- + ":" + pad((millisSinceMidnight % HOUR) / MINUTE) -- + ":" + pad((millisSinceMidnight % MINUTE) / SECOND) -- + "." + padMilli(millisSinceMidnight % SECOND); --} -- --function formatDate() { -- return pad(todaysMidnight.getFullYear()) -- + "-" + pad(todaysMidnight.getMonth() + 1) -- + "-" + pad(todaysMidnight.getDate()); --} -- - module.exports = { - info, - error, diff --git a/pkgs/applications/office/trilium/default.nix b/pkgs/applications/office/trilium/default.nix index 39bb5d1bf141b..fd317b8481090 100644 --- a/pkgs/applications/office/trilium/default.nix +++ b/pkgs/applications/office/trilium/default.nix @@ -19,16 +19,16 @@ let maintainers = with maintainers; [ fliegendewurst ]; }; - version = "0.49.5"; + version = "0.50.1"; desktopSource = { url = "https://github.com/zadam/trilium/releases/download/v${version}/trilium-linux-x64-${version}.tar.xz"; - sha256 = "0bis0xkpcr8rvhm9364v0np5cnvkscv2fgl90f455lcwy7kk9m12"; + sha256 = "1fb491ld3z6b2cndy8nl7zhpdsbb2v6kkrrc0hv92zm9qnfp7a99"; }; serverSource = { url = "https://github.com/zadam/trilium/releases/download/v${version}/trilium-linux-x64-server-${version}.tar.xz"; - sha256 = "1wv9xz1asjadz1jzgpaxf6lzbj5azgsq0qpawp3y257h488r1z9k"; + sha256 = "1yfj1i5hsphp1y52rgsapqmmv7cvl4imf6dkv8fp3qx5i7j4y5j9"; }; in { |