PHPackages                             daftspunk/laravel-config-writer - 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. daftspunk/laravel-config-writer

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

daftspunk/laravel-config-writer
===============================

Laravel provider to be able to rewrite configuration

v1.2.2(2y ago)17548.8k—1.6%79[6 issues](https://github.com/daftspunk/laravel-config-writer/issues)1MITPHPPHP &gt;=7.1.0

Since Aug 11Pushed 2y ago4 watchersCompare

[ Source](https://github.com/daftspunk/laravel-config-writer)[ Packagist](https://packagist.org/packages/daftspunk/laravel-config-writer)[ Docs](http://octobercms.com)[ RSS](/packages/daftspunk-laravel-config-writer/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (3)Versions (5)Used By (1)

Laravel Config Writer
=====================

[](#laravel-config-writer)

Write to Laravel Config files and maintain file integrity.

This library is an extension of the Config component used by Laravel. It adds the ability to write to configuration files.

You can rewrite array values inside a basic configuration file that returns a single array definition (like a Laravel config file) whilst maintaining the file integrity, leaving comments and advanced settings intact.

The following value types are supported for writing: strings, integers, booleans and single-dimension arrays.

Support
-------

[](#support)

This provider is designed to be used in Laravel from `5.4` version.

Setup
-----

[](#setup)

Install through composer:

```
composer require "daftspunk/laravel-config-writer"

```

Add this to `app/config/app.php` under the 'providers' key:

```
October\Rain\Config\ServiceProvider::class,
```

### Lumen case

[](#lumen-case)

Add this to `bootstrap/app.php` in the 'service providers' section declaration:

```
$app->register(October\Rain\Config\ServiceProvider::class);
```

Usage
-----

[](#usage)

You can write to config files like this:

```
Config::write('app.url', 'http://domain.com');

app('config')->write('app.url', 'http://domain.com');
```

### Outside Laravel

[](#outside-laravel)

The `Rewrite` class can be used anywhere.

```
$writeConfig = new October\Rain\Config\DataWriter\Rewrite;
$writeConfig->toFile('path/to/config.php', [
    'item' => 'new value',
    'nested.config.item' => 'value',
    'arrayItem' => ['Single', 'Level', 'Array', 'Values'],
    'numberItem' => 3,
    'booleanItem' => true
]);
```

###  Health Score

42

—

FairBetter than 90% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity49

Moderate usage in the ecosystem

Community27

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~1095 days

Total

4

Last Release

1012d ago

PHP version history (2 changes)v1.0PHP &gt;=5.4.0

v1.1PHP &gt;=7.1.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/56e1225d057f3fd1bb140ef044b04d464b6b55ef5fcbc3671f58774e05190688?d=identicon)[oc](/maintainers/oc)

---

Top Contributors

[![daftspunk](https://avatars.githubusercontent.com/u/1392869?v=4)](https://github.com/daftspunk "daftspunk (23 commits)")[![rrebilla](https://avatars.githubusercontent.com/u/111347542?v=4)](https://github.com/rrebilla "rrebilla (20 commits)")[![greatwitenorth](https://avatars.githubusercontent.com/u/547583?v=4)](https://github.com/greatwitenorth "greatwitenorth (15 commits)")[![xdevor](https://avatars.githubusercontent.com/u/98752059?v=4)](https://github.com/xdevor "xdevor (4 commits)")[![geimsdin](https://avatars.githubusercontent.com/u/46976508?v=4)](https://github.com/geimsdin "geimsdin (3 commits)")[![martink635](https://avatars.githubusercontent.com/u/444687?v=4)](https://github.com/martink635 "martink635 (2 commits)")[![vahidalvandi](https://avatars.githubusercontent.com/u/7871623?v=4)](https://github.com/vahidalvandi "vahidalvandi (2 commits)")[![octoberapp](https://avatars.githubusercontent.com/u/6543374?v=4)](https://github.com/octoberapp "octoberapp (1 commits)")[![JoshuaBehrens](https://avatars.githubusercontent.com/u/1133593?v=4)](https://github.com/JoshuaBehrens "JoshuaBehrens (1 commits)")[![tekreme73](https://avatars.githubusercontent.com/u/6062154?v=4)](https://github.com/tekreme73 "tekreme73 (1 commits)")[![hrace009](https://avatars.githubusercontent.com/u/7691118?v=4)](https://github.com/hrace009 "hrace009 (1 commits)")[![CodeLingoBot](https://avatars.githubusercontent.com/u/45469328?v=4)](https://github.com/CodeLingoBot "CodeLingoBot (1 commits)")

---

Tags

laravelconfigproviderwriteoctober cmsoctober

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/daftspunk-laravel-config-writer/health.svg)

```
[![Health](https://phpackages.com/badges/daftspunk-laravel-config-writer/health.svg)](https://phpackages.com/packages/daftspunk-laravel-config-writer)
```

PHPackages © 2026

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