remove fcitx and satellite systemd service

This commit is contained in:
ulic-youthlic 2025-05-10 01:10:25 +08:00
parent 5b145e5b83
commit e488d6ee4b
Signed by: youthlic
GPG key ID: 63E86C3C14A0D721
5 changed files with 8 additions and 85 deletions

View file

@ -3,7 +3,5 @@
./openssh.nix
./niri
./wluma
./xwayland-satellite.nix
./fcitx5-reload.nix
];
}

View file

@ -1,33 +0,0 @@
{
lib,
config,
pkgs,
osConfig ? null,
...
}: let
cfg = config.david.programs.fcitx5-reload;
fcitx5 = lib.getExe' osConfig.i18n.inputMethod.package "fcitx5";
in {
options = {
david.programs.fcitx5-reload = {
enable = lib.mkEnableOption "fcitx5-reload";
};
};
config = lib.mkIf cfg.enable {
systemd.user.services = {
"fcitx5-reload" = {
Install = {
WantedBy = ["graphical-session.target"];
};
Unit = {
PartOf = ["graphical-session.target"];
After = ["graphical-session.target"];
};
Service = {
ExecStart = "${fcitx5} --replace";
Restart = "on-failure";
};
};
};
};
}

View file

@ -3,6 +3,7 @@
pkgs,
lib,
inputs,
osConfig ? null,
DISPLAY,
...
}: let
@ -26,11 +27,14 @@
plain
;
bash = getExe config.programs.bash.package;
sh = getExe' config.programs.bash.package "sh";
swaylock = getExe config.programs.swaylock.package;
fuzzel = getExe config.programs.fuzzel.package;
waybar = getExe config.programs.waybar.package;
swaync = getExe config.services.swaync.package;
fcitx5 = lib.getExe' osConfig.i18n.inputMethod.package "fcitx5";
xwayland-satellite = lib.getExe pkgs.xwayland-satellite;
sleep = lib.getExe' pkgs.coreutils "sleep";
polkit-kde-agent = getExe' pkgs.kdePackages.polkit-kde-agent-1 "polkit-kde-agent";
wpctl = getExe' pkgs.wireplumber "wpctl";
@ -46,7 +50,7 @@ in
in [
(plain "binds" [
(plain "Mod+V" [
(spawn [bash "-c" "${cliphist} list | ${fuzzel} --dmenu | ${cliphist} decode | ${wl-copy}"])
(spawn [sh "-c" "${cliphist} list | ${fuzzel} --dmenu | ${cliphist} decode | ${wl-copy}"])
])
(plain "Mod+Shift+P" [
(spawn [swaylock "--screenshots" "--clock" "--indicator" "--indicator-radius" "100" "--indicator-thickness" "7" "--effect-blur" "7x5" "--effect-vignette" "0.5:0.5" "--grace" "2" "--fade-in" "0.5"])
@ -388,6 +392,8 @@ in
(spawn-at-startup [swaybg "-i" "${config.home.homeDirectory}/wallpaper/01.png"])
(spawn-at-startup [polkit-kde-agent])
(spawn-at-startup [wl-paste "--watch" cliphist "store"])
(spawn-at-startup [xwayland-satellite "${DISPLAY}"])
(spawn-at-startup [sh "-c" "${sleep} 10; ${fcitx5} --replace"])
(plain "input" [
(plain "touchpad" [
(leaf "click-method" "clickfinger")

View file

@ -27,19 +27,6 @@ in {
home.sessionVariables = {
inherit (cfg) DISPLAY;
};
david.programs = {
xwayland-satellite = {
inherit (cfg) DISPLAY;
enable = true;
};
fcitx5-reload = {
enable = true;
};
};
systemd.user.services = {
"fcitx5-reload".Unit.After = ["xwayland-satellite.service"];
"xwayland-satellite".Unit.Before = ["fcitx5-reload.service"];
};
youthlic.programs.niri = {
# settings = lib.mkMerge [(import ./settings.nix args) cfg.settings];
config =

View file

@ -1,35 +0,0 @@
{
lib,
config,
pkgs,
...
}: let
cfg = config.david.programs.xwayland-satellite;
in {
options = {
david.programs.xwayland-satellite = {
enable = lib.mkEnableOption "xwayland-satellite";
DISPLAY = lib.mkOption {
type = lib.types.str;
example = ":1";
};
};
};
config = lib.mkIf cfg.enable {
systemd.user = {
services."xwayland-satellite" = {
Install = {
WantedBy = ["graphical-session.target"];
};
Unit = {
PartOf = ["graphical-session.target"];
After = ["graphical-session.target"];
};
Service = {
ExecStart = "${lib.getExe pkgs.xwayland-satellite} ${cfg.DISPLAY}";
Restart = "on-failure";
};
};
};
};
}