Skip to content

Instantly share code, notes, and snippets.

@ensup
Created May 9, 2019 12:54
Show Gist options
  • Save ensup/08e29682ff63dc19bf8866c20c45225b to your computer and use it in GitHub Desktop.
Save ensup/08e29682ff63dc19bf8866c20c45225b to your computer and use it in GitHub Desktop.
Check-IP(Unix)
#!/bin/bash
ip addr | grep "inet " | grep brd | awk '{print $2}' | awk -F/ '{print $1}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment