feat(wayland pkgs): use cachix and overlays instead of package set

This commit is contained in:
matt1432 2023-10-20 11:22:20 -04:00
parent 254dcbe941
commit 61047b3dcc
6 changed files with 62 additions and 44 deletions

View file

@ -2,6 +2,7 @@
, home-manager , home-manager
, lib , lib
, nixpkgs , nixpkgs
, nixpkgs-wayland
, nur , nur
, nix-melt , nix-melt
, nurl , nurl
@ -32,10 +33,18 @@
substituters = [ substituters = [
"https://hyprland.cachix.org" "https://hyprland.cachix.org"
"https://nix-gaming.cachix.org" "https://nix-gaming.cachix.org"
# Nixpkgs-Wayland
"https://cache.nixos.org"
"https://nixpkgs-wayland.cachix.org"
#
]; ];
trusted-public-keys = [ trusted-public-keys = [
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc=" "hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
"nix-gaming.cachix.org-1:nbjlureqMbRAxR1gJ/f3hxemL9svXaZF/Ees8vCUUs4=" "nix-gaming.cachix.org-1:nbjlureqMbRAxR1gJ/f3hxemL9svXaZF/Ees8vCUUs4="
# Nixpkgs-Wayland
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
"nixpkgs-wayland.cachix.org-1:3lwxaILxMRkVhehr5StQprHdEo4IrE8sRho9R9HOLYA="
#
]; ];
}; };
@ -45,6 +54,7 @@
exact = false; exact = false;
}; };
}; };
nixpkgs.overlays = [ nixpkgs-wayland.overlay ];
services.xserver = { services.xserver = {
layout = "ca"; layout = "ca";

View file

@ -531,9 +531,7 @@
"flake-compat": "flake-compat_2", "flake-compat": "flake-compat_2",
"lib-aggregate": "lib-aggregate", "lib-aggregate": "lib-aggregate",
"nix-eval-jobs": "nix-eval-jobs", "nix-eval-jobs": "nix-eval-jobs",
"nixpkgs": [ "nixpkgs": "nixpkgs_6"
"nixpkgs"
]
}, },
"locked": { "locked": {
"lastModified": 1697793343, "lastModified": 1697793343,
@ -613,6 +611,22 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_6": {
"locked": {
"lastModified": 1697456312,
"narHash": "sha256-roiSnrqb5r+ehnKCauPLugoU8S36KgmWraHgRqVYndo=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "ca012a02bf8327be9e488546faecae5e05d7d749",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nur": { "nur": {
"locked": { "locked": {
"lastModified": 1697793907, "lastModified": 1697793907,

View file

@ -1,8 +1,11 @@
{ {
inputs = { inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
nixpkgs-wayland.url = "github:nix-community/nixpkgs-wayland";
nur.url = "github:nix-community/NUR"; nur.url = "github:nix-community/NUR";
nix-gaming.url = "github:fufexan/nix-gaming";
home-manager = { home-manager = {
url = "github:nix-community/home-manager"; url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
@ -20,18 +23,11 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
nixpkgs-wayland = {
url = "github:nix-community/nixpkgs-wayland";
inputs.nixpkgs.follows = "nixpkgs";
};
neovim-nightly-overlay = { neovim-nightly-overlay = {
url = "github:nix-community/neovim-nightly-overlay"; url = "github:nix-community/neovim-nightly-overlay";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
nix-gaming.url = "github:fufexan/nix-gaming";
nix-melt = { nix-melt = {
url = "github:nix-community/nix-melt"; url = "github:nix-community/nix-melt";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";

View file

@ -21,6 +21,7 @@ const AppItem = (app, window) => {
connections: [['clicked', () => { connections: [['clicked', () => {
App.closeWindow(window); App.closeWindow(window);
Utils.exec(`hyprctl dispatch exec ${app.executable}`); Utils.exec(`hyprctl dispatch exec ${app.executable}`);
// TODO: focus on new client. Is this only needed after launch?
++app.frequency; ++app.frequency;
}]], }]],
child: Box({ child: Box({

View file

@ -1,6 +1,4 @@
{ pkgs, config, hyprland, hyprgrass, ags, nixpkgs-wayland, ... }: let { pkgs, config, hyprland, hyprgrass, ags, ... }: let
waypkgs = nixpkgs-wayland.packages.x86_64-linux;
configDir = config.services.hostvars.configDir; configDir = config.services.hostvars.configDir;
symlink = config.lib.file.mkOutOfStoreSymlink; symlink = config.lib.file.mkOutOfStoreSymlink;
@ -52,44 +50,44 @@ in {
''; '';
}; };
home.packages = [ home.packages = with pkgs; [
# ags # ags
pkgs.sassc sassc
pkgs.coloryou coloryou
pkgs.libnotify libnotify
pkgs.playerctl playerctl
pkgs.bluez-tools bluez-tools
pkgs.brightnessctl brightnessctl
pkgs.pulseaudio pulseaudio
pkgs.libinput libinput
## gui ## gui
pkgs.pavucontrol # TODO: replace with ags widget pavucontrol # TODO: replace with ags widget
pkgs.networkmanagerapplet # TODO: replace with ags widget networkmanagerapplet # TODO: replace with ags widget
pkgs.blueberry # TODO: replace with ags widget blueberry # TODO: replace with ags widget
# Hyprland # Hyprland
pkgs.hyprpaper hyprpaper
waypkgs.swayidle swayidle
pkgs.lisgd lisgd
pkgs.swayosd swayosd
pkgs.squeekboard squeekboard
pkgs.xclip xclip
waypkgs.wl-clipboard wl-clipboard
pkgs.cliphist cliphist
## gui ## gui
pkgs.gtklock gtklock
pkgs.wl-color-picker # TODO: add bind for this in hyprland wl-color-picker # TODO: add bind for this in hyprland
waypkgs.grim grim
waypkgs.slurp slurp
pkgs.swappy swappy
## libs ## libs
pkgs.libayatana-appindicator libayatana-appindicator
pkgs.xdg-utils xdg-utils
pkgs.evtest evtest
pkgs.glib glib
]; ];
} }

View file

@ -1,10 +1,9 @@
# Home-manager module # Home-manager module
{ nixpkgs-wayland, ... }: { { ... }: {
programs = { programs = {
wofi = { wofi = {
enable = true; enable = true;
package = nixpkgs-wayland.packages.x86_64-linux.wofi;
settings = { settings = {
prompt = ""; prompt = "";
allow_images = true; allow_images = true;