Search Results

Search: Posts Made By: asal_email
37,940
Posted By asal_email
I have tried that method you proposed ... but...
I have tried that method you proposed ...
but ... you only delete one specific pattern in each iteration and left the others which you will be retained when you delete another pattern.
In the end...
37,940
Posted By asal_email
multiple delete using sed
Hi, I used to use sed to delete pattern from file using:

sed '/PATTERN/d' myfile

but how if I have 100 pattern to delete which is listed separated by new line in file called mypattern

sed -e...
29,202
Posted By asal_email
The condition guarantee to be satisfied after...
The condition guarantee to be satisfied after about 10 loops
29,202
Posted By asal_email
I actually want to use those random number on the...
I actually want to use those random number on the fly such :
#! /bin/bash
while (condition)
do
number=$RANDOM
do some work here using random number until condition satisfied
done

the...
29,202
Posted By asal_email
Thanks, great code !!! but I need some...
Thanks, great code !!! but I need some clarifications.

when you compare the generated number to previous one, using :
if (!(numb in prev))
isn't comparing only the last generated random number...
29,202
Posted By asal_email
Random numbers without repetition
Is anyone know some scripts to generate random number without repetition using bash; for example generate 10 different random numbers.

Thanks
23,331
Posted By asal_email
thx
Thanks, it really works. but when I want to put in standard output it takes a very slow processing.

Do u know other way using sed or awk ?
since I want to print other thing after the file name...
23,331
Posted By asal_email
find | xargs cat
Hai I just want to find a file *.txt in particular direcotry and display the file name puls the content. Do someone know hot to do this, thanks.

I try :
find test/ -name '*.txt' | xargs cat
...
1,659
Posted By asal_email
awk problem
Say I have string=test99
I would like to extact the number 99 and put it in different variable using shell script including awk as well.

I know it will be easy in Perl :
$_=test99;
/.*(\d+)/;...
Showing results 1 to 9 of 9

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