业精于勤,荒于嬉;行成于思,毁于随。
这个可以匹配出来 grep -o "ed2k[^\"]*"
grep -o "ed2k[^\"]*"
[root@localhost oldlog.md]# echo '你的地址' | grep -o "ed2k[^\"]*" ed2k://|file|%E7%A1%85%E8%B0%B7.Silicon.Valley.S01E01.%E4%B8%AD%E8%8B%B1%E5%AD%97%E5%B9%95.HDTVrip.1024X576.mkv|348759100|04dc44e4978ea2d4dc9bf41b08829a3e|h=rfe5smulijxlmz7mgtpmn2bt3vmofk56|/ ed2k://|file|silicon.valley.s01e01.720p.hdtv.x264-killers.mkv|843706966|3B4B08BD9C960B5B8F2372158F84B1AE|h=36632AROF43T63NSXFLIGSYEB4PNDEFN|/
建议通过一些html的parser把a标签单独提取出来进行匹配,可以避免一行出现多个a的问题
By default grep doesn't support non-greedy modifiers, but you can use grep -P to use the Perl syntax.
How to do a non-greedy match in grep?
这个可以匹配出来
grep -o "ed2k[^\"]*"
建议通过一些html的parser把a标签单独提取出来进行匹配,可以避免一行出现多个a的问题
By default grep doesn't support non-greedy modifiers, but you can use grep -P to use the Perl syntax.
How to do a non-greedy match in grep?