PHPackages                             starrysea/usually - 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. starrysea/usually

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

starrysea/usually
=================

Here is the definition that often needs to be used to make development easier.

1.0.2(7y ago)034MITPHPPHP ^7.0

Since Dec 7Pushed 7y agoCompare

[ Source](https://github.com/caixingyue/laravel-starrysea-usually)[ Packagist](https://packagist.org/packages/starrysea/usually)[ Docs](https://github.com/caixingyue/laravel-starrysea-usually)[ RSS](/packages/starrysea-usually/feed)WikiDiscussions master Synced 4d ago

READMEChangelogDependenciesVersions (4)Used By (0)

安装
--

[](#安装)

- [Laravel](#laravel)
- [Lumen](#lumen)

### Laravel

[](#laravel)

该软件包可用于 Laravel 5.6 或更高版本。

您可以通过 composer 安装软件包：

```
composer require starrysea/usually
```

在 Laravel 5.6 中，服务提供商将自动注册。在旧版本的框架中，只需在 `config/app.php` 文件中添加服务提供程序：

```
'providers' => [
    // ...
    Starrysea\Usually\ConvertServiceProvider::class,
];

'aliases' => [
    // ...
    'Convert' => Starrysea\Usually\Convert::class,
];
```

### Lumen

[](#lumen)

您可以通过 composer 安装软件包：

```
composer require starrysea/usually
```

注册服务提供者和门面：

```
$app->register(Starrysea\Usually\ConvertServiceProvider::class); // 注册 Convert 服务提供者

class_alias(Starrysea\Usually\Convert::class, 'Convert'); // 添加 Convert 门面
```

用法
--

[](#用法)

```
use Starrysea\Usually\Convert;

class ConvertGatherTest
{
    public static function collectNumerals()
    {
        $data = '你好, Laravel5.6';
        return Convert::collectNumerals($data); // 56
    }

    public static function filtercharacter()
    {
        $data = '你好, Laravel5.6';
        return Convert::filtercharacter($data); // 你好Laravel56
    }

    public static function hPhone()
    {
        $data = '13333336895';
        return Convert::hPhone($data); // 133****6895
//        return Convert::hPhone($data, '·'); // 133····6895
//        return Convert::hPhone($data, '·', '1'); // 1····336895
//        return Convert::hPhone($data, '·', 2, 6); // 13······895
    }

    public static function randstr()
    {
        return Convert::randstr(); // oIKNmM4Y
//        return Convert::randstr(3); // 2SV
//        return Convert::randstr(8, 's'); // 27723077
//        return Convert::randstr(8, 'x'); // aibiolgs
//        return Convert::randstr(8, 'd'); // JMDPYQNB
//        return Convert::randstr(8, 'sx'); // 3k1b0l2p
//        return Convert::randstr(8, 'sd'); // 2V3LTC5H
//        return Convert::randstr(8, 'xd'); // iGnyrQge
//        return Convert::randstr(8, 'sxd'); // ov1YRpns
    }

    public static function uniqueNumber()
    {
        return Convert::uniqueNumber(); // 111268305027050944060822644
//        return Convert::uniqueNumber('你好, laravel'); // 846243285156900266804426466422
    }

    public static function Pscws4()
    {
        $data = '我爱连衣裙';
        return Convert::Pscws4()->send_text($data)->set_ignore(true)->get_result('word'); // ['我爱', '连衣裙']
    }

    public static function isTerminal()
    {
        return Convert::isTerminal('pc'); // true
//        return Convert::isTerminal('phone'); // false
//        return Convert::isTerminal('android'); // false
//        return Convert::isTerminal('ios'); // false
//        return Convert::isTerminal('wechat'); // false
    }
}
```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity58

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

Total

3

Last Release

2714d ago

### Community

Maintainers

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

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/starrysea-usually/health.svg)

```
[![Health](https://phpackages.com/badges/starrysea-usually/health.svg)](https://phpackages.com/packages/starrysea-usually)
```

###  Alternatives

[tareq1988/wp-php-cs-fixer

WordPress rules for php-cs-fixer

3567.8k6](/packages/tareq1988-wp-php-cs-fixer)[liopic/korean-romanizer

Library to romanize Korean in UTF-8 format

18162.4k](/packages/liopic-korean-romanizer)

PHPackages © 2026

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