From d7e3b972e637ea732d5a6a810a875b098ba1bb11 Mon Sep 17 00:00:00 2001 From: Tao Tien <29749622+taotien@users.noreply.github.com> Date: Sat, 1 Jun 2024 17:01:22 -0700 Subject: [PATCH] bump --- flake.lock | 37 +++++++++++++++++++-------- users/tao/nushell/stuff.nu | 52 +++++++++++++++++++------------------- 2 files changed, 53 insertions(+), 36 deletions(-) diff --git a/flake.lock b/flake.lock index 50bfd8a..0463c62 100644 --- a/flake.lock +++ b/flake.lock @@ -104,14 +104,15 @@ "flake-compat": "flake-compat", "nixpkgs": [ "nixpkgs" - ] + ], + "nixpkgs-stable": "nixpkgs-stable" }, "locked": { - "lastModified": 1717048113, - "narHash": "sha256-adjeBeqMoCYr/iY3/zHCl2c8WYRzi+0TfH/3itJZ0qE=", + "lastModified": 1717221137, + "narHash": "sha256-Ku5dXil8eQxCQhdC/LmyCEoTXtm4ctwSJlHNcGDCqyc=", "owner": "lilyinstarlight", "repo": "nixos-cosmic", - "rev": "f7b84cb8a0c081a36c2692cbdcb6aee122f27e77", + "rev": "848384c85159d3009f24f78b8b53082be451a9e5", "type": "github" }, "original": { @@ -122,11 +123,11 @@ }, "nixos-hardware": { "locked": { - "lastModified": 1716987116, - "narHash": "sha256-uuEkErFVsFdg2K0cKbNQ9JlFSAm/xYqPr4rbPLI91Y8=", + "lastModified": 1717248095, + "narHash": "sha256-e8X2eWjAHJQT82AAN+mCI0B68cIDBJpqJ156+VRrFO0=", "owner": "NixOS", "repo": "nixos-hardware", - "rev": "8251761f93d6f5b91cee45ac09edb6e382641009", + "rev": "7b49d3967613d9aacac5b340ef158d493906ba79", "type": "github" }, "original": { @@ -150,6 +151,22 @@ "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": { "locked": { "lastModified": 1716948383, @@ -173,11 +190,11 @@ ] }, "locked": { - "lastModified": 1716902607, - "narHash": "sha256-jShqpVupP/7ksp6gCBVG9/05zYSX8Q+z6eGe9HLYtUs=", + "lastModified": 1717265895, + "narHash": "sha256-SsNTqFnefBO5wV5qD7nzd5wwrf2eOA/yahnP0lnQXhk=", "owner": "pjones", "repo": "plasma-manager", - "rev": "4a255e5ea6bf2c7815d893a693c5c801d835ba6b", + "rev": "6e6d6a457355c7675484c0197bab06c2a4840b7d", "type": "github" }, "original": { diff --git a/users/tao/nushell/stuff.nu b/users/tao/nushell/stuff.nu index 984f1e8..bed2d8a 100644 --- a/users/tao/nushell/stuff.nu +++ b/users/tao/nushell/stuff.nu @@ -76,31 +76,31 @@ def tse [exit_node: string = ""] { } 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 @@ -120,7 +120,7 @@ alias tss = tailscale status alias tsu = tailscale up alias tsd = tailscale down alias tsx = tailscale exit-node list -alias tsp = tailscale exit-node suggest +alias tsa = tailscale exit-node suggest def "config stuff" [] { hx ~/projects/NOflake/users/tao/nushell/stuff.nu