ren (command)

Description of the RENAME command of RT-11SJ displayed on a VT100.

In computing, ren (or rename) is a command in various CP/M[1], MP/M[2][3], DOS, OS/2 and Microsoft Windows[4] command line interpreters (shells) such as COMMAND.COM, cmd.exe, 4DOS, 4NT and Windows PowerShell.

It is used to rename files and in some implementations (such as AmigaDOS[5]) also directories. It can also move a file to a new path, if it is on the same device. It is analogous to the Unix mv command.

OpenVOS[6], RT-11[7], RSX-11, OS/8[8], TOPS-20[9], FlexOS[10] and OpenVMS also provide the rename command which in some cases can be contracted to ren. In Windows PowerShell, ren is a predefined command alias for the Rename-Item Cmdlet which basically serves the same purpose.[11]

The command is also available in the open source MS-DOS emulator DOSBox.

Example

ren filename newname
ren *.htm *.html

Another example. This will rename a default video found in Windows 7 with a new name:

ren C:\Users\Public\Videos\"Sample Videos"\Wildlife.wmv Wildlife2.wmv

See also

References

  1. http://www.cpm.z80.de/manuals/cpm22-m.pdf
  2. Digital Research (July 1981) [1979]. MP/M - Multi-Programming Monitor Control Program - User's Guide (PDF) (4 ed.). Pacific Grove, CA, USA: Digital Research. Archived (PDF) from the original on 2017-01-04. Retrieved 2017-01-04.
  3. Digital Research (1981-09-25). MP/M-86 Operating System - User's Guide (PDF) (1 ed.). Pacific Grove, CA, USA: Digital Research. Archived (PDF) from the original on 2017-01-04. Retrieved 2017-01-04.
  4. "Microsoft TechNet Rename (ren) article".
  5. https://archive.org/details/1988-rugheimer-spanik-amigados-quick-reference
  6. http://stratadoc.stratus.com/vos/19.1.0/r098-19/wwhelp/wwhimpl/common/html/r098-19.pdf
  7. http://paleoferrosaurus.com/beta/documents/rt11help.html#RENAME
  8. "Concise Command Language" (CCL)."OS/8 Handbook" (PDF). April 1974. Retrieved 28 November 2017.
  9. "TOPS-20 Command manual" (PDF).
  10. http://www.bitsavers.org/pdf/digitalResearch/flexos/1073-2003_FlexOS_Users_Guide_V1.3_Nov86.pdf
  11. "Microsoft TechNet PowerShell Rename-Item (ren) article".
This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.