projects
/
external
/
ifupdown.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Git init
[external/ifupdown.git]
/
contrib
/
ifstate
1
#!/bin/sh
2
3
iface="$1"
4
if [ -z "$iface" ] ; then
5
echo "Usage: $0 IFACE"
6
exit 1
7
fi
8
9
if ifconfig "$iface" | grep -Fw UP >/dev/null
10
then
11
echo UP
12
else
13
echo DOWN
14
fi