根据你方展示的样品,请尝试以下内容。
在线演示如下:
Online demo of regex
(?P<serial>(?:\d+\.)+)\s*(?P<description>\S+)
说明:
增加了对以上内容的详细解释。
(?P<serial> ##Starting a named capturing group named serial here.
(?:\d+\.)+) ##Starting a non capturing group which is looking for continuous occurrence of digits followed with dot with 1 or more occurrences of this combinations.
\s* ##Looking for 1 or more occurrences of spaces here.
(?P<description>\S+) ##Starting a named capturing group named description here which has all values except spaces occurrences.