PHPackages                             yangweijie/gb\_tools - 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. yangweijie/gb\_tools

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

yangweijie/gb\_tools
====================

国标工具用于验证或生成等

1.0.1(3y ago)111MITPHP

Since Jul 17Pushed 3y ago1 watchersCompare

[ Source](https://github.com/yangweijie/gb_tools)[ Packagist](https://packagist.org/packages/yangweijie/gb_tools)[ RSS](/packages/yangweijie-gb-tools/feed)WikiDiscussions main Synced 2d ago

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

 gbTools
=========

[](#-gbtools-)

 国标工具用于验证或生成等

Installing
----------

[](#installing)

```
$ composer require yangweijie/gb_tools -vvv
```

Usage
-----

[](#usage)

### 身份证

[](#身份证)

```

$a = new Yangweijie\GbTools\Gb('11643-1999');

$b = $a->isValid('440308199901101512'); //是否有效
var_dump($b);

var_dump($a->getInfo('440308199901101512')); // 获取信息

$c = $a->upgradeId('610104620927690');  // 15位升级
var_dump($c);

$d = $a->fakeId(); //伪造
var_dump($d);

```

### 法人和其他组织统一社会信用代码

[](#法人和其他组织统一社会信用代码)

```

$a = new Yangweijie\GbTools\Gb('32100-2015');

$b = $a->isValid('91120222MA06DG3067');
var_dump($b);

```

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

[](#contributing)

You can contribute in one of three ways:

1. File bug reports using the [issue tracker](https://github.com/yangweijie/gbTools/issues).
2. Answer questions or fix bugs on the [issue tracker](https://github.com/yangweijie/gbTools/issues).
3. Contribute new features or update the wiki.

*The code contribution process is not very formal. You just need to make sure that you follow the PSR-0, PSR-1, and PSR-2 coding guidelines. Any new code contributions must be accompanied by unit tests where applicable.*

算法
--

[](#算法)

License
-------

[](#license)

MIT

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity48

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

1395d ago

### Community

Maintainers

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

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/yangweijie-gb-tools/health.svg)

```
[![Health](https://phpackages.com/badges/yangweijie-gb-tools/health.svg)](https://phpackages.com/packages/yangweijie-gb-tools)
```

###  Alternatives

[paquettg/string-encode

Facilitating the process of altering string encoding in PHP.

698.7M43](/packages/paquettg-string-encode)[jbtronics/settings-bundle

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

9546.7k2](/packages/jbtronics-settings-bundle)[ibrand/laravel-shopping-cart

Shopping cart for Laravel Application.

385.6k1](/packages/ibrand-laravel-shopping-cart)[bolt/bolt-extension-starter

103.3k](/packages/bolt-bolt-extension-starter)

PHPackages © 2026

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