Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-24 Thread energy . d
One thing you could do to prevent such accidental data loss in the future is changing the default behaviour of the rm command for example with aliases. This is what i have in my /etc/bash.bashrc to do this job: alias rm='rm -div' alias rrm='\rm -IRv' alias mv='mv -iv' alias cp='cp -iv' a

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-22 Thread dguthrie
yay! please stay join irc for stuff like this and talk to us on #trisquel, #fsf, and #gnu on freenode :-)

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-22 Thread mkl80
Thanks I will continue to make questions if there are any. Abracao

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-22 Thread Adonay Felipe Nogueira
Don't worry mate, I accept your apologies. I'm glad that you didn't insist on calling me like that again and again (I know some people that are really difficult to deal with because of this). We all know that humans experience pressure due to external factors, and everyone reacts differently ever

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-21 Thread Adonay Felipe Nogueira
Thank you very much! :) signature.asc Description: This is a digitally signed message part

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-19 Thread mkl80
Thank you all for the replies, thank you very much! But first of all I want to apologise to ADFENO. What I said it was not right, i Admit. Even if I was furious due to that event it was no way an excuse to talk to somebody like that. Sorry ADFENO and sorry to all the Forum. Desculpa colega, vo

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-19 Thread martin
Or you could use: find -name '*.c' -exec rm {} + Which should be even better.

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-19 Thread martin
To add to what jbar suggests, it's even better to write: find -name '*.c' -print0 | xargs -0 rm Doing it this way should be even safer since names may have new lines in them (almost never in reality, but it's possible). I would also suggest adding an echo before rm or any other command you r

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-18 Thread jbar
By default xargs uses both spaces and newlines as item delimiters. The -d "\n" option tells xargs to use only newlines as delimiters, thus avoiding this problem in this context. $ find ./ -name "*.c" | xargs -d "\n" rm

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-18 Thread greatgnu
Actually his photo is very nice and he is a very nice dood. I cannot say the same of you. Spitting out nonsense shit on someone who tries to help you speaks loud of yourself, and you should maybe not write at all here, not until you learn some common decency anyway.

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-18 Thread legimet . calc
You probably have spaces in your filenames (perhaps your home directory). In this case, not using -rf would have mitigated the damage. But, you shouldn't use xargs with find. Instead, use the -exec option like this: $ find . -name '*.c' -exec rm {} \; That way, you don't have to worry about s

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-18 Thread firefoxbugreporter
If you create a directory and a file like this mkdir 'x ./' touch 'x ./ x.c' and try the find command, you will have a match x ./ x.c Now if you pipe this into xargs rm you don't have just one path. You have three x ./ x.c The middle one is the current directory. So all will be gone. You are r

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-17 Thread Adonay Felipe Nogueira
Readers must note: The message to which I'm replying to has more content than what appears in the forums, see the same comment in the trisquel-users mailing list for the complete message (with more command options):

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-17 Thread isaac
And that, folks, is how you respond extremely generously when someone comes asking for help and proceeds to treat you with offensive disrespect. Obrigado, compa. You're one of the people who consistently keeps this forum a pleasant and supportive environment for new-comers, old-timers, and ev

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-17 Thread Adonay Felipe Nogueira
Sorry, I know I'm dumb in most things (and slow also, :D), but I wouldn't go that far as to call someone a dumb/donkey person. Besides, my portrait is indeed not ideal, but it's the best I have for now. :) So, regarding the incident: Perhaps I know what happened... Although I'm not sure how your .

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-17 Thread mkl80
Sirs are you joking with me? this command is a blue print of my history file. here it is again: 416 sudo find . -name "*.c" | xargs rm -rf There is no "c*" nor "*c*"!!! Common! If I had used such a command it was in the history file! More it would then had removed all files and not just Docum

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-17 Thread Adonay Felipe Nogueira
I tested your command with: find -name "*.c" | less ... And got every good match, except ".bashrc". You must have used: find -name "*c" ... to result in such a mess. Every time I work with the command line, I do multiple tests to make sure things would work as expected, and since I'm slow, it

Re: [Trisquel-users] Just lost every important files in my Trisquel Linux!!!! Very serious!

2016-09-17 Thread dguthrie
Recover with photorec/testdisk. Don't run weird commands without understanding them. I have no idea what the command does. It looks strange though. If the bashrc file is gone as well as documents you probably did "*c*" instead of "*.c". Make frequent backups. Always.