10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hi,
I wrote a csh script where I want to save in a loop each time a different line from a text file (att_file) in the $name variable.
But it seems not to work.
att_file looks like:
123123123
345345345
345345345
set name = `head -n $count $att_file | tail -n 1 | awk '{print $1}'`
Do... (3 Replies)
Discussion started by: MLImag
3 Replies
2. UNIX for Beginners Questions & Answers
I have a file with a list of references towards the end and want to apply a grep for some string.
text ....
@unnumbered References
@sp 1
@paragraphindent 0
2017. @strong{Chalenski, D.A.}; Wang, K.; Tatanova, Maria; Lopez,
Jorge L.; Hatchell, P.; Dutta, P.; @strong{Small airgun... (1 Reply)
Discussion started by: kristinu
1 Replies
3. Shell Programming and Scripting
I have a expect file like this
#!/opt/tools/unsupported/expect-5.39/bin/expect
spawn ssh -l user ip
expect_after eof {exit 0}
set timeout 10
log_file /report.txt
expect "Password:" { send "pasword\r" }
expect "$ " { send "date\r" }
expect "$ " { send "readlink /somelink\r" }
set... (7 Replies)
Discussion started by: bebehnaz
7 Replies
4. Shell Programming and Scripting
HI,
I have the below input file
/* ----------------- cmdsDlyStartFWJ -----------------*/
UNIX_JOB CMDS065J
RUN ANY
CMDNAME sleep 5
AGENT CMDSHP
USER proddata
RUN MON,TUE,WED,THU,FRI
DELAYSUB 02:00
/* "Triggers daily file watcher jobs" */
ENVAR... (5 Replies)
Discussion started by: varun22486
5 Replies
5. UNIX for Dummies Questions & Answers
Hi All,
I am writing a script to work with files in a folder.
The files are all in the following patterns (without quotes):
"some filename - NxNN - the end.YYY"
or
"some filename - NNxNN - the end.YYY"
Where N = a single number and YYY is the extension.
Basically what I want... (5 Replies)
Discussion started by: sgtbobie
5 Replies
6. Shell Programming and Scripting
Hey,I have a file in following format
>1
ABC........
>2
XYZ.....
>3
ABC........
>4
MNO.......
>5
ABC.......
now I would like to find only those entries that doesn't start with ABC (specific pattern)e.g preferred output:
>2
XYZ....
>4
MNO.......
it will be nice if anybody how... (2 Replies)
Discussion started by: ankitachaurasia
2 Replies
7. Shell Programming and Scripting
Hi
I want to read a file line by line and search for a particular string in each line(say for example string containing @ )and save that string into a variable.
Can someone suggest me the way to implement it.I am using K- shell
Thanks
Ishita (5 Replies)
Discussion started by: Ishita
5 Replies
8. Shell Programming and Scripting
Hi,
I have file 1.txt with following entries as shown:
0152364|134444|10.20.30.40|015236433
0233654|122555|10.20.30.50|023365433
**
**
**
In file 2.txt I have the following entries as shown:
0152364|134444|10.20.30.40|015236433
0233654|122555|10.20.30.50|023365433... (4 Replies)
Discussion started by: imas
4 Replies
9. UNIX for Dummies Questions & Answers
Hi,
I think you ppl did not get my question correctly, let me explain
I have 1.txt with following entries as shown:
0152364|134444|10.20.30.40|015236433
0233654|122555|10.20.30.50|023365433
**
**
**
In file 2.txt I have the following entries as shown:
... (1 Reply)
Discussion started by: imas
1 Replies
10. UNIX for Dummies Questions & Answers
Hi,
I am new to this forum and i would like to get help in this issue.
I have a file 1.txt as shown:
apple
banana
orange
apple
grapes
banana
orange
grapes
orange
....
Now i would like to search for pattern say apple or orange and then put a # at the beginning of the pattern... (2 Replies)
Discussion started by: imas
2 Replies