PHPackages                             marcogeorge7/permission-generator - 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. marcogeorge7/permission-generator

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

marcogeorge7/permission-generator
=================================

Generate json file with all permission that call in controllers and views

v1.0.0(4y ago)1241MITPHPPHP ^7.4|^8.0

Since Feb 1Pushed 4y ago1 watchersCompare

[ Source](https://github.com/marcogeorge7/permission-generator)[ Packagist](https://packagist.org/packages/marcogeorge7/permission-generator)[ RSS](/packages/marcogeorge7-permission-generator/feed)WikiDiscussions 1.x Synced 1mo ago

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

Laravel permission-generator
============================

[](#laravel-permission-generator)

permission-generator scans your project `resources/view/` and `app/` folder to find `@can(...)`, `Gate::allow(...)`functions, then it create keys based on first parameter value and insert into json permission file.

### Installation

[](#installation)

You just have to require the package

```
$ composer require marcogeorge7/permission-generator
```

This package register the provider automatically, [See laravel package discover](https://laravel.com/docs/5.5/packages#package-discovery).

### Usage

[](#usage)

First you have to create json files in resource to save permission in it:

```
app/
  resources/
    role/
      permissions.json

```

second, publish the configuration file.

```
php artisan vendor:publish --provider="PermissionGenerator\Framework\GeneratorServiceProvider"

```

### Output

[](#output)

`generator:update` command will scan your code to identify new permission keys, then it'll update json file on `app/resources/role/` folder appending this keys.

```
{
    "access_index": "can access all",
    "create_user": "can create user",
    "update_user": ""
}
```

if for any reason artisan can't find `generator:update` command, you can register the provider manually on your `config/app.php` file:

```
return [
    ...
    'providers' => [
        ...
        PermissionGenerator\Framework\GeneratorServiceProvider::class,
        ...
    ]
]
```

### Customization

[](#customization)

You can change the default path of views to scan and the output of the json permission file.

### Todo

[](#todo)

- auto create value as a description of permission in json object
- insert permission in database table permission as defult and can replace it with config file

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity55

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

1560d ago

### Community

Maintainers

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

---

Top Contributors

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

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/marcogeorge7-permission-generator/health.svg)

```
[![Health](https://phpackages.com/badges/marcogeorge7-permission-generator/health.svg)](https://phpackages.com/packages/marcogeorge7-permission-generator)
```

###  Alternatives

[wireui/wireui

TallStack components

1.8k1.3M16](/packages/wireui-wireui)[livewire/volt

An elegantly crafted functional API for Laravel Livewire.

4195.3M84](/packages/livewire-volt)[ramonrietdijk/livewire-tables

Dynamic tables for models with Laravel Livewire

21147.4k](/packages/ramonrietdijk-livewire-tables)

PHPackages © 2026

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