![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| find command in while loop - how to get control when no files found? | mavsman | Shell Programming and Scripting | 3 | 04-03-2008 12:44 PM |
| find common elements in 2 files (for loop) | ibking | Shell Programming and Scripting | 4 | 12-11-2007 04:51 PM |
| Find fields with no spaces in value | alfredo123 | UNIX for Dummies Questions & Answers | 10 | 04-18-2007 07:14 PM |
| For Loop with find | kadishmj | Shell Programming and Scripting | 4 | 05-17-2005 10:42 PM |
| Strip leading and trailing spaces only in a shell variable with embedded spaces | jerardfjay | Shell Programming and Scripting | 6 | 03-07-2005 02:24 PM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
For loop using find with file name spaces
Hello All,
This question is actually for the service console of VMware ESX 3.5 but is relevant to this forum I think. I have been advised to use the following commands: for i in `find /vmfs/volumes/Test_VMFS/ -name "*.vmx"` do echo "$i" #sed -i 's/scsi1:0.present = "true"/scsi1:0.present = "false"/g' "$i" done This works to modify that line in all the .vmx files that do NOT contain spaces in their path. But the ones that do fail. It has to do with the way that the FOR command reads in the variable. I have seen some posts on using the while command but I am unable to translate it into what I need. Plus I am not sure if VMware uses the while command from the Service Console. Any help would be much appreciated! Thanx, Matt |
| Bookmarks |
| Tags |
| for loop with spaces, solaris |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|