config
This commit is contained in:
parent
3f1279ea08
commit
6a2cc7b49d
7 changed files with 78 additions and 52 deletions
|
|
@ -8,6 +8,7 @@
|
|||
# fontforge
|
||||
# radicle-node
|
||||
# hyperfine # benchmarking
|
||||
markdown-oxide
|
||||
git-cliff
|
||||
b3sum
|
||||
direnv
|
||||
|
|
|
|||
24
flake.lock
generated
24
flake.lock
generated
|
|
@ -65,11 +65,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1716930911,
|
||||
"narHash": "sha256-t4HT5j3Jy7skRB5PINnxcEBCkgE89rGBpwTI7YS4Ffo=",
|
||||
"lastModified": 1717097707,
|
||||
"narHash": "sha256-HC5vJ3oYsjwsCaSbkIPv80e4ebJpNvFKQTBOGlHvjLs=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "a9b36cbe9292a649222b89fdb9ae9907e9c74086",
|
||||
"rev": "0eb314b4f0ba337e88123e0b1e57ef58346aafd9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -107,11 +107,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1716853176,
|
||||
"narHash": "sha256-9gUu2VJu5bL+jjNS3mWG/h7T+vIsYhKYyQAunvZtBT4=",
|
||||
"lastModified": 1717048113,
|
||||
"narHash": "sha256-adjeBeqMoCYr/iY3/zHCl2c8WYRzi+0TfH/3itJZ0qE=",
|
||||
"owner": "lilyinstarlight",
|
||||
"repo": "nixos-cosmic",
|
||||
"rev": "996ad8af9bfe04587c0457fcf72f5167e481fe5a",
|
||||
"rev": "f7b84cb8a0c081a36c2692cbdcb6aee122f27e77",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -122,11 +122,11 @@
|
|||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1716881121,
|
||||
"narHash": "sha256-oTf3enbe/lbiNzsyZ8ria+422hx4e/FB3xQcY2LPnJw=",
|
||||
"lastModified": 1716987116,
|
||||
"narHash": "sha256-uuEkErFVsFdg2K0cKbNQ9JlFSAm/xYqPr4rbPLI91Y8=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "806e9d4a933dd1e75592e88894d4bd2f296f5bbf",
|
||||
"rev": "8251761f93d6f5b91cee45ac09edb6e382641009",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -152,11 +152,11 @@
|
|||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1716509168,
|
||||
"narHash": "sha256-4zSIhSRRIoEBwjbPm3YiGtbd8HDWzFxJjw5DYSDy1n8=",
|
||||
"lastModified": 1716948383,
|
||||
"narHash": "sha256-SzDKxseEcHR5KzPXLwsemyTR/kaM9whxeiJohbL04rs=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "bfb7a882678e518398ce9a31a881538679f6f092",
|
||||
"rev": "ad57eef4ef0659193044870c731987a6df5cf56b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@
|
|||
pueue
|
||||
ripgrep
|
||||
rustdesk
|
||||
screen
|
||||
# screen
|
||||
skim
|
||||
tree
|
||||
wezterm
|
||||
|
|
@ -78,6 +78,8 @@
|
|||
|
||||
networking.networkmanager.enable = true;
|
||||
services.tailscale.enable = true;
|
||||
# TODO figure out a socks5 that blocks when not connected to tailscale exit-node
|
||||
# services.tailscale.extraDaemonFlags = ["--socks5-server=localhost:1055"];
|
||||
services.resolved.enable = true;
|
||||
# networking.interfaces.tailscale0.useDHCP = false;
|
||||
|
||||
|
|
|
|||
|
|
@ -78,7 +78,6 @@
|
|||
'';
|
||||
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
# boot.kernelPackages = pkgs.linuxPackages_zen;
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"sd_mod"
|
||||
|
|
@ -89,10 +88,7 @@
|
|||
"uas"
|
||||
];
|
||||
boot.kernelParams = [
|
||||
# "mem_sleep_default=deep"
|
||||
"amdgpu.abmlevel=1"
|
||||
# TODO DMUB bugfix? (apparently disables PSR?)
|
||||
# "amdgpu.dcdebugmask=0x10"
|
||||
];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = with config.boot.kernelPackages; [
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@
|
|||
typst-lsp
|
||||
vial
|
||||
wezterm
|
||||
wl-clipboard-rs
|
||||
yt-dlp
|
||||
zathura
|
||||
zellij
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@
|
|||
};
|
||||
keys.insert = {
|
||||
C-space = "completion";
|
||||
k = {k = "normal_mode";};
|
||||
};
|
||||
keys.normal = {
|
||||
k = "move_line_down";
|
||||
|
|
@ -51,7 +52,7 @@
|
|||
};
|
||||
};
|
||||
languages = {
|
||||
use-grammars.only = ["rust" "c" "cpp" "typst" "nix" "html"];
|
||||
use-grammars.only = ["rust" "c" "cpp" "typst" "nix" "html" "toml" "markdown"];
|
||||
language = [
|
||||
{
|
||||
name = "arduino";
|
||||
|
|
|
|||
|
|
@ -35,24 +35,23 @@ def l [
|
|||
| sort-by type name -i -n
|
||||
}
|
||||
|
||||
def rg [pattern?] {
|
||||
if $pattern == null {
|
||||
def srg [pattern] {
|
||||
sk --ansi -i -c 'rg --color=always --line-number "{}"'
|
||||
} else {
|
||||
rg $pattern
|
||||
}
|
||||
}
|
||||
|
||||
alias nd = nix develop
|
||||
def ns [package] {
|
||||
nix shell $"nixpkgs#($package)"
|
||||
}
|
||||
def nr [package] {
|
||||
nix search nixpkgs $package
|
||||
}
|
||||
|
||||
def rebuild [subcommand] {
|
||||
sudo nice -n19 nixos-rebuild $subcommand --flake /home/tao/projects/NOflake/ --impure --verbose
|
||||
rm ~/.config/helix/runtime/grammars/*
|
||||
rm -r ~/.config/helix/runtime/grammars/
|
||||
hx --grammar fetch; hx --grammar build
|
||||
rm -rf ~/.cache/jdtls/
|
||||
rustup update
|
||||
}
|
||||
def bump [] {
|
||||
cd /home/tao/projects/NOflake/
|
||||
|
|
@ -69,34 +68,39 @@ alias gc = nh clean all
|
|||
|
||||
|
||||
def tse [exit_node: string = ""] {
|
||||
if ($exit_node | is-empty) and (ps | find deluge | is-not-empty) {
|
||||
print "stop summoning first!"
|
||||
return
|
||||
} else {
|
||||
tailscale set --exit-node $exit_node
|
||||
}
|
||||
http get https://am.i.mullvad.net/json
|
||||
}
|
||||
def tsp [] {
|
||||
tailscale exit-node list
|
||||
| split row "\n"
|
||||
| each {str trim}
|
||||
| filter {is-not-empty}
|
||||
| skip 1
|
||||
| last 19
|
||||
| first 17
|
||||
| split column -r '\s{2,}'
|
||||
| reject column5 column3
|
||||
| rename ip addr city
|
||||
| par-each {
|
||||
insert ping {
|
||||
|row| $row.addr
|
||||
| str replace "mullvad.ts.net" "relays.mullvad.net"
|
||||
| ping -c5 -q $in
|
||||
| split row "\n"
|
||||
| last
|
||||
| split column "/"
|
||||
| get column6?
|
||||
| get 0
|
||||
}
|
||||
}
|
||||
| sort-by ping -n -r
|
||||
}
|
||||
# def tsp [] {
|
||||
# tailscale exit-node list
|
||||
# | split row "\n"
|
||||
# | each {str trim}
|
||||
# | filter {is-not-empty}
|
||||
# | skip 1
|
||||
# | last 19
|
||||
# | first 17
|
||||
# | split column -r '\s{2,}'
|
||||
# | reject column5 column3
|
||||
# | rename ip addr city
|
||||
# | par-each {
|
||||
# insert ping {
|
||||
# |row| $row.addr
|
||||
# | str replace "mullvad.ts.net" "relays.mullvad.net"
|
||||
# | ping -c5 -q $in
|
||||
# | split row "\n"
|
||||
# | last
|
||||
# | split column "/"
|
||||
# | get column6?
|
||||
# | get 0
|
||||
# }
|
||||
# }
|
||||
# | sort-by ping -n -r
|
||||
# }
|
||||
def tsr [] {
|
||||
tailscale status --json
|
||||
| from json
|
||||
|
|
@ -116,7 +120,28 @@ alias tss = tailscale status
|
|||
alias tsu = tailscale up
|
||||
alias tsd = tailscale down
|
||||
alias tsx = tailscale exit-node list
|
||||
alias tsp = tailscale exit-node suggest
|
||||
|
||||
def "config stuff" [] {
|
||||
hx ~/projects/NOflake/users/tao/nushell/stuff.nu
|
||||
}
|
||||
|
||||
def deluge-gtk [] {
|
||||
tsr
|
||||
deluge-gtk
|
||||
}
|
||||
alias deluge = deluge-gtk
|
||||
|
||||
def fixme [] {
|
||||
rg TODO --json
|
||||
| lines
|
||||
| each {from json}
|
||||
| where type == "match"
|
||||
| get data
|
||||
| flatten
|
||||
| each {$"($in.text):($in.line_number)"}
|
||||
| hx ...$in
|
||||
}
|
||||
|
||||
source ~/.cache/starship/init.nu
|
||||
source ~/.zoxide.nu
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue