Adds an entry to the project's .gitignore file.
Will create a .gitignore file if it doesn't exist.
Will insert the pattern under the heading and create the
heading if it doesn't exist.
the pattern to add to the .gitignore file
Optionalheading: stringoptional heading to place the pattern under
Public API for the project namespace