Nix: revamp

This commit is contained in:
Mihai Fufezan 2024-08-13 23:13:20 +03:00
parent a0278ab718
commit 32ab590cf1
Signed by: fufexan
SSH key fingerprint: SHA256:SdnKmEpJrDu1+2UO1QpB/Eg4HKcdDi6n+xSRqFNJVpg
3 changed files with 17 additions and 3 deletions

View file

@ -2,8 +2,8 @@
title: Contributing and Debugging
---
Everything needed to build and debug Hyprland is included inside the provided
`devShell`.
Everything needed to build and debug Hyprland and other hyprwm programs is
included inside the provided `devShell`s.
To use it in the cloned repo, simply run `nix develop`.
@ -12,6 +12,11 @@ To use it in the cloned repo, simply run `nix develop`.
A debug build is already provided through
`hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland-debug`.
Most hyprwm apps also provide their own `-debug` versions. For those that don't,
one can build the debug version from the CLI by using
[overrideAttrs](../Options-Overrides/#using-nix-repl) with
`cmakeBuildType = "debug";`.
## Bisecting an issue
Follow the

View file

@ -51,3 +51,12 @@ nix-repl> :bl outputs.packages.x86_64-linux.hyprland.override { /* flag here */
```
Then you can run Hyprland from the built path.
You can also use `overrideAttrs` to override `mkDerivation`'s arguments, such as
`cmakeBuildType`:
```nix
$ nix repl
nix-repl> :lf git+https://github.com/hyprwm/Hyprland?submodules=1
nix-repl> :bl outputs.packages.x86_64-linux.hyprland.overrideAttrs (self: super: { cmakeBuildType = "debug" })
```

View file

@ -35,7 +35,7 @@ For more options, see
For other NixOS options, see [Hyprland on NixOS](./Hyprland-on-NixOS).
## Home-manager module
## Home Manager module
Read [Hyprland on Home Manager](./Hyprland-on-Home-Manager).