Search Results

Search: Posts Made By: shanmu
28,656
Posted By shanmu
Hi ningy, small change in your solution ...
Hi ningy,
small change in your solution

awk -F";" '{for(i=1;i<=NF;i++){if ($i ~ /rrr/){print $i}}}' FileName

Regards,
Shanmu

---------- Post updated at 11:33 AM ---------- Previous...
1,297
Posted By shanmu
search file in a unix
Hi,

You can use find command ,

find `pwd` -name "partoffilename"

if you need to get the full path means you can use this

cheers,
shanmu
28,433
Posted By shanmu
Add a new column to txt file containing filename
Hi Kelly,

Try this too,

nawk '{a=FILENAME;}{print a"\t"$0}' yourFilename > yourFilename.bk && mv yourFilename.bk yourFilename

since you are working for single file, you can get your...
2,690
Posted By shanmu
mount directry
hi mate,

u need to list the all directries from current dir or u need all sub directries which inside current directries

thanks
shanmu
2,705
Posted By shanmu
Hi Robin, Pls try this using sed and awk: ...
Hi Robin,

Pls try this using sed and awk:

find . -type f -exec ls -1 {} \; | sed 's/\(.*\)\///g' | xargs ls -l | awk '{print $4,$8;}'

find . -type f -exec ls -l {} \; |nawk...
3,121
Posted By shanmu
Hi try this
Hi Robin,

Please try this,

find . -type f -exec ls -1 {} \; | sed 's/\(.*\)\///g' | xargs ls -l | awk '{print $4,$8;}'

with cheers:b:,

shanmu
2,934
Posted By shanmu
FYI
Hi Dude,

FYI,

ls -ltr | grep '^d' | awk '{print $8;}' | xargs -I {} find `pwd`'/{}' -type d

the above mentioned one sort the sub directries by time from older date to latest date but we...
2,934
Posted By shanmu
please try this
Hi nomadvisuals,

Please try this,

find `pwd` -type d | xargs ls -ld | awk '{print $4,$5,$6,$7,$8}'

with Chears :b:,

Shanmu
1,844
Posted By shanmu
Dear Praveen, Try the below mentioned command...
Dear Praveen,
Try the below mentioned command to solve the mentioned one,
CODE:
in sed ::
sed 's/,[0-9][0-9]*,/,/g' File1
in nawk ::
nawk '{gsub(/,[0-9]*,/,",");print ;}' File1

Your i/p...
Showing results 1 to 9 of 9

 
All times are GMT -4. The time now is 03:22 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy