Is there any windows or unix/linux commandline script that can do this?I.e the word "boss" should be incremented from 1 to 60,then 1 to 60 again.
I have a file that contains a list of text like so;
She is the new boss She is the new boss She is the new boss She is the new boss She is the new boss She is the new boss She is the new boss She is the new boss She is the new boss . . .
I want the output to be:
She is the new boss1 She is the new boss2 She is the new boss3 . . . She is the new boss60 She is the new boss1 She is the new boss2 She is the new boss3 . . . She is the new boss60 . . .
So,far I use this
perl -i.bak -ape "s/"old-text"/$&.++$A /ge" input.txt && del input.txt.bakto do repeated increment but the output it produces is not what I want.