mirror of
https://github.com/Trensa-Organization/split-monitor-workspaces.git
synced 2025-03-15 11:13:39 +01:00
docs: include NixOS installation instructions in the README
This commit is contained in:
parent
11d8167adf
commit
1d8197c0a9
1 changed files with 66 additions and 0 deletions
66
README.md
66
README.md
|
@ -17,6 +17,7 @@ plugins = [
|
|||
Then update via the `hyprload,update` dispatcher
|
||||
|
||||
## Manual installation
|
||||
|
||||
1. Export the `HYPRLAND_HEADERS` variable to point to the root directory of the Hyprland repo
|
||||
- `export HYPRLAND_HEADERS="$HOME/repos/Hyprland"`
|
||||
2. Compile
|
||||
|
@ -24,9 +25,74 @@ Then update via the `hyprload,update` dispatcher
|
|||
3. Add this line to the bottom of your hyprland config
|
||||
- `exec-once=hyprctl plugin load <ABSOLUTE PATH TO split-monitor-workspaces.so>`
|
||||
|
||||
## NixOS installation
|
||||
|
||||
With flakes enabled, a sample installation will look like this:
|
||||
|
||||
```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";
|
||||
split-monitor-workspaces = {
|
||||
url = "github:Duckonaut/split-monitor-workspaces";
|
||||
inputs.hyprland.follows = "hyprland"; # <- make sure this line is present for the plugin to work as intended
|
||||
};
|
||||
};
|
||||
|
||||
outputs = {
|
||||
self,
|
||||
nixpkgs,
|
||||
home-manager,
|
||||
split-monitor-workspaces,
|
||||
...
|
||||
}: let
|
||||
system = "x86_64-linux";
|
||||
# ↑ Swap it for your system if needed
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
in {
|
||||
nixosConfigurations = {
|
||||
yourHostname = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
# ...
|
||||
home-manager.nixosModules.home-manager
|
||||
{
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
users.yourUsername = {
|
||||
wayland.windowManager.hyprland = {
|
||||
# ...
|
||||
plugins = [
|
||||
split-monitor-workspaces.packages.${pkgs.system}.split-monitor-workspaces
|
||||
];
|
||||
# ...
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
# ...
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
```
|
||||
|
||||
You will need to have home-manager installed and configured. You use `wayland.windowManager.hyprland.plugins = [];` to add the plugin. The home-manager
|
||||
module will handle the rest.
|
||||
|
||||
# Usage
|
||||
|
||||
The plugin provides drop-in replacements for workspace-related commands
|
||||
|
||||
| Normal | Replacement |
|
||||
|-----------------------|-------------------------------|
|
||||
| workspace | split-workspace |
|
||||
|
|
Loading…
Add table
Reference in a new issue