GithubHelp home page GithubHelp logo

Comments (12)

solaris765 avatar solaris765 commented on July 23, 2024 4

I'd like to add that I experienced this issue after updating my flake with nix flake update
It seems the recent(?) change that requires you set stylix.enable may have caused stylix.image not to be defined anymore.

I added stylix.enable = true; to my configuration.nix to solve the issue.

from stylix.

danth avatar danth commented on July 23, 2024 1

Hi! I'm not sure if you're just trying to install Stylix, or if this is a new issue as a result of recent updates.

Do you have any other Stylix settings in your nixos/configuration.nix?

If you're installing Stylix for the first time, then from the config you've provided, it looks like you'll need to do the following:

  1. Move your Stylix settings from home.nix to configuration.nix, since you imported the NixOS version of Stylix.
  2. Choose a wallpaper using stylix.image.

from stylix.

joefiorini avatar joefiorini commented on July 23, 2024 1

I have what I believe to be the latest stylix and the latest nix-darwin. I'm getting error: The option 'stylix.image' is used but not defined. as well when trying to use nix-darwin switch.

I noticed the error actually occurs at: /nix/store/c5d7z0g0mqdvqanndgcfxcffvkcn4ymd-source/stylix/home-manager-integration.nix. Based on that, is it breaking because the home-manager config doesn't have defs for stylix?

Here is the relevant subset of my nix flake metadata output:

├───home-manager: github:nix-community/home-manager/845a5c4c073f74105022533907703441e0464bc3?narHash=sha256-vWSkg6AMok1UUQiSYVdGMOXKD2cDFnajITiSi0Zjd1A%3D (2024-06-04 18:53:02)
│   └───nixpkgs follows input 'nixpkgs'
├───nix-darwin: github:lnl7/nix-darwin/58b905ea87674592aa84c37873e6c07bc3807aba?narHash=sha256-iMVwdob8F6P6Ib%2BpnhMZqyvYI10ZxmvA885jjnEaO54%3D (2024-06-15 08:40:58)
│   └───nixpkgs follows input 'nixpkgs-darwin'
└───stylix: github:danth/stylix/f13c946181730f98e1a5cd09714100490207b250?narHash=sha256-REUyeY%2BgD/QuTwAhuJycheej0FWFGPTosI%2BjiG5TsQk%3D (2024-06-17 14:30:35)
    ├───home-manager: github:nix-community/home-manager/e3ad5108f54177e6520535768ddbf1e6af54b59d?narHash=sha256-W9pyM3/vePxrffHtzlJI6lDS3seANQ%2BNqp%2Bi58O46LI%3D (2024-05-17 07:24:04)
    │   └───nixpkgs follows input 'stylix/nixpkgs'
    └───nixpkgs: github:NixOS/nixpkgs/ee4a6e0f566fe5ec79968c57a9c2c3c25f2cf41d?narHash=sha256-clkcOIkg8G4xuJh%2B1onLG4HPMpbtzdLv4rHxFzgsH9c%3D (2024-05-05 12:27:12)
 

from stylix.

MercuryHgO avatar MercuryHgO commented on July 23, 2024

Hi! I'm not sure if you're just trying to install Stylix, or if this is a new issue as a result of recent updates.

Do you have any other Stylix settings in your nixos/configuration.nix?

If you're installing Stylix for the first time, then from the config you've provided, it looks like you'll need to do the following:

1. Move your Stylix settings from `home.nix` to `configuration.nix`, since you imported the NixOS version of Stylix.

2. Choose a wallpaper using `stylix.image`.

Same result, if i try adding the image it says

error: builder for '/nix/store/y5491140ymf8vcvgky4hdqkcfnghc3d6-stylix-kde-theme.drv' failed with exit code 1;
       last 1 log lines:
       > magick: unable to open image '/home/bittermann/nix/wallpaper.jpg': No such file or directory @ error/blob.c/OpenBlob/3596.

Directory is valid

from stylix.

MercuryHgO avatar MercuryHgO commented on July 23, 2024

Is it necessary to add wallpaper to config?

from stylix.

MercuryHgO avatar MercuryHgO commented on July 23, 2024

if i try adding the image it says

