- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: command help
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:02 AM
09-05-2002 11:02 AM
BobMenefee
I want it to look like this:
Bob Menefee
_____________________________________________
My input file is called caps
I enter the following command:
sed s/'[A-Z]'/' [a-z]'/g caps
and I get
[a-z]ob [a-z]enefee
Any ideas how to do this ?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:10 AM
09-05-2002 11:10 AM
Re: command help
HTH
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:15 AM
09-05-2002 11:15 AM
Re: command help
the data in the file is 'BobMenefee'
I want to use sed to change it to Bob Menefee.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:16 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:18 AM
09-05-2002 11:18 AM
Re: command help
"I have a file that looks like this:
BobMenefee
I want it to look like this:
Bob Menefee "
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:24 AM
09-05-2002 11:24 AM
Re: command help
Thanks,
I've only been trying this for about 2 hours. It took you 2 seconds. I hate people like you.......just kidding.
Thanks a heck of a lot.
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:24 AM
09-05-2002 11:24 AM
Re: command help
sed -e 's/\([A-Z]\)/ &/g' caps | sed -e 's/^ //'
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:26 AM
09-05-2002 11:26 AM
Re: command help
I thibk you cannot subsitute for the whole set it slef bcoz the logic will fail when it seraches for what to put ?
may be you can try for each and then run the whole 26 times like this
sed s/'A'/a/g
sed s/'B'/b/g
sed s/'C'/c/g
and so on
and then run this on the cpas file
Manoj Srivastava
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:27 AM
09-05-2002 11:27 AM
Re: command help
Manoj Srivastava
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:29 AM
09-05-2002 11:29 AM
Re: command help
perl -n -e '{s/([^ ])([A-Z])/$1 $2/;print}' caps
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2002 11:33 AM
09-05-2002 11:33 AM
Re: command help
perl -n -e '{s/([^ ])([A-Z])/$1 $2/g;print}' caps
need more caffeine...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-06-2002 12:54 AM
09-06-2002 12:54 AM
Re: command help
# perl -pi -e 's/([a-z])([A-Z])/$1 $2/g' data_file