how to allow files starting with period and no extension in windows 2003 server? [closed]
Asked Answered
P

2

23

How can I create this file in a directory in windows 2003 SP2:

.hgignore

I get error: You must type a file name.

Poulos answered 21/8, 2008 at 7:26 Comment(3)
This is not related to software development? How to make an ignore file on windows server for mercurial? What is it related to, then, masonry and plumbing?Poulos
Relevant: blog.stackoverflow.com/2013/06/the-war-of-the-closes I mean, a more helpful way to deal with this issue would have been to migrate the question to Super User. Anyway, I found the question and answer useful, so I gave them upvotes.Ileus
Related post on the desired forum - Create/rename a file/folder that begins with a dot in Windows?Dam
N
27

That's a "feature" of Windows Explorer. Try to create your files from a command line (or from a batch/program you wrote) and it should work fine. Try this from a dos prompt:

echo Hello there! > .hgignore
Numismatist answered 21/8, 2008 at 7:28 Comment(4)
You CAN. Just type another dot at the end. Type the name as .hgignore.Summand
That works, but only on Vista or later.Numismatist
The MSWindows command line interface is not a "DOS prompt" in NT-based OS versions.Malenamalet
@Malenamalet I will never not ridicule the tacked-on, inferior and clunky DOS prompt of Windows by not calling it a DOS prompt. (:-P)Numismatist
N
5

By the way Raymond Chen had a blog post about this topic a while back:

Why doesn't Explorer let you create a file whose name begins with a dot? (archive.org link with comments: https://web.archive.org/web/20100305064616/http://blogs.msdn.com/oldnewthing/archive/2008/04/14/8389268.aspx)

In which he mentions

You can do it from the command line or use your favorite file management tool.

Nab answered 21/8, 2008 at 8:18 Comment(1)
'or use your favorite file management tool' # Useful, I thought Explorer was a 'file management tool'Pasticcio

© 2022 - 2024 — McMap. All rights reserved.