PHPackages                             larva/hyperf-settings - 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. larva/hyperf-settings

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

larva/hyperf-settings
=====================

This is hyperf settings module.

2.0.0(2y ago)0383MITPHPPHP &gt;= 8.0.2

Since Aug 11Pushed 2y agoCompare

[ Source](https://github.com/larvatecn/hyperf-settings)[ Packagist](https://packagist.org/packages/larva/hyperf-settings)[ RSS](/packages/larva-hyperf-settings/feed)WikiDiscussions master Synced 4d ago

READMEChangelog (6)Dependencies (6)Versions (8)Used By (0)

hyperf-settings
===============

[](#hyperf-settings)

 [![Stable Version](https://camo.githubusercontent.com/9d9a69b030ca0c8e99befff0f7c2d4a0ebfcb9e5b51eee889f11b61fb3ca409f/68747470733a2f2f706f7365722e707567782e6f72672f6c617276612f6879706572662d73657474696e67732f762f737461626c65)](https://packagist.org/packages/larva/hyperf-settings) [![Total Downloads](https://camo.githubusercontent.com/576e1819f77c4665b5208cb1f69d1165a1208ed34d6d86f76182d70fdd05ac4c/68747470733a2f2f706f7365722e707567782e6f72672f6c617276612f6879706572662d73657474696e67732f646f776e6c6f616473)](https://packagist.org/packages/larva/hyperf-settings) [![License](https://camo.githubusercontent.com/47effd69fd5fbbdb066210eb7418b0f0a2f4b5359ed7aed9cc6baeb7e72567c7/68747470733a2f2f706f7365722e707567782e6f72672f6c617276612f6879706572662d73657474696e67732f6c6963656e7365)](https://packagist.org/packages/larva/hyperf-settings)

适用于 Hyperf 的配置组件。

安装
--

[](#安装)

```
composer require larva/hyperf-settings -vv
```

发布迁移文件

```
php ./bin/hyperf.php vendor:publish larva/hyperf-settings
```

使用
--

[](#使用)

快捷使用

```
// 获取
$setting = settings('xx.aa', null);
```

```
//设置
settings()->set('xx.aa', 'value', 'string');
settings()->set('xx.bb', '1', 'bool');
```

或者直接使用实例

```
/** @var \Larva\Settings\SettingsRepository $settings
$settings = ApplicationContext::getContainer()->get(SettingsRepository::class);
// 获取
$setting = $settings->get('xx.aa', null);
$sets = $settings->section('xx');

var_dump($sets);
var_dump($setting);

//设置
$settings->set('xx.aa', 'value', 'string');
$settings->set('xx.bb', '1', 'bool');

if($settings->has('xx.bb')) {
  //配置存在
}

//重载配置
$settings->refresh();
//删除配置
$settings->forge('xx.bb');
```

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 90% 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 ~138 days

Recently: every ~180 days

Total

7

Last Release

905d ago

Major Versions

1.1.0 → 2.0.02023-11-21

PHP version history (2 changes)1.0.5PHP &gt;= 7.4

2.0.0PHP &gt;= 8.0.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/534cdb651e8c806590fa945c6b5a18f361613848e890db1349f4a9fbcae1a650?d=identicon)[xutongle](/maintainers/xutongle)

---

Top Contributors

[![xutongle](https://avatars.githubusercontent.com/u/46956076?v=4)](https://github.com/xutongle "xutongle (18 commits)")[![xutl](https://avatars.githubusercontent.com/u/20939388?v=4)](https://github.com/xutl "xutl (2 commits)")

---

Tags

hyperfphpsettingsSettingshyperfLarva

### Embed Badge

![Health badge](/badges/larva-hyperf-settings/health.svg)

```
[![Health](https://phpackages.com/badges/larva-hyperf-settings/health.svg)](https://phpackages.com/packages/larva-hyperf-settings)
```

###  Alternatives

[mineadmin/mineadmin

Quickly build a background management system for web applications

1.2k2.0k](/packages/mineadmin-mineadmin)

PHPackages © 2026

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