Skip to content

Commit

Permalink
Fixed bug in Updates script
Browse files Browse the repository at this point in the history
Added xorgScale.nix file that will set scaling in xorg if the
xrandrScale option is set in a options.nix file

gnome-keyring should work properly now when we login (from sddm)
  • Loading branch information
jwyuen committed May 27, 2024
1 parent 51492b7 commit f2c8653
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 12 deletions.
2 changes: 1 addition & 1 deletion dots/.config/bspwm/scripts/Updates
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Script to check for new updates in NixOS

HOST=$(hostname -s)
PROJECT_DIR=~/jwy-gh0stzk-dots
PROJECT_DIR=~/jwy-gh0stzk-dotfiles

get_total_updates() {
#nhstring="Closure size: 2048 -> 2048 (0 paths added, 0 paths removed, delta +0, disk usage +0B)."
Expand Down
3 changes: 3 additions & 0 deletions nix-config/hosts/nix-lappy/options.nix
Original file line number Diff line number Diff line change
Expand Up @@ -76,4 +76,7 @@ in {
# Enable SyncThing
syncthing = true;

# Xorg scaling
xrandrScale = "0.8x0.8";

}
1 change: 1 addition & 0 deletions nix-config/system/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,6 @@
./services.nix
./syncthing.nix
./vm.nix
./xorgScale.nix
];
}
18 changes: 9 additions & 9 deletions nix-config/system/displaymanager.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ pkgs, config, host, ... }:
{ lib, pkgs, config, host, ... }:

let inherit (import ../hosts/${host}/options.nix) theKBDVariant
theKBDLayout theSecondKBDLayout; in
Expand All @@ -25,12 +25,12 @@ theKBDLayout theSecondKBDLayout; in
# _JAVA_OPTIONS = "-Dsun.java2d.uiScale=1.2";
# };
environment.systemPackages =
let
sugar = pkgs.callPackage ../pkgs/sddm-sugar-dark.nix {};
tokyo-night = pkgs.libsForQt5.callPackage ../pkgs/sddm-tokyo-night.nix {};
in [
sugar.sddm-sugar-dark # Name: sugar-dark
tokyo-night # Name: tokyo-night-sddm
pkgs.libsForQt5.qt5.qtgraphicaleffects
];
let
sugar = pkgs.callPackage ../pkgs/sddm-sugar-dark.nix {};
tokyo-night = pkgs.libsForQt5.callPackage ../pkgs/sddm-tokyo-night.nix {};
in [
sugar.sddm-sugar-dark # Name: sugar-dark
tokyo-night # Name: tokyo-night-sddm
pkgs.libsForQt5.qt5.qtgraphicaleffects
];
}
6 changes: 4 additions & 2 deletions nix-config/system/services.nix
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,13 @@
programs.thunar.enable = true;
services.gvfs.enable = true;
services.tumbler.enable = true;
services.gnome.gnome-keyring.enable=true;
hardware.bluetooth.enable = true; # enables support for Bluetooth
hardware.bluetooth.powerOnBoot = false; # powers up the default Bluetooth controller on boot
services.blueman.enable = true;
#security.pam.services.swaylock = {

services.gnome.gnome-keyring.enable=true;
security.pam.services.sddm.enableGnomeKeyring = true;
#security.pam.services.login.enableGnomeKeyring = true;
security.pam.services.betterlockscreen = {

text = ''
Expand Down
8 changes: 8 additions & 0 deletions nix-config/system/xorgScale.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{ config, lib, host, ... }:

let inherit (import ../hosts/${host}/options.nix) xrandrScale; in
lib.mkIf ("${xrandrScale}" != null && "${host}" == "nix-lappy") {
services.xserver.displayManager.sessionCommands = ''
xrandr --output eDP-1 --scale ${xrandrScale} --mode 2880x1800
'';
}

0 comments on commit f2c8653

Please sign in to comment.