Coder Social home page Coder Social logo

Comments (12)

nikp123 avatar nikp123 commented on August 18, 2024

also i think i can patch onlyoffice instead
https://github.com/ONLYOFFICE/core/blob/02c78a1e6fb91260b371ccaa051e5d66a5d637c8/DesktopEditor/fontengine/ApplicationFonts.cpp#L1780

from erosanix.

nikp123 avatar nikp123 commented on August 18, 2024

yep
https://search.nixos.org/options?channel=22.11&show=fonts.fontDir.enable&from=0&size=50&sort=relevance&type=packages&query=font
though, this is a massive hack

from erosanix.

nikp123 avatar nikp123 commented on August 18, 2024

didnt work because onlyoffice was built from binary, but they've thankfully added a CUSTOM_PATH to play around with ONLYOFFICE/core@68582b6

from erosanix.

nikp123 avatar nikp123 commented on August 18, 2024

bummer, it doesn't work with symlinks. though, you could use something like this in order to get fonts to work

from erosanix.

nikp123 avatar nikp123 commented on August 18, 2024

worked a bad solution, but it's a solution:

  nixpkgs.overlays = [
    ( self: super: {
      onlyoffice-bin = super.onlyoffice-bin.overrideAttrs (old: {
        preFixup = (old.preFixup or "") + ''
          gappsWrapperArgs+=(
            --set CUSTOM_FONTS_PATH "${pkgs.microsoft-fonts}/share/fonts/TTF"  # or whatever font you desire to use
          )
        '';
      });
    })
  ];

from erosanix.

emmanuelrosa avatar emmanuelrosa commented on August 18, 2024

Yes, ONLYOFFICE has a known issue (which I've reported) when /usr/share/fonts contains symlinks. The ONLYOFFICE module uses the code from fonts.fontDir.enable but I copy the fonts instead of creating symlinks to them.

I'm unable to reproduce your error. Can you show me the build log?

from erosanix.

nikp123 avatar nikp123 commented on August 18, 2024

Yes, ONLYOFFICE has a known issue (which I've reported) when /usr/share/fonts contains symlinks. The ONLYOFFICE module uses the code from fonts.fontDir.enable but I copy the fonts instead of creating symlinks to them.

I'm unable to reproduce your error. Can you show me the build log?

The log is quite boring, as it's just a simple "folder not found" error.
log.txt

from erosanix.

nikp123 avatar nikp123 commented on August 18, 2024

I imported your module as a flake, added this to my nixOS modules: erosanix.nixosModules.onlyoffice

And invoked programs.onlyoffice.enable = true;

from erosanix.

emmanuelrosa avatar emmanuelrosa commented on August 18, 2024

I pushed an update that I think will fix it.

The error message is correct in that the given path is not a directory; It's a symlink. The update copies the icons instead of using a symlink. There must be a difference between how that's handled on NixOS 22.11 and NixOS master.

from erosanix.

nikp123 avatar nikp123 commented on August 18, 2024

image

Uh, yeah, more bugs to crush unfortunately.

from erosanix.

emmanuelrosa avatar emmanuelrosa commented on August 18, 2024

OK, I see that the package on NixOS 21.11 doesn't have icons. I pushed an update that should work around that.

from erosanix.

nikp123 avatar nikp123 commented on August 18, 2024

Works perfectly now, thank you.

from erosanix.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.