Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript npm Basics (retiring) Installing Packages with npm Managing Dependencies in the package.json File

can not change the name of gitignore.txt to .gitignore on mac OS

searching about this issue I was not able to find a solution for this problem. Any ideas....

I get this message on mac: you can't use a name that begins with a dot ".", because these names are reserved for the system. Please choose another name.

I don't have a Mac but I do use Linux and I've been told it's similar. Can you go into the terminal and use a command line to copy the file and use .gitignore as the new file name? For example in Linux we can go into the directory that has the file and to copy it we would do: cp gitignore.txt .gitignore

That would create a new file name .gitignore in the current directory.

1 Answer

Robert Schaap
Robert Schaap
19,836 Points

If you haven't already just copied the content and pasted it in a new .gitignore file, try going into your terminal to the folder where it's located and doing mv gitignore.txt .gitignore, that should work.