flake: bump

This commit is contained in:
Guanran Wang 2024-11-07 11:31:03 +08:00
parent 1d0f2f9ccb
commit 7279a85e3a
Signed by: nyancat
GPG key ID: 91F97D9ED12639CF
5 changed files with 84 additions and 106 deletions

View file

@ -31,11 +31,11 @@
}, },
"crane": { "crane": {
"locked": { "locked": {
"lastModified": 1729741221, "lastModified": 1730652660,
"narHash": "sha256-8AHZZXs1lFkERfBY0C8cZGElSo33D/et7NKEpLRmvzo=", "narHash": "sha256-+XVYfmVXAiYA0FZT7ijHf555dxCe+AoAT5A6RU+6vSo=",
"owner": "ipetkov", "owner": "ipetkov",
"repo": "crane", "repo": "crane",
"rev": "f235b656ee5b2bfd6d94c3bfd67896a575d4a6ed", "rev": "a4ca93905455c07cb7e3aca95d4faf7601cba458",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -51,11 +51,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1729942962, "lastModified": 1730751873,
"narHash": "sha256-xzt7tb4YUw6VZXSCGw4sukirJSfYsIcFyvmhK5KMiKw=", "narHash": "sha256-sdY29RWz0S7VbaoTwSy6RummdHKf0wUTaBlqPxrtvmQ=",
"owner": "nix-community", "owner": "nix-community",
"repo": "disko", "repo": "disko",
"rev": "58cd832497f9c87cb4889744b86aba4284fd0474", "rev": "856a2902156ba304efebd4c1096dbf7465569454",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -86,11 +86,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1727826117, "lastModified": 1730504689,
"narHash": "sha256-K5ZLCyfO/Zj9mPFldf3iwS6oZStJcU4tSpiXTMYaaL0=", "narHash": "sha256-hgmguH29K2fvs9szpq2r3pz2/8cJd2LPS+b4tfNFCwE=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "3d04084d54bedc3d6b8b736c70ef449225c361b1", "rev": "506278e768c2a08bec68eb62932193e341f55c90",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -146,11 +146,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1729894599, "lastModified": 1730837930,
"narHash": "sha256-nL9nzNE5/re/P+zOv7NX6bRm5e+DeS1HIufQUJ01w20=", "narHash": "sha256-0kZL4m+bKBJUBQse0HanewWO0g8hDdCvBhudzxgehqc=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "93435d27d250fa986bfec6b2ff263161ff8288cb", "rev": "2f607e07f3ac7e53541120536708e824acccfaa8",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -175,11 +175,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1730003334, "lastModified": 1730536459,
"narHash": "sha256-Mw2hyY6wOKwLAWLb+IdnKOzL8bcixwkJ1qB/qAz5tzM=", "narHash": "sha256-kb3EZS4EndrmRVON/mEV4LvfW9k0b09gRc2JqUCKBdM=",
"rev": "ebbd49cce5f4bbcd887c3a95d29f7f2bc703c2d3", "rev": "1446585272acf9aa15cee990054663738c6c3417",
"type": "tarball", "type": "tarball",
"url": "https://git.ny4.dev/api/v1/repos/nyancat/ip-checker/archive/ebbd49cce5f4bbcd887c3a95d29f7f2bc703c2d3.tar.gz" "url": "https://git.ny4.dev/api/v1/repos/nyancat/ip-checker/archive/1446585272acf9aa15cee990054663738c6c3417.tar.gz"
}, },
"original": { "original": {
"type": "tarball", "type": "tarball",
@ -208,11 +208,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1729064530, "lastModified": 1730739295,
"narHash": "sha256-oSr/w/5dvf/8ll6NvQlL7+rrK8wzjIcEMP1LvI4Ag08=", "narHash": "sha256-aYeJ/P/9AuK6Kee63ZdsmDjEwhnksF+gIv/OyGtlBJE=",
"owner": "nix-community", "owner": "nix-community",
"repo": "lanzaboote", "repo": "lanzaboote",
"rev": "2fa1368f938b50e35ca87334b5aeba38a3402165", "rev": "cef39a78679c266300874e7a7000b4da066228d4",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -237,11 +237,11 @@
}, },
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1729742320, "lastModified": 1730919458,
"narHash": "sha256-u3Of8xRkN//me8PU+RucKA59/6RNy4B2jcGAF36P4jI=", "narHash": "sha256-yMO0T0QJlmT/x4HEyvrCyigGrdYfIXX3e5gWqB64wLg=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "e8a2f6d5513fe7b7d15701b2d05404ffdc3b6dda", "rev": "e1cc1f6483393634aee94514186d21a4871e78d7",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -252,11 +252,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1729951556, "lastModified": 1730949899,
"narHash": "sha256-bpb6r3GjzhNW8l+mWtRtLNg5PhJIae041sPyqcFNGb4=", "narHash": "sha256-hVoMop28jyTeNVCggWtZQDlUU4oPQcx/NsJqA9zUxfA=",
"owner": "Guanran928", "owner": "Guanran928",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "4e0eec54db79d4d0909f45a88037210ff8eaffee", "rev": "e130eea86336ae2e26cfc084f61dd53c376c90c7",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -281,11 +281,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1729104314, "lastModified": 1730814269,
"narHash": "sha256-pZRZsq5oCdJt3upZIU4aslS9XwFJ+/nVtALHIciX/BI=", "narHash": "sha256-fWPHyhYE6xvMI1eGY3pwBTq85wcy1YXqdzTZF+06nOg=",
"owner": "cachix", "owner": "cachix",
"repo": "git-hooks.nix", "repo": "git-hooks.nix",
"rev": "3c3e88f0f544d6bb54329832616af7eb971b6be6", "rev": "d70155fdc00df4628446352fc58adc640cd705c2",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -296,11 +296,11 @@
}, },
"preservation": { "preservation": {
"locked": { "locked": {
"lastModified": 1725460242, "lastModified": 1730126375,
"narHash": "sha256-9n9Ygta1MCfpbF9D88tG2B4EL5nuSz4eIOAofGSlxoE=", "narHash": "sha256-RnXYMkXytsdvXQZdRcci5IiuxWFkWDzawPm2L1K+KGA=",
"owner": "WilliButz", "owner": "WilliButz",
"repo": "preservation", "repo": "preservation",
"rev": "02e731a820d05107bc648460f8630d0d80a5ffd4", "rev": "96a98a3eb4e8ecdc70f299723e2a4d78f5ba3bd6",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -339,11 +339,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1729996302, "lastModified": 1730946479,
"narHash": "sha256-QEU1NQq1+7s1na69Chig9K0iDDTKN0O4Zreo9A9rccA=", "narHash": "sha256-AxGJ3BRc44o3RBcfXxZqjVYftVtJ2sl+/WEjiLUmXRY=",
"owner": "oxalica", "owner": "oxalica",
"repo": "rust-overlay", "repo": "rust-overlay",
"rev": "a1b337569f334ff0a01b57627f17b201d746d24c", "rev": "7fba269fe89ffad47206e0afba233d337c04cf08",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -362,11 +362,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1729999681, "lastModified": 1730883027,
"narHash": "sha256-qm0uCtM9bg97LeJTKQ8dqV/FvqRN+ompyW4GIJruLuw=", "narHash": "sha256-pvXMOJIqRW0trsW+FzRMl6d5PbsM4rWfD5lcKCOrrwI=",
"owner": "Mic92", "owner": "Mic92",
"repo": "sops-nix", "repo": "sops-nix",
"rev": "1666d16426abe79af5c47b7c0efa82fd31bf4c56", "rev": "c5ae1e214ff935f2d3593187a131becb289ea639",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -397,11 +397,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1729613947, "lastModified": 1730321837,
"narHash": "sha256-XGOvuIPW1XRfPgHtGYXd5MAmJzZtOuwlfKDgxX5KT3s=", "narHash": "sha256-vK+a09qq19QNu2MlLcvN4qcRctJbqWkX7ahgPZ/+maI=",
"owner": "numtide", "owner": "numtide",
"repo": "treefmt-nix", "repo": "treefmt-nix",
"rev": "aac86347fb5063960eccb19493e0cadcdb4205ca", "rev": "746901bb8dba96d154b66492a29f5db0693dbfcc",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -37,7 +37,6 @@
fastfetch fastfetch
fd fd
file-roller file-roller
fractal
gnome-calculator gnome-calculator
hyperfine hyperfine
libnotify libnotify

View file

@ -1,4 +1 @@
{ { redlib = 8010; }
redlib = 8010;
ip-checker = 8020;
}

View file

@ -2,24 +2,25 @@
lib, lib,
pkgs, pkgs,
inputs, inputs,
ports,
... ...
}: }:
let let
port = ports.ip-checker;
pkgs' = inputs.ip-checker.packages.${pkgs.stdenv.hostPlatform.system}; pkgs' = inputs.ip-checker.packages.${pkgs.stdenv.hostPlatform.system};
in in
{ {
systemd.services."ip-checker" = { systemd.services."ip-checker" = {
wantedBy = [ "multi-user.target" ]; wantedBy = [ "multi-user.target" ];
environment = { environment = {
IP_CHECKER_LISTEN = "127.0.0.1:${toString port}";
IP_CHECKER_MODE = "prod";
IP_CHECKER_ASN_DB = pkgs.dbip-asn-lite.mmdb; IP_CHECKER_ASN_DB = pkgs.dbip-asn-lite.mmdb;
IP_CHECKER_CITY_DB = pkgs.dbip-city-lite.mmdb; IP_CHECKER_CITY_DB = pkgs.dbip-city-lite.mmdb;
IP_CHECKER_LISTEN = "unix//run/ip-checker/ip-checker.sock";
IP_CHECKER_MODE = "prod";
IP_CHECKER_SOCKET_PERMISSION = "0770";
}; };
serviceConfig = { serviceConfig = {
ExecStart = lib.getExe pkgs'.api; ExecStart = lib.getExe pkgs'.api;
RuntimeDirectory = "ip-checker";
Group = "ip-checker";
CapabilityBoundingSet = ""; CapabilityBoundingSet = "";
DynamicUser = true; DynamicUser = true;
@ -48,6 +49,8 @@ in
}; };
}; };
systemd.services."caddy".serviceConfig.SupplementaryGroups = [ "ip-checker" ];
services.caddy.settings.apps.http.servers.srv0.routes = lib.singleton { services.caddy.settings.apps.http.servers.srv0.routes = lib.singleton {
match = lib.singleton { host = [ "ip.ny4.dev" ]; }; match = lib.singleton { host = [ "ip.ny4.dev" ]; };
handle = lib.singleton { handle = lib.singleton {
@ -58,7 +61,7 @@ in
match = [ { path = [ "/api/v1/*" ]; } ]; match = [ { path = [ "/api/v1/*" ]; } ];
handle = lib.singleton { handle = lib.singleton {
handler = "reverse_proxy"; handler = "reverse_proxy";
upstreams = lib.singleton { dial = "127.0.0.1:${toString port}"; }; upstreams = lib.singleton { dial = "unix//run/ip-checker/ip-checker.sock"; };
}; };
} }
{ {

View file

@ -1,19 +1,12 @@
let
addPatches =
pkg: patches:
pkg.overrideAttrs (old: {
patches = (old.patches or [ ]) ++ patches;
});
in
_final: prev: { _final: prev: {
# https://aur.archlinux.org/pkgbase/nautilus-typeahead # https://aur.archlinux.org/pkgbase/nautilus-typeahead
nautilus = prev.nautilus.overrideAttrs { nautilus = prev.nautilus.overrideAttrs {
src = prev.fetchFromGitLab { src = prev.fetchFromGitLab {
domain = "gitlab.gnome.org"; domain = "gitlab.gnome.org";
owner = "albertvaka"; owner = "xclaesse";
repo = "nautilus"; repo = "nautilus";
rev = "f5f593bf36c41756a29d5112a10cf7ec70b8eafb"; rev = "05f8e6e9bee25c894d2f3582649750737081253b";
hash = "sha256-PfkCY2gQ8jfPIgTRC9Xzxh4N3f2oB339Hym5RCbKwkw="; hash = "sha256-BDWYWBdty/SumkhftEH5fOAow9EjYwdw7pwnSWL+Q48=";
}; };
# Enable type-ahead behavior by default # Enable type-ahead behavior by default
@ -25,16 +18,17 @@ _final: prev: {
qt6Packages = prev.qt6Packages.overrideScope ( qt6Packages = prev.qt6Packages.overrideScope (
_final': prev': { _final': prev': {
# HACK: no more qt5 # HACK: no more qt5
fcitx5-with-addons = prev'.fcitx5-with-addons.override { fcitx5-with-addons = prev'.fcitx5-with-addons.override { libsForQt5.fcitx5-qt = null; };
libsForQt5.fcitx5-qt = prev.emptyDirectory;
}; # HACK: no more kde stuff
fcitx5-configtool = prev'.fcitx5-configtool.override { kcmSupport = false; };
# HACK: no more qtwebengine, opencc # HACK: no more qtwebengine, opencc
fcitx5-chinese-addons = fcitx5-chinese-addons =
(prev'.fcitx5-chinese-addons.override { (prev'.fcitx5-chinese-addons.override {
curl = prev.emptyDirectory; curl = null;
opencc = prev.emptyDirectory; opencc = null;
qtwebengine = prev.emptyDirectory; qtwebengine = null;
}).overrideAttrs }).overrideAttrs
(oldAttrs: { (oldAttrs: {
buildInputs = oldAttrs.buildInputs ++ [ buildInputs = oldAttrs.buildInputs ++ [
@ -51,45 +45,30 @@ _final: prev: {
); );
# HACK: no more gtk2 # HACK: no more gtk2
gnome-themes-extra = gnome-themes-extra = (prev.gnome-themes-extra.override { gtk2 = null; }).overrideAttrs {
(prev.gnome-themes-extra.override { gtk2 = prev.emptyDirectory; }).overrideAttrs configureFlags = [ "--disable-gtk2-engine" ];
{ configureFlags = [ "--disable-gtk2-engine" ]; }; };
sway-unwrapped = addPatches prev.sway-unwrapped [ # TODO:
# text_input: Implement input-method popups # sway-unwrapped = prev.sway-unwrapped.overrideAttrs (oldAttrs: {
# https://github.com/swaywm/sway/pull/7226 # patches = (oldAttrs.patches or [ ]) ++ [
(prev.fetchpatch2 { # # Tray D-Bus Menu
name = "0001-text_input-Implement-input-method-popups.patch"; # # https://github.com/swaywm/sway/pull/6249
url = "https://github.com/swaywm/sway/commit/de74d1f6360810c0a5fd11d8022fbffe56fc97c5.patch"; # (prev.fetchpatch2 {
hash = "sha256-iTZIYHBp8vxjVdmH/k+jlN0/Zj6Ofe/qefv7ubtowHs="; # name = "0001-Tray-Implement-dbusmenu.patch";
}) # url = "https://github.com/NickHu/sway/commit/0fc5d7aed84415a77b718ca9dc3c0b3ad2c05b02.patch";
(prev.fetchpatch2 { # hash = "sha256-eosg6m2P6e8NRXjOAQL3SZg+Yc4Av9Wd+LOy0G3+xkA=";
name = "0002-chore-fractal-scale-handle.patch"; # })
url = "https://github.com/swaywm/sway/commit/2aa72e8dfd3b3d051fdec6b2d05c5635adcfb57b.patch"; # (prev.fetchpatch2 {
hash = "sha256-aJYXoZ7xEEy8J8DjxANOe14HdHRni6IXSNcAzLzNvIo="; # name = "0002-Tray-dont-invoke-dbus-menu-when-tray-is-disabled.patch";
}) # url = "https://github.com/NickHu/sway/commit/03c14421354e54332e12f78d029dcaa9919fd161.patch";
(prev.fetchpatch2 { # hash = "sha256-8RGtpfN/tnkA7nuGdXGHoKUoKVeG7brSQR6V4RU3z88=";
name = "0003-chore-left_pt-on-method-popup.patch"; # })
url = "https://github.com/swaywm/sway/commit/0789c12a8edf46fbc1c7024e153f3e8f8f35fe12.patch"; # (prev.fetchpatch2 {
hash = "sha256-zvhp5eXqDngMNtctzVpryZY3zKi3IVjV7oFIBMC2jMk="; # name = "0003-swaybar-dbusmenu-fix-crash-if-the-program-exits-while-menu.patch";
}) # url = "https://github.com/llyyr/sway/commit/84481c26a4c55674da5804bb2619d3575ba405b3.patch";
# hash = "sha256-+JJoHNOmDzqT1TaFM83DR3/BdCab240tfs21VNMv6wE=";
# Tray D-Bus Menu # })
# https://github.com/swaywm/sway/pull/6249 # ];
(prev.fetchpatch2 { # });
name = "0001-Tray-Implement-dbusmenu.patch";
url = "https://github.com/NickHu/sway/commit/0fc5d7aed84415a77b718ca9dc3c0b3ad2c05b02.patch";
hash = "sha256-eosg6m2P6e8NRXjOAQL3SZg+Yc4Av9Wd+LOy0G3+xkA=";
})
(prev.fetchpatch2 {
name = "0002-Tray-dont-invoke-dbus-menu-when-tray-is-disabled.patch";
url = "https://github.com/NickHu/sway/commit/03c14421354e54332e12f78d029dcaa9919fd161.patch";
hash = "sha256-8RGtpfN/tnkA7nuGdXGHoKUoKVeG7brSQR6V4RU3z88=";
})
(prev.fetchpatch2 {
name = "0003-swaybar-dbusmenu-fix-crash-if-the-program-exits-while-menu.patch";
url = "https://github.com/llyyr/sway/commit/84481c26a4c55674da5804bb2619d3575ba405b3.patch";
hash = "sha256-+JJoHNOmDzqT1TaFM83DR3/BdCab240tfs21VNMv6wE=";
})
];
} }