Search Results

Search: Posts Made By: Kibou
3,549
Posted By Kibou
Thanks. My bad. Those previous solutions work. ...
Thanks. My bad. Those previous solutions work.

I was testing it with the wrong file. My apologies.

Thanks again for the help. I've learned a lot.
3,549
Posted By Kibou
@Scrutinizer Unfortunately doesn't work either....
@Scrutinizer Unfortunately doesn't work either. I've tried a few modifications but it only prints the first three lines.

@MadeInGermany It works, but for some reason the text is all the way...
3,549
Posted By Kibou
it works!.. however I don't know how to make it...
it works!.. however I don't know how to make it work for the whole file. After the first three lines it stops.

awk '{k=1;j=1;for (i=1;i<=NR;++i) k=i+2;j=i+1;print k,j,i}' RS= FS='\n' OFS='\n'...
3,549
Posted By Kibou
Swapping lines
Hi there,

I have a text that I'm trying to format into something more readable. However, I'm stuck in the last step. I've searched and tried things over the internet with no avail.

OS: Mac
...
2,013
Posted By Kibou
I really appreciate it. I am always speechless...
I really appreciate it. I am always speechless with your amazing approaches. :b:
2,013
Posted By Kibou
Put in one line only the lines with digits
Hello,
I haven't been here for a while and I might be forgetting some things.
I have an input text like this

titleA
http://myurl/bla/blabla/1234
http://myurl/bla/blabla/6789

titleB...
2,402
Posted By Kibou
I see what he means. I got confused with emailing...
I see what he means. I got confused with emailing inside the script and emailing outside the script. Thanks Aia.
2,402
Posted By Kibou
First thing I notice is that you are redirecting...
First thing I notice is that you are redirecting the output of a script to /dev/null in crontab which does not make much sense to me.
Second, it is a bit difficult to guess what is your script doing...
3,401
Posted By Kibou
Thank you! I understand it now. Thanks for...
Thank you! I understand it now.
Thanks for your time and effort, to both of you.
3,401
Posted By Kibou
sorry to ask again, the s=s and the $1 all alone...
sorry to ask again, the s=s and the $1 all alone there? Never seen OFS on its own, always something like OFS="whatever"
3,401
Posted By Kibou
Could you explain it for us? Why sub for an "x"?...
Could you explain it for us? Why sub for an "x"? I don't get it..

thnx
1,516
Posted By Kibou
Hello, As Don said, that fixed an error. Now...
Hello,

As Don said, that fixed an error. Now you have a new one.

If you just want to extract the percentage, try something like this:

mountpoint=$(df -h /home | awk -F' |%' '{print $17}' |...
1,831
Posted By Kibou
Sample output, kibou@laptop:~$ touch...
Sample output,

kibou@laptop:~$ touch /tmp/file{1..5}
kibou@laptop:~$ find /tmp/ -name file*
find: Las rutas deben preceder la expresión: file1
Uso: find [-H] [-L] [-P] [-Onivel] [-D...
1,831
Posted By Kibou
This can be easily mistaken after you have seen...
This can be easily mistaken after you have seen something like this

find -name "*.jpg"

which it does actually expands. The find command does not expand the same way the shell does.
1,533
Posted By Kibou
I am glad it helped, but does it work? This...
I am glad it helped, but does it work?

This line complains using the sample you gave to us in the beginning

cat yes_output.csv >> $(ls -ltr BW* | awk 'END{print $9}')
1,533
Posted By Kibou
Oh, you used the same file for the explanation! ...
Oh, you used the same file for the explanation!

I've just come up with something like this

kibou@laptop:~$ awk -F, '$2 == "e" {f=3} END{exit f}' file ; echo $?
3
kibou@laptop:~$ cat file...
1,533
Posted By Kibou
Thank you Akshay Hedge. I also tried it...
Thank you Akshay Hedge.

I also tried it also outside the BEGIN block but it didn't work to me. It does work so I obviously did something wrong.

And thank you for the explanation as well.
1,533
Posted By Kibou
I am sure it must be a more elegant solution and...
I am sure it must be a more elegant solution and more efficient.

If I understood correctly, you want to rename the file BW*2014*.csv if the field 12 is "No" and remove those lines matching.

#...
1,473
Posted By Kibou
Bash syntax
Hello,

I have seen this syntax,

{ ;;};quite often and I don't know what it means exactly.

It seems like a distinctive thing of Bash, so it's been used for the logo of the last bug,
...
1,299
Posted By Kibou
Just this little detail in case our friend...
Just this little detail in case our friend doesn't know how to add a Field Separator,
1,962
Posted By Kibou
The else / if syntax is something basic you can...
The else / if syntax is something basic you can look for on the internet with a simple search looking for bash syntax.

If you want to delete more than one file you need it to be recursive, with...
1,890
Posted By Kibou
kibou@laptop:~$ cat text.txt 21356 suresh...
kibou@laptop:~$ cat text.txt
21356 suresh 12/12/2012
23511 ramesh 11/06/2011
31456 biswajit 09/08/2013
53134 archan 06/02/2009
kibou@laptop:~$ sed 's;\(ramesh\);\1_terminated;' text.txt ...
20,342
Posted By Kibou
As Corona688 said, you better use nohup, but I...
As Corona688 said, you better use nohup, but I think he missed the & at the end.

nohup run_server.csh &
1,568
Posted By Kibou
Hello, May I explain this one? awk...
Hello,

May I explain this one?

awk -F"[:,]" '{if ($1~/@2 line/){print $1": <XO>"$2"<XC,\""$2"\",\"\",\"\",\"\",0,0,\"\">,<XO>"$3"\",\"\",\"\",\"\",0,0,\"\">"}else{print $0}}' file

-F is the...
3,683
Posted By Kibou
Yes!! Thank you, RudiC.
Yes!!

Thank you, RudiC.
Showing results 1 to 25 of 72

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