Like many Lego-playing pre-teens, my son has recently been drawn to the “building with blocks” computer game called Minecraft. Despite being a relatively new game (version 1.0 was released on November 18, 2011), Minecraft already has a huge following. How huge? According to the Minecraft stats page, as of January 28, 2012, Minecraft has “20,915,072 registered users, of which 4,784,102 (22.87%) have bought the game. In the last 24 hours, 89,886 people registered, and 14,127 people bought the game.”
What accounts for this massive popularity in such short a time? I haven’t played the game myself (yet) but I’ve been looking over my son’s shoulder and what I see is one cool game. Admittedly, the graphics aren’t amazing compared to what you typically see on the XBox 360 and PS3. However, if you like Lego, you’ll love Minecraft. According to the Minecraft website, “Minecraft is a game about placing blocks to build anything you can imagine.” Yup, that sounds a lot like Lego! The best part is, Minecraft is a whole lot cheaper than buying a large Star Wars Lego set!
If you haven’t seen Minecraft yet, I find the graphics somewhat reminiscent of the Doom and Quake games…but without all the gore. Feel free to call me crazy, I’m just saying that on an initial brief look, Minecraft looks at bit like Doom and Quake.
Another similarly of Minecraft compared with Doom and Quake is that Minecraft can be modded by savvy end users. This ability to install mods into Minecraft leads me to the actual topic of this article, which is how to fix the “you must type a file name” error when you try to rename a dot folder or dot file in Windows Explorer. Let me explain.
The process of installing Minecraft mods involves modifying files (usually “minecraft.jar”) inside your “.minecraft” folder (i.e. dot minecraft folder). When my son was trying to install mods the other day, I advised him to backup his entire “.minecraft” folder, just in case the mod didn’t work. So, we copied the “.minecraft” folder to a new folder named “.minecraft.bak”.
Sure enough, one of the mod installations didn’t go well and we had to revert to the backup “.minecraft” folder. To revert back, we used Windows Explorer in Windows 7 to make a copy of “.minecraft.bak”. The copy was named “.minecraft.bak – Copy”. Next, we deleted the ailing “.minecraft” folder. Finally, we tried to rename “.minecraft.bak – Copy” to “.minecraft”. However, Windows Explorer did not allow the rename and instead gave us the annoying error message “You must type a file name.”
Excuse me, Windows Explorer, we did type a name: “.minecraft”!
There are two ways to fix (or rather work around) this rename error. The first way is to open a command prompt window (i.e. “cmd.exe”), “cd” (navigate) to the folder containing the folder to be renamed and then execute the following rename command:
rename “.minecraft.bak – Copy” “.minecraft”
That solution works. However, if you’re not comfortable using the command line, there is a trick you can use to do the rename from within Windows Explorer. Instead of typing in “.minecraft” for the new name, type in “.minecraft.”. Note the extra trailing dot! After you enter that name and press enter, Windows Explorer magically removes the trailing dot. As a result, you end up with the name “.minecraft”, which is what you want.
.minecraft folder, another common dot file that people have problems renaming in Windows Explorer is
.htaccess (i.e. dot htaccess). The solution above works for
I hope this tip helps you rename your dot minecraft folder!
Epilog (Bonus Points for Nerds!)
As an aside, you may be wondering, “What’s the deal with using the folder name
.minecraft, anyway? Why didn’t they just call the folder
It turns out that Minecraft isn’t just for Windows. In addition to Minecraft for Windows, you can also get Minecraft for Mac OS and Linux. Heck, there’s even a pocket edition of Minecraft that runs on Android and iOS. On many non-Windows operating systems, it’s common to store configuration settings in dot folders and dot files. A classic example on Linux is the “.bashrc” file.
Some people refer to “dot files” as “hidden files”. In a sense, this is correct because dot files and folders don’t appear in listings output by the command “ls” (unless you add the “-a” switch). However, in many operating systems such as Windows, you can make a file hidden by applying the “hidden” attribute to the file.