mass update

This commit is contained in:
Sense T 2023-06-26 06:18:07 +08:00
parent 683a772bc4
commit 8781b2d636
8 changed files with 217 additions and 109 deletions

101
flake.lock generated Normal file
View File

@ -0,0 +1,101 @@
{
"nodes": {
"flake-utils": {
"locked": {
"lastModified": 1638122382,
"narHash": "sha256-sQzZzAbvKEqN9s0bzWuYmRaA03v40gaJ4+iL1LXjaeI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "74f7e4319258e287b0f9cb95426c9853b282730b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1687647567,
"narHash": "sha256-Ua90LZYJO7/7KW/KK/AqijhIekd+wxPwbVKXuBYzJeQ=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "6ca1e16eb3016c94b7ac16699e1d4158bd4e39a4",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "release-23.05",
"repo": "home-manager",
"type": "github"
}
},
"impermanence": {
"locked": {
"lastModified": 1684264534,
"narHash": "sha256-K0zr+ry3FwIo3rN2U/VWAkCJSgBslBisvfRIPwMbuCQ=",
"owner": "nix-community",
"repo": "impermanence",
"rev": "89253fb1518063556edd5e54509c30ac3089d5e6",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "impermanence",
"type": "github"
}
},
"nixos-cn": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1682818384,
"narHash": "sha256-l8jh9BQj6nfjPDYGyrZkZwX1GaOqBX+pBHU+7fFZU3w=",
"owner": "nixos-cn",
"repo": "flakes",
"rev": "2d475ec68cca251ef6c6c69a9224db5c264c5e5b",
"type": "github"
},
"original": {
"owner": "nixos-cn",
"repo": "flakes",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1687555006,
"narHash": "sha256-GD2Kqb/DXQBRJcHqkM2qFZqbVenyO7Co/80JHRMg2U0=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "33223d479ffde3d05ac16c6dff04ae43cc27e577",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-23.05",
"type": "indirect"
}
},
"root": {
"inputs": {
"home-manager": "home-manager",
"impermanence": "impermanence",
"nixos-cn": "nixos-cn",
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}

View File

@ -25,13 +25,13 @@
inputs.nixpkgs.follows = "nixpkgs";
};
inputs.nixos-cn = {
nixos-cn = {
url = "github:nixos-cn/flakes";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = {self, nixpkgs, home-manager, nixos-cn,...}: {
outputs = {self, nixpkgs, home-manager, nixos-cn, impermanence, ...}: {
nixosConfigurations.gpd = nixpkgs.lib.nixosSystem rec {
system = "x86_64-linux";
@ -54,7 +54,7 @@
home-manager.nixosModules.home-manager {
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users = import ./per-user;
home-manager.users = import ./home;
}
];
};

View File

@ -2,7 +2,7 @@
xdg.portal = {
enable = true;
wlr.enable = true;
}
};
# Enable automatic login for the user.
services = {

View File

@ -1,8 +1,13 @@
{pkgs, ...}: {
home = import ./home.nix;
programs = import ./programs.nix;
services = import ./services.nix;
systemd.user.services = import ./systemd.nix;
imports = [
./home.nix
./programs.nix
./services.nix
];
systemd.user.services = {
# TODO: Podman
};
i18n.inputMethod.enabled = "fcitx5";
i18n.inputMethod.fcitx5.addons = with pkgs; [

View File

@ -1,44 +1,46 @@
{pkgs, ...}: {
stateVersion = "23.05"; # Static
username = "GPD User";
homeDirectory = "/home/user";
home = {
stateVersion = "23.05"; # Static
username = "GPD User";
homeDirectory = "/home/user";
packages = with pkgs; [
btop
bat
thefuck
ranger
icdiff
podman
jdk17
rofi
rofi-rbw
];
packages = with pkgs; [
btop
bat
thefuck
ranger
icdiff
podman
jdk17
rofi
rofi-rbw
];
sessionPath = {
".local/bin"
"Applications"
}
sessionPath = [
".local/bin"
"Applications"
];
shellAliases = {
cao = "fuck";
top = "btop";
ls = "ls --color=auto";
cat = "bat -p --paging=never -u";
diff="icdiff";
};
shellAliases = {
cao = "fuck";
top = "btop";
ls = "ls --color=auto";
cat = "bat -p --paging=never -u";
diff="icdiff";
};
file = {
# hyprland
".config/hypr/hyprland.conf".source = ./files/hyprland.conf;
file = {
# hyprland
".config/hypr/hyprland.conf".source = ./files/hyprland.conf;
# Use flatseal to change permissions.
".local/share/fonts".source = /run/current-system/sw/share/X11/fonts
# Use flatseal to change permissions.
".local/share/fonts".source = /run/current-system/sw/share/X11/fonts;
# Fix flatpak fonts
".local/share/flatpak/overrides/global".text = ''
[Context]
filesystems=~/.local/share/fonts:ro;~/.icons;
'';
# Fix flatpak fonts
".local/share/flatpak/overrides/global".text = ''
[Context]
filesystems=~/.local/share/fonts:ro;~/.icons;
'';
};
};
}

View File

@ -1,63 +1,65 @@
{pkgs, ...}: {
home-manager.enable = true;
programs = {
home-manager.enable = true;
vim = {
enable = true;
defaultEditor = true;
};
zsh = {
enable = true;
enableSyntaxHighlighting = true;
oh-my-zsh = {
vim = {
enable = true;
plugins = [ "sudo" "git" "golang" "thefuck" "kubectl" "emoji" "pip" "npm" "yarn" "vscode" ];
theme = "agnoster";
};
};
waybar = {
enable = true;
systemd.enable = true;
# see https://github.com/theCode-Breaker/riverwm/blob/main/waybar/river/config-river
# https://blog.cascade.moe/posts/hyprland-configure/
settings = {
mainBar = import ./config/waybar.nix;
defaultEditor = true;
};
style = import ./config/waybar-style.nix;
};
zsh = {
enable = true;
enableSyntaxHighlighting = true;
kitty = {
enable = true;
font = {
name = "Powerline";
size = 12;
oh-my-zsh = {
enable = true;
plugins = [ "sudo" "git" "golang" "thefuck" "kubectl" "emoji" "pip" "npm" "yarn" "vscode" ];
theme = "agnoster";
};
};
keybindings = {
"ctrl+c" = "copy_or_interrupt";
"ctrl+v" = "paste_from_clipboard";
waybar = {
enable = true;
systemd.enable = true;
# see https://github.com/theCode-Breaker/riverwm/blob/main/waybar/river/config-river
# https://blog.cascade.moe/posts/hyprland-configure/
settings = {
mainBar = import ./config/waybar.nix;
};
style = import ./config/waybar-style.nix;
};
shellIntegration = {
enableZshIntegration = true;
enableBashIntegration = true;
kitty = {
enable = true;
font = {
name = "Powerline";
size = 12;
};
keybindings = {
"ctrl+c" = "copy_or_interrupt";
"ctrl+v" = "paste_from_clipboard";
};
shellIntegration = {
enableZshIntegration = true;
enableBashIntegration = true;
};
settings = {
background_opacity = 0.8;
};
};
settings = {
background_opacity = 0.8;
};
};
rbw = {
enable = true;
settings = {
base_url = "https://pass.sense-t.eu.org";
email = "sense-t@sense-t.eu.org";
lock_timeout = 300;
pinentry = "gnome3";
rbw = {
enable = true;
settings = {
base_url = "https://pass.sense-t.eu.org";
email = "sense-t@sense-t.eu.org";
lock_timeout = 300;
pinentry = "gnome3";
};
};
};
}

View File

@ -1,19 +1,21 @@
{
dunst = {
enable = true;
settings = {
global = {
width = 300;
height = 300;
offset = "30x50";
origin = "top-right";
notification_limit = 10;
progress_bar = true;
transparency = 20;
corner_radius = 8;
services = {
dunst = {
enable = true;
settings = {
global = {
width = 300;
height = 300;
offset = "30x50";
origin = "top-right";
notification_limit = 10;
progress_bar = true;
transparency = 20;
corner_radius = 8;
};
};
};
};
network-manager-applet.enable = true;
network-manager-applet.enable = true;
};
}

View File

@ -1,4 +0,0 @@
# Will used for podman
{
}