mirror of
https://github.com/notwa/rc
synced 2024-11-14 17:19:02 -08:00
13 lines
199 B
Text
13 lines
199 B
Text
|
#!/bin/sh
|
||
|
awk '
|
||
|
{
|
||
|
i=0
|
||
|
split($0,a,"")
|
||
|
split(L,b,"")
|
||
|
for (c in a)
|
||
|
if (a[c]==b[c]) i++
|
||
|
else break
|
||
|
print substr($0,1,i) "\033[7m" substr($0,i+1) "\033[0m"
|
||
|
L=$0
|
||
|
}'
|