revert to nixos23
Revert "docs: add rpm-ostree status output" This reverts commit ab4d52098130661a6397a4b40774717ec0bb3647. Revert "fix(sway): disable title text" This reverts commit ad027daa59fc025f982da0cc90ddb7a9ff2b8530. Revert "feat: add ominous to cargo mommy moods" This reverts commit f68ccc7e69f2a2404c81205dfeaa7b970da5716d. Revert "fix(bash): add assume-yes to flatpak update" This reverts commit 36fd6488e6011855989bfc4d317d1234e55fd661. Revert "feat: set up env better" This reverts commit f6dd44a0bb0aaf710f7299999690b3ab92cb06df. Revert "feat(sway): enable borders" This reverts commit bc4e2d934d3aa99c72bb35f2774a33101d20232d. Revert "feat(sway): use foot instead of footclient by default" This reverts commit 760db618884698d6fa9e360326c877eace44f416. Revert "feat(bash): improve prompt" This reverts commit 2dc1a49955a579649630fd2af3dca68a6f42a678. Revert "bash: add update command" This reverts commit 64c20bc06d654a09af138353dedd2c58d583f13d. Revert "profile: add cargo bin to PATH" This reverts commit d4b2b31fd64b2132a07194e3e44aecc40b1dee9f. Revert "sway: remove foot autostart from sway config" This reverts commit 9d656b5d68d654d4b654f5047661bb4b519af6d5. Revert "sway: remove autostart from sway" This reverts commit d07c7fcaa17337659295f9af48fcebdc31ae0e45. Revert "fcitx5: change install target to fix autostart" This reverts commit a189c2f52f283872b72a79422eb4ce79939998ba. Revert "firefox: make colors match better" This reverts commit 722e9fc8627c5ab5e109e5ffd7a874ac643ca33a. Revert "swaylock: use new colors" This reverts commit f8ffdbd6fe1fd013ff345a6d74a76ccaed3bf711. Revert "foot: use new greens and cyans" This reverts commit 23e62347cbce7aa132e5e59cb7aa626480c46b59. Revert "bash: better prompt" This reverts commit 2ad5b813294338a0947d4145bc18c32f8ab77c7f. Revert "foot: new colors" This reverts commit aa1130d4962060710cf6f2f22cfca0686cf275f6. Revert "sway: new rice" This reverts commit d6fd3bca6b8d24bf3128ebe5495ccba68e7be03d. Revert "profile: add roswell/bin to PATH" This reverts commit 00dae6a9887e70e72d9023d757b54670cfff70d3. Revert "foot: set TERM=xterm-256color" This reverts commit 944ba167ea4a51503bb6f82ac07a1f6534fea1f3. Revert "bash: use CONTAINER_ID instead of DISTROBOX_ENTER_PATH" This reverts commit 98c88c91f922b89368b37ba79911e1c3c30cbf44. Revert "bash: add distrobox alias" This reverts commit 0c5a16c9bdd74a6807a82cb1b8e53713ff801bac. Revert "profile: add .local/bin to PATH" This reverts commit d901806cdc799db0032815e798c804e3adb1c033. Revert "bash: print reverse video % when last line doesn't end in linebreak" This reverts commit c79cc7936a739a4a42b0c05d62951fb1dfc71627. Revert "bash: use == for comparison" This reverts commit 55c6628409daa63f2973b7988f56cee1d38324a7. Revert "bash: don't set PS0" This reverts commit b72ea9fea1626f42ca75df15dd2a0b84036a1e03. Revert "sway: add rofi bind" This reverts commit 9d3fd60da599af07d5f614edea2f45a0ab532bc3. Revert "sway: use firefox instead of firefox-wayland" This reverts commit 1a98cdf50e1b4bc08e9151ab2924124e1c0909aa. Revert "firefox: use new profile name" This reverts commit 7dd8f1bbd61ac96b64c4b13121b3e1f476c133da. Revert "bash: switch to prompt with more info" This reverts commit 080c0c9f824f3d678ab3627e3eafa81e240329a4. Revert "sway: don't autostart wl-paste, it doesn't do anything" This reverts commit 37ddd0e50cdf627a14b237cfdd9a980235e55e53. Revert "sway: make use of foot server" This reverts commit 0013096d2621a9624efd9265f7313d4717d36c09. Revert "port configs" This reverts commit 9ea4f090f73ed124d5b4eed58d300ad234957133. Revert "get rid of old config" This reverts commit 942e1dff74b7465a0be5817b187a8580b0102f6f.
This commit is contained in:
parent
e28d7eaa5f
commit
afcd343d0a
46 changed files with 2265 additions and 387 deletions
42
alice/default.nix
Normal file
42
alice/default.nix
Normal file
|
@ -0,0 +1,42 @@
|
|||
{nixos-hardware, ...}: let
|
||||
password = "$y$j9T$g/a4KaQ5VitWI9ZtAh9i3/$wjejk5W8LMc0gaVgw69kwrKLqBgZ95ekaOl/GaTOZVC";
|
||||
in {
|
||||
imports = [
|
||||
nixos-hardware.nixosModules.lenovo-thinkpad-x270
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
# Don't change!
|
||||
system.stateVersion = "23.05";
|
||||
home-manager.users.buffet.home.stateVersion = "23.05";
|
||||
|
||||
users.users.buffet.hashedPassword = password;
|
||||
users.users.root.hashedPassword = password;
|
||||
|
||||
networking.hostName = "alice";
|
||||
|
||||
services = {
|
||||
tlp = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
START_CHARGE_THRESH_BAT0 = 40;
|
||||
STOP_CHARGE_THRESH_BAT0 = 60;
|
||||
|
||||
START_CHARGE_THRESH_BAT1 = 40;
|
||||
STOP_CHARGE_THRESH_BAT1 = 60;
|
||||
};
|
||||
};
|
||||
|
||||
keyd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
"102nd" = "layer(shift)"; # < as shift
|
||||
"enter" = "\\";
|
||||
"\\" = "enter";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
64
alice/hardware-configuration.nix
Normal file
64
alice/hardware-configuration.nix
Normal file
|
@ -0,0 +1,64 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = ["xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = [];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/ad5a4aba-eb04-45e7-874e-375e7a9e4ea0";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@"];
|
||||
};
|
||||
|
||||
fileSystems."/persist" = {
|
||||
device = "/dev/disk/by-uuid/ad5a4aba-eb04-45e7-874e-375e7a9e4ea0";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@persist"];
|
||||
};
|
||||
|
||||
fileSystems."/nix" = {
|
||||
device = "/dev/disk/by-uuid/ad5a4aba-eb04-45e7-874e-375e7a9e4ea0";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@nix"];
|
||||
};
|
||||
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/46F6-8161";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
fileSystems."/old" = {
|
||||
device = "/dev/disk/by-uuid/ad5a4aba-eb04-45e7-874e-375e7a9e4ea0";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@old"];
|
||||
};
|
||||
|
||||
swapDevices = [
|
||||
{device = "/dev/disk/by-uuid/2df05abc-60cb-4269-86ae-7c16a4a05369";}
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp0s31f6.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp3s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
159
common.nix
Normal file
159
common.nix
Normal file
|
@ -0,0 +1,159 @@
|
|||
{pkgs, ...}: {
|
||||
imports = [
|
||||
./programs/bash.nix
|
||||
./programs/borg.nix
|
||||
./programs/cargo.nix
|
||||
./programs/firefox.nix
|
||||
./programs/foot.nix
|
||||
./programs/git.nix
|
||||
./programs/gpg.nix
|
||||
./programs/ime.nix
|
||||
./programs/keyd.nix
|
||||
./programs/lsd.nix
|
||||
./programs/mako.nix
|
||||
./programs/newsboat.nix
|
||||
./programs/nvim.nix
|
||||
./programs/pipewire.nix
|
||||
./programs/sbcl.nix
|
||||
./programs/sioyek.nix
|
||||
./programs/sway.nix
|
||||
];
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
gitFull
|
||||
neovim
|
||||
];
|
||||
|
||||
fonts.fonts = with pkgs; [
|
||||
apl386
|
||||
dejavu_fonts
|
||||
noto-fonts
|
||||
noto-fonts-cjk
|
||||
];
|
||||
|
||||
home-manager.users.buffet = {
|
||||
home = {
|
||||
sessionVariables = {
|
||||
ANKI_WAYLAND = 1;
|
||||
};
|
||||
|
||||
packages = with pkgs; [
|
||||
unstable.anki
|
||||
|
||||
SDL2
|
||||
SDL2.dev
|
||||
alejandra
|
||||
bear
|
||||
black
|
||||
c2ffi
|
||||
cage
|
||||
cairo
|
||||
chromium
|
||||
ed
|
||||
gcc
|
||||
gnumake
|
||||
mpv
|
||||
python3
|
||||
|
||||
cargo
|
||||
cargo-crev
|
||||
cargo-limit
|
||||
mosh
|
||||
cargo-nextest
|
||||
du-dust
|
||||
fd
|
||||
gdb
|
||||
github-cli
|
||||
htop
|
||||
hyperfine
|
||||
jq
|
||||
kcachegrind
|
||||
linuxPackages.perf
|
||||
man-pages
|
||||
man-pages-posix
|
||||
okular
|
||||
pavucontrol
|
||||
radare2
|
||||
ripgrep
|
||||
rr
|
||||
rustfmt
|
||||
strace
|
||||
tokei
|
||||
trash-cli
|
||||
tree
|
||||
valgrind
|
||||
wget
|
||||
wl-clipboard
|
||||
|
||||
(luajit.withPackages (ps:
|
||||
with ps; [
|
||||
fennel
|
||||
inspect
|
||||
luv
|
||||
]))
|
||||
|
||||
(retroarch.override {
|
||||
cores = with libretro; [
|
||||
genesis-plus-gx
|
||||
];
|
||||
})
|
||||
];
|
||||
|
||||
pointerCursor = {
|
||||
package = pkgs.phinger-cursors;
|
||||
name = "phinger-cursors-light";
|
||||
gtk.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
enableBashIntegration = true;
|
||||
};
|
||||
};
|
||||
|
||||
users.users.buffet = {
|
||||
isNormalUser = true;
|
||||
uid = 1000;
|
||||
extraGroups = [
|
||||
"docker"
|
||||
"networkmanager"
|
||||
"sway"
|
||||
"uinput"
|
||||
"wheel"
|
||||
];
|
||||
};
|
||||
|
||||
systemd.coredump.enable = true;
|
||||
|
||||
hardware = {
|
||||
bluetooth.enable = true;
|
||||
uinput.enable = true;
|
||||
};
|
||||
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
libvirtd.enable = true;
|
||||
};
|
||||
|
||||
powerManagement = {
|
||||
enable = true;
|
||||
powertop.enable = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
earlyoom = {
|
||||
enable = true;
|
||||
enableNotifications = true;
|
||||
};
|
||||
|
||||
mullvad-vpn = {
|
||||
enable = true;
|
||||
package = pkgs.mullvad-vpn; # enable gui
|
||||
};
|
||||
|
||||
systembus-notify.enable = true;
|
||||
upower.enable = true;
|
||||
};
|
||||
}
|
|
@ -1,2 +0,0 @@
|
|||
[[ -f ~/.bashrc ]] && . ~/.bashrc
|
||||
[[ -f ~/.profile ]] && . ~/.profile
|
49
dots/.bashrc
49
dots/.bashrc
|
@ -1,49 +0,0 @@
|
|||
shopt -s cdspell checkjobs extglob globstar histappend nocaseglob
|
||||
HISTCONTROL=erasedups:ignorespace
|
||||
|
||||
alias db=distrobox
|
||||
alias mkdir='mkdir -p'
|
||||
alias rg='rg -S'
|
||||
|
||||
bind '"\C-o": "\C-a\C-k fg; if [[ $? == 1 ]]; then nvim; fi\n"'
|
||||
bind '"\e\C-m": "\C-e | nvim\C-m"'
|
||||
|
||||
update() {
|
||||
rpm-ostree upgrade
|
||||
distrobox upgrade --all
|
||||
rustup update
|
||||
flatpak update -y
|
||||
}
|
||||
|
||||
__prompt() {
|
||||
local status="$?"
|
||||
local row
|
||||
local col
|
||||
|
||||
IFS=';' read -rs -dR -p $'\e[6n' row col >/dev/tty
|
||||
if [[ $col != 1 ]]; then
|
||||
printf '%s' $'\e[0;7m%\n\e[0m'
|
||||
fi
|
||||
|
||||
PS1='\[\e[0;1m\]['
|
||||
|
||||
case $status in
|
||||
0) PS1+='\[\e[32m\]' ;;
|
||||
*) PS1+='\[\e[31m\]' ;;
|
||||
esac
|
||||
|
||||
if [[ "$PWD" == "$HOME" ]]; then
|
||||
PS1+="~"
|
||||
elif [[ "$PWD" == / ]]; then
|
||||
PS1+=/
|
||||
else
|
||||
PS1+="${PWD##*/}"
|
||||
fi
|
||||
|
||||
PS1+='\[\e[0;1m\]]\[\e[0m\]'
|
||||
|
||||
[[ $CONTAINER_ID ]] && PS1+="'"
|
||||
|
||||
PS1+=' '
|
||||
}
|
||||
PROMPT_COMMAND=__prompt
|
|
@ -1,53 +0,0 @@
|
|||
# -*- conf -*-
|
||||
|
||||
term=xterm-256color
|
||||
|
||||
font=APL386 Unicode:weight=bold:size=8
|
||||
pad=12x8 # optionally append 'center'
|
||||
|
||||
[scrollback]
|
||||
lines=10000
|
||||
|
||||
[url]
|
||||
launch=xdg-open ${url}
|
||||
|
||||
[cursor]
|
||||
color=dcd7ba 6f6f78
|
||||
|
||||
[colors]
|
||||
background=ffffff
|
||||
foreground=000000
|
||||
|
||||
## Normal/regular colors (color palette 0-7)
|
||||
regular0=393939 # black
|
||||
regular1=e96161 # red
|
||||
regular2=3cc970 # green
|
||||
regular3=e6d250 # yellow
|
||||
regular4=4f9afa # blue
|
||||
regular5=d949d9 # magenta
|
||||
regular6=31d6c8 # cyan
|
||||
regular7=d6d6d6 # white
|
||||
|
||||
## Bright colors (color palette 8-15)
|
||||
bright0=5c5c5c # bright black
|
||||
bright1=ff5353 # bright red
|
||||
bright2=62ec75 # bright green
|
||||
bright3=ffea2e # bright yellow
|
||||
bright4=56c7ff # bright blue
|
||||
bright5=fd5cff # bright magenta
|
||||
bright6=55f2ea # bright cyan
|
||||
bright7=ffffff # bright white
|
||||
|
||||
## Misc colors
|
||||
# selection-foreground=<inverse foreground/background>
|
||||
# selection-background=<inverse foreground/background>
|
||||
# jump-labels=<regular0> <regular3> # black-on-yellow
|
||||
# scrollback-indicator=<regular0> <bright4> # black-on-bright-blue
|
||||
# search-box-no-match=<regular0> <regular1> # black-on-red
|
||||
# search-box-match=<regular0> <regular3> # black-on-yellow
|
||||
# urls=<regular3>
|
||||
|
||||
[key-bindings]
|
||||
show-urls-launch=Control+Shift+l
|
||||
|
||||
# vim: ft=dosini
|
|
@ -1,23 +0,0 @@
|
|||
[user]
|
||||
email = dev@buffet.sh
|
||||
name = buffet
|
||||
|
||||
[alias]
|
||||
b = branch
|
||||
c = commit --verbose
|
||||
m = commit --ammend --verbose
|
||||
|
||||
d = diff
|
||||
ds = diff --stat
|
||||
dc = diff --cached
|
||||
l = log
|
||||
s = status -s
|
||||
|
||||
[init]
|
||||
defaultBranch = master
|
||||
|
||||
[push]
|
||||
autoSetupRemote = true
|
||||
|
||||
[pull]
|
||||
ff = only
|
|
@ -1,10 +0,0 @@
|
|||
anchor=top-right
|
||||
background-color=#1f1f28
|
||||
border-color=#54546d
|
||||
progress-color=#dcd7ba
|
||||
text-color=#dcd7ba
|
||||
border-size=1
|
||||
|
||||
default-timeout=4000
|
||||
|
||||
#font=APL386 Unicode
|
|
@ -1,144 +0,0 @@
|
|||
### Variables
|
||||
set $mod Mod4
|
||||
set $left h
|
||||
set $down j
|
||||
set $up k
|
||||
set $right l
|
||||
|
||||
set $term foot
|
||||
set $browser firefox
|
||||
set $lock swaylock
|
||||
set $rofi_cmd rofi -terminal '$term'
|
||||
set $menu $rofi_cmd -show combi -combi-modes drun#run -modes combi
|
||||
|
||||
input * {
|
||||
xkb_layout us
|
||||
xkb_options "compose:prsc"
|
||||
}
|
||||
|
||||
seat * hide_cursor when-typing enable
|
||||
|
||||
### Key bindings
|
||||
floating_modifier $mod normal
|
||||
|
||||
bindsym $mod+Return exec $term
|
||||
bindsym $mod+i exec $browser
|
||||
bindsym $mod+Shift+y exec $lock
|
||||
bindsym $mod+d exec $menu
|
||||
|
||||
bindsym $mod+z exec light -U 0.5
|
||||
bindsym $mod+x exec light -A 0.5
|
||||
bindsym $mod+Shift+z exec light -U 5
|
||||
bindsym $mod+Shift+x exec light -A 5
|
||||
|
||||
bindsym $mod+Shift+q kill
|
||||
bindsym $mod+Shift+c reload
|
||||
bindsym $mod+Shift+e exit
|
||||
|
||||
# Move your focus around
|
||||
bindsym $mod+$left focus left
|
||||
bindsym $mod+$down focus down
|
||||
bindsym $mod+$up focus up
|
||||
bindsym $mod+$right focus right
|
||||
|
||||
bindsym $mod+Left focus left
|
||||
bindsym $mod+Down focus down
|
||||
bindsym $mod+Up focus up
|
||||
bindsym $mod+Right focus right
|
||||
|
||||
bindsym $mod+Shift+$left move left
|
||||
bindsym $mod+Shift+$down move down
|
||||
bindsym $mod+Shift+$up move up
|
||||
bindsym $mod+Shift+$right move right
|
||||
|
||||
bindsym $mod+Shift+Left move left
|
||||
bindsym $mod+Shift+Down move down
|
||||
bindsym $mod+Shift+Up move up
|
||||
bindsym $mod+Shift+Right move right
|
||||
|
||||
bindsym $mod+1 workspace number 1
|
||||
bindsym $mod+2 workspace number 2
|
||||
bindsym $mod+3 workspace number 3
|
||||
bindsym $mod+4 workspace number 4
|
||||
bindsym $mod+5 workspace number 5
|
||||
bindsym $mod+6 workspace number 6
|
||||
bindsym $mod+7 workspace number 7
|
||||
bindsym $mod+8 workspace number 8
|
||||
bindsym $mod+9 workspace number 9
|
||||
bindsym $mod+0 workspace number 10
|
||||
|
||||
bindsym $mod+Shift+1 move container to workspace number 1
|
||||
bindsym $mod+Shift+2 move container to workspace number 2
|
||||
bindsym $mod+Shift+3 move container to workspace number 3
|
||||
bindsym $mod+Shift+4 move container to workspace number 4
|
||||
bindsym $mod+Shift+5 move container to workspace number 5
|
||||
bindsym $mod+Shift+6 move container to workspace number 6
|
||||
bindsym $mod+Shift+7 move container to workspace number 7
|
||||
bindsym $mod+Shift+8 move container to workspace number 8
|
||||
bindsym $mod+Shift+9 move container to workspace number 9
|
||||
bindsym $mod+Shift+0 move container to workspace number 10
|
||||
|
||||
bindsym $mod+o splith
|
||||
bindsym $mod+u splitv
|
||||
|
||||
bindsym $mod+s layout stacking
|
||||
bindsym $mod+t layout tabbed
|
||||
bindsym $mod+e layout toggle split
|
||||
|
||||
bindsym $mod+f fullscreen
|
||||
|
||||
bindsym $mod+Shift+space floating toggle
|
||||
bindsym $mod+space focus mode_toggle
|
||||
bindsym $mod+a focus parent
|
||||
|
||||
bindsym $mod+Shift+minus move scratchpad
|
||||
bindsym $mod+minus scratchpad show
|
||||
|
||||
bindsym $mod+Ctrl+$left grow left 10 px or 10 ppt
|
||||
bindsym $mod+Ctrl+$down grow down 10 px or 10 ppt
|
||||
bindsym $mod+Ctrl+$up grow up 10 px or 10 ppt
|
||||
bindsym $mod+Ctrl+$right grow right 10 px or 10 ppt
|
||||
|
||||
bindsym $mod+Ctrl+Left grow left 10 px or 10 ppt
|
||||
bindsym $mod+Ctrl+Down grow down 10 px or 10 ppt
|
||||
bindsym $mod+Ctrl+Up grow up 10 px or 10 ppt
|
||||
bindsym $mod+Ctrl+Right grow right 10 px or 10 ppt
|
||||
|
||||
set $accent #e96161
|
||||
|
||||
output * bg #e6e6e6 solid_color
|
||||
|
||||
gaps inner 12
|
||||
gaps left 8
|
||||
gaps right 8
|
||||
gaps bottom 8
|
||||
gaps top 0
|
||||
default_border normal 1
|
||||
font "APL386 Unicode 8"
|
||||
|
||||
for_window [title="."] title_format ""
|
||||
|
||||
client.focused $accent $accent $accent $accent $accent
|
||||
client.unfocused #5c5c5c #5c5c5c #5c5c5c #5c5c5c #5c5c5c
|
||||
client.focused_inactive #5c5c5c #5c5c5c #5c5c5c #5c5c5c #5c5c5c
|
||||
|
||||
for_window [title="^oyster$"] floating enable
|
||||
|
||||
# Status Bar:
|
||||
bar {
|
||||
position top
|
||||
gaps 16 20
|
||||
font "APL386 Unicode 8"
|
||||
|
||||
status_command ~/.config/sway/status_command
|
||||
|
||||
colors {
|
||||
background #ffffff
|
||||
statusline #000000
|
||||
focused_workspace $accent $accent #ffffff
|
||||
active_workspace #ffffff #ffffff #000000
|
||||
inactive_workspace #ffffff #ffffff #000000
|
||||
}
|
||||
}
|
||||
|
||||
include /etc/sway/config.d/*
|
|
@ -1,24 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
while :; do
|
||||
energy_full=0
|
||||
energy_now=0
|
||||
charging=
|
||||
|
||||
for bat in /sys/class/power_supply/*/capacity; do
|
||||
bat="${bat%/*}"
|
||||
read -r full <"$bat/energy_full"
|
||||
read -r now <"$bat/energy_now"
|
||||
energy_full=$((energy_full + full))
|
||||
energy_now=$((energy_now + now))
|
||||
done
|
||||
|
||||
if cat /sys/class/power_supply/*/status | grep -q Charging; then
|
||||
charging=+
|
||||
fi
|
||||
|
||||
percentage=$((energy_now * 100 / energy_full))
|
||||
|
||||
printf '%s %s ' "$charging$percentage%" "$(date +'%H:%M:%S')"
|
||||
sleep 1
|
||||
done
|
|
@ -1,16 +0,0 @@
|
|||
ignore-empty-password
|
||||
color=#ffffff
|
||||
key-hl-color=#3cc970
|
||||
bs-hl-color=#e96161
|
||||
caps-lock-key-hl-color=#3cc970
|
||||
caps-lock-bs-hl-color=#e96161
|
||||
inside-color=#ffffff
|
||||
inside-clear-color=#ffffff
|
||||
inside-caps-lock-color=#ffffff
|
||||
inside-ver-color=#ffffff
|
||||
inside-wrong-color=#ffffff
|
||||
ring-color=#ffffff
|
||||
ring-clear-color=#ffffff
|
||||
ring-caps-lock-color=#ffffff
|
||||
ring-ver-color=#ffffff
|
||||
ring-wrong-color=#ffffff
|
|
@ -1,11 +0,0 @@
|
|||
[Unit]
|
||||
Description=Fcitx is an input method framework with extension support.
|
||||
Documentation=https://fcitx-im.org/wiki/Fcitx_5
|
||||
|
||||
[Service]
|
||||
Type=exec
|
||||
Restart=always
|
||||
ExecStart=/usr/bin/fcitx5
|
||||
|
||||
[Install]
|
||||
WantedBy=graphical.target
|
|
@ -1 +0,0 @@
|
|||
set completion-ignore-case on
|
|
@ -1,16 +0,0 @@
|
|||
#TabsToolbar {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#nav-bar {
|
||||
background: #ffffff !important;
|
||||
}
|
||||
|
||||
#sidebar-splitter {
|
||||
background: #ffffff !important;
|
||||
width: 0 !important;
|
||||
}
|
||||
|
||||
#sidebar-header {
|
||||
display: none;
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
#[ "$PROFILE_LOADED_" ] && return
|
||||
#export PROFILE_LOADED_=1
|
||||
|
||||
export GTK_IM_MODULE=fcitx
|
||||
export QT_IM_MODULE=fcitx
|
||||
export XMODIFIERS=@im=fcitx
|
||||
|
||||
export PATH="$HOME/.local/bin:$HOME/.roswell/bin:$HOME/.cargo/bin:$PATH"
|
||||
export EDITOR=nvim
|
||||
|
||||
export CARGO_MOMMYS_MOODS="chill/thirsty/yikes/ominous"
|
30
fanya/default.nix
Normal file
30
fanya/default.nix
Normal file
|
@ -0,0 +1,30 @@
|
|||
{lib, ...}: let
|
||||
password = "$6$FHwMlUwmRdAsPqS4$4XND0L0EEVf2Mhc/tvo6y3ZLIrMTOlsIZrG3w69EeXvtVZhdeNyoDOkPNIe.GBB8.PrchuUKDacqbvcvyuPkt0";
|
||||
in {
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
# Don't change!
|
||||
system.stateVersion = "22.05";
|
||||
home-manager.users.buffet.home.stateVersion = "22.05";
|
||||
|
||||
users.users.buffet.hashedPassword = password;
|
||||
users.users.root.hashedPassword = password;
|
||||
|
||||
networking.hostName = "fanya";
|
||||
|
||||
services.tlp.enable = true;
|
||||
|
||||
home-manager.users.buffet = {
|
||||
programs.foot = let
|
||||
theme = import ../theme.nix;
|
||||
in {
|
||||
settings.main.font = lib.mkForce "${theme.font.family}:size=${toString (theme.font.size - 1)}";
|
||||
};
|
||||
|
||||
wayland.windowManager.sway = {
|
||||
config.gaps.inner = lib.mkForce 5;
|
||||
};
|
||||
};
|
||||
}
|
62
fanya/hardware-configuration.nix
Normal file
62
fanya/hardware-configuration.nix
Normal file
|
@ -0,0 +1,62 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "usb_storage" "sd_mod" "rtsx_pci_sdmmc"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-intel"];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/d2c87f01-cdb7-4871-ae9d-c3a843e1199d";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@"];
|
||||
};
|
||||
|
||||
fileSystems."/old" = {
|
||||
device = "/dev/disk/by-uuid/d2c87f01-cdb7-4871-ae9d-c3a843e1199d";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@old"];
|
||||
};
|
||||
|
||||
fileSystems."/persist" = {
|
||||
device = "/dev/disk/by-uuid/d2c87f01-cdb7-4871-ae9d-c3a843e1199d";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@persist"];
|
||||
};
|
||||
|
||||
fileSystems."/nix" = {
|
||||
device = "/dev/disk/by-uuid/d2c87f01-cdb7-4871-ae9d-c3a843e1199d";
|
||||
fsType = "btrfs";
|
||||
options = ["subvol=@nix"];
|
||||
};
|
||||
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/29E0-A9D9";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices = [
|
||||
{device = "/dev/disk/by-uuid/c7344d44-0e66-461d-ba99-a177a8efe982";}
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp0s25.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp3s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
367
flake.lock
Normal file
367
flake.lock
Normal file
|
@ -0,0 +1,367 @@
|
|||
{
|
||||
"nodes": {
|
||||
"agenix": {
|
||||
"inputs": {
|
||||
"darwin": "darwin",
|
||||
"home-manager": "home-manager",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1690228878,
|
||||
"narHash": "sha256-9Xe7JV0krp4RJC9W9W9WutZVlw6BlHTFMiUP/k48LQY=",
|
||||
"owner": "ryantm",
|
||||
"repo": "agenix",
|
||||
"rev": "d8c973fd228949736dedf61b7f8cc1ece3236792",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "ryantm",
|
||||
"repo": "agenix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"apl386": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1646646198,
|
||||
"narHash": "sha256-oHk4e7NRgAjGtZzQmZToYz7wCZETaj7/yRwZMeeYF2M=",
|
||||
"owner": "abrudz",
|
||||
"repo": "APL386",
|
||||
"rev": "6332c9dbb588946a0e8c9d7984dd0c003eeea266",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "abrudz",
|
||||
"repo": "APL386",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"cmp-conventionalcommits": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1665962366,
|
||||
"narHash": "sha256-PAEWX0U8qbBwC3DqfCrDDlTLoIRIlcbwS1eDu3yarTc=",
|
||||
"owner": "davidsierradz",
|
||||
"repo": "cmp-conventionalcommits",
|
||||
"rev": "a4dfacf0601130b7f8afa7c948d735c27802fb7f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "davidsierradz",
|
||||
"repo": "cmp-conventionalcommits",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"cmp-git": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1685409535,
|
||||
"narHash": "sha256-McIYDGXu+tSaY/U6eu1XouSHto/mSpJ/i4Z4UKYa+mk=",
|
||||
"owner": "petertriho",
|
||||
"repo": "cmp-git",
|
||||
"rev": "f900a4cf117300fdc3ba31d26f8b6223ccd9c574",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "petertriho",
|
||||
"repo": "cmp-git",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"copilot-cmp": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1683831407,
|
||||
"narHash": "sha256-+MzEGnhlrYRvAfskOwmw69OC1CsPXt7s3z+xPe9XPqs=",
|
||||
"owner": "zbirenbaum",
|
||||
"repo": "copilot-cmp",
|
||||
"rev": "c2cdb3c0f5078b0619055af192295830a7987790",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "zbirenbaum",
|
||||
"repo": "copilot-cmp",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"copilot-lua": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1691165896,
|
||||
"narHash": "sha256-lAj7LKVbxTnLUpjJeuPTT3JBo1LQJWffiZmTyU+Y5uw=",
|
||||
"owner": "zbirenbaum",
|
||||
"repo": "copilot.lua",
|
||||
"rev": "f306957de0f9730de4298bb1ea85c3735ef7cc43",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "zbirenbaum",
|
||||
"repo": "copilot.lua",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"darwin": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"agenix",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1673295039,
|
||||
"narHash": "sha256-AsdYgE8/GPwcelGgrntlijMg4t3hLFJFCRF3tL5WVjA=",
|
||||
"owner": "lnl7",
|
||||
"repo": "nix-darwin",
|
||||
"rev": "87b9d090ad39b25b2400029c64825fc2a8868943",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "lnl7",
|
||||
"ref": "master",
|
||||
"repo": "nix-darwin",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"fennel-ls": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1689863239,
|
||||
"narHash": "sha256-xPTgGmeILJSNsC++r9x+ussS7ttG7a5Cgl/D02auTgE=",
|
||||
"owner": "~xerool",
|
||||
"repo": "fennel-ls",
|
||||
"rev": "e7c642e12a15c6d452559414ee1890b30f4e8406",
|
||||
"type": "sourcehut"
|
||||
},
|
||||
"original": {
|
||||
"owner": "~xerool",
|
||||
"repo": "fennel-ls",
|
||||
"type": "sourcehut"
|
||||
}
|
||||
},
|
||||
"gh-nvim": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1682521998,
|
||||
"narHash": "sha256-R+vzppfF3AAAGAUdH1kEPpX7XjHowBlilWNJfHyzZ10=",
|
||||
"owner": "ldelossa",
|
||||
"repo": "gh.nvim",
|
||||
"rev": "2b5551656c1b896bf4ae06546eaaab00311f9a18",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "ldelossa",
|
||||
"repo": "gh.nvim",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"agenix",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1682203081,
|
||||
"narHash": "sha256-kRL4ejWDhi0zph/FpebFYhzqlOBrk0Pl3dzGEKSAlEw=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "32d3e39c491e2f91152c84f8ad8b003420eab0a1",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager_2": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1687871164,
|
||||
"narHash": "sha256-bBFlPthuYX322xOlpJvkjUBz0C+MOBjZdDOOJJ+G2jU=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "07c347bb50994691d7b0095f45ebd8838cf6bc38",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"ref": "release-23.05",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"impermanence": {
|
||||
"locked": {
|
||||
"lastModified": 1690797372,
|
||||
"narHash": "sha256-GImz19e33SeVcIvBB7NnhbJSbTpFFmNtWLh7Z85Y188=",
|
||||
"owner": "nix-community",
|
||||
"repo": "impermanence",
|
||||
"rev": "e3a7acd113903269a1b5c8b527e84ce7ee859851",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "impermanence",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1691305349,
|
||||
"narHash": "sha256-0Pig7jnmuRH3c5dOTVTOvTLwo2CRzYTyvJRQ82HWRSo=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "5426a95071d0b9782b3209b3995cde1f5689616e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"repo": "nixos-hardware",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1691328192,
|
||||
"narHash": "sha256-w59N1zyDQ7SupfMJLFvtms/SIVbdryqlw5AS4+DiH+Y=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "61676e4dcfeeb058f255294bcb08ea7f3bc3ce56",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-23.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-unstable": {
|
||||
"locked": {
|
||||
"lastModified": 1691368598,
|
||||
"narHash": "sha256-ia7li22keBBbj02tEdqjVeLtc7ZlSBuhUk+7XTUFr14=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "5a8e9243812ba528000995b294292d3b5e120947",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nur": {
|
||||
"locked": {
|
||||
"lastModified": 1691426742,
|
||||
"narHash": "sha256-NNyk6xL6E8lAI1wQ3ErzC4s+BOypXAZ+qPcyKNScxUQ=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NUR",
|
||||
"rev": "33fc23d321725093266f69e0f948a27adf02c0b8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "NUR",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nvim-cmp-vlime": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1672313103,
|
||||
"narHash": "sha256-ejjJWNGjx28viKz8tsaifCkJ9HHYAOkbOZAdlR8gQJo=",
|
||||
"owner": "HiPhish",
|
||||
"repo": "nvim-cmp-vlime",
|
||||
"rev": "5bc7fa02f255f6faed0ba5fda5f4883b46a66676",
|
||||
"type": "gitlab"
|
||||
},
|
||||
"original": {
|
||||
"owner": "HiPhish",
|
||||
"repo": "nvim-cmp-vlime",
|
||||
"type": "gitlab"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"agenix": "agenix",
|
||||
"apl386": "apl386",
|
||||
"cmp-conventionalcommits": "cmp-conventionalcommits",
|
||||
"cmp-git": "cmp-git",
|
||||
"copilot-cmp": "copilot-cmp",
|
||||
"copilot-lua": "copilot-lua",
|
||||
"fennel-ls": "fennel-ls",
|
||||
"gh-nvim": "gh-nvim",
|
||||
"home-manager": "home-manager_2",
|
||||
"impermanence": "impermanence",
|
||||
"nixos-hardware": "nixos-hardware",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs-unstable": "nixpkgs-unstable",
|
||||
"nur": "nur",
|
||||
"nvim-cmp-vlime": "nvim-cmp-vlime",
|
||||
"rust-tools-nvim": "rust-tools-nvim",
|
||||
"vim-hy": "vim-hy",
|
||||
"vlime": "vlime"
|
||||
}
|
||||
},
|
||||
"rust-tools-nvim": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1689033186,
|
||||
"narHash": "sha256-jtfyDxifchznUupLSao6nmpVqaX1yO0xN+NhqS9fgxg=",
|
||||
"owner": "simrat39",
|
||||
"repo": "rust-tools.nvim",
|
||||
"rev": "0cc8adab23117783a0292a0c8a2fbed1005dc645",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "simrat39",
|
||||
"repo": "rust-tools.nvim",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"vim-hy": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1688564453,
|
||||
"narHash": "sha256-FwVWUxC4T0qCz/4XgBv8BsUsD+nsOb9g2hQXqVGlQuA=",
|
||||
"owner": "hylang",
|
||||
"repo": "vim-hy",
|
||||
"rev": "dbd001668db9deae19a8f631a38a9d96ef441c27",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hylang",
|
||||
"repo": "vim-hy",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"vlime": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1688286786,
|
||||
"narHash": "sha256-t96BZl2qEnFYPnXnVNRUUI2vICdz/0lnnmw+LT0PzLU=",
|
||||
"owner": "vlime",
|
||||
"repo": "vlime",
|
||||
"rev": "c1ac16c1a50bec4c30da87cd4ce2af12e26fb022",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "vlime",
|
||||
"repo": "vlime",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
110
flake.nix
Normal file
110
flake.nix
Normal file
|
@ -0,0 +1,110 @@
|
|||
{
|
||||
inputs = {
|
||||
impermanence.url = "github:nix-community/impermanence";
|
||||
nixos-hardware.url = "github:NixOS/nixos-hardware";
|
||||
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05";
|
||||
nur.url = "github:nix-community/NUR";
|
||||
|
||||
agenix = {
|
||||
url = "github:ryantm/agenix";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
apl386 = {
|
||||
url = "github:abrudz/APL386";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
cmp-conventionalcommits = {
|
||||
url = "github:davidsierradz/cmp-conventionalcommits";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
cmp-git = {
|
||||
url = "github:petertriho/cmp-git";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
copilot-cmp = {
|
||||
url = "github:zbirenbaum/copilot-cmp";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
copilot-lua = {
|
||||
url = "github:zbirenbaum/copilot.lua";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
fennel-ls = {
|
||||
url = "sourcehut:~xerool/fennel-ls";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
gh-nvim = {
|
||||
url = "github:ldelossa/gh.nvim";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager/release-23.05";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
nvim-cmp-vlime = {
|
||||
url = "gitlab:HiPhish/nvim-cmp-vlime";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
# work around for nixpkgs version being too old
|
||||
rust-tools-nvim = {
|
||||
url = "github:simrat39/rust-tools.nvim";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
vim-hy = {
|
||||
url = "github:hylang/vim-hy";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
vlime = {
|
||||
url = "github:vlime/vlime";
|
||||
flake = false;
|
||||
};
|
||||
};
|
||||
|
||||
outputs = {
|
||||
agenix,
|
||||
home-manager,
|
||||
nur,
|
||||
nixpkgs-unstable,
|
||||
nixpkgs,
|
||||
...
|
||||
} @ args: {
|
||||
nixosConfigurations = let
|
||||
mkSystem = system: module:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
inherit system;
|
||||
specialArgs = args;
|
||||
modules = let
|
||||
overlay-unstable = final: prev: {
|
||||
unstable = nixpkgs-unstable.legacyPackages.${prev.system};
|
||||
};
|
||||
in [
|
||||
module
|
||||
|
||||
agenix.nixosModules.default
|
||||
home-manager.nixosModule
|
||||
nur.nixosModules.nur
|
||||
./common.nix
|
||||
./impermanence.nix
|
||||
./system.nix
|
||||
(_: {nixpkgs.overlays = [(import ./overlay args) overlay-unstable];})
|
||||
];
|
||||
};
|
||||
in {
|
||||
alice = mkSystem "x86_64-linux" ./alice;
|
||||
fanya = mkSystem "x86_64-linux" ./fanya;
|
||||
};
|
||||
};
|
||||
}
|
83
impermanence.nix
Normal file
83
impermanence.nix
Normal file
|
@ -0,0 +1,83 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
impermanence,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
"${impermanence}/nixos.nix"
|
||||
];
|
||||
|
||||
environment.persistence."/persist/system" = {
|
||||
directories = [
|
||||
"/etc/NetworkManager/system-connections"
|
||||
"/etc/nixos"
|
||||
"/root/.ssh"
|
||||
"/srv"
|
||||
"/var/lib/bluetooth"
|
||||
"/var/lib/docker"
|
||||
"/var/lib/machines"
|
||||
"/var/lib/portables"
|
||||
"/var/log"
|
||||
];
|
||||
|
||||
files = [];
|
||||
};
|
||||
|
||||
programs.fuse.userAllowOther = true; # required for allowOther
|
||||
home-manager.users.buffet = {
|
||||
imports = [
|
||||
"${impermanence}/home-manager.nix"
|
||||
];
|
||||
|
||||
home.persistence."/persist/buffet" = {
|
||||
removePrefixDirectory = true;
|
||||
allowOther = true;
|
||||
|
||||
directories = [
|
||||
"anki/.local/share/Anki"
|
||||
"anki/.local/share/Anki2"
|
||||
"crev/.local/share/crev"
|
||||
"data/books"
|
||||
"data/docs"
|
||||
"data/git"
|
||||
"data/proj"
|
||||
"data/reminders"
|
||||
"data/rice"
|
||||
"data/uni"
|
||||
"direnv/.local/share/direnv"
|
||||
"firefox/.cache/mozilla"
|
||||
"firefox/.mozilla"
|
||||
"gpg/.gnupg"
|
||||
"newsboat/.local/share/newsboat"
|
||||
"ssh/.ssh"
|
||||
"trash/.local/share/Trash"
|
||||
];
|
||||
|
||||
files = [
|
||||
"bash/.bash_history"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
fileSystems."/persist".neededForBoot = true;
|
||||
|
||||
boot = {
|
||||
supportedFilesystems = ["btrfs"];
|
||||
|
||||
# recreate the root subvolume at boot
|
||||
initrd.postDeviceCommands = lib.mkBefore ''
|
||||
echo "recreating root subvolume..."
|
||||
mkdir -p /mnt
|
||||
mount ${config.fileSystems."/".device} /mnt
|
||||
btrfs subvolume delete /mnt/@old
|
||||
mv /mnt/@ /mnt/@old
|
||||
btrfs subvolume create /mnt/@
|
||||
umount /mnt
|
||||
echo "done recreating subvolume"
|
||||
'';
|
||||
};
|
||||
|
||||
# workaround for agenix running before /etc impermanence gets set up
|
||||
age.identityPaths = ["/persist/buffet/ssh/.ssh/id_agenix"];
|
||||
}
|
26
overlay/apl386/default.nix
Normal file
26
overlay/apl386/default.nix
Normal file
|
@ -0,0 +1,26 @@
|
|||
{
|
||||
inputs,
|
||||
lib,
|
||||
stdenvNoCC,
|
||||
}:
|
||||
stdenvNoCC.mkDerivation {
|
||||
name = "apl386";
|
||||
|
||||
src = inputs.apl386;
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
install -Dm644 APL386.ttf -t $out/share/fonts/apl386
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "APL385 Unicode font evolved ";
|
||||
homepage = "https://github.com/abrudz/APL386";
|
||||
license = licenses.unlicense;
|
||||
maintainers = with maintainers; [buffet];
|
||||
platforms = platforms.all;
|
||||
};
|
||||
}
|
6
overlay/default.nix
Normal file
6
overlay/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
inputs: self: super: {
|
||||
inherit inputs;
|
||||
|
||||
apl386 = super.callPackage ./apl386 {};
|
||||
fennel-ls = super.callPackage ./fennel-ls {};
|
||||
}
|
25
overlay/fennel-ls/default.nix
Normal file
25
overlay/fennel-ls/default.nix
Normal file
|
@ -0,0 +1,25 @@
|
|||
{
|
||||
inputs,
|
||||
lib,
|
||||
stdenvNoCC,
|
||||
lua,
|
||||
luaPackages,
|
||||
}:
|
||||
stdenvNoCC.mkDerivation {
|
||||
name = "fennel-ls";
|
||||
|
||||
src = inputs.fennel-ls;
|
||||
|
||||
nativeBuildInputs = [luaPackages.fennel];
|
||||
buildInputs = [lua];
|
||||
|
||||
makeFlags = ["PREFIX=$(out)"];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A language server for fennel-ls.";
|
||||
homepage = "https://git.sr.ht/~xerool/fennel-ls";
|
||||
license = licenses.mit;
|
||||
platforms = lua.meta.platforms;
|
||||
maintainers = with maintainers; [buffet];
|
||||
};
|
||||
}
|
47
programs/bash.nix
Normal file
47
programs/bash.nix
Normal file
|
@ -0,0 +1,47 @@
|
|||
{pkgs, ...}: let
|
||||
inputrc = pkgs.writeText "inputrc" ''
|
||||
set completion-ignore-case on
|
||||
'';
|
||||
in {
|
||||
home-manager.users.buffet = {
|
||||
home.sessionVariables = {
|
||||
INPUTRC = inputrc;
|
||||
};
|
||||
|
||||
programs.bash = {
|
||||
enable = true;
|
||||
historyControl = ["erasedups" "ignorespace"];
|
||||
|
||||
shellAliases = {
|
||||
"cd.." = "cd ..";
|
||||
ch = "ssh -t irc.buffet.sh -- screen -r weechat";
|
||||
htop = "htop -t";
|
||||
mkdir = "mkdir -p";
|
||||
rg = "rg -S";
|
||||
update = let
|
||||
change-message = pkgs.writeScript "change-commit-message" ''
|
||||
#!/bin/sh
|
||||
sed -i '1s/.*/chore: update/' "$1"
|
||||
'';
|
||||
in "nix flake update --commit-lock-file && EDITOR=${change-message} git commit --amend";
|
||||
};
|
||||
|
||||
shellOptions = [
|
||||
"cdspell"
|
||||
"checkjobs"
|
||||
"extglob"
|
||||
"globstar"
|
||||
"histappend"
|
||||
"nocaseglob"
|
||||
];
|
||||
|
||||
initExtra = ''
|
||||
PS0='\[\e[0m\]'
|
||||
PS1='\[\e[1m\] '
|
||||
|
||||
bind '"\C-o": "\C-a\C-k fg; if [[ $? == 1 ]]; then nvim; fi\n"'
|
||||
bind '"\e\C-m": "\C-e | nvim\C-m"'
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
49
programs/borg.nix
Normal file
49
programs/borg.nix
Normal file
|
@ -0,0 +1,49 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
host = "11967@prio.ch-s011.rsync.net";
|
||||
in {
|
||||
age.secrets.borgpassword.file = ../secrets/borgpassword.age;
|
||||
|
||||
services.borgbackup = {
|
||||
jobs.backup = {
|
||||
paths = ["/persist"];
|
||||
exclude = ["/persist/system/var/log"];
|
||||
repo = "${host}:${config.networking.hostName}";
|
||||
encryption = {
|
||||
mode = "repokey";
|
||||
passCommand = "cat ${config.age.secrets.borgpassword.path}";
|
||||
};
|
||||
startAt = "daily";
|
||||
persistentTimer = true;
|
||||
environment.BORG_RSH = "ssh -i /home/buffet/.ssh/id_borg";
|
||||
extraArgs = "--remote-path borg1";
|
||||
prune.keep = {
|
||||
within = "1d";
|
||||
daily = 7;
|
||||
weekly = 4;
|
||||
monthly = -1;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services = {
|
||||
borgbackup-job-backup = {
|
||||
after = ["ensure-online.service"];
|
||||
requires = ["ensure-online.service"];
|
||||
};
|
||||
|
||||
ensure-online = {
|
||||
description = "waiting for Network";
|
||||
after = ["network-online.target"];
|
||||
requires = ["network-online.target"];
|
||||
|
||||
serviceConfig = {
|
||||
ExecStart = "${pkgs.networkmanager}/bin/nm-online -q --timeout=300";
|
||||
Type = "oneshot";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
9
programs/cargo.nix
Normal file
9
programs/cargo.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{pkgs, ...}: {
|
||||
home-manager.users.buffet = {
|
||||
home.file.".cargo/config.toml".text = ''
|
||||
[target.x86_64-unknown-linux-gnu]
|
||||
linker = "${pkgs.clang}/bin/clang"
|
||||
rustflags = ["-C", "link-arg=-fuse-ld=${pkgs.mold}/bin/mold"]
|
||||
'';
|
||||
};
|
||||
}
|
37
programs/firefox.nix
Normal file
37
programs/firefox.nix
Normal file
|
@ -0,0 +1,37 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
home-manager.users.buffet = {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
package = pkgs.firefox-wayland;
|
||||
|
||||
profiles."buffet" = {
|
||||
extensions = with config.nur.repos.rycee.firefox-addons; [
|
||||
config.nur.repos.rycee.firefox-addons."10ten-ja-reader"
|
||||
bitwarden
|
||||
clearurls
|
||||
decentraleyes
|
||||
fediact
|
||||
istilldontcareaboutcookies
|
||||
refined-github
|
||||
sidebery
|
||||
ublock-origin
|
||||
];
|
||||
|
||||
settings = {
|
||||
"toolkit.legacyUserProfileCustomizations.stylesheets" = true;
|
||||
};
|
||||
|
||||
userChrome = ''
|
||||
#TabsToolbar {
|
||||
visibility: collapse !important;
|
||||
}
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
55
programs/foot.nix
Normal file
55
programs/foot.nix
Normal file
|
@ -0,0 +1,55 @@
|
|||
{lib, ...}: {
|
||||
home-manager.users.buffet = {
|
||||
programs.foot = {
|
||||
enable = true;
|
||||
server.enable = true;
|
||||
|
||||
settings = let
|
||||
theme = import ../theme.nix;
|
||||
dehash = lib.attrsets.mapAttrs (_: lib.strings.removePrefix "#");
|
||||
normal = dehash theme.normal;
|
||||
bright = dehash theme.bright;
|
||||
in {
|
||||
main = {
|
||||
font = "${theme.font.family}:size=${toString (theme.font.size - 2)}";
|
||||
#font-italic = "${theme.font.family}:size=${toString (theme.font.size - 2)}";
|
||||
#font-bold-italic = "${theme.font.family}:style=Bold:size=${toString (theme.font.size - 2)}";
|
||||
pad = "${toString theme.font.size}x${toString theme.font.size}";
|
||||
};
|
||||
|
||||
scrollback.lines = 10000;
|
||||
|
||||
url = {
|
||||
launch = ''firefox ''${url}'';
|
||||
};
|
||||
|
||||
key-bindings = {
|
||||
show-urls-launch = "Control+Shift+l";
|
||||
};
|
||||
|
||||
colors = {
|
||||
foreground = lib.strings.removePrefix "#" theme.primary.foreground;
|
||||
background = lib.strings.removePrefix "#" theme.primary.background;
|
||||
|
||||
regular0 = normal.black;
|
||||
regular1 = normal.red;
|
||||
regular2 = normal.green;
|
||||
regular3 = normal.yellow;
|
||||
regular4 = normal.blue;
|
||||
regular5 = normal.magenta;
|
||||
regular6 = normal.cyan;
|
||||
regular7 = normal.white;
|
||||
|
||||
bright0 = bright.black;
|
||||
bright1 = bright.red;
|
||||
bright2 = bright.green;
|
||||
bright3 = bright.yellow;
|
||||
bright4 = bright.blue;
|
||||
bright5 = bright.magenta;
|
||||
bright6 = bright.cyan;
|
||||
bright7 = bright.white;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
51
programs/git.nix
Normal file
51
programs/git.nix
Normal file
|
@ -0,0 +1,51 @@
|
|||
_: {
|
||||
home-manager.users.buffet = {
|
||||
programs.git = {
|
||||
enable = true;
|
||||
userEmail = "dev@buffet.sh";
|
||||
userName = "buffet";
|
||||
difftastic = {
|
||||
enable = true;
|
||||
background =
|
||||
if (import ../theme.nix).light
|
||||
then "light"
|
||||
else "dark";
|
||||
};
|
||||
|
||||
aliases = {
|
||||
a = "add";
|
||||
b = "branch";
|
||||
c = "commit --verbose";
|
||||
m = "commit --amend --verbose";
|
||||
|
||||
d = "diff";
|
||||
ds = "diff --stat";
|
||||
dc = "diff --cached";
|
||||
|
||||
l = "log";
|
||||
s = "status -s";
|
||||
co = "checkout";
|
||||
cob = "checkout -b";
|
||||
};
|
||||
|
||||
signing = {
|
||||
key = "EBAC355935FD7382";
|
||||
signByDefault = true;
|
||||
};
|
||||
|
||||
extraConfig = {
|
||||
init = {
|
||||
defaultBranch = "master";
|
||||
};
|
||||
|
||||
push = {
|
||||
autoSetupRemote = true;
|
||||
};
|
||||
|
||||
pull = {
|
||||
ff = "only";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
11
programs/gpg.nix
Normal file
11
programs/gpg.nix
Normal file
|
@ -0,0 +1,11 @@
|
|||
{pkgs, ...}: {
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
pinentryFlavor = "curses";
|
||||
};
|
||||
|
||||
home-manager.users.buffet = {
|
||||
programs.gpg.enable = true;
|
||||
};
|
||||
}
|
12
programs/ime.nix
Normal file
12
programs/ime.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{pkgs, ...}: {
|
||||
home-manager.users.buffet = {
|
||||
i18n.inputMethod = {
|
||||
enabled = "fcitx5";
|
||||
fcitx5.addons = with pkgs; [
|
||||
fcitx5-configtool
|
||||
fcitx5-gtk
|
||||
fcitx5-mozc
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
19
programs/keyd.nix
Normal file
19
programs/keyd.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
_: {
|
||||
services.keyd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
"capslock" = "overload(control, esc)";
|
||||
"esc" = "capslock";
|
||||
"rightalt" = "layer(symbols)";
|
||||
};
|
||||
|
||||
symbols = {
|
||||
"h" = "left";
|
||||
"j" = "down";
|
||||
"k" = "up";
|
||||
"l" = "right";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
8
programs/lsd.nix
Normal file
8
programs/lsd.nix
Normal file
|
@ -0,0 +1,8 @@
|
|||
_: {
|
||||
home-manager.users.buffet = {
|
||||
programs.lsd = {
|
||||
enable = true;
|
||||
enableAliases = true;
|
||||
};
|
||||
};
|
||||
}
|
21
programs/mako.nix
Normal file
21
programs/mako.nix
Normal file
|
@ -0,0 +1,21 @@
|
|||
{pkgs, ...}: {
|
||||
home-manager.users.buffet = {
|
||||
services.mako = let
|
||||
theme = import ../theme.nix;
|
||||
in {
|
||||
enable = true;
|
||||
|
||||
anchor = "top-right";
|
||||
|
||||
backgroundColor = theme.primary.background;
|
||||
borderColor = theme.wm.focused.border;
|
||||
progressColor = theme.primary.foreground;
|
||||
textColor = theme.primary.foreground;
|
||||
borderSize = 1;
|
||||
|
||||
defaultTimeout = 4000;
|
||||
|
||||
font = with theme; "${font.family} ${toString font.size}";
|
||||
};
|
||||
};
|
||||
}
|
32
programs/newsboat.nix
Normal file
32
programs/newsboat.nix
Normal file
|
@ -0,0 +1,32 @@
|
|||
{lib, ...}: {
|
||||
home-manager.users.buffet = {
|
||||
programs.newsboat = {
|
||||
enable = true;
|
||||
autoReload = true;
|
||||
|
||||
extraConfig = ''
|
||||
color listnormal black white
|
||||
color listfocus white yellow
|
||||
color listnormal_unread black white bold
|
||||
color listfocus_unread white yellow bold
|
||||
color title white blue bold
|
||||
color info yellow white bold
|
||||
color hint-key default white bold
|
||||
color hint-keys-delimiter default white
|
||||
color hint-separator default white bold
|
||||
color hint-description default white
|
||||
'';
|
||||
|
||||
urls = lib.mapAttrsToList (title: url: {inherit title url;}) {
|
||||
drew = "https://drewdevault.com/blog/index.xml";
|
||||
ducko = "https://goose.icu/index.xml";
|
||||
emersion = "https://emersion.fr/blog/atom.xml";
|
||||
fasterthanlime = "https://fasterthanli.me/index.xml";
|
||||
matklad = "https://matklad.github.io/feed.xml";
|
||||
neeasade = "https://notes.neeasade.net/rss_full.xml";
|
||||
sammyette = "https://sammy.is-a.dev/blog/index.xml";
|
||||
xkcd = "https://xkcd.com/rss.xml";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
559
programs/nvim.nix
Normal file
559
programs/nvim.nix
Normal file
|
@ -0,0 +1,559 @@
|
|||
{
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
} @ inputs: {
|
||||
# TODO: use some flake
|
||||
home-manager.users.buffet = {
|
||||
home.sessionVariables = {
|
||||
EDITOR = "nvim";
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
clang-tools
|
||||
fennel-ls
|
||||
nil
|
||||
rust-analyzer
|
||||
sumneko-lua-language-server
|
||||
];
|
||||
|
||||
programs.neovim = let
|
||||
leader = ",";
|
||||
in {
|
||||
enable = true;
|
||||
plugins = let
|
||||
buildPlugin = pname:
|
||||
pkgs.vimUtils.buildVimPluginFrom2Nix {
|
||||
inherit pname;
|
||||
version = "unknown";
|
||||
src = inputs."${pname}";
|
||||
};
|
||||
buildPlugins = names: lib.attrsets.genAttrs names buildPlugin;
|
||||
plugins = buildPlugins [
|
||||
"cmp-conventionalcommits"
|
||||
"cmp-git"
|
||||
"gh-nvim"
|
||||
"nvim-cmp-vlime"
|
||||
"rust-tools-nvim"
|
||||
"vim-hy"
|
||||
"vlime"
|
||||
];
|
||||
in
|
||||
with pkgs.vimPlugins;
|
||||
with plugins; [
|
||||
{plugin = cmp-buffer;}
|
||||
{plugin = cmp-calc;}
|
||||
{plugin = cmp-conventionalcommits;}
|
||||
{plugin = cmp-latex-symbols;}
|
||||
{plugin = cmp-nvim-lsp;}
|
||||
{plugin = cmp-path;}
|
||||
{plugin = cmp-treesitter;}
|
||||
{plugin = cmp-vsnip;}
|
||||
{plugin = editorconfig-nvim;}
|
||||
{plugin = fennel-vim;}
|
||||
{plugin = friendly-snippets;}
|
||||
{plugin = fugitive;}
|
||||
{plugin = lualine-lsp-progress;}
|
||||
{plugin = nvim-cmp-vlime;}
|
||||
{plugin = parinfer-rust;}
|
||||
{plugin = pest-vim;}
|
||||
{plugin = playground;}
|
||||
{plugin = rust-vim;}
|
||||
{plugin = tabular;}
|
||||
{plugin = vim-nix;}
|
||||
{plugin = vim-hy;}
|
||||
{plugin = vim-repeat;}
|
||||
{plugin = vlime;}
|
||||
|
||||
{
|
||||
plugin = cmp-git;
|
||||
config = "lua require 'cmp_git'.setup {}";
|
||||
}
|
||||
|
||||
{
|
||||
plugin = crates-nvim;
|
||||
config = ''
|
||||
lua require 'crates'.setup {}
|
||||
|
||||
nnoremap <silent> ${leader}ct :lua require('crates').toggle()<cr>
|
||||
nnoremap <silent> ${leader}cr :lua require('crates').reload()<cr>
|
||||
|
||||
nnoremap <silent> ${leader}cv :lua require('crates').show_versions_popup()<cr>
|
||||
nnoremap <silent> ${leader}cf :lua require('crates').show_features_popup()<cr>
|
||||
nnoremap <silent> ${leader}cd :lua require('crates').show_dependencies_popup()<cr>
|
||||
|
||||
nnoremap <silent> ${leader}cu :lua require('crates').update_crate()<cr>
|
||||
vnoremap <silent> ${leader}cu :lua require('crates').update_crates()<cr>
|
||||
nnoremap <silent> ${leader}ca :lua require('crates').update_all_crates()<cr>
|
||||
nnoremap <silent> ${leader}cU :lua require('crates').upgrade_crate()<cr>
|
||||
vnoremap <silent> ${leader}cU :lua require('crates').upgrade_crates()<cr>
|
||||
nnoremap <silent> ${leader}cA :lua require('crates').upgrade_all_crates()<cr>
|
||||
|
||||
nnoremap <silent> ${leader}cH :lua require('crates').open_homepage()<cr>
|
||||
nnoremap <silent> ${leader}cR :lua require('crates').open_repository()<cr>
|
||||
nnoremap <silent> ${leader}cD :lua require('crates').open_documentation()<cr>
|
||||
nnoremap <silent> ${leader}cC :lua require('crates').open_crates_io()<cr>
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = gh-nvim;
|
||||
config = ''
|
||||
lua <<EOF
|
||||
require 'litee.lib'.setup {}
|
||||
require 'litee.gh'.setup {}
|
||||
EOF
|
||||
|
||||
nnoremap <silent> ${leader}qcc :GHCloseCommit<cr>
|
||||
nnoremap <silent> ${leader}qce :GHExpandCommit<cr>
|
||||
nnoremap <silent> ${leader}qct :GHOpenToCommit<cr>
|
||||
nnoremap <silent> ${leader}qcp :GHPopOutCommit<cr>
|
||||
nnoremap <silent> ${leader}qcz :GHCollapseCommit<cr>
|
||||
|
||||
nnoremap <silent> ${leader}qip :GHPreviewIssue<cr>
|
||||
|
||||
nnoremap <silent> ${leader}qrb :GHStartReview<cr>
|
||||
nnoremap <silent> ${leader}qrc :GHCloseReview<cr>
|
||||
nnoremap <silent> ${leader}qrd :GHDeleteReview<cr>
|
||||
nnoremap <silent> ${leader}qre :GHExpandReview<cr>
|
||||
nnoremap <silent> ${leader}qrs :GHSubmitReview<cr>
|
||||
nnoremap <silent> ${leader}qrz :GHCollapseReview<cr>
|
||||
|
||||
nnoremap <silent> ${leader}qpc :GHClosePR<cr>
|
||||
nnoremap <silent> ${leader}qpd :GHPRDetails<cr>
|
||||
nnoremap <silent> ${leader}qpe :GHExpandPR<cr>
|
||||
nnoremap <silent> ${leader}qpo :GHOpenPR<cr>
|
||||
nnoremap <silent> ${leader}qpp :GHPopOutPR<cr>
|
||||
nnoremap <silent> ${leader}qpr :GHRefreshPR<cr>
|
||||
nnoremap <silent> ${leader}qpt :GHOpenToPR<cr>
|
||||
nnoremap <silent> ${leader}qpz :GHCollapsePR<cr>
|
||||
|
||||
nnoremap <silent> ${leader}qtc :GHCreateThread<cr>
|
||||
nnoremap <silent> ${leader}qtn :GHNextThread<cr>
|
||||
nnoremap <silent> ${leader}qt :GHToggleThread<cr>
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = gitsigns-nvim;
|
||||
config = ''
|
||||
lua <<EOF
|
||||
require 'gitsigns'.setup {
|
||||
signs = {
|
||||
add = { text = '┆' },
|
||||
change = { text = '┆' },
|
||||
},
|
||||
}
|
||||
EOF
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = litee-nvim;
|
||||
config = ''
|
||||
lua require 'litee.lib'.setup {}
|
||||
|
||||
nnoremap <silent> ${leader}lt :LTPanel<cr>
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = litee-calltree-nvim;
|
||||
config = ''
|
||||
lua require 'litee.calltree'.setup {}
|
||||
|
||||
nnoremap <silent> ${leader}lci :lua vim.lsp.buf.incoming_calls()<cr>
|
||||
nnoremap <silent> ${leader}lco :lua vim.lsp.buf.outgoing_calls()<cr>
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = litee-symboltree-nvim;
|
||||
config = ''
|
||||
lua require 'litee.symboltree'.setup {}
|
||||
|
||||
nnoremap <silent> ${leader}ls :lua vim.lsp.buf.document_symbol()<cr>
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = lualine-nvim;
|
||||
config = ''
|
||||
lua <<EOF
|
||||
require 'lualine'.setup {
|
||||
options = {
|
||||
icons_enabled = true,
|
||||
theme = 'auto',
|
||||
component_separators = {left = ''', right = '''},
|
||||
section_separators = {left = ''', right = '''},
|
||||
disabled_filetypes = {
|
||||
statusline = {},
|
||||
winbar = {},
|
||||
},
|
||||
ignore_focus = {},
|
||||
always_divide_middle = true,
|
||||
globalstatus = false,
|
||||
refresh = {
|
||||
statusline = 1000,
|
||||
tabline = 1000,
|
||||
winbar = 1000,
|
||||
}
|
||||
},
|
||||
sections = {
|
||||
lualine_a = {'mode'},
|
||||
lualine_b = {'diff', 'diagnostics'},
|
||||
lualine_c = {
|
||||
'filename',
|
||||
{
|
||||
'lsp_progress',
|
||||
display_components = {'lsp_client_name', 'spinner'},
|
||||
spinner_symbols = {'⠋', '⠙', '⠸', '⠴', '⠦', '⠇'},
|
||||
timer = {spinner = '75'}
|
||||
}
|
||||
},
|
||||
lualine_x = {'encoding', 'fileformat', 'filetype'},
|
||||
lualine_y = {'progress'},
|
||||
lualine_z = {'location'}
|
||||
},
|
||||
inactive_sections = {
|
||||
lualine_a = {},
|
||||
lualine_b = {},
|
||||
lualine_c = {'filename'},
|
||||
lualine_x = {'location'},
|
||||
lualine_y = {},
|
||||
lualine_z = {}
|
||||
},
|
||||
tabline = {},
|
||||
winbar = {},
|
||||
inactive_winbar = {},
|
||||
extensions = {}
|
||||
}
|
||||
EOF
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = kanagawa-nvim;
|
||||
config = ''
|
||||
colorscheme kanagawa
|
||||
lua <<EOF
|
||||
local colors = require 'kanagawa.colors'.setup();
|
||||
|
||||
require 'kanagawa'.setup {
|
||||
overrides = {
|
||||
EndOfBuffer = { fg = colors.waveBlue2 },
|
||||
},
|
||||
}
|
||||
EOF
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = lspsaga-nvim;
|
||||
config = ''
|
||||
lua require 'lspsaga'.init_lsp_saga()
|
||||
|
||||
nnoremap <silent> ${leader}a :Lspsaga code_action<cr>
|
||||
nnoremap <silent> ${leader}r :Lspsaga rename<cr>
|
||||
nnoremap <silent> gd :lua vim.lsp.buf.definition()<cr>
|
||||
nnoremap <silent> gD :lua vim.lsp.buf.declaration()<cr>
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = nvim-cmp;
|
||||
config = ''
|
||||
set completeopt=menu,menuone,noselect
|
||||
|
||||
lua <<EOF
|
||||
local cmp = require 'cmp'
|
||||
|
||||
cmp.setup {
|
||||
snippet = {
|
||||
expand = function(args)
|
||||
vim.fn["vsnip#anonymous"](args.body)
|
||||
end,
|
||||
},
|
||||
window = {
|
||||
completion = cmp.config.window.bordered(),
|
||||
documentation = cmp.config.window.bordered(),
|
||||
},
|
||||
mapping = {
|
||||
['<tab>'] = cmp.mapping.confirm({ select = true }),
|
||||
['<c-p>'] = cmp.mapping.select_prev_item(select_opts),
|
||||
['<c-n>'] = cmp.mapping.select_next_item(select_opts),
|
||||
['<c-d>'] = cmp.mapping.scroll_docs(4),
|
||||
['<c-u>'] = cmp.mapping.scroll_docs(-4),
|
||||
['<c-e>'] = cmp.mapping.abort(),
|
||||
},
|
||||
sources = cmp.config.sources {
|
||||
{ name = 'buffer' },
|
||||
{ name = 'calc' },
|
||||
{ name = 'conventionalcommits' },
|
||||
{ name = 'crates' },
|
||||
{ name = 'git' },
|
||||
{ name = 'latex_symbols' },
|
||||
{ name = 'nvim_lsp' },
|
||||
{ name = 'path' },
|
||||
{ name = 'treesitter' },
|
||||
{ name = 'vlime' },
|
||||
{ name = 'vsnip' },
|
||||
},
|
||||
}
|
||||
EOF
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = nvim-dap;
|
||||
config = ''
|
||||
nnoremap <silent> <f5> <cmd>lua require 'dap'.continue()<cr>
|
||||
nnoremap <silent> <f10> <cmd>lua require 'dap'.step_over()<cr>
|
||||
nnoremap <silent> <f11> <cmd>lua require 'dap'.step_into()<cr>
|
||||
nnoremap <silent> <f12> <cmd>lua require 'dap'.step_out()<cr>
|
||||
nnoremap <silent> ${leader}db <cmd>lua require'dap'.toggle_breakpoint()<cr>
|
||||
nnoremap <silent> ${leader}dB <cmd>lua require'dap'.set_breakpoint(vim.fn.input('Breakpoint condition: '))<cr>
|
||||
nnoremap <silent> ${leader}dr <cmd>lua require'dap'.repl.open()<cr>
|
||||
nnoremap <silent> ${leader}dl <cmd>lua require'dap'.run_last()<cr>
|
||||
|
||||
lua <<EOF
|
||||
local dap = require 'dap'
|
||||
|
||||
dap.adapters.lldb = {
|
||||
type = 'executable',
|
||||
command = '${pkgs.lldb}/bin/lldb-vscode',
|
||||
name = 'lldb',
|
||||
}
|
||||
|
||||
local lldb = {
|
||||
name = 'Launch lldb',
|
||||
type = 'lldb',
|
||||
request = 'launch',
|
||||
program = function()
|
||||
return vim.fn.input('Path to executable: ', vim.fn.getcwd() .. '/', 'file')
|
||||
end,
|
||||
cwd = "''${workspaceFolder}",
|
||||
stopOnEntry = false,
|
||||
runInTerminal = true,
|
||||
args = {},
|
||||
}
|
||||
|
||||
dap.configurations.rust = { lldb }
|
||||
EOF
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = nvim-dap-ui;
|
||||
config = ''
|
||||
lua require 'dapui'.setup()
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = nvim-dap-virtual-text;
|
||||
config = ''
|
||||
lua <<EOF
|
||||
require 'nvim-dap-virtual-text'.setup {
|
||||
commented = true,
|
||||
}
|
||||
EOF
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = nvim-hlslens;
|
||||
config = ''
|
||||
lua require 'hlslens'.setup {}
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = nvim-lspconfig;
|
||||
config = let
|
||||
configure = srv: ''
|
||||
lspconfig.${srv}.setup {
|
||||
capabilities = caps,
|
||||
}
|
||||
'';
|
||||
servers = [
|
||||
"clangd"
|
||||
"fennel_ls"
|
||||
"gopls"
|
||||
"lua_ls"
|
||||
"nil_ls"
|
||||
"rust_analyzer"
|
||||
];
|
||||
serverConfigs = lib.strings.concatStringsSep "\n" (builtins.map configure servers);
|
||||
in ''
|
||||
lua <<EOF
|
||||
local lspconfig = require 'lspconfig'
|
||||
local caps = require 'cmp_nvim_lsp'.default_capabilities(
|
||||
vim.lsp.protocol.make_client_capabilities()
|
||||
)
|
||||
${serverConfigs}
|
||||
EOF
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = nvim-treesitter.withPlugins (plugins:
|
||||
with plugins; [
|
||||
tree-sitter-bash
|
||||
tree-sitter-bibtex
|
||||
tree-sitter-c
|
||||
tree-sitter-c-sharp
|
||||
tree-sitter-clojure
|
||||
tree-sitter-cmake
|
||||
tree-sitter-comment
|
||||
tree-sitter-commonlisp
|
||||
tree-sitter-cpp
|
||||
tree-sitter-css
|
||||
tree-sitter-devicetree
|
||||
tree-sitter-dockerfile
|
||||
tree-sitter-dot
|
||||
tree-sitter-fennel
|
||||
tree-sitter-glsl
|
||||
tree-sitter-go
|
||||
tree-sitter-java
|
||||
tree-sitter-javascript
|
||||
tree-sitter-json
|
||||
tree-sitter-latex
|
||||
tree-sitter-llvm
|
||||
tree-sitter-lua
|
||||
tree-sitter-make
|
||||
tree-sitter-markdown
|
||||
tree-sitter-markdown-inline
|
||||
tree-sitter-nix
|
||||
tree-sitter-perl
|
||||
tree-sitter-python
|
||||
tree-sitter-regex
|
||||
tree-sitter-rst
|
||||
tree-sitter-rust
|
||||
tree-sitter-sql
|
||||
tree-sitter-scheme
|
||||
tree-sitter-svelte
|
||||
tree-sitter-toml
|
||||
tree-sitter-typescript
|
||||
tree-sitter-vim
|
||||
tree-sitter-yaml
|
||||
tree-sitter-zig
|
||||
]);
|
||||
config = ''
|
||||
lua <<EOF
|
||||
require 'nvim-treesitter.configs'.setup {
|
||||
highlight = {
|
||||
enable = true,
|
||||
additional_vim_regex_highlighting = false,
|
||||
},
|
||||
}
|
||||
EOF
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = rust-tools-nvim;
|
||||
config = ''
|
||||
lua require 'rust-tools'.setup {}
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = telescope-nvim;
|
||||
config = ''
|
||||
nnoremap <silent> ${leader}f :Telescope find_files<cr>
|
||||
nnoremap <silent> ${leader}F :Telescope find_files hidden=true no_ignore=true<cr>
|
||||
nnoremap <silent> ${leader}g :Telescope live_grep<cr>
|
||||
nnoremap <silent> ${leader}b :Telescope buffers<cr>
|
||||
nnoremap <silent> ${leader}: :Telescope commands<cr>
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = trouble-nvim;
|
||||
config = ''
|
||||
nnoremap <silent> ${leader}t :TroubleToggle<cr>
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = vim-vsnip;
|
||||
config = ''
|
||||
imap <expr> <c-k> vsnip#jumpable(1) ? '<Plug>(vsnip-jump-next)' : '<Tab>'
|
||||
smap <expr> <c-k> vsnip#jumpable(1) ? '<Plug>(vsnip-jump-next)' : '<Tab>'
|
||||
imap <expr> <c-j> vsnip#jumpable(-1) ? '<Plug>(vsnip-jump-prev)' : '<S-Tab>'
|
||||
smap <expr> <c-j> vsnip#jumpable(-1) ? '<Plug>(vsnip-jump-prev)' : '<S-Tab>'
|
||||
'';
|
||||
}
|
||||
|
||||
{
|
||||
plugin = vimwiki;
|
||||
# TODO: vimwiki config
|
||||
}
|
||||
];
|
||||
|
||||
extraConfig = let
|
||||
theme = import ../theme.nix;
|
||||
in ''
|
||||
" keybinds
|
||||
let mapleader = "${leader}"
|
||||
let g:mapleader = "${leader}"
|
||||
|
||||
inoremap kj <esc>
|
||||
|
||||
vnoremap < <gv
|
||||
vnoremap > >gv
|
||||
|
||||
nnoremap <c-h> <c-w>h
|
||||
nnoremap <c-j> <c-w>j
|
||||
nnoremap <c-k> <c-w>k
|
||||
nnoremap <c-l> <c-w>l
|
||||
|
||||
nnoremap <leader>s :w<cr>
|
||||
|
||||
" misc
|
||||
set termguicolors
|
||||
set mouse=a
|
||||
set undofile
|
||||
set hidden
|
||||
set encoding=utf-8
|
||||
set hlsearch
|
||||
set incsearch
|
||||
set ignorecase
|
||||
set smartcase
|
||||
set lazyredraw
|
||||
set splitbelow
|
||||
set splitright
|
||||
set matchtime=2
|
||||
set showmatch
|
||||
set wrap
|
||||
set breakindent
|
||||
set nowritebackup
|
||||
set updatetime=250
|
||||
set colorcolumn=+1
|
||||
set cursorline
|
||||
set signcolumn=yes
|
||||
|
||||
set shiftwidth=4
|
||||
set tabstop=4
|
||||
set expandtab
|
||||
|
||||
set shiftround
|
||||
set autoindent
|
||||
set smartindent
|
||||
|
||||
highlight! ExtraWhitespace guibg=${theme.normal.red}
|
||||
match ExtraWhitespace /\s\+$/
|
||||
|
||||
autocmd FileType lisp setlocal shiftwidth=2 tabstop=2
|
||||
autocmd FileType c setlocal noexpandtab shiftwidth=8 tabstop=8
|
||||
|
||||
lua <<EOF
|
||||
vim.diagnostic.config {
|
||||
severity_sort = true,
|
||||
}
|
||||
EOF
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
9
programs/pipewire.nix
Normal file
9
programs/pipewire.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
_: {
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
jack.enable = true;
|
||||
pulse.enable = true;
|
||||
};
|
||||
}
|
14
programs/sbcl.nix
Normal file
14
programs/sbcl.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{pkgs, ...}: {
|
||||
home-manager.users.buffet = {
|
||||
home = {
|
||||
packages = with pkgs; [
|
||||
roswell
|
||||
sbcl
|
||||
];
|
||||
|
||||
file.".config/common-lisp/source-registry.conf.d/lisp.conf".text = ''
|
||||
(:include (:home "proj" "cl-proj.lisp"))
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
11
programs/senpai.nix
Normal file
11
programs/senpai.nix
Normal file
|
@ -0,0 +1,11 @@
|
|||
_: {
|
||||
home-manager.users.buffet = {
|
||||
programs.senpai = {
|
||||
enable = true;
|
||||
config = {
|
||||
addr = "irc.buffet.sh";
|
||||
nick = "buffet";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
11
programs/sioyek.nix
Normal file
11
programs/sioyek.nix
Normal file
|
@ -0,0 +1,11 @@
|
|||
_: {
|
||||
home-manager.users.buffet = {
|
||||
programs.sioyek = {
|
||||
enable = true;
|
||||
|
||||
#config = with import ../theme.nix; {
|
||||
# background_color = makeRgbFloat primary.background;
|
||||
#};
|
||||
};
|
||||
};
|
||||
}
|
224
programs/sway.nix
Normal file
224
programs/sway.nix
Normal file
|
@ -0,0 +1,224 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
# TODO: turn off primary selection
|
||||
programs.sway.enable = true;
|
||||
|
||||
home-manager.users.buffet = {
|
||||
wayland.windowManager.sway = {
|
||||
enable = true;
|
||||
wrapperFeatures.gtk = true;
|
||||
xwayland = false;
|
||||
|
||||
config = let
|
||||
browser = "firefox";
|
||||
mod = "Mod4";
|
||||
terminal = "foot";
|
||||
theme = import ../theme.nix;
|
||||
|
||||
makeWorkspaceBinds = num: let
|
||||
ws = toString num;
|
||||
in {
|
||||
"${mod}+${ws}" = "workspace ${ws}";
|
||||
"${mod}+Shift+${ws}" = "move container to workspace ${ws}";
|
||||
};
|
||||
|
||||
joinAttrSets = builtins.foldl' (x: y: x // y) {};
|
||||
|
||||
statusCommand = pkgs.writeScript "status_command" ''
|
||||
#!/bin/sh
|
||||
|
||||
while :; do
|
||||
energy_full=
|
||||
energy_now=
|
||||
charge=
|
||||
|
||||
for bat in /sys/class/power_supply/*/capacity; do
|
||||
bat="''${bat%/*}"
|
||||
read -r full < $bat/energy_full
|
||||
read -r now < $bat/energy_now
|
||||
energy_full=$((energy_full + full))
|
||||
energy_now=$((energy_now + now))
|
||||
done
|
||||
|
||||
if cat /sys/class/power_supply/*/status | grep -q Charging; then
|
||||
charge=+
|
||||
fi
|
||||
|
||||
if ${pkgs.mullvad}/bin/mullvad status | grep -q 'Connected to'; then
|
||||
mullvad='&'
|
||||
else
|
||||
mullvad=
|
||||
fi
|
||||
|
||||
printf '%s %s %s ' "$mullvad" "$charge$((energy_now * 100 / energy_full))%" "$(date +'%H:%M')"
|
||||
|
||||
sleep 3
|
||||
done
|
||||
'';
|
||||
in {
|
||||
modifier = mod;
|
||||
window.border = 1;
|
||||
focus.followMouse = true;
|
||||
fonts = {
|
||||
names = [theme.font.family];
|
||||
style = "Regular";
|
||||
size = theme.font.size * 1.0;
|
||||
};
|
||||
|
||||
gaps = {
|
||||
inner = 8;
|
||||
outer = 0;
|
||||
};
|
||||
|
||||
input."*" = {
|
||||
xkb_layout = "us";
|
||||
xkb_options = "compose:prsc";
|
||||
};
|
||||
|
||||
output."*" = {bg = "${theme.primary.background} solid_color";};
|
||||
|
||||
floating.titlebar = false;
|
||||
window.titlebar = false;
|
||||
|
||||
colors = with theme; rec {
|
||||
focused = rec {
|
||||
inherit (wm.focused) border text;
|
||||
inherit (primary) background;
|
||||
indicator = border;
|
||||
childBorder = border;
|
||||
};
|
||||
|
||||
unfocused = rec {
|
||||
inherit (wm.unfocused) border text;
|
||||
inherit (primary) background;
|
||||
indicator = border;
|
||||
childBorder = border;
|
||||
};
|
||||
|
||||
focusedInactive = unfocused;
|
||||
};
|
||||
|
||||
keybindings = let
|
||||
swaylockConf = pkgs.writeText "swaylock.conf" ''
|
||||
ignore-empty-password
|
||||
color=${theme.primary.background}
|
||||
bs-hl-color=${theme.normal.red}
|
||||
caps-lock-bs-hl-color=${theme.normal.red}
|
||||
caps-lock-key-hl-color=${theme.bright.green}
|
||||
inside-color=${theme.primary.background}
|
||||
inside-clear-color=${theme.normal.yellow}
|
||||
inside-caps-lock-color=${theme.primary.background}
|
||||
inside-ver-color=${theme.normal.blue}
|
||||
inside-wrong-color=${theme.normal.red}
|
||||
key-hl-color=${theme.bright.green}
|
||||
ring-color=${theme.normal.green}
|
||||
ring-clear-color=${theme.normal.yellow}
|
||||
ring-caps-lock-color=${theme.bright.yellow}
|
||||
ring-ver-color=${theme.bright.blue}
|
||||
ring-wrong-color=${theme.bright.red}
|
||||
'';
|
||||
in
|
||||
{
|
||||
"${mod}+Shift+c" = "kill";
|
||||
"${mod}+Control+r" = "reload";
|
||||
"${mod}+Shift+e" = "exit";
|
||||
|
||||
"${mod}+Shift+Return" = "exec ${terminal}";
|
||||
"${mod}+i" = "exec ${browser}";
|
||||
"${mod}+Shift+y" = "exec ${pkgs.swaylock}/bin/swaylock -C '${swaylockConf}'";
|
||||
"${mod}+z" = "exec ${pkgs.brightnessctl}/bin/brightnessctl s 1%-";
|
||||
"${mod}+x" = "exec ${pkgs.brightnessctl}/bin/brightnessctl s 1%+";
|
||||
"${mod}+Shift+z" = "exec ${pkgs.brightnessctl}/bin/brightnessctl s 5%-";
|
||||
"${mod}+Shift+x" = "exec ${pkgs.brightnessctl}/bin/brightnessctl s 5%+";
|
||||
|
||||
"${mod}+p" = "exec ${pkgs.sway-contrib.grimshot}/bin/grimshot copy window";
|
||||
"${mod}+Shift+p" = "exec ${pkgs.sway-contrib.grimshot}/bin/grimshot copy active";
|
||||
|
||||
"${mod}+o" = "splith";
|
||||
"${mod}+u" = "splitv";
|
||||
|
||||
"${mod}+s" = "layout stacking";
|
||||
"${mod}+t" = "layout tabbed";
|
||||
"${mod}+e" = "layout toggle split";
|
||||
"${mod}+f" = "fullscreen";
|
||||
|
||||
"${mod}+h" = "focus left";
|
||||
"${mod}+j" = "focus down";
|
||||
"${mod}+k" = "focus up";
|
||||
"${mod}+l" = "focus right";
|
||||
|
||||
"${mod}+Left" = "focus left";
|
||||
"${mod}+Down" = "focus down";
|
||||
"${mod}+Up" = "focus up";
|
||||
"${mod}+Right" = "focus right";
|
||||
|
||||
"${mod}+Shift+h" = "move left";
|
||||
"${mod}+Shift+j" = "move down";
|
||||
"${mod}+Shift+k" = "move up";
|
||||
"${mod}+Shift+l" = "move right";
|
||||
|
||||
"${mod}+Ctrl+h" = "resize grow left 10 px or 10 ppt";
|
||||
"${mod}+Ctrl+j" = "resize grow down 10 px or 10 ppt";
|
||||
"${mod}+Ctrl+k" = "resize grow up 10 px or 10 ppt";
|
||||
"${mod}+Ctrl+l" = "resize grow right 10 px or 10 ppt";
|
||||
|
||||
"${mod}+space" = "focus mode_toggle";
|
||||
"${mod}+a" = "focus parent";
|
||||
|
||||
"${mod}+Shift+space" = "floating toggle";
|
||||
}
|
||||
// (joinAttrSets (map makeWorkspaceBinds (lib.range 1 9)));
|
||||
|
||||
seat."*" = {hide_cursor = "when-typing enable";};
|
||||
|
||||
bars = [
|
||||
{
|
||||
position = "top";
|
||||
fonts = {
|
||||
names = [theme.font.family];
|
||||
style = "Regular";
|
||||
size = theme.font.size * 1.0;
|
||||
};
|
||||
statusCommand = "${statusCommand}";
|
||||
|
||||
colors = with theme; {
|
||||
statusline = primary.foreground;
|
||||
inherit (primary) background;
|
||||
|
||||
focusedWorkspace = {
|
||||
inherit (primary) background;
|
||||
inherit (wm.focused) text;
|
||||
inherit (wm.focused) border;
|
||||
};
|
||||
|
||||
inactiveWorkspace = {
|
||||
inherit (primary) background;
|
||||
inherit (wm.unfocused) text;
|
||||
border = primary.background;
|
||||
};
|
||||
};
|
||||
|
||||
extraConfig = ''
|
||||
gaps 5
|
||||
'';
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
extraConfig = ''
|
||||
for_window [title="leftovers"] floating enable
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
xdg.portal = {
|
||||
enable = true;
|
||||
wlr.enable = true;
|
||||
extraPortals = with pkgs; [
|
||||
xdg-desktop-portal-gtk
|
||||
];
|
||||
};
|
||||
}
|
|
@ -1,27 +0,0 @@
|
|||
State: idle
|
||||
Deployments:
|
||||
● fedora:fedora/39/x86_64/sericea
|
||||
Version: 39.20231126.0 (2023-11-26T00:52:40Z)
|
||||
BaseCommit: cdcc929dec2eb8c2cd090a967d0397442aafee312441ac521970bc95eb9967d7
|
||||
GPGSignature: Valid signature by E8F23996F23218640CB44CBE75CF5AC418B8E74C
|
||||
RemovedBasePackages: libavfilter-free libavformat-free libpostproc-free libswresample-free libavutil-free libswscale-free libavcodec-free 6.0.1-1.fc39
|
||||
mesa-va-drivers 23.2.1-2.fc39 toolbox 0.0.99.4-5.fc39
|
||||
LayeredPackages: distrobox earlyoom fcitx5-mozc ffmpeg
|
||||
gstreamer1-plugins-bad-free-extras
|
||||
gstreamer1-plugins-bad-freeworld gstreamer1-plugins-ugly
|
||||
gstreamer1-vaapi intel-media-driver mesa-va-drivers-freeworld
|
||||
mesa-vdpau-drivers-freeworld mullvad-vpn rpmfusion-free-release
|
||||
rpmfusion-nonfree-release tlp
|
||||
|
||||
fedora:fedora/39/x86_64/sericea
|
||||
Version: 39.20231125.0 (2023-11-25T02:13:42Z)
|
||||
BaseCommit: f89fe4d4416061daa02750bc05f0c2bdc6a28ad17543509eaf4308b430b85347
|
||||
GPGSignature: Valid signature by E8F23996F23218640CB44CBE75CF5AC418B8E74C
|
||||
RemovedBasePackages: libavfilter-free libavformat-free libpostproc-free libswresample-free libavutil-free libswscale-free libavcodec-free 6.0.1-1.fc39
|
||||
mesa-va-drivers 23.2.1-2.fc39 toolbox 0.0.99.4-5.fc39
|
||||
LayeredPackages: distrobox earlyoom fcitx5-mozc ffmpeg
|
||||
gstreamer1-plugins-bad-free-extras
|
||||
gstreamer1-plugins-bad-freeworld gstreamer1-plugins-ugly
|
||||
gstreamer1-vaapi intel-media-driver mesa-va-drivers-freeworld
|
||||
mesa-vdpau-drivers-freeworld mullvad-vpn rpmfusion-free-release
|
||||
rpmfusion-nonfree-release tlp
|
5
secrets.nix
Normal file
5
secrets.nix
Normal file
|
@ -0,0 +1,5 @@
|
|||
let
|
||||
buffet = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOA928bjB90FwkTLtQcPW1mP+QLViVfEVdMHg+7/8Fxh";
|
||||
in {
|
||||
"secrets/borgpassword.age".publicKeys = [buffet];
|
||||
}
|
10
secrets/borgpassword.age
Normal file
10
secrets/borgpassword.age
Normal file
|
@ -0,0 +1,10 @@
|
|||
age-encryption.org/v1
|
||||
-> ssh-ed25519 zRvPWg kFRBhVsPwM0Y7d/to2HZlK3QYa+rrJS663unhFYAUl8
|
||||
XqHrme+FUS3qEJODmbq3I5oNtUuIzD0KZZ84/HDoQrs
|
||||
-> HZsYe9qT-grease T_?% t%Ew2u
|
||||
Ib3oPsORNcIZYGWIyrDWH51rM2cWQJLz5U7oOVty+as+sFGGR5f/4EcD04B18jgC
|
||||
egHRSNZkzQCDE2CUVJ8emfdHRl20oH0PzpElIHvKPwoyzrrmroFZs8nWnxmZkQ
|
||||
--- 1OnkX3KPJ6tPSSUrQL22va6IQxq/wL5Q65//yX6+G88
|
||||
M`ê?<Jˆ´l4V
<0A>ßN<C39F>”¡v#f1¾,0˃PàHÍÑÈòÃ/´™j¾ÅøºòŠK¢òÿCêaÛ&ô§,Rðc¼ùÙ½x†%ªÝaå[5¢`°r¨yè™»}àŸIõºF"ÆÀ¯w¯gUˆ?ÇÌÙmŽ>°†cª½ã|Ý/R9C|
|
||||
MÝ”lÔɦ-Ë9
|
||||
“
K³>S2û¦#;Ž
|
45
system.nix
Normal file
45
system.nix
Normal file
|
@ -0,0 +1,45 @@
|
|||
{
|
||||
nixpkgs,
|
||||
nixpkgs-unstable,
|
||||
...
|
||||
}: {
|
||||
time.timeZone = "Europe/Berlin";
|
||||
i18n.defaultLocale = "en_US.UTF-8";
|
||||
|
||||
boot.loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
};
|
||||
|
||||
fileSystems = {
|
||||
"/".options = ["compress=zstd"];
|
||||
"/nix".options = ["compress=zstd" "noatime"];
|
||||
"/persist".options = ["compress=zstd"];
|
||||
};
|
||||
|
||||
networking = {
|
||||
networkmanager.enable = true;
|
||||
nameservers = ["1.1.1.1"];
|
||||
};
|
||||
|
||||
nix = {
|
||||
registry = {
|
||||
nixpkgs.flake = nixpkgs;
|
||||
nixpkgs-unstable.flake = nixpkgs-unstable;
|
||||
};
|
||||
settings = {
|
||||
auto-optimise-store = true;
|
||||
trusted-users = ["root" "buffet"];
|
||||
};
|
||||
|
||||
gc = {
|
||||
automatic = true;
|
||||
dates = "weekly";
|
||||
options = "--delete-older-than 30d";
|
||||
};
|
||||
|
||||
extraOptions = ''
|
||||
experimental-features = nix-command flakes
|
||||
'';
|
||||
};
|
||||
}
|
52
theme.nix
Normal file
52
theme.nix
Normal file
|
@ -0,0 +1,52 @@
|
|||
{
|
||||
light = false;
|
||||
|
||||
font = {
|
||||
family = "APL386 Unicode";
|
||||
size = 7;
|
||||
};
|
||||
|
||||
primary = {
|
||||
background = "#1f1f28";
|
||||
foreground = "#dcd7ba";
|
||||
};
|
||||
|
||||
cursor = {
|
||||
background = "#2d4f67";
|
||||
foreground = "#c8c093";
|
||||
};
|
||||
|
||||
normal = {
|
||||
black = "#090618";
|
||||
red = "#c34043";
|
||||
green = "#76946a";
|
||||
yellow = "#c0a36e";
|
||||
blue = "#7e9cd8";
|
||||
magenta = "#957fb8";
|
||||
cyan = "#6a9589";
|
||||
white = "#c8c093";
|
||||
};
|
||||
|
||||
bright = {
|
||||
black = "#727169";
|
||||
red = "#e82424";
|
||||
green = "#98bb6c";
|
||||
yellow = "#e6c384";
|
||||
blue = "#7fb4ca";
|
||||
magenta = "#938aa9";
|
||||
cyan = "#7aa89f";
|
||||
white = "#dcd7ba";
|
||||
};
|
||||
|
||||
wm = {
|
||||
focused = {
|
||||
text = "#dcd7ba";
|
||||
border = "#54546d";
|
||||
};
|
||||
|
||||
unfocused = {
|
||||
text = "#c8c093";
|
||||
border = "#363646";
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue