diff --git a/flake.lock b/flake.lock index 290373d8..189f5679 100644 --- a/flake.lock +++ b/flake.lock @@ -38,6 +38,21 @@ } }, "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" + } + }, + "flake-utils_2": { "inputs": { "systems": "systems" }, @@ -119,7 +134,7 @@ }, "lib-aggregate": { "inputs": { - "flake-utils": "flake-utils", + "flake-utils": "flake-utils_2", "nixpkgs-lib": "nixpkgs-lib" }, "locked": { @@ -155,6 +170,27 @@ "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": 1683014792, @@ -259,6 +295,7 @@ "inputs": { "home-manager": "home-manager", "hyprland": "hyprland", + "nixos-cn": "nixos-cn", "nixpkgs": "nixpkgs_2", "nixpkgs-wayland": "nixpkgs-wayland" } diff --git a/flake.nix b/flake.nix index fb137159..adfa7d0c 100644 --- a/flake.nix +++ b/flake.nix @@ -46,7 +46,7 @@ nixpkgs-wayland = { url = "github:nix-community/nixpkgs-wayland"; }; # nixos-cn 提供了一些国内常用的程序包,如 qq wechat dingtalk 等 - inputs.nixos-cn = { + nixos-cn = { url = "github:nixos-cn/flakes"; # 强制 nixos-cn 和该 flake 使用相同版本的 nixpkgs inputs.nixpkgs.follows = "nixpkgs"; @@ -60,6 +60,7 @@ self, nixpkgs, home-manager, + nixos-cn, ... }: { # 名为 nixosConfigurations 的 outputs 会在执行 `nixos-rebuild switch --flake .` 时被使用 diff --git a/home/programs/browsers.nix b/home/programs/browsers.nix index 89205d68..6166bd2b 100644 --- a/home/programs/browsers.nix +++ b/home/programs/browsers.nix @@ -8,7 +8,7 @@ firefox-wayland ]; - programs = { + programs = let commandLineArgs = [ "--enable-wayland-ime" "--ozone-platform=wayland" ]; in { chromium = { @@ -20,5 +20,4 @@ inherit commandLineArgs; }; }; - }; -} \ No newline at end of file +} diff --git a/home/programs/common.nix b/home/programs/common.nix index c589f05f..b22f5daf 100644 --- a/home/programs/common.nix +++ b/home/programs/common.nix @@ -120,7 +120,6 @@ jq.enable = true; # A lightweight and flexible command-line JSON processor ssh.enable = true; aria2.enable = true; - adb.enable = true; skim = { enable = true; @@ -144,4 +143,4 @@ # auto mount usb drives udiskie.enable = true; }; -} \ No newline at end of file +} diff --git a/home/programs/xdg.nix b/home/programs/xdg.nix index e009f85b..e9962228 100644 --- a/home/programs/xdg.nix +++ b/home/programs/xdg.nix @@ -1,4 +1,4 @@ -{config, ...}: let +{config, pkgs, ...}: let browser = ["firefox.desktop"]; # XDG MIME types @@ -44,14 +44,5 @@ in { }; }; - # https://github.com/flatpak/xdg-desktop-portal - # enable wayland wlroots support - portal = { - enable = true; - extraPortals = with pkgs; [ - xdg-desktop-portal-wlr - xdg-desktop-portal-gtk - ]; - }; }; -} \ No newline at end of file +}