خرید بک لینک

Vote count: 0

I am trying to do a line replace given contexts on two sides of a split. This seems much easier to do in python but my entire pipeline is in bash so I would love to stick to tools like sed, awk, grep, etc.

For example:

split_0 = split('t')[0]
split_1 = split('t')[1]
if a b c in split_0 AND w x y z in split_1:
    split_1 = split_1.replace('w x y z', 'w x_y z')

I can use awk to do splits like this:

awk -F 't' '{print$1}'

But I don't know how to do this on both sides simultaneously in order to satisfy both conditions. Any help would be greatly appreciated.

asked 4 mins ago

برچسب: نویسنده: استخدام کار تاريخ: جمعه 27 فروردين 1395 ساعت: 23:30

صفحه بندی