Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Rm (Unix)
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== History == On some old versions of Unix, the <code>rm</code> command would remove directories if they were empty.<ref>{{Cite web|url=http://man.cat-v.org/unix_8th/1/rm|title=rm page from Section 1 of the unix 8th manual|website=man.cat-v.org}}</ref> This behaviour can still be obtained in some versions of <code>rm</code> with the <code>-d</code> flag, e.g., the [[Berkeley Software Distribution|BSDs]] (such as [[FreeBSD]],<ref>{{citation |url=http://modman.unixdev.net/?manpath=FreeBSD-5.4-RELEASE&page=rm&sektion=1&apropos= |title=RM(1) |work=FreeBSD-5.4-RELEASE |access-date=February 5, 2015 }}</ref> [[NetBSD]],<ref>{{citation |url=http://modman.unixdev.net/?manpath=NetBSD-2.0&page=rm&sektion=1&apropos= |title=RM(1) |work=NetBSD-2.0 |access-date=February 5, 2015 }}</ref> [[OpenBSD]]<ref>{{citation |url=http://modman.unixdev.net/?manpath=OpenBSD-3.6&page=rm&sektion=1&apropos= |title=RM(1) |work=OpenBSD-3.6 |access-date=February 5, 2015 }}</ref> and [[macOS]]) derived from 4.4BSD-Lite2. The version in [[GNU Core Utilities]] was written by Paul Rubin, David MacKenzie, [[Richard Stallman]], and Jim Meyering.<ref>{{Cite web|url=https://linux.die.net/man/1/rm|title=rm(1): remove files/directories - Linux man page|website=linux.die.net}}</ref> This version provides a <code>-d</code> option to help with compatibility.<ref>{{cite web |url=http://git.savannah.gnu.org/cgit/coreutils.git/commit/src/rm.c?id=fdc2da7165d93c8065365999341173ad2a818833 |title=rm: new option --dir (-d) to remove empty directories |date=January 22, 2012 |author=Krzysztof Goj |website=coreutils.git }}</ref> The same functionality is provided by the standard <code>[[rmdir]]</code> command.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)