如何將'number:number'的所有文本放到與前面的'number:number'相同的行上?sed/awk - 將所有文本放在與前面的數字相同的行上
10:15
text line one
text line two
text no pattern
11:12
random text
text is random
totally random
could be four lines
could be five
應該再成爲
10:15 text line one text line two text no pattern
11:12 random text text is random totally random could be four lines could be five
文本是否會有任何數字? – VM17
不,它只會是文本或東西線逗號和停止 – user1776732
讓我知道我的答案是否適合你。 – VM17