r/ProgrammerHumor • • Aug 01 '22

>>>print(“Hello, World!”)

Post image
60.8k Upvotes

5.7k comments sorted by

View all comments

449

u/magicmulder Aug 01 '22
  rm -rf /

379

u/vld-ul Aug 01 '22

Real ones use -no-preserve-root

59

u/[deleted] Aug 01 '22

Only limited to the gnu implementation of rm. You can technically run this command under BSD without using ---no-preserve-root

10

u/bilinmeyenuzayli Aug 01 '22

man you just gotta do rm -rf /\*

and it works fine everywhere

5

u/Modena89 Aug 01 '22

...which I mistakingly did once

5

u/Daniel15 Aug 01 '22

One time I was trying to delete a directory literally called ~ and accidentally deleted my homedir. Luckily this was on my development server at work and they have hourly backups.

4

u/ItsPronouncedJithub Aug 02 '22

What a coincidence. I once tried to remove a directory called /

→ More replies (2)

7

u/[deleted] Aug 01 '22

This should work without that flag:

sudo find / –type f | xargs rm -f

do it pussy

→ More replies (1)

345

u/akashy12 Aug 01 '22

Since OP hasn't replied to this, so I think he tried this and deleted himself out of existence.

6

u/theghostofme Aug 01 '22

Like putting My Computer into the Recycle Bin erased your computer from existence.

→ More replies (1)

159

u/[deleted] Aug 01 '22

pro tip - use

sudo rm -rf /

124

u/VladVV Aug 01 '22

Real men are always logged in as root

10

u/TheCrimsnGhost Aug 01 '22

I am become root, destroyer of directories.

4

u/Tcloud Aug 01 '22

I am Root!

4

u/Siegelski Aug 01 '22

Brb gonna use this on my old computer. Well, I have to reinstall Linux first but that's fine.

→ More replies (5)

32

u/zoinkability Aug 01 '22

You forgot the sudo

41

u/bingo_is_my_game_o Aug 01 '22

I'm an expert computer user so my user account is already privileged obvi

→ More replies (1)
→ More replies (3)

36

u/EthanHermsey Aug 01 '22

That's a command

34

u/__SpeedRacer__ Aug 01 '22

It was a command.

17

u/Kobens Aug 01 '22

(true story... about 10 years ago, afternoon on a Friday)

- New hire approaches me:: "I... I think I did something wrong"

- 5 minutes later, My boss, once I got on the phone with him: "Type ___ and tell me what it says"

- Me: "Command not found" Boss: "fuck..."

(what had happened: rm -rf /var... server still partially worked, was still in process of deleting itself)

→ More replies (1)
→ More replies (1)

12

u/[deleted] Aug 01 '22

It's technically a line of code in Bash, so...

→ More replies (3)
→ More replies (2)

5

u/dethnight Aug 01 '22

rm -rf /

Not sure, let me try that in my terminal real quick.

→ More replies (22)