Add a script to get the next hop in a route.

I never remember the incantation, and its slightly different between FreeBSD and Linux so I am adding this script essentially as a note.
This commit is contained in:
Tom Alexander
2024-10-13 22:02:59 -04:00
parent 9d6ddfd1bd
commit cd0208f3fc
4 changed files with 36 additions and 0 deletions

View File

@@ -0,0 +1,7 @@
#!/usr/bin/env bash
#
set -euo pipefail
IFS=$'\n\t'
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
exec route get "${@}"