make vscode settings mutable, try to make gtk theme work on hyprland and
restart portals on login
This commit is contained in:
@@ -363,7 +363,7 @@ exec --no-startup-id sleep 5 && nvidia-settings -a "[gpu:0]/GPUGraphicsClockOffs
|
||||
#exec --no-startup-id sleep 7 && firefox https://github.com/endeavouros-team/endeavouros-i3wm-setup/blob/main/force-knowledge.md
|
||||
#exec --no-startup-id sleep 3 && thunar
|
||||
exec --no-startup-id i3-msg workspace $ws9; exec discord
|
||||
exec --no-startup-id i3-msg workspace $ws10; exec firefox
|
||||
exec --no-startup-id i3-msg workspace $ws10; exec floorp
|
||||
|
||||
###############
|
||||
# system tray #
|
||||
|
||||
@@ -1,5 +1,20 @@
|
||||
{ osConfig, config, pkgs, inputs, lib, ... }: {
|
||||
config = lib.mkIf osConfig.custom.graphical.code.enable {
|
||||
config = lib.mkIf osConfig.custom.graphical.code.enable rec {
|
||||
home.activation.makeVSCodeConfigWritable = let
|
||||
configDirName = {
|
||||
"vscode" = "Code";
|
||||
"vscode-insiders" = "Code - Insiders";
|
||||
"vscodium" = "VSCodium";
|
||||
}.${programs.vscode.package.pname};
|
||||
configPath =
|
||||
"${config.xdg.configHome}/${configDirName}/User/settings.json";
|
||||
in {
|
||||
after = [ "writeBoundary" ];
|
||||
before = [ ];
|
||||
data = ''
|
||||
install -m 0640 "$(readlink ${configPath})" ${configPath}
|
||||
'';
|
||||
};
|
||||
programs.vscode = {
|
||||
enable = true;
|
||||
package = pkgs.vscodium;
|
||||
@@ -10,6 +25,7 @@
|
||||
];
|
||||
"editor.mouseWheelZoom" = true;
|
||||
"files.autoSave" = "afterDelay";
|
||||
"clangd.path" = "/run/current-system/sw/bin/clangd";
|
||||
};
|
||||
extensions = with pkgs.vscode-extensions; [
|
||||
jnoortheen.nix-ide
|
||||
@@ -17,6 +33,8 @@
|
||||
myriad-dreamin.tinymist
|
||||
#tomoki1207.pdf latex-workshop is faster to preview pdf
|
||||
james-yu.latex-workshop
|
||||
twxs.cmake
|
||||
llvm-vs-code-extensions.vscode-clangd
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
@@ -3,6 +3,13 @@ let
|
||||
cfg = osConfig.custom.graphical.hyprland;
|
||||
isPc = osConfig.networking.hostName == "kop-pc";
|
||||
isLaptop = osConfig.networking.hostName == "nix-laptop";
|
||||
restartPortals = pkgs.writeShellScript "restart-portals" ''
|
||||
#!/usr/bin/env bash
|
||||
systemctl --user restart xdg-desktop-portal-gtk
|
||||
systemctl --user restart xdg-desktop-portal-hyprland
|
||||
sleep 4
|
||||
systemctl --user restart xdg-desktop-portal
|
||||
'';
|
||||
in {
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
||||
@@ -290,9 +297,10 @@ in {
|
||||
] ++ lib.lists.optionals (osConfig.networking.hostName == "kop-pc") [
|
||||
"[workspace 9 silent] discord"
|
||||
"[workspace 9 silent] discordcanary"
|
||||
"[workspace 10 silent] firefox"
|
||||
"[workspace 10 silent] floorp"
|
||||
] ++ [
|
||||
"sleep 3 && ${pkgs.waybar}/bin/waybar &"
|
||||
"${restartPortals}"
|
||||
];
|
||||
};
|
||||
extraConfig = let
|
||||
|
||||
@@ -8,7 +8,12 @@ in {
|
||||
hyprlock.enable = false;
|
||||
hyprland.enable = false;
|
||||
waybar.enable = false;
|
||||
gtk.flatpakSupport.enable = true; #edits ~/.themes/adw-gtk3
|
||||
};
|
||||
};
|
||||
|
||||
wayland.windowManager.hyprland.settings.env = lib.mkIf osConfig.custom.graphical.hyprland.enable [
|
||||
"GTK_THEME,adw-gtk3"
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -14,7 +14,8 @@ in {
|
||||
xkb.variant = config.mainUser.variant;
|
||||
enable = true;
|
||||
};
|
||||
services.displayManager.sddm.enable = !config.services.xserver.displayManager.gdm.enable;
|
||||
services.displayManager.sddm.enable =
|
||||
!config.services.xserver.displayManager.gdm.enable;
|
||||
|
||||
#nix.settings = {
|
||||
# substituters = [ "https://hyprland.cachix.org" ];
|
||||
@@ -24,7 +25,10 @@ in {
|
||||
#};
|
||||
|
||||
xdg.portal.enable = true;
|
||||
xdg.portal.extraPortals = lib.mkDefault [ pkgs.xdg-desktop-portal-gtk pkgs.xdg-desktop-portal-hyprland ];
|
||||
xdg.portal.extraPortals = lib.mkDefault [
|
||||
pkgs.xdg-desktop-portal-gtk
|
||||
pkgs.xdg-desktop-portal-hyprland
|
||||
];
|
||||
|
||||
programs.hyprland = { enable = true; };
|
||||
|
||||
@@ -46,8 +50,6 @@ in {
|
||||
#qt6.qmake
|
||||
#qt6.qtwayland
|
||||
#waybar
|
||||
#xdg-desktop-portal-hyprland
|
||||
#xdg-desktop-portal-gtk
|
||||
#xdg-utils
|
||||
#xwayland
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user