10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Re: Query on using command "SED" for replacing text in bash shell
While using the command "sed" for find and replace, I wanted to know how one could find a constant and replace it with a variable inside the quotation syntax of sed?
I wanted to replace constant 3 with variable name... (3 Replies)
Discussion started by: achandra81
2. Shell Programming and Scripting
I need to cat two files with similar names. I am using the following script:
echo fetching data from R2 file ...
cat $file $file2 > infile
echo "Input_file passed... (2 Replies)
Discussion started by: Xterra
3. Shell Programming and Scripting
Script newbie, so I'm sure I'm missing something obvious here, but how come this simple script does not work?
#!/bin/bash ... (3 Replies)
Discussion started by: KidCactus
4. UNIX for Dummies Questions & Answers
Hello, I have a comma seperated data sheet with multiple fields of biological data. One column contains the ID name of the sample, where there could be more than one sample separated by a comma. I would like a script that reads this field, and for each sample ID, copies the entire line and writes... (18 Replies)
Discussion started by: torchij
5. UNIX for Dummies Questions & Answers
Could you help me writing a simple version control script for a text files.
the format could be
./version_control <file(s)> (I want it to be able to work with more than 1 file at the same time)
commands are add and get, add means you add new file(s) to the archive, get means you... (4 Replies)
Discussion started by: s3270226
6. UNIX for Dummies Questions & Answers
I am fairly new to the world of Unix, and I am looking for a way to replace a line of text in a file with a delimited array of values.
I have an aliases file that is currently in use on our mail server that we are migrating off of. Until the migration is complete, the server must stay... (8 Replies)
Discussion started by: phoenixjc
7. UNIX for Dummies Questions & Answers
say I have a few files in a directory (58 text files or somthing)
each one contains mulitple strings that I wish to replace with other strings
so in these 58 files I'm looking for say the following strings:
JAM (replace with BUTTER)
BREAD (replace with CRACKER)
SCOOP (replace... (19 Replies)
Discussion started by: rich@ardz
8. Shell Programming and Scripting
I have the following text which I want to search and replace using perl and sed. I would appreciate any help.
Please notice the file contains schema name with a single dot and a double dot . &&WEBDIR_SCHEMA. and &&WEBDIR_SCHEMA .. }
I would like to change it to the acutal schema... (5 Replies)
Discussion started by: jville
9. Shell Programming and Scripting
I am new to unix shell programming. I need to write a script which needs to edit 4 text files.
File 1:- PCH_Test.txt
File 2:- PCT_Test.txt
File 3:- PCY_Test.txt
File 4:- PCW_Test.txt
First it needs to get into PCH_Test file and prefix the 6th coloumn... (2 Replies)
Discussion started by: phani333
10. Shell Programming and Scripting
I just created a file in vi, looks like this:
What I need is to have sed change the file so it looks like this:
In other words, the sed query needs to look for both instances of "nobody" before it puts the word "everybody" on the first line. ... (2 Replies)
Discussion started by: calrog