summaryrefslogtreecommitdiffstats
path: root/ship/lib/core
diff options
context:
space:
mode:
authormakefu <root@pigstarter.de>2013-11-13 10:48:10 +0100
committermakefu <root@pigstarter.de>2013-11-13 10:48:10 +0100
commitb0ff50f9ce05381c710ef114b39167bd634d3726 (patch)
treed217bf7dda37d09fde554e9d2435520b4cb013fa /ship/lib/core
parentbe7f471ff83fc68b09ddde94a45a58d665849d3b (diff)
ship: add internet command to core
Diffstat (limited to 'ship/lib/core')
-rw-r--r--ship/lib/core4
1 files changed, 3 insertions, 1 deletions
diff --git a/ship/lib/core b/ship/lib/core
index 1ef1fbf9..d1a7333e 100644
--- a/ship/lib/core
+++ b/ship/lib/core
@@ -7,7 +7,9 @@ exists(){ type "$1" >/dev/null 2>/dev/null; }
is_root(){
test $(id -u) -eq 0
}
-
+internet(){
+ ping -w 1 google.de >/dev/null 2>&1
+}
defer(){
#close enough
trapstr="$1;${trapstr:-exit}"