Answer the question
In order to leave comments, you need to log in
How to create a gitignore file on mac when uploading a project to gitHub?
How to create a gitignore file on mac when uploading a project to gitHub?
Answer the question
In order to leave comments, you need to log in
The .gitignore file is not created when the finished work is submitted to an external repository, but long before. Preferably even before the first local commit is created. This is a plain text file and is created like any other code file. Mac is no different from Windows or Linux. Unless the Finder does not show names starting with a dot. If you press command
+ shift
+ .
, you will see hidden files. But we still create files in a text editor or IDE, and not in Explorer. Both the editor and Git see this file anyway.
You just create a file called .gitignore, write everything that needs to be ignored into it, commit to a turnip. That
's it But the already committed files that are ignored will not disappear from this - they will have to be deleted separately.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question