git-ignores
is a Git plugin designed to streamline the creation of .gitignore
files for your projects. It leverages GitHub's extensive collection of .gitignore
templates to generate tailored ignore rules based on your project's language or framework.
To use git-ignores
, follow these simple steps:
-
Install the Plugin: Ensure you have Go 1.22 or later installed, then run:
$ make $ sudo make install
-
Generate
.gitignore
: Run theignores
subcommand with the desired options:$ git ignores --template [TEMPLATE_NAME] [--force] [--output PATH]
--template [TEMPLATE_NAME]
: Specifies the name of the gitignore template from the GitHub repository. For example,Python
orJavascript
.--force
: (Optional) Forces the replacement of the existing.gitignore
file with the new template.--output [PATH]
: (Optional) Specifies a custom path to write the.gitignore
file.
-
Example:
$ git ignores --template Python --force
-
View Help: To view the help message, run:
$ git-ignores --help
Contributions to git-ignores
are welcome! Whether it's bug fixes, feature enhancements, or documentation improvements, feel free to submit pull requests.