added mcmojave hyprland cursor

This commit is contained in:
Nickiel12 2024-08-22 20:46:53 -07:00
parent 3ebdcf1f50
commit a3c3c91699
5 changed files with 29 additions and 85 deletions

View file

@ -444,7 +444,9 @@
"mcmojave-hyprcursor": { "mcmojave-hyprcursor": {
"inputs": { "inputs": {
"hyprcursor": "hyprcursor", "hyprcursor": "hyprcursor",
"nixpkgs": "nixpkgs_4", "nixpkgs": [
"nixpkgs"
],
"systems": "systems_3" "systems": "systems_3"
}, },
"locked": { "locked": {
@ -463,7 +465,7 @@
}, },
"nicks_nextcloud_integrations": { "nicks_nextcloud_integrations": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs_5", "nixpkgs": "nixpkgs_4",
"rust-overlay": "rust-overlay_2" "rust-overlay": "rust-overlay_2"
}, },
"locked": { "locked": {
@ -505,7 +507,7 @@
"inputs": { "inputs": {
"flake-compat": "flake-compat_2", "flake-compat": "flake-compat_2",
"flake-utils": "flake-utils_3", "flake-utils": "flake-utils_3",
"nixpkgs": "nixpkgs_7" "nixpkgs": "nixpkgs_6"
}, },
"locked": { "locked": {
"lastModified": 1724065442, "lastModified": 1724065442,
@ -587,22 +589,6 @@
} }
}, },
"nixpkgs_4": { "nixpkgs_4": {
"locked": {
"lastModified": 1722062969,
"narHash": "sha256-QOS0ykELUmPbrrUGmegAUlpmUFznDQeR4q7rFhl8eQg=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "b73c2221a46c13557b1b3be9c2070cc42cf01eb3",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_5": {
"locked": { "locked": {
"lastModified": 1692447944, "lastModified": 1692447944,
"narHash": "sha256-fkJGNjEmTPvqBs215EQU4r9ivecV5Qge5cF/QDLVn3U=", "narHash": "sha256-fkJGNjEmTPvqBs215EQU4r9ivecV5Qge5cF/QDLVn3U=",
@ -618,7 +604,7 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_6": { "nixpkgs_5": {
"locked": { "locked": {
"lastModified": 1681358109, "lastModified": 1681358109,
"narHash": "sha256-eKyxW4OohHQx9Urxi7TQlFBTDWII+F+x2hklDOQPB50=", "narHash": "sha256-eKyxW4OohHQx9Urxi7TQlFBTDWII+F+x2hklDOQPB50=",
@ -634,7 +620,7 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_7": { "nixpkgs_6": {
"locked": { "locked": {
"lastModified": 1723688146, "lastModified": 1723688146,
"narHash": "sha256-sqLwJcHYeWLOeP/XoLwAtYjr01TISlkOfz+NG82pbdg=", "narHash": "sha256-sqLwJcHYeWLOeP/XoLwAtYjr01TISlkOfz+NG82pbdg=",
@ -650,7 +636,7 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_8": { "nixpkgs_7": {
"locked": { "locked": {
"lastModified": 1724224976, "lastModified": 1724224976,
"narHash": "sha256-Z/ELQhrSd7bMzTO8r7NZgi9g5emh+aRKoCdaAv5fiO0=", "narHash": "sha256-Z/ELQhrSd7bMzTO8r7NZgi9g5emh+aRKoCdaAv5fiO0=",
@ -666,7 +652,7 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_9": { "nixpkgs_8": {
"locked": { "locked": {
"lastModified": 1724224976, "lastModified": 1724224976,
"narHash": "sha256-Z/ELQhrSd7bMzTO8r7NZgi9g5emh+aRKoCdaAv5fiO0=", "narHash": "sha256-Z/ELQhrSd7bMzTO8r7NZgi9g5emh+aRKoCdaAv5fiO0=",
@ -690,7 +676,7 @@
"git-hooks": "git-hooks", "git-hooks": "git-hooks",
"home-manager": "home-manager_2", "home-manager": "home-manager_2",
"nix-darwin": "nix-darwin", "nix-darwin": "nix-darwin",
"nixpkgs": "nixpkgs_9", "nixpkgs": "nixpkgs_8",
"nuschtosSearch": "nuschtosSearch", "nuschtosSearch": "nuschtosSearch",
"treefmt-nix": "treefmt-nix" "treefmt-nix": "treefmt-nix"
}, },
@ -740,7 +726,7 @@
"mcmojave-hyprcursor": "mcmojave-hyprcursor", "mcmojave-hyprcursor": "mcmojave-hyprcursor",
"nicks_nextcloud_integrations": "nicks_nextcloud_integrations", "nicks_nextcloud_integrations": "nicks_nextcloud_integrations",
"nixos-wsl": "nixos-wsl", "nixos-wsl": "nixos-wsl",
"nixpkgs": "nixpkgs_8", "nixpkgs": "nixpkgs_7",
"nixpkgs-stable": "nixpkgs-stable", "nixpkgs-stable": "nixpkgs-stable",
"nixvim": "nixvim", "nixvim": "nixvim",
"utils": "utils" "utils": "utils"
@ -784,7 +770,7 @@
"rust-overlay_2": { "rust-overlay_2": {
"inputs": { "inputs": {
"flake-utils": "flake-utils_2", "flake-utils": "flake-utils_2",
"nixpkgs": "nixpkgs_6" "nixpkgs": "nixpkgs_5"
}, },
"locked": { "locked": {
"lastModified": 1692497375, "lastModified": 1692497375,

View file

@ -11,7 +11,10 @@
nixos-wsl.url = "github:nix-community/NixOS-WSL/main"; nixos-wsl.url = "github:nix-community/NixOS-WSL/main";
mcmojave-hyprcursor.url = "github:libadoxon/mcmojave-hyprcursor"; mcmojave-hyprcursor = {
url = "github:libadoxon/mcmojave-hyprcursor";
inputs.nixpkgs.follows = "nixpkgs";
};
nixpkgs-stable = { nixpkgs-stable = {
url = "github:NixOS/nixpkgs/release-23.11"; url = "github:NixOS/nixpkgs/release-23.11";
@ -38,7 +41,7 @@
}; };
}; };
outputs = inputs@{ outputs = {
self, self,
nixpkgs, nixpkgs,
nixpkgs-stable, nixpkgs-stable,
@ -49,7 +52,7 @@
atuin, atuin,
nixos-wsl, nixos-wsl,
... ...
}: } @ inputs:
let let
user = "nixolas"; user = "nixolas";
system = "x86_64-linux"; system = "x86_64-linux";
@ -99,6 +102,9 @@
# To change username after installing: https://nix-community.github.io/NixOS-WSL/how-to/change-username.html # To change username after installing: https://nix-community.github.io/NixOS-WSL/how-to/change-username.html
NicksNixWSL = lib.nixosSystem { NicksNixWSL = lib.nixosSystem {
inherit system; inherit system;
specialArgs = {
inherit inputs;
};
modules = [ modules = [
nixos-wsl.nixosModules.default nixos-wsl.nixosModules.default
@ -138,7 +144,7 @@
NicksNixLaptop = lib.nixosSystem { NicksNixLaptop = lib.nixosSystem {
inherit system; inherit system;
specialArgs = { specialArgs = {
inherit user; inherit user inputs;
}; };
modules = [ modules = [
@ -170,7 +176,7 @@
NicksNixDesktop = lib.nixosSystem { NicksNixDesktop = lib.nixosSystem {
inherit system; inherit system;
specialArgs = { inherit user; }; specialArgs = { inherit user inputs; };
modules = [ modules = [
{ {

View file

@ -15,6 +15,12 @@
WLR_NO_HARDWARE_CURSORS = "1"; WLR_NO_HARDWARE_CURSORS = "1";
}; };
environment.variables.HYPRCURSOR_THEME = "McMojave";
environment.variables.HYPRCURSOR_SIZE = "32";
environment.systemPackages = [
inputs.mcmojave-hyprcursor.packages.${pkgs.stdenv.hostPlatform.system}.default
];
programs.hyprland.enable = true; programs.hyprland.enable = true;
services = { services = {

View file

@ -16,7 +16,6 @@ in
../ewwbar ../ewwbar
./displays.nix ./displays.nix
./keybinds.nix ./keybinds.nix
./hyprcursors.nix
./window_rules.nix ./window_rules.nix
]; ];

View file

@ -1,53 +0,0 @@
# Borrowed from https://github.com/cafetestrest/nixos/blob/87e6b88b39f01c893888e3dea9785b21c2d0b2b9/home-manager/hypr/hyprcursors.nix#L6
{ config, lib, pkgs, ... }:
with lib;
let
cursor = "McMojave";
McMojave = with pkgs; stdenv.mkDerivation rec {
name = "McMojave";
src = fetchFromGitHub {
owner = "OtaK";
repo = "McMojave-hyprcursor";
rev = "main";
sha256 = "sha256-+Qo88EJC0nYDj9FDsNtoA4nttck81J9CQFgtrP4eBjk=";
};
installPhase = ''
runHook preInstall
mkdir -p $out/share/icons/McMojave
cp -R dist/* $out/share/icons/McMojave/
runHook postInstall
'';
};
#TODO rename this and put into hyprcursors folder
cursorPackage = McMojave;
cfg = config.module.hypr.hyprcursors;
in
{
options = {
module.hypr.hyprcursors.enable = mkEnableOption "Enables hyprcursors";
};
config = mkIf cfg.enable {
home.packages = [
cursorPackage
];
# xdg.dataFile.".icons/${cursor}".source = "${cursorPackage}/share/icons/${cursor}";
home.file = {
".icons/${cursor}" = {
source = "${cursorPackage}/share/icons/${cursor}";
};
};
};
}