Del (command)#DOS

{{Short description|Command in various operating systems}}

{{lowercase}}

{{Infobox software

| name = del / erase

| logo =

| screenshot = ReactOS-0.4.13 del command 667x530.png

| screenshot size =

| caption = The ReactOS del command

| developer = DEC, Microware, Microsoft, IBM, DR, Datalight, Novell, JP Software, ReactOS Contributors

| released =

| latest release version =

| latest release date =

| operating system = RT-11, OS/8, RSX-11, OpenVMS, DOS, OS-9, MSX-DOS, FlexOS, SISNE plus, OS/2, Windows, ReactOS, KolibriOS, SymbOS, DexOS

| platform = Cross-platform

| genre = Command

| license =

| website =

}}

In computing, del (or erase) is a command in command-line interpreters (shells) such as COMMAND.COM, cmd.exe, 4DOS, NDOS, 4OS2, 4NT and Windows PowerShell. It is used to delete one or more files or directories from a file system.

Implementations

The command is available for various operating systems including DOS, Microware OS-9,{{cite book|author=Paul S. Dayan|year=1992|title=The OS-9 Guru - 1 : The Facts|publisher=Galactic Industrial Limited|isbn=0-9519228-0-7}} IBM OS/2,{{Cite web |url=http://www.jatomes.com/Help/Os2Cmd.php#ERASE |title=JaTomes Help - OS/2 Commands |access-date=2019-07-20 |archive-date=2019-04-14 |archive-url=https://web.archive.org/web/20190414130029/http://www.jatomes.com/Help/Os2Cmd.php#ERASE |url-status=dead }} Microsoft Windows{{Cite web|url=https://docs.microsoft.com/en-us/previous-versions/windows/it-pro/windows-server-2012-r2-and-2012/cc771049(v=ws.11)|title=Del|website=docs.microsoft.com|date=31 August 2016 }} and ReactOS.{{Cite web|url=https://github.com/reactos/reactos|title=reactos/reactos|website=GitHub|date=3 January 2022}} It is analogous to the Unix rm command and to the Stratus OpenVOS delete_file and delete_dircommands.{{cite web |url=http://stratadoc.stratus.com/vos/19.1.0/r098-19/wwhelp/wwhimpl/common/html/r098-19.pdf |title=Reference manual|website=stratadoc.stratus.com |access-date=2020-09-14}}

DEC RT-11,{{Cite web|url=http://paleoferrosaurus.com/beta/documents/rt11help.html#DELETE|title=RT-11 HELP FILE|website=paleoferrosaurus.com|access-date=2019-07-06|archive-date=2018-07-17|archive-url=https://web.archive.org/web/20180717041552/http://paleoferrosaurus.com/beta/documents/rt11help.html#DELETE|url-status=dead}} OS/8,"Concise Command Language" (CCL).{{cite web

|url=http://bitsavers.trailing-edge.com/pdf/dec/pdp8/os8/OS8_Handbook_Apr1974.pdf

|title=OS/8 Handbook |date=April 1974 |access-date=28 November 2017}} RSX-11,{{Cite book |title=RSX A Guide for Users |date=1987 |author=John F. Pieper |publisher=Digital Equipment Corporation |url=http://www.rsx11m.com/rsxguide.pdf |isbn=0-932376-90-8 |access-date=2020-09-19}} and OpenVMS{{Cite web|url=https://www.itec.suny.edu/scsys/vms/OVMSDOC073/v73/6489/6489pro_005.html|title=OpenVMS User's Manual|website=www.itec.suny.edu}}{{Dead link|date=October 2023 |bot=InternetArchiveBot |fix-attempted=yes }} also provide the delete command which can be contracted to del. AmigaDOS{{Cite book|url=https://archive.org/details/1988-rugheimer-spanik-amigados-quick-reference|title=AmigaDOS quick reference|first1=Hannes|last1=Rügheimer|first2=Christian|last2=Spanik|date=September 14, 1988|publisher=Grand Rapids, Mi : Abacus|isbn=9781557550491|via=Internet Archive}} and TSC FLEX{{Cite web|url=http://www.flexusergroup.com/flexusergroup/pdfs/flex2um.pdf|title=FLEX 2.0 User's Manual}} provide a delete command as well.

The erase command is supported by Tim Paterson's SCP 86-DOS.{{cite book |title=86-DOS - Disk Operating System for the 8086 - User's Manual |edition=Preliminary |version=Version 0.3 |date=1980 |publisher=Seattle Computer Products, Inc. |location=Seattle, Washington, USA |url=http://www.patersontech.com/Dos/docs/86_Dos_usr_03.pdf |access-date=2019-07-14 |url-status=dead |archive-url=https://web.archive.org/web/20190714004434/http://www.patersontech.com/dos/docs/86_Dos_usr_03.pdf |archive-date=2019-07-14}} (59 pages) On MS-DOS, the command is available in versions 1 and later.{{Cite book|author-last=Wolverton|author-first=Van|title=Running MS-DOS Version 6.22 (20th Anniversary Edition), 6th Revised edition|date=2003|publisher=Microsoft Press|isbn=0-7356-1812-7}} It is also available in the open-source MS-DOS emulator DOSBox.

Datalight ROM-DOS also includes an implementation of the {{code|del}} and {{code|erase}} commands.{{Cite web|url=https://www.datalight.com/assets/files/ROM-DOS_Users_Guide.pdf|title=Datalight ROM-DOS User's Guide|website=www.datalight.com}}

While Digital Research DR-DOS supports del and erase as well, it also supports the shorthand form era, which derived from CP/M. In addition to this, the DR-DOS command processor also supports delq/eraq. These are shorthand forms for the del/era/erase command with an assumed /Q parameter (for 'Query') given as well.[https://www.4corn.co.uk/archive/docs/DR%20DOS%206.0%20User%20Guide-opt.pdf DR DOS 6.0 User Guide Optimisation and Configuration Tips]

THEOS/OASIS[http://www.bitsavers.org/pdf/phaseOneSystems/THEOS_OASIS_Users_Handbook_1985.pdf THEOS/OASIS User′s Handbook] and FlexOS{{cite web |url=http://www.bitsavers.org/pdf/digitalResearch/flexos/1073-2003_FlexOS_Users_Guide_V1.3_Nov86.pdf |title=FlexOS User's Guide |date=1986 |website=www.bitsavers.org |access-date=2020-09-14 |archive-date=2019-09-25 |archive-url=https://web.archive.org/web/20190925131719/http://bitsavers.org/pdf/digitalResearch/flexos/1073-2003_FlexOS_Users_Guide_V1.3_Nov86.pdf |url-status=dead }} provide only the erase command.

In PowerShell, del and erase are predefined command aliases for the Remove-Item cmdlet which basically serves the same purpose.

Syntax

>del filename

>erase filename

See also

References

{{Reflist}}

Further reading

  • {{Cite book|author-last=Wolverton|author-first=Van|title=MS-DOS Commands: Microsoft Quick Reference, 4th Revised edition|date=1990|publisher=Microsoft Press|isbn=978-1556152894}}
  • {{Cite book|author1=Kathy Ivens|author2=Brian Proffit|year=1993|title=OS/2 Inside & Out|publisher=Osborne McGraw-Hill|isbn=978-0078818714}}
  • {{Cite book|first=Æleen|last=Frisch|year=2001|title=Windows 2000 Commands Pocket Reference|publisher=O'Reilly|isbn=978-0-596-00148-3}}