error: builder for '/nix/store/y5491140ymf8vcvgky4hdqkcfnghc3d6-stylix-kde-theme.drv' failed with exit code 1;
       last 1 log lines:
       > magick: unable to open image '/home/bittermann/nix/wallpaper.jpg': No such file or directory @ error/blob.c/OpenBlob/3596.

My fault, but even if i add the image, it says this:

error:
       … while calling the 'head' builtin

         at /nix/store/giq1qbcwfx5gq0g9jf6id0b3m55a860j-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/giq1qbcwfx5gq0g9jf6id0b3m55a860j-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: syntax error, unexpected invalid token

       at /nix/store/19njvlyri8lkvrq3md997i1adwzicldr-source/nixos/wallpaper.jpg:1:1:

            1| ����JFIF,,AMPF��
             | ^
            2| �ExifMM*
                      ����(1�2�<��i��%	XAppleiPhone 12 miniHH17.4.12024:05:16 17:33:37iPhone 12 mini$�������"�' �0232���
                      ```

from stylix.

danth avatar danth commented on July 23, 2024

That error sounds like it's trying to import the image as if it was Nix code.

How did you set the wallpaper option?

from stylix.

MercuryHgO avatar MercuryHgO commented on July 23, 2024

That error sounds like it's trying to import the image as if it was Nix code.

How did you set the wallpaper option?

Yea, im accidentally imported as import ./wallaper.png.

Its still not processing this image if configures as absolute path:

  stylix = {
    enable = true;
    base16Scheme = "${pkgs.base16-schemes}/share/themes/gruvbox-dark-medium.yaml";
    image = "/home/bittermann/nix/nixos/wallpaper.png";
  };

error

error: builder for '/nix/store/xzkgbldmbngj32m9glv5yjxf87ji0bxc-stylix-kde-theme.drv' failed with exit code 1;
       last 1 log lines:
       > magick: unable to open image '/home/bittermann/nix/nixos/wallpaper.png': No such file or directory @ error/blob.c/OpenBlob/3596.
       For full logs, run 'nix log /nix/store/xzkgbldmbngj32m9glv5yjxf87ji0bxc-stylix-kde-theme.drv'.
error: 1 dependencies of derivation '/nix/store/gjva7p2b3nvn7xng9h7cljgd5i3p11km-activation-script.drv' failed to build
error: 1 dependencies of derivation '/nix/store/9pm011fcspbjka488shwr3ly2ivhj4ss-home-manager-path.drv' failed to build
error: 1 dependencies of derivation '/nix/store/53dbnjp5mqfskr75aw067dlvg5dahrmn-home-manager-generation.drv' failed to build
error: 1 dependencies of derivation '/nix/store/89xbmkg0wn3fmac18gwdg6wcsykz8yc7-unit-home-manager-bittermann.service.drv' failed to build
error: 1 dependencies of derivation '/nix/store/rclra762f5mx13cb8phl9zgr37pav3fh-system-units.drv' failed to build
error: 1 dependencies of derivation '/nix/store/lj3ivdnaw5zwljhsv5rh30xmhw0cv05h-etc.drv' failed to build
error: 1 dependencies of derivation '/nix/store/hyj48amrxzwsr45k3hn6ij485h88rh6y-nixos-system-nixos-24.05.20240609.2819fff.drv' failed to build

from stylix.

danth avatar danth commented on July 23, 2024

Try configuring it as a relative path without quotes, like this: ./wallpaper.png

It will need to be in the same directory as your Nix files.

from stylix.

geryzhydrox avatar geryzhydrox commented on July 23, 2024

Hey there, I've had various arcane errors with Stylix that I've tried - and failed - to get help with on Element, but now after switching to flakes my error message has switched to something that apparently at least someone else has too, error: The option 'stylix.image' is used but not defined.. I'm trying the same things now and am still stuck at that error.

from stylix.

MercuryHgO avatar MercuryHgO commented on July 23, 2024

Try configuring it as a relative path without quotes, like this: ./wallpaper.png

It will need to be in the same directory as your Nix files.

That fixed my issue, thanks.
But still, is it should be necessary to define wallpaper?

from stylix.

trueNAHO avatar trueNAHO commented on July 23, 2024

But still, is it should be necessary to define wallpaper?

See #200.

from stylix.

Related Issues (20)

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.