PHPackages                             gravatalonga/driver-manager - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. gravatalonga/driver-manager

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

gravatalonga/driver-manager
===========================

Driver manager is a class responsible to hold information to configure another objects, for example, database connections, logs configurations, etc

1.0.1(5y ago)15151MITPHP

Since Apr 14Pushed 5y ago1 watchersCompare

[ Source](https://github.com/gravataLonga/driver-manager)[ Packagist](https://packagist.org/packages/gravatalonga/driver-manager)[ GitHub Sponsors](https://github.com/gravataLonga)[ RSS](/packages/gravatalonga-driver-manager/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (5)Versions (3)Used By (1)

[![Driver Manager](DriverManager.jpg)](DriverManager.jpg)

Driver Manager
==============

[](#driver-manager)

[![Latest Version on Packagist](https://camo.githubusercontent.com/d424788d3e153ba420c4ff0e81ef3f83826401cf22dc796e07aaaebcf7c10b59/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f677261766174614c6f6e67612f6472697665722d6d616e616765722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gravataLonga/driver-manager)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/daf2185b2d10ab8375f1e9cc09546684a323888cb0130be9d1f73410b78a05d9/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f677261766174614c6f6e67612f6472697665722d6d616e616765722f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/gravataLonga/driver-manager)[![Tests](https://github.com/gravataLonga/driver-manager/actions/workflows/run-tests.yml/badge.svg)](https://github.com/gravataLonga/driver-manager/actions/workflows/run-tests.yml)[![Coverage Status](https://camo.githubusercontent.com/0a77adffbb09df8bcd513fde0aae58cdfc9d986a77a3bd62f1f71b10f7977140/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f677261766174614c6f6e67612f6472697665722d6d616e616765722e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/gravataLonga/driver-manager/code-structure)[![Quality Score](https://camo.githubusercontent.com/21daa08d6e9adcca07c762208a4215f172c672749dcde73e54546bba67b119dc/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f677261766174614c6f6e67612f6472697665722d6d616e616765722e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/gravataLonga/driver-manager)[![Total Downloads](https://camo.githubusercontent.com/1351727faf065e812fec5735f8c3128f0d869e6977eb5b2448b1cf0561f7e2f1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f677261766174614c6f6e67612f6472697665722d6d616e616765722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gravataLonga/driver-manager)

Driver manager is a class responsible to hold information to configure another objects, for example, database connections, logs configurations, etc

Structure
---------

[](#structure)

```
build/
src/
examples/
tests/
vendor/

```

Install
-------

[](#install)

Via Composer

```
$ composer require gravataLonga/driver-manager
```

Usage
-----

[](#usage)

```
$drivers = [
    'memory' => [
        'host' => ':memory:',
        'driver' => 'sqlite'
    ],
    'master' => [
        'host' => 'server.com',
        'username' => 'root',
        'password' => '1234',
        'driver' => 'mysql'
    ]
];
$required = ['driver', 'host'];
$default = ['timezone' => 'UTC'];
$manager = new Gravatalonga\DriverManager($drivers, $required, $default);
$setting = $manager->driver('memory');
/*
Results:
[
    'host' => ':memory:',
    'driver' => 'sqlite',
    'timezone' => 'UTC'
]
*/
```

Change log
----------

[](#change-log)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Testing
-------

[](#testing)

```
$ composer test
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](.github/CONTRIBUTING.md) and [CODE\_OF\_CONDUCT](CODE_OF_CONDUCT.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Jonathan Fontes](https://github.com/gravataLonga)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

1905d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e4ffa38be69914cd6a634e2916246b70931885bd81e64c8c6848950e99c4c791?d=identicon)[gravataLonga](/maintainers/gravataLonga)

---

Top Contributors

[![gravataLonga](https://avatars.githubusercontent.com/u/1126525?v=4)](https://github.com/gravataLonga "gravataLonga (7 commits)")

---

Tags

configurationSettingsmanagerdriversconfig managerdriver configuration

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/gravatalonga-driver-manager/health.svg)

```
[![Health](https://phpackages.com/badges/gravatalonga-driver-manager/health.svg)](https://phpackages.com/packages/gravatalonga-driver-manager)
```

###  Alternatives

[chillerlan/php-settings-container

A container class for immutable settings objects. Not a DI container.

3435.1M22](/packages/chillerlan-php-settings-container)[dmishh/settings-bundle

Database centric Symfony configuration management. Global and per-user settings supported.

115257.8k1](/packages/dmishh-settings-bundle)[clagiordano/weblibs-configmanager

weblibs-configmanager is a tool library for easily read and access to php config array file and direct read/write configuration file / object

173.7M9](/packages/clagiordano-weblibs-configmanager)[jbtronics/settings-bundle

A symfony bundle to easily create typesafe, user-configurable settings for symfony applications

9558.8k3](/packages/jbtronics-settings-bundle)[selective/config

Config component, strictly typed

19194.8k3](/packages/selective-config)[michaels/data-manager

Simple data manager for nested data, dot notation array access, extendability, and container interoperability.

121.9k2](/packages/michaels-data-manager)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
