Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 780
  • Last Modified:

Deleting a file named 'nul'

Here is the problem, a script I have written output its errors to 'nul'
 ie. ls > nul
This is pdksh with a cygwin base for unix commands.
Where the big problem exists is that the script creates a file in the running dir called 'nul'. Windows can not have a file named nul nor can you delete a 'nul' file.... pdksh, bask, csh, dos, windows xp, winpe, all cannot delete the file. I have even tried using rar and other comprestion programs to add the file to an archive and delete the file after making archive, and yet again, the file is still there.
Using cat I can see the contents of the file, but so far that is the only command that can see the file, noptead and all windows based programs error on 'nul' files.
If anyone has a way to delete this file that would be great.
0
remyservices
Asked:
remyservices
1 Solution
 
jkrCommented:
Check out http://support.microsoft.com/default.aspx?scid=kb;en-us;315226 ("How to Remove Files with Reserved Names in Windows XP")
0
 
remyservicesAuthor Commented:
Thanks, that got it. Been looking for something like that page for some time, thanks alot.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now