上传文件至「/」
This commit is contained in:
+10
-4
@@ -54,13 +54,18 @@
|
|||||||
type = "fcitx5";
|
type = "fcitx5";
|
||||||
fcitx5.waylandFrontend = true;
|
fcitx5.waylandFrontend = true;
|
||||||
fcitx5.addons = with pkgs; [
|
fcitx5.addons = with pkgs; [
|
||||||
# 拼音输入 + KDE/Qt 集成
|
fcitx5-rime
|
||||||
qt6Packages.fcitx5-chinese-addons
|
|
||||||
fcitx5-gtk
|
fcitx5-gtk
|
||||||
kdePackages.fcitx5-qt
|
kdePackages.fcitx5-qt
|
||||||
kdePackages.fcitx5-configtool
|
kdePackages.fcitx5-configtool
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
environment.sessionVariables = {
|
||||||
|
GTK_IM_MODULE = "fcitx";
|
||||||
|
QT_IM_MODULE = "fcitx";
|
||||||
|
XMODIFIERS = "@im=fcitx";
|
||||||
|
NIXOS_OZONE_WL = "1";
|
||||||
|
};
|
||||||
|
|
||||||
# ── 桌面环境 (KDE Plasma 6 / Wayland) ───────────────────────
|
# ── 桌面环境 (KDE Plasma 6 / Wayland) ───────────────────────
|
||||||
services.xserver.enable = true;
|
services.xserver.enable = true;
|
||||||
@@ -114,9 +119,9 @@
|
|||||||
services.flatpak.enable = true;
|
services.flatpak.enable = true;
|
||||||
|
|
||||||
# ── 用户 ────────────────────────────────────────────────────
|
# ── 用户 ────────────────────────────────────────────────────
|
||||||
users.users.test = {
|
users.users.luodh = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
description = "test";
|
description = "luodh";
|
||||||
shell = pkgs.fish;
|
shell = pkgs.fish;
|
||||||
extraGroups = [ "networkmanager" "wheel" ];
|
extraGroups = [ "networkmanager" "wheel" ];
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
@@ -142,6 +147,7 @@
|
|||||||
zip
|
zip
|
||||||
unzip
|
unzip
|
||||||
ffmpeg
|
ffmpeg
|
||||||
|
librime
|
||||||
];
|
];
|
||||||
|
|
||||||
# ── 系统状态版本(请勿修改) ────────────────────────────────
|
# ── 系统状态版本(请勿修改) ────────────────────────────────
|
||||||
|
|||||||
@@ -39,7 +39,7 @@
|
|||||||
home-manager.sharedModules = [ plasma-manager.homeModules.plasma-manager ];
|
home-manager.sharedModules = [ plasma-manager.homeModules.plasma-manager ];
|
||||||
|
|
||||||
# ⚠️ 极其重要:把这里的 "luodh" 替换成你在 NixOS 里登录的实际系统用户名
|
# ⚠️ 极其重要:把这里的 "luodh" 替换成你在 NixOS 里登录的实际系统用户名
|
||||||
home-manager.users.test = import ./home.nix;
|
home-manager.users.luodh = import ./home.nix;
|
||||||
}
|
}
|
||||||
|
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -4,20 +4,29 @@
|
|||||||
{ config, lib, pkgs, modulesPath, ... }:
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [ ];
|
imports =
|
||||||
|
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||||
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "ata_piix" "ohci_pci" "ehci_pci" "ahci" "sd_mod" "sr_mod" ];
|
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "usbhid" "usb_storage" "sd_mod" ];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [ ];
|
||||||
boot.kernelModules = [ ];
|
boot.kernelModules = [ "kvm-amd" ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
fileSystems."/" =
|
fileSystems."/" =
|
||||||
{ device = "/dev/disk/by-uuid/a4dec1b6-8027-46c5-b143-0fc9ea1e2ef7";
|
{ device = "/dev/disk/by-uuid/b818ea33-5c41-4eeb-b7b9-7e1e3397964f";
|
||||||
fsType = "ext4";
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=@" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/home" =
|
||||||
|
{ device = "/dev/disk/by-uuid/b818ea33-5c41-4eeb-b7b9-7e1e3397964f";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=@home" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" =
|
fileSystems."/boot" =
|
||||||
{ device = "/dev/disk/by-uuid/0115-3C19";
|
{ device = "/dev/disk/by-uuid/BF34-E3A0";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
options = [ "fmask=0077" "dmask=0077" ];
|
options = [ "fmask=0077" "dmask=0077" ];
|
||||||
};
|
};
|
||||||
@@ -25,5 +34,5 @@
|
|||||||
swapDevices = [ ];
|
swapDevices = [ ];
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
virtualisation.virtualbox.guest.enable = true;
|
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,8 +2,8 @@
|
|||||||
|
|
||||||
{
|
{
|
||||||
# ⚠️ 极其重要:替换成你的实际系统用户名
|
# ⚠️ 极其重要:替换成你的实际系统用户名
|
||||||
home.username = "test";
|
home.username = "luodh";
|
||||||
home.homeDirectory = "/home/test";
|
home.homeDirectory = "/home/luodh";
|
||||||
|
|
||||||
# 你的个人日常软件全写在这里!
|
# 你的个人日常软件全写在这里!
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
@@ -29,25 +29,51 @@
|
|||||||
nodejs
|
nodejs
|
||||||
pnpm
|
pnpm
|
||||||
kdePackages.kate
|
kdePackages.kate
|
||||||
|
rime-ice
|
||||||
|
wemeet
|
||||||
];
|
];
|
||||||
|
|
||||||
# 用 Home Manager 固定 Fcitx5 输入法配置,仅保留拼音
|
# Rime 输入法配置(雾凇拼音)
|
||||||
home.file.".config/fcitx5/profile".text = ''
|
home.file.".local/share/fcitx5/rime/default.custom.yaml".text = ''
|
||||||
[Groups/0]
|
patch:
|
||||||
Name=Default
|
schema_list:
|
||||||
Default Layout=us
|
- schema: rime_ice
|
||||||
DefaultIM=pinyin
|
menu/page_size: 7
|
||||||
|
'';
|
||||||
|
|
||||||
[Groups/0/Items/0]
|
xdg.configFile."fcitx5/profile" = {
|
||||||
Name=keyboard-us
|
force = true;
|
||||||
Layout=
|
text = ''
|
||||||
|
[Groups/0]
|
||||||
|
Name=Default
|
||||||
|
Default Layout=us
|
||||||
|
DefaultIM=keyboard-us
|
||||||
|
|
||||||
[Groups/0/Items/1]
|
[Groups/0/Items/0]
|
||||||
Name=pinyin
|
Name=keyboard-us
|
||||||
Layout=
|
Layout=
|
||||||
|
|
||||||
[GroupOrder]
|
[Groups/0/Items/1]
|
||||||
0=Default
|
Name=rime
|
||||||
|
Layout=
|
||||||
|
|
||||||
|
[GroupOrder]
|
||||||
|
0=Default
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
home.activation.setupRimeIce = config.lib.dag.entryAfter ["writeBoundary"] ''
|
||||||
|
RIME_DIR="$HOME/.local/share/fcitx5/rime"
|
||||||
|
mkdir -p "$RIME_DIR"
|
||||||
|
for item in ${pkgs.rime-data}/share/rime-data/*; do
|
||||||
|
name=$(basename "$item")
|
||||||
|
[ -e "$RIME_DIR/$name" ] || ln -sf "$item" "$RIME_DIR"
|
||||||
|
done
|
||||||
|
for item in ${pkgs.rime-ice}/share/rime-data/*; do
|
||||||
|
name=$(basename "$item")
|
||||||
|
[ -e "$RIME_DIR/$name" ] && rm -rf "$RIME_DIR/$name"
|
||||||
|
ln -sf "$item" "$RIME_DIR"
|
||||||
|
done
|
||||||
'';
|
'';
|
||||||
|
|
||||||
home.sessionPath = [
|
home.sessionPath = [
|
||||||
@@ -88,10 +114,6 @@
|
|||||||
"XLbInptAccelProfileFlat" = true; # 平坦加速曲线
|
"XLbInptAccelProfileFlat" = true; # 平坦加速曲线
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# 虚拟键盘 / 输入法设置为 fcitx5
|
|
||||||
configFile."kwinrc"."Wayland"."InputMethod" =
|
|
||||||
"${pkgs.fcitx5}/share/applications/org.fcitx.Fcitx5.desktop";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
# 这个版本号不要改!它不是软件版本,而是系统状态标识
|
# 这个版本号不要改!它不是软件版本,而是系统状态标识
|
||||||
|
|||||||
Reference in New Issue
Block a user