Newbie hw engineer


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Newbie hw engineer
# 1  
Old 12-04-2013
perl word extraction

Need a perl script that will extract component reference designators from a text file and write them to a new file. The refdes attribute will always follow the characters "REFDES=". So for the first line below I'd like to extract the reference designator R2402.

Code:
A 2158 1882 12 2 2 3 REFDES=R2042
C 3975 2 1 0
A 2041 1898 12 1 3 3 #=1
C 3982 15 2 0
A 2110 1892 12 1 3 3 #=2


Last edited by jeffs123456; 12-05-2013 at 01:00 PM.. Reason: Please use code tags for code and data samples
# 2  
Old 12-05-2013
Does it have to be perl?

Code:
$ sed -n '/REFDES=/s/.*REFDES=\([^ ]*\).*/\1/p' input
R2042

# 3  
Old 12-05-2013
what kind of thread title it is "Newbie hw engineer" ?
This User Gave Thanks to Akshay Hegde For This Post:
# 4  
Old 12-05-2013
he said pre-newbie hw engineer, lol, I guess he hasn't reached full newbie hw engineer status. I would guess the dream would be to reach just regular hw engineer status. pre-newbie and full-newbie...like the unicorn, I don't think these animals exist.
This User Gave Thanks to blackrageous For This Post:
# 5  
Old 12-05-2013
Code:
perl -ne '/REFDES=(.*?)\s+/ && print $1' your_file

# 6  
Old 12-05-2013
Mea culpa, mea culpa. Sorry for not knowing the rules. Will comply in the future.
Login or Register to Ask a Question

Previous Thread | Next Thread

7 More Discussions You Might Find Interesting

1. What is on Your Mind?

How to become good UNIX engineer

Maybe my question is quite stupid , but how to become good UNIX engineer. What to read , how to practice ? What a good engineer must know to call himself engineer . :cool: (14 Replies)
Discussion started by: solaris_user
14 Replies

2. Advertise with Us

Systems Engineer- Emeryville, CA (UNIX, C)

Systems Engineer- Emeryville, CA (UNIX, C) Gracenote is seeking a Systems Engineer to develop features and fixes in Gracenote's online media recognition service. You will contribute regularly to team design and code reviews, and be responsible for the analysis and resolution of software defects... (0 Replies)
Discussion started by: cwilliams
0 Replies

3. UNIX for Dummies Questions & Answers

Information on Network engineer and Unix Systems Engineer

Hi, I'm exploring a few different careers( Unix System's Admin, Network Engineer, and Unix System's Engineer). I asked in another thread about System's Admin, so I have some more info on that already. I'm not finding very much info on Network Engineers or Unix System Engineers though. Can you guys... (0 Replies)
Discussion started by: hpicracing
0 Replies

4. HP-UX

Customer support engineer

Hi All, I need the help to deploy or implement HP MC service guard 2 node cluster step by step procedure is any1 who can help me to send me the step by step procedure. Thanks and Regards Jahangir (12 Replies)
Discussion started by: Jahangir
12 Replies

5. Linux

Linux Network Engineer

Hi, I was wondering has anybodu completed the linux + Nework Engineer CompTIA Linux+ Certificate. Hows does it stand to the others, such as Red Hat certifications? Txs (1 Reply)
Discussion started by: Breen
1 Replies

6. UNIX for Dummies Questions & Answers

How to reverse engineer directories

Hi, I need to reverse engineer certain directories so I can create the exact directory structure in another machine. How do I go about doing that? Thanks in advance for your help. JTrinh (1 Reply)
Discussion started by: Jtrinh
1 Replies

7. Shell Programming and Scripting

courses which will place me as a network engineer?

Hi, I'm a hardware er now. Can anyone say some courses which will place me as a Networking er. I'm doing my CCNA now. I've lot of interest in Networks. (3 Replies)
Discussion started by: yuvasyntel
3 Replies
Login or Register to Ask a Question