mirror of
https://github.com/genebean/dots.git
synced 2026-03-27 01:17:42 -04:00
Add nixroutes alias for comparing network routes
Allows easy comparison of current routes with routes in new build
This commit is contained in:
parent
1f9db8cb1f
commit
67458c0ae3
1 changed files with 7 additions and 0 deletions
7
modules/hosts/common/linux/nixroutes.nix
Normal file
7
modules/hosts/common/linux/nixroutes.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
hostName = config.networking.hostName;
|
||||
in {
|
||||
programs.zsh.shellAliases.nixroutes =
|
||||
"cd ~/repos/dots && echo '=== Current Routes ===' && ip route show && ip -6 route show && echo '' && echo '=== New Build Routes ===' && nix eval --json '.#nixosConfigurations.${hostName}.config.systemd.network.networks.\"10-wan\".routes'";
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue