hyprwm / Hyprland

Hyprland is a highly customizable dynamic tiling Wayland compositor that doesn't sacrifice on its looks.
https://hyprland.org
BSD 3-Clause "New" or "Revised" License
18.05k stars 753 forks source link

Unable to update hyprpm headers, "fatal: error processing shallow info: 4" (nixOS) #6540

Open fredcamaral opened 3 weeks ago

fredcamaral commented 3 weeks ago

Bug or Regression?

Bug

System Info and Version

System/Version info ```sh Hyprland, built from branch at commit dirty (). Date: Tag: , commits: flags: (if any) System Information: System name: Linux Node name: megaman Release: 6.9.4 Version: #1-NixOS SMP PREEMPT_DYNAMIC Wed Jun 12 09:39:59 UTC 2024 GPU information: os-release: ANSI_COLOR="1;34" BUG_REPORT_URL="https://github.com/NixOS/nixpkgs/issues" BUILD_ID="24.05.20240612.cc54fb4" DOCUMENTATION_URL="https://nixos.org/learn.html" HOME_URL="https://nixos.org/" ID=nixos IMAGE_ID="" IMAGE_VERSION="" LOGO="nix-snowflake" NAME=NixOS PRETTY_NAME="NixOS 24.05 (Uakari)" SUPPORT_END="2024-12-31" SUPPORT_URL="https://nixos.org/community.html" VERSION="24.05 (Uakari)" VERSION_CODENAME=uakari VERSION_ID="24.05" plugins: ```

Description

Just refresh NixOS install, trying to update headers through hyprpm update. I am getting the fatal: error processing shallow info: 4. I've also tried doing the sudo rm -rf /tmp/hyprpm/hyprland-[USER]* && git clone --recursive https://github.com/hyprwm/Hyprland /tmp/hyprpm/hyprland-[USER] before performing the hyprpm update, but did not work.

Another thing I did is to try to make all myself the within Hyprland cloned repo, to follow with a make installheaders, but it is claiming there is a missing OpenGL lib (GLES3).

Searching through git's bugs, I saw a post saying the parsing of the shallow date could be wrong if language is not set as en_US. The echo $LC_TIME is en_US.UTF-8, so should not be it.

If it helps:

How to reproduce

hyprpm update

Crash reports, logs, images, videos

No response

fufexan commented 3 weeks ago

It's very probable that hyprpm doesn't work on NixOS, but we have several other mechanisms of using plugins.

The easiest is using this option with the Home Manager Hyprland module.

If you don't want to use that, simply use plugin = ${yourpluginpackage}/lib/yourplugin.so in your Hyprland config (wrapped with nix).

For a better understanding of the problem, which plugins are you using?

fredcamaral commented 3 weeks ago

None at the moment. But I would like to use hyprbars and hy3. I've tried your suggestion, like this:

and then, on ./home/default.nix:

{ config, pkgs, pkgs-unstable, lib, inputs, ... }:

{
  imports = [
    ./user
  ];

  wayland.windowManager.hyprland = {
    enable = true;
    systemd.enable = true;

   plugins = [
     inputs.hy3.packages.x86_64-linux.hy3
   ];

    settings = {
      "$mod" = "SUPER";
    };
  };

  home.username = "[[USER]]";
  home.homeDirectory = "/home/[[USER]]";
  home.stateVersion = "24.05";
  programs.home-manager.enable = true;
}

It's not working either. Although now I can compile everything (apparently), I still can't load the plugin.

fufexan commented 3 weeks ago

Hyprland 0.41 should be merged in Nixpkgs soon, along with hy3 ver 0.41, and hopefully this is going to be fixed.

fredcamaral commented 3 weeks ago

Thanks. I imagine for now the alternative is wait, right? Best -

AstralPhnx commented 1 week ago

With 0.41 pushed to repos I can confirm... hyprpm still does not work properly.

There are plugins available as nixpkg's now but I shouldn't have to use HomeManager to get working plugins. If an official nixpkg and nix module option is being provided I would expect proper functionality with that installation option, especially if it's the primarily recommended way to install hyprland.

fufexan commented 1 week ago

@AstralPhnx it's gonna come eventually. I just don't have time for it right now. If you don't want to use Home Manager, you're free to yank all the nix2hyprlang generation and add that to the NixOS module to generate a config file. You can then wrap cfg.finalPackage and pass the args -c ${configFile}.