updates, and maybe working discord

This commit is contained in:
Noa Aarts 2024-02-29 16:08:27 +01:00
parent afd8319ac7
commit c87350f6a7
5 changed files with 146 additions and 102 deletions

18
flake.lock generated
View file

@ -98,11 +98,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1708988456, "lastModified": 1709204054,
"narHash": "sha256-RCz7Xe64tN2zgWk+MVHkzg224znwqknJ1RnB7rVqUWw=", "narHash": "sha256-U1idK0JHs1XOfSI1APYuXi4AEADf+B+ZU4Wifc0pBHk=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "1d085ea4444d26aa52297758b333b449b2aa6fca", "rev": "2f3367769a93b226c467551315e9e270c3f78b15",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -155,11 +155,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1708984720, "lastModified": 1709150264,
"narHash": "sha256-gJctErLbXx4QZBBbGp78PxtOOzsDaQ+yw1ylNQBuSUY=", "narHash": "sha256-HofykKuisObPUfj0E9CJVfaMhawXkYx3G8UIFR/XQ38=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "13aff9b34cc32e59d35c62ac9356e4a41198a538", "rev": "9099616b93301d5cf84274b184a3a5ec69e94e08",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -181,11 +181,11 @@
"pre-commit-hooks": "pre-commit-hooks" "pre-commit-hooks": "pre-commit-hooks"
}, },
"locked": { "locked": {
"lastModified": 1709118025, "lastModified": 1709155917,
"narHash": "sha256-IwzgIAKHJI+qcno0pExTOfhqKgHzA5vc++gfgJ0ZCok=", "narHash": "sha256-S4yHqDKFmJpFQExP7bkOSw+RQaSr8pdOrfSFCOv3G70=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixvim", "repo": "nixvim",
"rev": "8bb460e261dd0fd8ac3f544f8a2a28ad64616cbe", "rev": "be87309e0c1da19d99d969625300aaed36ff1b91",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -1,55 +1,55 @@
# Edit this configuration file to define what should be installed on # Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page # your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help). # and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, inputs, ... }: { config, pkgs, inputs, ... }:
{ {
imports = imports =
[ # Include the results of the hardware scan. [ # Include the results of the hardware scan.
./hardware-configuration.nix ./hardware-configuration.nix
./nvidia.nix ./nvidia.nix
inputs.home-manager.nixosModules.default inputs.home-manager.nixosModules.default
]; ];
# Bootloader. # Bootloader.
boot.loader.systemd-boot.enable = true; boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true; boot.loader.efi.canTouchEfiVariables = true;
networking.hostName = "lambdaOS"; # Define your hostname. networking.hostName = "lambdaOS"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
# Configure network proxy if necessary # Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/"; # networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking # Enable networking
networking.networkmanager.enable = true; networking.networkmanager.enable = true;
nix.settings = { nix.settings = {
# auto optimise every so often # auto optimise every so often
auto-optimise-store = true; auto-optimise-store = true;
experimental-features = ["nix-command" "flakes"]; experimental-features = ["nix-command" "flakes"];
}; };
# Set your time zone. # Set your time zone.
time.timeZone = "Europe/Amsterdam"; time.timeZone = "Europe/Amsterdam";
# Select internationalisation properties. # Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8"; i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = { i18n.extraLocaleSettings = {
LC_ADDRESS = "nl_NL.UTF-8"; LC_ADDRESS = "nl_NL.UTF-8";
LC_IDENTIFICATION = "nl_NL.UTF-8"; LC_IDENTIFICATION = "nl_NL.UTF-8";
LC_MEASUREMENT = "nl_NL.UTF-8"; LC_MEASUREMENT = "nl_NL.UTF-8";
LC_MONETARY = "nl_NL.UTF-8"; LC_MONETARY = "nl_NL.UTF-8";
LC_NAME = "nl_NL.UTF-8"; LC_NAME = "nl_NL.UTF-8";
LC_NUMERIC = "nl_NL.UTF-8"; LC_NUMERIC = "nl_NL.UTF-8";
LC_PAPER = "nl_NL.UTF-8"; LC_PAPER = "nl_NL.UTF-8";
LC_TELEPHONE = "nl_NL.UTF-8"; LC_TELEPHONE = "nl_NL.UTF-8";
LC_TIME = "nl_NL.UTF-8"; LC_TIME = "nl_NL.UTF-8";
}; };
services.xserver = { services.xserver = {
enable = true; enable = true;
displayManager = { displayManager = {
sddm.enable = true; sddm.enable = true;
@ -59,41 +59,41 @@
layout = "us"; layout = "us";
variant = "intl"; variant = "intl";
}; };
}; };
# Configure console keymap # Configure console keymap
console.keyMap = "us-acentos"; console.keyMap = "us-acentos";
users.groups.nixpow.members = [ "root" ]; users.groups.nixpow.members = [ "root" ];
# Define a user account. Don't forget to set a password with passwd. # Define a user account. Don't forget to set a password with passwd.
users.users.noa = { users.users.noa = {
isNormalUser = true; isNormalUser = true;
description = "Noa Aarts"; description = "Noa Aarts";
extraGroups = [ "networkmanager" "wheel" "nixpow" ]; extraGroups = [ "networkmanager" "wheel" "nixpow" ];
packages = with pkgs; [ packages = with pkgs; [
]; ];
}; };
home-manager = { home-manager = {
extraSpecialArgs = { inherit inputs; }; extraSpecialArgs = { inherit inputs; };
users = { users = {
"noa" = import ./home.nix; "noa" = import ./home.nix;
"root" = import ./root.nix; "root" = import ./root.nix;
}; };
}; };
# Allow unfree packages # Allow unfree packages
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run: # List packages installed in system profile. To search, run:
# $ nix search wget # $ nix search wget
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
neovim neovim
sddm sddm
git git
zsh zsh
]; ];
# TODO find list of fonts to install # TODO find list of fonts to install
fonts.packages = with pkgs; [ fonts.packages = with pkgs; [
@ -104,49 +104,49 @@
liberation_ttf liberation_ttf
]; ];
# Some programs need SUID wrappers, can be configured further or are # Some programs need SUID wrappers, can be configured further or are
# started in user sessions. # started in user sessions.
# programs.mtr.enable = true; # programs.mtr.enable = true;
# programs.gnupg.agent = { # programs.gnupg.agent = {
# enable = true; # enable = true;
# enableSSHSupport = true; # enableSSHSupport = true;
# }; # };
programs.neovim.enable = true; programs.neovim.enable = true;
programs.neovim.defaultEditor = true; programs.neovim.defaultEditor = true;
programs.zsh.enable = true; programs.zsh.enable = true;
programs.hyprland.enable = true; programs.hyprland.enable = true;
users.defaultUserShell = pkgs.zsh; users.defaultUserShell = pkgs.zsh;
security.rtkit.enable = true; security.rtkit.enable = true;
services.pipewire = { services.pipewire = {
enable = true; enable = true;
alsa.enable = true; alsa.enable = true;
alsa.support32Bit = true; alsa.support32Bit = true;
pulse.enable = true; pulse.enable = true;
jack.enable = true; jack.enable = true;
}; };
# List services that you want to enable: # List services that you want to enable:
# Enable the OpenSSH daemon. # Enable the OpenSSH daemon.
# services.openssh.enable = true; # services.openssh.enable = true;
# Open ports in the firewall. # Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ]; # networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ]; # networking.firewall.allowedUDPPorts = [ ... ];
# Or disable the firewall altogether. # Or disable the firewall altogether.
# networking.firewall.enable = false; # networking.firewall.enable = false;
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system. # this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option # Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "23.11"; # Did you read the comment? system.stateVersion = "23.11"; # Did you read the comment?
} }

