Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Gitignore Laravel Package

civicrm/gitignore

A Laravel/PHP package for managing .gitignore rules, helping keep generated and environment-specific files out of version control. It provides a simple way to maintain consistent ignore patterns across CiviCRM projects.

View on GitHub
Deep Wiki
Context7

PHP library for parsing and applying .gitignore-like rules

Frequently asked questions about Gitignore
How do I install civicrm/gitignore with Composer in Laravel?
Run composer require civicrm/gitignore and let Composer autoload the library. There is no Laravel service provider shipped, so instantiate the parser or matcher directly or bind a thin adapter in a service provider. Confirm the package is available on Packagist with a tagged release before relying on it.
Does civicrm/gitignore work with Laravel 10, 11, and 12?
It is a framework-agnostic PHP library with no Laravel coupling, so Laravel version support depends mainly on its declared PHP range. Check composer.json for the supported PHP constraint, ideally ^8.1 or newer, and run your own integration test on the Laravel version you target. Do not assume Laravel compatibility from the package name alone.
What license does civicrm/gitignore use, and is it safe for commercial Laravel products?
The repository metadata shows NOASSERTION, meaning GitHub cannot classify the license automatically. Because CiviCRM projects often use GPL or AGPL-family licenses, read the LICENSE file and composer.json directly and get legal review before shipping it in a commercial product. Treat license clarity as a blocker, not a detail.
Does civicrm/gitignore match git check-ignore exactly for negation, ** globs, and directory-only rules?
That is the key acceptance criterion, and it must be proven rather than assumed. Gitignore semantics are deceptively hard around negation ordering, ** patterns, trailing-slash directory rules, anchoring, and escaping. Ask for a golden-file test suite derived from git's own ignore-rule cases; without one, you own the validation burden.
Do I need a Laravel service provider to use civicrm/gitignore?
No provider is shipped, and you do not need one to use the library. For clean Laravel integration, define a small GitIgnoreMatcher contract, write a CivicrmGitIgnoreAdapter, and bind it in a service provider. That adapter boundary lets you swap or fork the implementation without changing call sites.
What PHP versions does civicrm/gitignore support?
The authoritative answer is the PHP constraint in composer.json and the CI matrix on the repository. The package is expected to be plain PHP with no runtime dependencies beyond standard PHP, but you should verify the declared range, ideally ^8.1 or newer. Test installation under your production PHP version before adopting it.
How does civicrm/gitignore compare with Symfony Finder's Gitignore or running git check-ignore?
Symfony Finder already provides ignore-style filtering, and git check-ignore is the reference implementation when git is available. Adopt civicrm/gitignore only where you need precise gitignore semantics in pure PHP, such as deploy artifact filtering, sparse-checkout tooling, or monorepo path selection. Keep it behind an adapter so you can fall back to Finder or git.
Does civicrm/gitignore support sparse-checkout cone mode?
The package is described as parsing gitignore-like rules, which may cover sparse-checkout manifests as pattern lists. Cone mode semantics differ materially from a flat pattern list, so confirm whether the library supports cone mode or only non-cone patterns. Do not assume cone-mode parity without tests.
Can I cache compiled gitignore patterns when using civicrm/gitignore?
Caching depends on whether the API exposes pattern compilation separately from matching. If it does, compile once per repository state and cache the compiled rules, then reuse them for repeated path checks. If it does not, wrap matching in your adapter and cache at a higher level where safe.
Is civicrm/gitignore actively maintained and safe for production?
It appears to be an internally maintained CiviCRM utility with low external adoption, so expect a small maintainer base and unknown release cadence. The code is small enough to vendor or fork if needed, but make that an explicit contingency rather than a surprise. Pin a tagged version, monitor the repository, and isolate it behind your adapter.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
uni-method/symfony-lib
tacticmedia/scim-server-bundle
neika-ai/symfony-bundle
mattleads/agent-publishing-bundle
glavweb/framework-bundle
glavweb/extra-bundle
glavweb/api-bundle
glavweb/admin-bundle
adachsoft/api-version-bundle
elsayed85/laravel-api-exceptions
ouhssini/laravel-demo-mode
daworks/ncloud-outbound-mailer-driver
gp247/cms
ignibyte/aic-gates
nexa-merchant/blog
novasa/laravel-language-center
opencage/geocode
adolfoholzer/parameters
livenetworks/ln-starter
cgv/localized-resource