Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

trilium-next-{desktop,server}: init at 0.90.12 #356930

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

FliegendeWurst
Copy link
Member

New package, based on the old Trilium.

cc @eliandoran

Closes #348144
Closes #339237

Things done


Add a 👍 reaction to pull requests you find important.

@FliegendeWurst FliegendeWurst mentioned this pull request Nov 18, 2024
13 tasks
@github-actions github-actions bot added 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` labels Nov 18, 2024
@FliegendeWurst FliegendeWurst added the backport release-24.11 Backport PR automatically label Nov 18, 2024
@FliegendeWurst FliegendeWurst force-pushed the trilium-next branch 3 times, most recently from 741c113 to ccda165 Compare November 18, 2024 11:49
Copy link
Contributor

@eliandoran eliandoran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@FliegendeWurst
Copy link
Member Author

@ofborg build trilium-next-desktop trilium-next-server

(internal ofborg error)

@Pleune
Copy link
Contributor

Pleune commented Dec 5, 2024

Would it make sense to build the packages instead of fetching them from GitHub releases?

For the server, the build script is a little messy but I think most of this can be skipped. The desktop app is a little more involved, but this would let us use the nix-patched electron.

@FliegendeWurst
Copy link
Member Author

The desktop app is a little more involved, but this would let us use the nix-patched electron.

Unfortunately the desktop app uses electron-forge, which is used by no other packages in nixpkgs. I tried to build from source a while ago, and it wasn't really possible..

@FliegendeWurst
Copy link
Member Author

Note that we already use nixpkgs' electron to create the wrapper.

@FliegendeWurst
Copy link
Member Author

FliegendeWurst commented Dec 5, 2024

My previous attempt at a source build: https://github.com/FliegendeWurst/nixpkgs/blob/b37e2e7c3479d893d5acf9acf4566ae2e72b22f8/pkgs/applications/office/trilium-next/desktop.nix

@eliandoran
Copy link
Contributor

Hi, @FliegendeWurst .

We should probably update to v0.90.12 which is the latest stable version.

diff --git a/pkgs/by-name/tr/trilium-next-desktop/package.nix b/pkgs/by-name/tr/trilium-next-desktop/package.nix
index 33e09385b26d..0e72c1e9833d 100644
--- a/pkgs/by-name/tr/trilium-next-desktop/package.nix
+++ b/pkgs/by-name/tr/trilium-next-desktop/package.nix
@@ -16,13 +16,13 @@
 
 let
   pname = "trilium-next-desktop";
-  version = "0.90.8";
+  version = "0.90.12";
 
   linuxSource.url = "https://github.com/TriliumNext/Notes/releases/download/v${version}/TriliumNextNotes-v${version}-linux-x64.zip";
-  linuxSource.sha256 = "0l9a2l79jcbr4522k03bbzli9gv96pr15cyig6fg9qpf71cjvda1";
+  linuxSource.sha256 = "0ji28l60wyzhjbi6g5845dnm763bvg7535zfgzcmfgwjs6zr6nfq";
 
   darwinSource.url = "https://github.com/TriliumNext/Notes/releases/download/v${version}/TriliumNextNotes-v${version}-macos-x64.zip";
-  darwinSource.sha256 = "0wki6a6bpp698r51wvyl7xh8y8csj5yaihaxfplp8q33zp9nw2q8";
+  darwinSource.sha256 = "0jv80k7dk6gpyfj36iin6y7fk7qan4bya72f14jcgfla95wvk6ls";
 
   meta = {
     description = "Hierarchical note taking application with focus on building large personal knowledge bases";
@@ -89,7 +89,7 @@ let
       asar extract $out/share/trilium/resources/app.asar $tmp
       rm $out/share/trilium/resources/app.asar
 
-      for f in "src/services/i18n.ts" "dist/src/services/i18n.js" "dist/src/build/src/services/i18n.js" "build/src/services/i18n.js"; do
+      for f in "src/services/utils.ts" "dist/src/services/utils.js"; do
         substituteInPlace $tmp/$f \
           --replace-fail "process.resourcesPath" "'$out/share/trilium/resources'"
       done
diff --git a/pkgs/by-name/tr/trilium-next-server/package.nix b/pkgs/by-name/tr/trilium-next-server/package.nix
index 3544ef30885a..5d48f2b71184 100644
--- a/pkgs/by-name/tr/trilium-next-server/package.nix
+++ b/pkgs/by-name/tr/trilium-next-server/package.nix
@@ -8,10 +8,10 @@
 }:
 
 let
-  version = "0.90.8";
+  version = "0.90.12";
 
   serverSource.url = "https://github.com/TriliumNext/Notes/releases/download/v${version}/TriliumNextNotes-v${version}-server-linux-x64.tar.xz";
-  serverSource.sha256 = "0ax2z3siaxvmdiasn3ddll0yvllkyi3g2xbks5h6vmgh59ivjh2x";
+  serverSource.sha256 = "0gvb01cj334n805rs230xwwcv4rf2z2giikpagw8wqrs54gy3b35";
 in
 stdenv.mkDerivation {
   pname = "trilium-next-server";

@FliegendeWurst
Copy link
Member Author

I updated the package.

(by the way, are the docs at https://github.com/TriliumNext/Notes/tree/develop/docs hosted somewhere on the Github pages?)

@eliandoran
Copy link
Contributor

@FliegendeWurst ,

(by the way, are the docs at https://github.com/TriliumNext/Notes/tree/develop/docs hosted somewhere on the Github pages?)

They are hosted at https://triliumnext.github.io/Notes but they are slightly out of date as we are struggling a bit to get the documentation to be hosted on a TriliumNext instance.

A more up to date version of these documents can be found at https://elian-trilium.pikapod.net/share/4yYHqKbLovVX . It will be relocated to the TriliumNext documentation instance.

The latest version of the user-facing documentation is available here: https://triliumnext.pikapod.net/share/

Copy link
Contributor

@eliandoran eliandoran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please also don't forget to rename the PR to reflect the change in version to v0.90.12.

pkgs/by-name/tr/trilium-next-desktop/package.nix Outdated Show resolved Hide resolved
@FliegendeWurst FliegendeWurst changed the title trilium-next-{desktop,server}: init at 0.90.8 trilium-next-{desktop,server}: init at 0.90.12 Dec 9, 2024
@wegank wegank added the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Dec 9, 2024
@ofborg ofborg bot requested a review from eliandoran December 10, 2024 06:41
@wegank wegank added the 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in the package label Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 1-10 10.rebuild-darwin: 1 10.rebuild-linux: 1-10 11.by: package-maintainer This PR was created by the maintainer of the package it changes 12.approvals: 1 This PR was reviewed and approved by one reputable person 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in the package backport release-24.11 Backport PR automatically
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Package request: TriliumNext-server and TriliumNext-desktop
5 participants