View file

@ -0,0 +1,24 @@
self:
let
enableWayland = drv: bin: drv.overrideAttrs (
old: {
nativeBuildInputs = (old.nativeBuildInputs or []) ++ [ self.makeWrapper ];
postFixup = (old.postFixup or "") + ''
wrapProgram $out/bin/${bin} \
--add-flags "--enable-features=UseOzonePlatform" \
--add-flags "--ozone-platform=wayland"
'';
}
);
in
super:
{
slack = enableWayland super.slack "slack";
discord = enableWayland super.discord "discord";
vscode = enableWayland super.vscode "code";
google-chrome-beta = (
super.google-chrome-beta.override {
commandLineArgs = "--enable-features=UseOzonePlatform --ozone-platform=wayland";
}
);
}

View file

@ -21,6 +21,10 @@
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;
nixpkgs.overlays = [
(import ./electron-wayland.nix)
];
# The home.packages option allows you to install Nix packages into your # The home.packages option allows you to install Nix packages into your
# environment. # environment.
home.packages = with pkgs; [ home.packages = with pkgs; [
@ -32,18 +36,22 @@
mtr mtr
firefox firefox
(writeShellScriptBin "spotify" '' # (writeShellScriptBin "spotify" ''
exec ${pkgs.spotify}/bin/spotify --enable-features=UseOzonePlatform --ozone-platform=wayland # exec ${pkgs.spotify}/bin/spotify --enable-features=UseOzonePlatform --ozone-platform=wayland
'') # '')
spotify
hyprland hyprland
dunst dunst
waybar waybar
wl-clipboard wl-clipboard
(writeShellScriptBin "discord" '' dconf
exec ${discord}/bin/discord --enable-features=UseOzonePlatform --ozone-platform=wayland
'') # (writeShellScriptBin "discord" ''
# exec ${discord}/bin/discord --enable-features=UseOzonePlatform --ozone-platform=wayland
# '')
discord
kitty kitty
pipewire pipewire
lsd lsd
@ -124,6 +132,15 @@
xdg.userDirs.enable = true; xdg.userDirs.enable = true;
xdg.userDirs.createDirectories = true; xdg.userDirs.createDirectories = true;
dconf = {
enable = true;
settings = {
"org/gnome/desktop/interface" = {
color-scheme = "prefer-dark";
};
};
};
# Let Home Manager install and manage itself. # Let Home Manager install and manage itself.
programs.home-manager.enable = true; programs.home-manager.enable = true;
@ -142,7 +159,7 @@
#window { #window {
margin: 10px; margin: 10px;
border: none; border: none;
background-color: transparent; background-color: #530035;
border-radius: 10px; border-radius: 10px;
font-family: font-family:
JetBrains Mono NF, JetBrains Mono NF,

3
update.sh Executable file
View file

@ -0,0 +1,3 @@
#!/bin/sh
echo "hewwo"