Gitignore Maker
A powerful command-line tool for managing .gitignore files with language-specific templates and size-based filtering. This tool allows you to create and update .gitignore files based on your project's programming languages, while also filtering out large files and folders exceeding a user-defined size limit.
Introduction
Managing a clean and comprehensive .gitignore file is crucial for ensuring that unnecessary files are excluded from your Git repositories. This CLI tool simplifies that process by allowing you to:
- Automatically generate
.gitignorecontent based on your project's programming languages. - Filter files and folders by size, ensuring that large assets are ignored.
- Exclude specific files and folders from being added to
.gitignore.
With just a few commands, you can maintain an optimized and language-specific .gitignore file tailored to your project's needs.
Key Features
- Language-Specific
.gitignoreTemplates: Generate.gitignorecontent based on the programming languages used in your project. - Size-Based File Exclusion: Automatically add files and folders to
.gitignoreif they exceed a specified size limit. - Custom Folder and File Exclusion: Specify folders and files to ignore during size-based filtering.
- Seamless Integration: The tool can be easily integrated into your project management workflow, automating the generation and update of
.gitignore.
Installation
Install the libray:
pip install gitignore-maker
Usage
Run the CLI tool by specifying your desired options.
gitignore_maker [OPTIONS]
Options
| Option | Description |
|---|---|
--languages |
Specify the programming languages to include in the .gitignore. Example: --languages Python Node. |
--size-limit |
Set a size limit for files (in bytes). Files larger than this limit will be added to .gitignore. Default is 49 MB. |
--ignore-folders |
Specify folders to exclude during file size checks. Example: --ignore-folders venv node_modules. |
--ignore-files |
Specify files to exclude during file size checks. Example: --ignore-files large_file.txt. |
--list-languages |
List all supported programming languages and exit. |
Examples
-
Generate a
.gitignorefor Python and Node.js:gitignore_maker --languages Python Node
-
Add files larger than 10 MB to
.gitignore:gitignore_maker --size-limit 10485760
-
Ignore specific folders during size checks:
gitignore_maker --ignore-folders venv build
-
List all supported programming languages:
gitignore_maker --list-languages
Example Workflow
Here i s a typical workflow using this tool:
-
Generate a language-specific
.gitignorefile:gitignore_maker --languages Python Node
This will create or update the
.gitignorefile with content for Python and Node.js. -
Filter large files: After generating the
.gitignore, you may want to exclude files larger than 50 MB:gitignore_maker --size-limit 52428800
This will scan the project directory and add all files larger than 50 MB to the
.gitignore. -
Customize exclusion: To exclude certain folders like
venvorbuildfrom being added to.gitignore, you can run:gitignore_maker --ignore-folders venv build
Supported Languages
This tool supports .gitignore templates for various programming languages, including but not limited to:
- Python
- Node.js
- Java
- Ruby
- Go
- PHP
- C++
- ...and more.
To see the full list of supported languages, use the --list-languages option:
gitignore_maker --list-languages
License
This project is licensed under the MIT License - see the LICENSE file for details.
Metadata
Release files for gitignore-maker 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| gitignore_maker-0.1.3.tar.gz | 52.3 kB | Without provenance | Details for gitignore_maker-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| gitignore_maker-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for gitignore_maker-0.1.3-py3-none-any.whl |
Total release size: 132.5 kB
Release files / gitignore_maker-0.1.3.tar.gz
| Download URL | gitignore_maker-0.1.3.tar.gz |
|---|---|
| Size | 52.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
59d45a8a5b15e8a30df4a28cb9997890a1a3c8127827bba76fb1e0e9466cda41
|
|
BLAKE2b-256 checksum How to use checksums |
d11527f58b47c6d667b947a31bd919ba1101f41cae3b22ba839f715a44c6550d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.5
|
Release files / gitignore_maker-0.1.3-py3-none-any.whl
| Download URL | gitignore_maker-0.1.3-py3-none-any.whl |
|---|---|
| Size | 80.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d38df57c08ae3192c94d26311a966b4a2887488e2fbf983dc0dff34a7375589c
|
|
BLAKE2b-256 checksum How to use checksums |
1bd42072e5d5aab56f58acc23365fa19318ca8fc7622c551139bfcb3bbdedc0a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.5
|
Security for gitignore-maker 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.