an-anime-team / an-anime-game-launcher

An Anime Game launcher for Linux with telemetry disabling
https://discord.gg/ck37X6UWBp
GNU General Public License v3.0
1.44k stars 64 forks source link

Can't install on NixOS #387

Open Mooling0602 opened 1 week ago

Mooling0602 commented 1 week ago

Here are my config files:

/etc/nixos/configuration.nix

The same to this part


{ config, pkgs, ... }:

{ ... nix.settings = { substituters = [ "https://ezkea.cachix.org" ]; trusted-public-keys = [ "ezkea.cachix.org-1:ioBmUbJTZIKsHmWWXPe1FSFbeVe+afhfgqgTSNd34eI=" ]; }; ... }

## /etc/nixos/home.nix
```nix
{ config, pkgs, ... }:
let
  externalConfig = import ./userApps/an-anime-game-launcher.nix;
in
{
  ...
  import = externalConfig;
  ...
}

/etc/nixos/userApps/an-anime-game-launcher.nix

The same to this part

let
aagl-gtk-on-nix = import (builtins.fetchTarball "https://github.com/ezKEa/aagl-gtk-on-nix/archive/main.tar.gz");
in
{
home.packages = [ aagl-gtk-on-nix.an-anime-game-launcher ];
}

Error logs


~ ❯ sudo nixos-rebuild switch
building the system configuration...
error:
… while calling the 'head' builtin
     at /nix/store/bi5zxc0v5g6ylygdwyqzh280sccg3ykb-source/lib/attrsets.nix:1575:11:

     1574|         || pred here (elemAt values 1) (head values) then
     1575|           head values
         |           ^
     1576|         else

   … while evaluating the attribute 'value'

     at /nix/store/bi5zxc0v5g6ylygdwyqzh280sccg3ykb-source/lib/modules.nix:809:9:

      808|     in warnDeprecation opt //
      809|       { value = builtins.addErrorContext "while evaluating the option `${showOption loc}':" value;
         |         ^
      810|         inherit (res.defsFinal') highestPrio;

   (stack trace truncated; use '--show-trace' to show the full trace)

   error: in pure evaluation mode, 'fetchTarball' requires a 'sha256' argument
Mooling0602 commented 1 week ago

I have configured home-manager installation by this article, so there's no need for me to run home-manager switch for me.

Cryolitia commented 3 days ago

It's a Nix question, shouldn't come up here.


Does sudo nixos-rebuild switch --impure work for you?