gitignorio-cli
Create and update .gitignore files using gitignore.io with automatic language detection.
Install from PyPI:
pip install gitignorio-cli
# or
uv tool install gitignorio-cli
For local development:
uv tool install .
# or
pip install .
Usage
The command is gi:
gi create # OS template + detected languages
gi create --no-detect # OS template only
gi update # append newly detected languages
gi add python node # append specific templates
gi list # list available templates
gi hooks install # auto-create/update .gitignore via git hooks
Use --path / -p to target a directory other than the current one.
Git hooks
Install hooks once per repository (or use --global to seed new repos created with git init):
gi hooks install
gi hooks install --global
This installs:
- post-checkout — creates
.gitignorewhen a repository is initialized (clone/checkout) if one does not exist - pre-push — updates
.gitignorebefore each push, or creates it if missing
Existing hook scripts managed by gitignore-cli are updated in place. Other hook scripts are left intact and receive an appended gitignore-cli block.
Running gi hooks install also creates .gitignore immediately when it is missing in the current repository.
Language detection
create and update use github-linguist and magika. The CLI installs them automatically on first run if Ruby gem and pipx are available.
License
MIT — see LICENSE.md.
Templates are bundled locally (sourced from gitignore.io) and work offline. To refresh them:
python scripts/download_templates.py
Generated .gitignore content is CC0.
Metadata
Release files for gitignorio-cli 0.1.0
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 |
|---|---|---|---|---|
| gitignorio_cli-0.1.0.tar.gz | 135.9 kB | Without provenance | Details for gitignorio_cli-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| gitignorio_cli-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for gitignorio_cli-0.1.0-py3-none-any.whl |
Total release size: 468.6 kB
Release files / gitignorio_cli-0.1.0.tar.gz
| Download URL | gitignorio_cli-0.1.0.tar.gz |
|---|---|
| Size | 135.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
783f5afc7067dce460810c606357f1ef734e7048917dd3fd39429a368743d790
|
|
BLAKE2b-256 checksum How to use checksums |
e06c5a2cb516a2c0d383e36b7e44dd8f2a06c104fb5a2ffcd53d527475688141
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.5
|
Release files / gitignorio_cli-0.1.0-py3-none-any.whl
| Download URL | gitignorio_cli-0.1.0-py3-none-any.whl |
|---|---|
| Size | 332.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e26545095695526ccefd286dda06d3e4b0236df0a23881ae92be4b084d0c2fa9
|
|
BLAKE2b-256 checksum How to use checksums |
16aab124beadacdda8e392b9d542918c24b9ba643f2feae23a16906acaa59338
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.5
|
Security for gitignorio-cli 0.1.0
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.