I remember reading in an IBM PC-DOS manual, around 1988 maybe, that there was a special syntax of the COPY command :
COPY A.TXT +,,
which would simply update the file's last change date to now. This was equivalent to the touch
command which was available on Unix or bundled with MS-DOS compilers such as Turbo C. I used it occasionally from then on.
Around 1993, a colleague needed to do a "touch" on a file, so I wanted to show off and used COPY SOMEFILE +,,
... and somehow it corrupted her file.
I have a vague memory of trying it again with a later version of MS-DOS, like 6.0, and it didn't function as a "touch".
Which versions of MS-DOS or PC-DOS supported this use of COPY? Is there a story on why they chose this weird syntax?
copy +,,
a binary file that contains Ctrl-Z. If you include the/b
option that shouldn't happen.