mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-03-28 12:21:54 +01:00
feat: update flake.lock, add eye-protection.nix
This commit is contained in:
8
Makefile
8
Makefile
@@ -33,12 +33,18 @@ upp:
|
||||
history:
|
||||
nix profile history --profile /nix/var/nix/profiles/system
|
||||
|
||||
repl:
|
||||
nix repl -f flake:nixpkgs
|
||||
|
||||
eye:
|
||||
systemctl --user start gammastep.service
|
||||
|
||||
gc:
|
||||
# remove all generations older than 7 days
|
||||
sudo nix profile wipe-history --profile /nix/var/nix/profiles/system --older-than 7d
|
||||
|
||||
# garbage collect all unused nix store entries
|
||||
sudo nix store gc --debug
|
||||
# sudo nix store gc --debug
|
||||
|
||||
############################################################################
|
||||
#
|
||||
|
||||
96
flake.lock
generated
96
flake.lock
generated
@@ -29,11 +29,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1696926085,
|
||||
"narHash": "sha256-PuaKdM4Nems/wQ2B+K7hI2UJYld/+64NdkcsYD1YJwM=",
|
||||
"lastModified": 1701453400,
|
||||
"narHash": "sha256-hI9+KBShsSfvWX7bmRa/1VI20WGat3lDXmbceMZzMS4=",
|
||||
"owner": "Kirottu",
|
||||
"repo": "anyrun",
|
||||
"rev": "f9073a6184f61a07bb584ecc47fbb8eb997e9216",
|
||||
"rev": "e14da6c37337ffa3ee1bc66965d58ef64c1590e5",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -45,16 +45,16 @@
|
||||
"astronvim": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1701266895,
|
||||
"narHash": "sha256-wttBcj9OoFHx+EukGzQYKHVlApphZXzZqY5zP5chU6g=",
|
||||
"lastModified": 1702659104,
|
||||
"narHash": "sha256-h019vKDgaOk0VL+bnAPOUoAL8VAkhY6MGDbqEy+uAKg=",
|
||||
"owner": "AstroNvim",
|
||||
"repo": "AstroNvim",
|
||||
"rev": "bdbc0fef3f33443251e6b45b252b98c42335b881",
|
||||
"rev": "271c9c3f71c2e315cb16c31276dec81ddca6a5a6",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "AstroNvim",
|
||||
"ref": "v3.39.0",
|
||||
"ref": "v3.40.3",
|
||||
"repo": "AstroNvim",
|
||||
"type": "github"
|
||||
}
|
||||
@@ -158,11 +158,11 @@
|
||||
"catppuccin-hyprland": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1683122293,
|
||||
"narHash": "sha256-07B5QmQmsUKYf38oWU3+2C6KO4JvinuTwmW1Pfk8CT8=",
|
||||
"lastModified": 1702668781,
|
||||
"narHash": "sha256-9BhZq9J1LmHfAPBqOr64chiAEzS+YV6zqe9ma95V3no=",
|
||||
"owner": "catppuccin",
|
||||
"repo": "hyprland",
|
||||
"rev": "99a88fd21fac270bd999d4a26cf0f4a4222c58be",
|
||||
"rev": "fc228737d3d0c12e34a7fa155a0fc3192e5e4017",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -384,11 +384,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1700814205,
|
||||
"narHash": "sha256-lWqDPKHRbQfi+zNIivf031BUeyciVOtwCwTjyrhDB5g=",
|
||||
"lastModified": 1702676849,
|
||||
"narHash": "sha256-XqcREaTS38/QOsN8fk8PP325/UXHyF9enbP5ZPw5aiA=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "aeb2232d7a32530d3448318790534d196bf9427a",
|
||||
"rev": "aa99c2f4e9847cbb7e46fac0844ea1eb164b3b3a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -407,16 +407,16 @@
|
||||
"xdph": "xdph"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1699726486,
|
||||
"narHash": "sha256-8PP26+ybmScq5WpFd2JPqUDzG2VggYOvD6/rzY9/CJ4=",
|
||||
"lastModified": 1701881246,
|
||||
"narHash": "sha256-p7el5oQZPy9l1zyIrlHu6nA4BAu59eLoSqBjhkw2jaw=",
|
||||
"owner": "hyprwm",
|
||||
"repo": "Hyprland",
|
||||
"rev": "9afdd61adeaf413afbe853dbc5fdf6853c8bde21",
|
||||
"rev": "d74607e414dcd16911089a6d4b6aeb661c880923",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hyprwm",
|
||||
"ref": "v0.32.3",
|
||||
"ref": "v0.33.1",
|
||||
"repo": "Hyprland",
|
||||
"type": "github"
|
||||
}
|
||||
@@ -529,11 +529,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1699867978,
|
||||
"narHash": "sha256-+arl45HUOcBdKiRGrKXZYXDyBQ6MQGkYPZa/28f6Yzo=",
|
||||
"lastModified": 1700795494,
|
||||
"narHash": "sha256-gzGLZSiOhf155FW7262kdHo2YDeugp3VuIFb4/GGng0=",
|
||||
"owner": "lnl7",
|
||||
"repo": "nix-darwin",
|
||||
"rev": "e67f2bf515343da378c3f82f098df8ca01bccc5f",
|
||||
"rev": "4b9b83d5a92e8c1fbfd8eb27eda375908c11ec4d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -565,11 +565,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1696058303,
|
||||
"narHash": "sha256-eNqKWpF5zG0SrgbbtljFOrRgFgRzCc4++TMFADBMLnc=",
|
||||
"lastModified": 1701689616,
|
||||
"narHash": "sha256-ewnfgvRy73HoP5KnYmy1Rcr4m4yShvsb6TCCaKoW8pc=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nixos-generators",
|
||||
"rev": "150f38bd1e09e20987feacb1b0d5991357532fb5",
|
||||
"rev": "246219bc21b943c6f6812bb7744218ba0df08600",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -634,11 +634,11 @@
|
||||
},
|
||||
"nixpkgs-darwin": {
|
||||
"locked": {
|
||||
"lastModified": 1701386440,
|
||||
"narHash": "sha256-xI0uQ9E7JbmEy/v8kR9ZQan6389rHug+zOtZeZFiDJk=",
|
||||
"lastModified": 1702424505,
|
||||
"narHash": "sha256-Mj4Unppuzd05/JFrTQ+i/8+td0MRnaHpp+hInzkAo2A=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "293822e55ec1872f715a66d0eda9e592dc14419f",
|
||||
"rev": "a46b965ea7d1b9587a46f91adfdbac29e56c9b87",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -666,11 +666,11 @@
|
||||
},
|
||||
"nixpkgs-unstable": {
|
||||
"locked": {
|
||||
"lastModified": 1699781429,
|
||||
"narHash": "sha256-UYefjidASiLORAjIvVsUHG6WBtRhM67kTjEY4XfZOFs=",
|
||||
"lastModified": 1702312524,
|
||||
"narHash": "sha256-gkZJRDBUCpTPBvQk25G0B7vfbpEYM5s5OZqghkjZsnE=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "e44462d6021bfe23dfb24b775cc7c390844f773d",
|
||||
"rev": "a9bf124c46ef298113270b1f84a164865987a91c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -682,11 +682,11 @@
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1698134075,
|
||||
"narHash": "sha256-foCD+nuKzfh49bIoiCBur4+Fx1nozo+4C/6k8BYk4sg=",
|
||||
"lastModified": 1700612854,
|
||||
"narHash": "sha256-yrQ8osMD+vDLGFX7pcwsY/Qr5PUd6OmDMYJZzZi0+zc=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "8efd5d1e283604f75a808a20e6cde0ef313d07d4",
|
||||
"rev": "19cbff58383a4ae384dea4d1d0c823d72b49d614",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -730,11 +730,11 @@
|
||||
},
|
||||
"nixpkgs_5": {
|
||||
"locked": {
|
||||
"lastModified": 1701389149,
|
||||
"narHash": "sha256-rU1suTIEd5DGCaAXKW6yHoCfR1mnYjOXQFOaH7M23js=",
|
||||
"lastModified": 1702346276,
|
||||
"narHash": "sha256-eAQgwIWApFQ40ipeOjVSoK4TEHVd6nbSd9fApiHIw5A=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "5de0b32be6e85dc1a9404c75131316e4ffbc634c",
|
||||
"rev": "cf28ee258fd5f9a52de6b9865cdb93a1f96d09b7",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -765,11 +765,11 @@
|
||||
"nixpkgs": "nixpkgs_6"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1694184827,
|
||||
"narHash": "sha256-2l8RUUmMfioIv+r7eoHRZOm0Dvi1k09Dgg+Bv4zIzE0=",
|
||||
"lastModified": 1701952536,
|
||||
"narHash": "sha256-pKYooDFbWkN/DMhtiHNcsVcRMCZKsmETyarXWnz68kc=",
|
||||
"owner": "ryan4yin",
|
||||
"repo": "nur-packages",
|
||||
"rev": "22b45842973a412f47cce6fdc5499843335f7a3e",
|
||||
"rev": "a6b5606740e24b70b37a1de3af5867af64e3cb75",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -781,11 +781,11 @@
|
||||
"nushell-scripts": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1699979604,
|
||||
"narHash": "sha256-XRObmaD2dRwc2jlOHIpFIqSURfx23kyc90sELqo9N4I=",
|
||||
"lastModified": 1702558950,
|
||||
"narHash": "sha256-pai3qeD2hmpx2r/lDfGpUY3mkl0gRN6j72gplz9DQD4=",
|
||||
"owner": "nushell",
|
||||
"repo": "nu_scripts",
|
||||
"rev": "1fd3a3fa6ac454080fa726142e6ef2470fd5e51a",
|
||||
"rev": "6f1c0dfef203fa07449718b76d31580e8458c8b7",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -949,18 +949,18 @@
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"host": "gitlab.freedesktop.org",
|
||||
"lastModified": 1699292815,
|
||||
"narHash": "sha256-HXu98PyBMKEWLqiTb8viuLDznud/SdkdJsx5A5CWx7I=",
|
||||
"lastModified": 1701368958,
|
||||
"narHash": "sha256-7kvyoA91etzVEl9mkA/EJfB6z/PltxX7Xc4gcr7/xlo=",
|
||||
"owner": "wlroots",
|
||||
"repo": "wlroots",
|
||||
"rev": "5de9e1a99d6642c2d09d589aa37ff0a8945dcee1",
|
||||
"rev": "5d639394f3e83b01596dcd166a44a9a1a2583350",
|
||||
"type": "gitlab"
|
||||
},
|
||||
"original": {
|
||||
"host": "gitlab.freedesktop.org",
|
||||
"owner": "wlroots",
|
||||
"repo": "wlroots",
|
||||
"rev": "5de9e1a99d6642c2d09d589aa37ff0a8945dcee1",
|
||||
"rev": "5d639394f3e83b01596dcd166a44a9a1a2583350",
|
||||
"type": "gitlab"
|
||||
}
|
||||
},
|
||||
@@ -980,11 +980,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1697981233,
|
||||
"narHash": "sha256-y8q4XUwx+gVK7i2eLjfR32lVo7TYvEslyzrmzYEaPZU=",
|
||||
"lastModified": 1700508250,
|
||||
"narHash": "sha256-X4o/mifI7Nhu0UKYlxx53wIC+gYDo3pVM9L2u3PE2bE=",
|
||||
"owner": "hyprwm",
|
||||
"repo": "xdg-desktop-portal-hyprland",
|
||||
"rev": "22e7a65ff9633e1dedfa5317fdffc49f68de2ff2",
|
||||
"rev": "eb120ff25265ecacd0fc13d7dab12131b60d0f47",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
||||
@@ -307,7 +307,7 @@
|
||||
impermanence.url = "github:nix-community/impermanence";
|
||||
|
||||
# modern window compositor
|
||||
hyprland.url = "github:hyprwm/Hyprland/v0.32.3";
|
||||
hyprland.url = "github:hyprwm/Hyprland/v0.33.1";
|
||||
# community wayland nixpkgs
|
||||
# nixpkgs-wayland.url = "github:nix-community/nixpkgs-wayland";
|
||||
# anyrun - a wayland launcher
|
||||
@@ -329,7 +329,7 @@
|
||||
|
||||
# AstroNvim is an aesthetic and feature-rich neovim config.
|
||||
astronvim = {
|
||||
url = "github:AstroNvim/AstroNvim/v3.39.0";
|
||||
url = "github:AstroNvim/AstroNvim/v3.40.3";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
# You can update Home Manager without changing this value. See
|
||||
# the Home Manager release notes for a list of state version
|
||||
# changes in each release.
|
||||
stateVersion = "22.11";
|
||||
stateVersion = "23.11";
|
||||
};
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
# You can update Home Manager without changing this value. See
|
||||
# the Home Manager release notes for a list of state version
|
||||
# changes in each release.
|
||||
stateVersion = "22.11";
|
||||
stateVersion = "23.11";
|
||||
};
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
# You can update Home Manager without changing this value. See
|
||||
# the Home Manager release notes for a list of state version
|
||||
# changes in each release.
|
||||
stateVersion = "22.11";
|
||||
stateVersion = "23.11";
|
||||
};
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
./ssh.nix
|
||||
./wallpaper.nix
|
||||
./xdg.nix
|
||||
./eye-protection.nix
|
||||
];
|
||||
|
||||
home.packages = with pkgs; [
|
||||
|
||||
41
home/linux/desktop/eye-protection.nix
Normal file
41
home/linux/desktop/eye-protection.nix
Normal file
@@ -0,0 +1,41 @@
|
||||
{ pkgs, lib, ... }: {
|
||||
# Adjust the color temperature(& brightness) of your screen according to
|
||||
# your surroundings. This may help your eyes hurt less if you are
|
||||
# working in front of the screen at night.
|
||||
#
|
||||
# works fine with both x11 & wayland(hyprland)
|
||||
#
|
||||
# https://gitlab.com/chinstrap/gammastep
|
||||
services.gammastep = {
|
||||
enable = true;
|
||||
# add a gammastep icon in the system tray
|
||||
# has problem with wayland, so disable it
|
||||
tray = false;
|
||||
temperature = {
|
||||
day = 5700;
|
||||
night = 4000;
|
||||
};
|
||||
# https://gitlab.com/chinstrap/gammastep/-/blob/master/gammastep.conf.sample?ref_type=heads
|
||||
settings = {
|
||||
general = {
|
||||
fade = "1"; # gradually apply the new screen temperature/brightness over a couple of seconds.
|
||||
# it is a fake brightness adjustment obtained by manipulating the gamma ramps,
|
||||
# which means that it does not reduce the backlight of the screen.
|
||||
# Preferably only use it if your normal backlight adjustment is too coarse-grained.
|
||||
brightness-day = "1.0";
|
||||
brightness-night = "0.8";
|
||||
location-provider = "manual";
|
||||
|
||||
# by default, Redshift will use the current elevation of the sun
|
||||
# to determine whether it is daytime, night or in transition (dawn/dusk).
|
||||
# dawn-time = "6:00-8:45";
|
||||
# dusk-time = "18:35-20:15";
|
||||
};
|
||||
manual = {
|
||||
# China, Shenzhen
|
||||
lat = "22.5"; # latitude
|
||||
lon = "114.1"; # longitude
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -5,6 +5,7 @@
|
||||
"modules-left": [
|
||||
"custom/launcher",
|
||||
"temperature",
|
||||
"backlight",
|
||||
"wlr/workspaces"
|
||||
],
|
||||
"modules-center": [
|
||||
@@ -13,11 +14,11 @@
|
||||
"modules-right": [
|
||||
"mpd",
|
||||
"pulseaudio",
|
||||
"backlight",
|
||||
"memory",
|
||||
"cpu",
|
||||
"network",
|
||||
"clock",
|
||||
"idle_inhibitor",
|
||||
"custom/powermenu",
|
||||
"tray"
|
||||
],
|
||||
@@ -50,7 +51,9 @@
|
||||
},
|
||||
"cpu": {
|
||||
"format": "\udb80\udf5b {usage}%",
|
||||
"interval": 1
|
||||
"interval": 1,
|
||||
"on-click-middle": "kitty btop",
|
||||
"on-click-right": "kitty btop"
|
||||
},
|
||||
"custom/launcher": {
|
||||
"format": "\uf313 ",
|
||||
@@ -122,8 +125,10 @@
|
||||
"format-linked": " {ifname} (No IP)",
|
||||
"format-disconnected": "睊 Disconnected",
|
||||
"format-disabled": "睊 Disabled",
|
||||
"format-alt": " {bandwidthUpBits} | {bandwidthDownBits}",
|
||||
"format-alt": " {bandwidthUpBytes} | {bandwidthDownBytes}",
|
||||
"tooltip-format": " {ifname} via {gwaddr}",
|
||||
"on-click-middle": "nm-connection-editor",
|
||||
"on-click-right": "kitty nmtui"
|
||||
},
|
||||
"pulseaudio": {
|
||||
//"format": "{volume}% {icon} {format_source}",
|
||||
@@ -156,6 +161,20 @@
|
||||
"format": "\uf2c9 {temperatureC}\u00b0C",
|
||||
"tooltip": false
|
||||
},
|
||||
"backlight": {
|
||||
"format": "{icon} {percent}%",
|
||||
"format-icons": [
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
""
|
||||
]
|
||||
},
|
||||
"tray": {
|
||||
"icon-size": 15,
|
||||
"spacing": 5
|
||||
|
||||
@@ -8,9 +8,11 @@
|
||||
commandLineArgs = [
|
||||
# make it use GTK_IM_MODULE if it runs with Gtk4, so fcitx5 can work with it.
|
||||
# (only supported by chromium/chrome at this time, not electron)
|
||||
"--gtk-version=4"
|
||||
"--gtk-version=5"
|
||||
"--enable-features=UseOzonePlatform"
|
||||
"--ozone-platform=wayland"
|
||||
# make it use text-input-v1, which works for kwin 5.27 and weston
|
||||
# "--enable-wayland-ime"
|
||||
"--enable-wayland-ime"
|
||||
|
||||
# enable hardware acceleration - vulkan api
|
||||
# "--enable-features=Vulkan"
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
# You can update Home Manager without changing this value. See
|
||||
# the Home Manager release notes for a list of state version
|
||||
# changes in each release.
|
||||
stateVersion = "22.11";
|
||||
stateVersion = "23.11";
|
||||
};
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
|
||||
@@ -60,5 +60,5 @@
|
||||
# this value at the release version of the first install of this system.
|
||||
# Before changing this value read the documentation for this option
|
||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||
system.stateVersion = "22.11"; # Did you read the comment?
|
||||
system.stateVersion = "23.11"; # Did you read the comment?
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user