I know that this my be really simple, but I'm having a hard time accomplishing it. I am trying to add a new line of text after finding a particular string of text in a file. Here's what I'm getting:
sed: command garbled: N/search_string/\\new_text/
I was using "N" to add a line after the... (3 Replies)
Hey. I'm just getting started with scripting and although i will admit i haven't searched the forum yet, i think it would be a waste of time. It really will be very simple.
I want to enter a list of arguments after my script with the last being the filename. (not the first, as this is part of... (3 Replies)
I assume there is a simple solution, but as usual i can't find it!
How can i add a line of text to the end of a text file on a new line?
this is my text file
this is my text file
WITH A NEW LINE... (6 Replies)
I am in need of a simple, (typically one-liner) script to get the last 17 bytes of a line.
here i would need the last 17 bytes of the text
The text length is dymanic (but always more than 17)...it can even span upto... (2 Replies)
I have what I believe is a simple programming question. I have a text file that looks like:
mol 1 G:\stereo01.hin
However, I would like a file that repeats this entire block of text several times over. The lines of text in the middle remain the same for each... (2 Replies)
First of all I am VERY new to this so bare with me and try and explain everything even if it seems simple.
Basically I want to read a line of text from a html file. See if the line of text has a certain string in it. copy an unknown number of characters (the last 4 characters wiil be ".jpg" the... (1 Reply)
I have a simple question:
I need to enter some text in a text file at a certain place via perl.
I would first need to find that specific text in the file and then I would like to insert a line after that particular line.
Say I have this text file:
I am a great Perl Programmer
I... (1 Reply)
Can anyone help with a effective solution ?
I need to change a variable length text field (between 1 - 18 characters) to a fixed length text of 18 characters with the unused portion, at the end, filled with spaces.
The text field is actually field 10 of a .csv file however I could cut... (7 Replies)
there is a text file like this
how can i extract the someusername from this file which has a path like /home/myfile.txt?
i want to store it in a variable $u (3 Replies)
Hello Unix gurus,
I'm creating this analysis to determine whether the maximum allowable process is nearly reached then alarm the user with it. Can someone please help me on how I can determine the maximum allowable process that a platform can handle? BTW, below are the details that might be... (0 Replies)
I am trying to use the text of one file as a text file name with and the text of another as the contents of that text file. Is this possible? Thank you :).
For example, in the two files attached, target.txt has:
and out_parse.txt has:
13 20763642 20763642 C G... (5 Replies)