This commit is contained in:
Tao Tien 2024-06-01 17:01:22 -07:00
parent cb2a82de91
commit d7e3b972e6
2 changed files with 53 additions and 36 deletions

37
flake.lock generated
View file

@ -104,14 +104,15 @@
"flake-compat": "flake-compat", "flake-compat": "flake-compat",
"nixpkgs": [ "nixpkgs": [
"nixpkgs" "nixpkgs"
] ],
"nixpkgs-stable": "nixpkgs-stable"
}, },
"locked": { "locked": {
"lastModified": 1717048113, "lastModified": 1717221137,
"narHash": "sha256-adjeBeqMoCYr/iY3/zHCl2c8WYRzi+0TfH/3itJZ0qE=", "narHash": "sha256-Ku5dXil8eQxCQhdC/LmyCEoTXtm4ctwSJlHNcGDCqyc=",
"owner": "lilyinstarlight", "owner": "lilyinstarlight",
"repo": "nixos-cosmic", "repo": "nixos-cosmic",
"rev": "f7b84cb8a0c081a36c2692cbdcb6aee122f27e77", "rev": "848384c85159d3009f24f78b8b53082be451a9e5",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -122,11 +123,11 @@
}, },
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1716987116, "lastModified": 1717248095,
"narHash": "sha256-uuEkErFVsFdg2K0cKbNQ9JlFSAm/xYqPr4rbPLI91Y8=", "narHash": "sha256-e8X2eWjAHJQT82AAN+mCI0B68cIDBJpqJ156+VRrFO0=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "8251761f93d6f5b91cee45ac09edb6e382641009", "rev": "7b49d3967613d9aacac5b340ef158d493906ba79",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -150,6 +151,22 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs-stable": {
"locked": {
"lastModified": 1717144377,
"narHash": "sha256-F/TKWETwB5RaR8owkPPi+SPJh83AQsm6KrQAlJ8v/uA=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "805a384895c696f802a9bf5bf4720f37385df547",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-24.05",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1716948383, "lastModified": 1716948383,
@ -173,11 +190,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1716902607, "lastModified": 1717265895,
"narHash": "sha256-jShqpVupP/7ksp6gCBVG9/05zYSX8Q+z6eGe9HLYtUs=", "narHash": "sha256-SsNTqFnefBO5wV5qD7nzd5wwrf2eOA/yahnP0lnQXhk=",
"owner": "pjones", "owner": "pjones",
"repo": "plasma-manager", "repo": "plasma-manager",
"rev": "4a255e5ea6bf2c7815d893a693c5c801d835ba6b", "rev": "6e6d6a457355c7675484c0197bab06c2a4840b7d",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -76,31 +76,31 @@ def tse [exit_node: string = ""] {
} }
http get https://am.i.mullvad.net/json http get https://am.i.mullvad.net/json
} }
# def tsp [] { def tsp [] {
# tailscale exit-node list tailscale exit-node list
# | split row "\n" | split row "\n"
# | each {str trim} | each {str trim}
# | filter {is-not-empty} | filter {is-not-empty}
# | skip 1 | skip 1
# | last 19 | last 19
# | first 17 | first 17
# | split column -r '\s{2,}' | split column -r '\s{2,}'
# | reject column5 column3 | reject column5 column3
# | rename ip addr city | rename ip addr city
# | par-each { | par-each {
# insert ping { insert ping {
# |row| $row.addr |row| $row.addr
# | str replace "mullvad.ts.net" "relays.mullvad.net" | str replace "mullvad.ts.net" "relays.mullvad.net"
# | ping -c5 -q $in | ping -c5 -q $in
# | split row "\n" | split row "\n"
# | last | last
# | split column "/" | split column "/"
# | get column6? | get column6?
# | get 0 | get 0
# } }
# } }
# | sort-by ping -n -r | sort-by ping -n -r
# } }
def tsr [] { def tsr [] {
tailscale status --json tailscale status --json
| from json | from json
@ -120,7 +120,7 @@ alias tss = tailscale status
alias tsu = tailscale up alias tsu = tailscale up
alias tsd = tailscale down alias tsd = tailscale down
alias tsx = tailscale exit-node list alias tsx = tailscale exit-node list
alias tsp = tailscale exit-node suggest alias tsa = tailscale exit-node suggest
def "config stuff" [] { def "config stuff" [] {
hx ~/projects/NOflake/users/tao/nushell/stuff.nu hx ~/projects/NOflake/users/tao/nushell/stuff.nu