#!/bin/bash
#匹配http://样式url
read -p "input the file path:" file
egrep -o "\<http://[a-z0-9\.]+\.[a-z]{2,3}\>" $file |sort|uniq -c|sort -rn >url
注释:[a-z0-9\.]+ ----这样做的意义是为了匹配二级域名及多级
本文出自 “天晴了要下雨” 博客,请务必保留此出处http://8776055.blog.51cto.com/8766055/1836659
原文:http://8776055.blog.51cto.com/8766055/1836659