mirror of
https://github.com/Trensa-Organization/hy3.git
synced 2025-03-16 03:03:40 +01:00
Update readme with new nix instructions
Also simplify hyprload example
This commit is contained in:
parent
3618e186aa
commit
e41c3cb256
1 changed files with 60 additions and 6 deletions
66
README.md
66
README.md
|
@ -41,7 +41,62 @@ You can use `hy3:makegroup` to create a new split.
|
||||||
## Installing
|
## Installing
|
||||||
|
|
||||||
### Nix
|
### Nix
|
||||||
Under nix, use the provided devShell, then go to [Manual Installation](#manual)
|
#### Using the home-manager module
|
||||||
|
Assuming you use hyprland's home manager module, you can easily integrate hy3, as hy3 provides a home manager module that exposes the `wayland.windowManager.hyprland.plugins.hy3.enable` option.
|
||||||
|
|
||||||
|
```nix
|
||||||
|
# flake.nix
|
||||||
|
|
||||||
|
{
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||||
|
|
||||||
|
home-manager = {
|
||||||
|
url = "github:nix-community/home-manager";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
hyprland.url = "github:hyprwm/Hyprland";
|
||||||
|
|
||||||
|
hy3 = {
|
||||||
|
url = "github:outfoxxed/hy3";
|
||||||
|
inputs.hyprland.follows = "hyprland";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs = { nixpkgs, home-manager, hyprland, hy3, ... }: {
|
||||||
|
homeConfigurations."user@hostname" = home-manager.lib.homeManagerConfiguration {
|
||||||
|
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
||||||
|
|
||||||
|
modules = [
|
||||||
|
hyprland.homeManagerModules.default
|
||||||
|
hy3.homeManagerModules.default
|
||||||
|
|
||||||
|
{
|
||||||
|
wayland.windowManager.hyprland = {
|
||||||
|
enable = true;
|
||||||
|
plugins.hy3.enable = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
#### Manually (Nix)
|
||||||
|
hy3's binary is availible as `${hy3.packages.<system>.hy3}/lib/libhy3.so`, so you can also
|
||||||
|
directly use it in your hyprland config like so:
|
||||||
|
|
||||||
|
```nix
|
||||||
|
# ...
|
||||||
|
wayland.windowManager.hyprland = {
|
||||||
|
# ...
|
||||||
|
extraConfig = ''
|
||||||
|
exec-once = hyprctl plugin load ${hy3.packages.x86_64-linux.hy3}/lib/libhy3.so
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
```
|
||||||
|
|
||||||
### [Hyprload](https://github.com/Duckonaut/hyprload)
|
### [Hyprload](https://github.com/Duckonaut/hyprload)
|
||||||
Add an entry to your hyprload.toml like so:
|
Add an entry to your hyprload.toml like so:
|
||||||
|
@ -49,19 +104,18 @@ Add an entry to your hyprload.toml like so:
|
||||||
```toml
|
```toml
|
||||||
plugins = [
|
plugins = [
|
||||||
# ...
|
# ...
|
||||||
{ git = "https://github.com/outfoxxed/hy3", branch = "master", name = "hy3" },
|
"outfoxxed/hy3",
|
||||||
# ...
|
# ...
|
||||||
]
|
]
|
||||||
```
|
```
|
||||||
|
|
||||||
### Manual
|
### Manual
|
||||||
First export `HYPRLAND_HEADERS`, then run the following commands:
|
Install hyprland, then run the following commands:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
cmake -DCMAKE_BUILD_TYPE=Debug -B build
|
cmake -DCMAKE_BUILD_TYPE=Debug -B build
|
||||||
cmake --build build
|
cmake --build build
|
||||||
```
|
```
|
||||||
|
|
||||||
> **Note**: Please use a debug build as debugging a backtrace from a release build is much more difficult if you need to report an error.
|
The plugin will be located at `build/libhy3.so`, and you can load it normally
|
||||||
|
(See [the hyprland wiki](https://wiki.hyprland.org/Plugins/Using-Plugins/#installing--using-plugins) for details.)
|
||||||
The plugin will be located at `build/libhy3.so`.
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue