Timeline for Since when do the POSIX and GNU rm not delete /?
Current License: CC BY-SA 3.0
14 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Dec 14, 2017 at 15:09 | comment | added | Stéphane Chazelas |
@Guru, yes those !(...) patterns come from ksh (ksh88, ksh86a didn't have them), they're enabled with set -o kshglob in zsh (zsh also has its own (more usable if you ask me) extensions, and zsh like pdksh or fish already do the right thing when it comes to . and .. in globs). With ksh, you get an interesting outcome if you do FIGNORE='!(..)' ksh -c 'echo rm -rf */*'
|
|
| Dec 14, 2017 at 10:05 | history | edited | Stéphane Chazelas | CC BY-SA 3.0 |
added 110 characters in body
|
| Dec 14, 2017 at 9:57 | history | edited | Stéphane Chazelas | CC BY-SA 3.0 |
added 160 characters in body
|
| Dec 14, 2017 at 9:45 | history | edited | Stéphane Chazelas | CC BY-SA 3.0 |
added 2410 characters in body
|
| Dec 14, 2017 at 3:52 | comment | added | Escoce | maybe in modern shells. It wasn't always that way. I left that depth of system administration and development more than 15 years ago | |
| Dec 14, 2017 at 3:49 | comment | added | Escoce | @GuruAdrian sure, * means match everything so .* = .filename but also ../ and therefore ../.. and ../../.. ad infinatum until you run out of bitspace for the command. | |
| Dec 14, 2017 at 2:23 | comment | added | Escoce | I bet $ rm -rf .* = rm -rf / in a convoluted way to get there. | |
| Dec 14, 2017 at 0:18 | comment | added | Aaron D. Marasco |
As a young co-op SA, I tried erasing the hidden files in a user's directory on SunOS w/ rm -rf .* from his home dir. Shortly after, all the phone lines lit up...
|
|
| Dec 13, 2017 at 23:46 | history | edited | Stéphane Chazelas | CC BY-SA 3.0 |
added 556 characters in body
|
| Dec 13, 2017 at 23:33 | history | edited | terdon♦ | CC BY-SA 3.0 |
Fixed date
|
| Dec 13, 2017 at 23:31 | vote | accept | terdon♦ | ||
| Dec 13, 2017 at 23:30 | history | edited | Stéphane Chazelas | CC BY-SA 3.0 |
added 403 characters in body
|
| Dec 13, 2017 at 23:24 | comment | added | JdeBP | Bryan Cantrill tells a story about this. See also superuser.com/questions/742334 and superuser.com/questions/542978 . | |
| Dec 13, 2017 at 23:19 | history | answered | Stéphane Chazelas | CC BY-SA 3.0 |