Jarno Rankinen 修订了这个 Gist . 跳至此修订
没有变更
Jarno Rankinen 修订了这个 Gist . 跳至此修订
1 file changed, 0 insertions, 0 deletions
gistfile1.txt 重命名为 geoiplookup.sh
File renamed without changes
Jarno Rankinen 修订了这个 Gist . 跳至此修订
1 file changed, 5 insertions
gistfile1.txt(file created)
@@ -0,0 +1,5 @@ | |||
1 | + | ## depends on curl and jq | |
2 | + | function geoiplookup() { | |
3 | + | GEOIPURL=https://json.geoiplookup.io/"$1" | |
4 | + | curl -s $GEOIPURL | jq '.ip, .org, .hostname, .city, .country_name' | |
5 | + | } |