PHPackages                             nikolad/nikogin - 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. [Framework](/categories/framework)
4. /
5. nikolad/nikogin

ActiveLibrary[Framework](/categories/framework)

nikolad/nikogin
===============

NikoGin framework for non-standard WordPress Plugin

40PHP

Since Aug 2Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/NikolaD01/NikoGin)[ Packagist](https://packagist.org/packages/nikolad/nikogin)[ RSS](/packages/nikolad-nikogin/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (3)Used By (0)

NikoGin - WordPress Plugin Generator
====================================

[](#nikogin---wordpress-plugin-generator)

Introduction
------------

[](#introduction)

NikoGin is a command-line tool that automates the creation of a structured, modern WordPress plugin. It sets up a professional foundation with an emphasis on best practices, saving you hours of boilerplate work.

- **Modern PHP:** Built with dependency injection and service providers.
- **Autoloading:** Uses Composer for a clean, autoloaded class structure.
- **Powerful CLI:** A robust command-line interface for generating plugins and their components.

Features
--------

[](#features)

- Generates a complete WordPress plugin structure from a single command.
- Includes commands for scaffolding controllers, cron events, migrations, providers, listeners, repositories, and shortcodes.
- Enforces a clean architecture with a pre-configured service container.
- Uses Composer for autoloading and dependency management.
- Starter kits : react ( in future : twig, vanilla etc ...)

---

Installation
------------

[](#installation)

NikoGin is a global CLI tool. You install it once on your system and can use it anywhere to create new plugins.

### 1. Requirements

[](#1-requirements)

Before you install, ensure your system is set up for modern PHP development.

- **PHP &gt;= 8.2**
- **Composer**
- The following PHP extensions must be installed and enabled:
- `intl` (Required by Symfony dependencies for string normalization)
- `mbstring` (Required by Symfony dependencies for multi-byte string handling)
- `curl` (Required by Composer for downloading packages)
- `xml` (Required by Composer and many PHP packages)
- `zip` (Required by Composer for extracting packages)

> **For Debian/Ubuntu/Pop!\_OS users:**If you need to set up a new PHP environment, you can use the `ppa:ondrej/php` repository.
>
> ```
> # Add the trusted PHP repository
> sudo add-apt-repository ppa:ondrej/php
>
> sudo apt update
>
> # Install PHP and all required extensions
> sudo apt install php8.2-cli php8.2-intl php8.2-mbstring php8.2-xml php8.2-curl php8.2-zip
> ```

### 2. Global Installation

[](#2-global-installation)

Since NikoGin is not yet on the public Packagist repository, you must install it directly from its private GitHub repository.

#### 2.1. Configure Composer

[](#21-configure-composer)

First, tell your global Composer installation where to find the package. This requires an SSH key configured with your GitHub account.

```
composer global config repositories.nikogin vcs git@github.com:NikolaD01/NikoGin.git
```

#### 2.2. Install the package

[](#22-install-the-package)

Now, run the require command using the specific branch you want to install. The dev- prefix is required.

```
# You can replace "main" with the branch you want to install (Keep in mind that "main" is the current stable branch.), e.g., "dev-feature/alpha-feature"
composer global require nikolad/nikogin:"dev-main"
```

Note: If this is your first time interacting with private GitHub repositories via Composer, you may be prompted to create and provide a Personal Access Token. If it is this first time doing this refer to the [Official GitHub documentation](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens#creating-a-personal-access-token-classic).

### 3. Update your system's PATH

[](#3-update-your-systems-path)

To run the nikogin command directly, you must add Composer's global bin directory to your system's PATH.

#### 3.1. Find the exact path to the directory by running:

[](#31-find-the-exact-path-to-the-directory-by-running)

```
composer global config bin-dir --absolute
```

#### 3.2. Add this path to your shell's startup file (e.g., .zshrc, .bashrc, or .profile).

[](#32-add-this-path-to-your-shells-startup-file-eg-zshrc-bashrc-or-profile)

```
export PATH="$(composer global config bin-dir --absolute):$PATH"
```

#### 3.3. After adding the previously mentioned path to your shell's startup you need to launch a new terminal instance so the change takes effect.

[](#33-after-adding-the-previously-mentioned-path-to-your-shells-startup-you-need-to-launch-a-new-terminal-instance-so-the-change-takes-effect)

#### Alternately you can run the following command so you see the changes immediately in the same terminal instance:

[](#alternately-you-can-run-the-following-command-so-you-see-the-changes-immediately-in-the-same-terminal-instance)

**NOTE**: If you are using a different shell (zshell, sh etc.) source the startup file that matches the shell you are using.

```
source ~/.bashrc
```

### 4. Verify the installation

[](#4-verify-the-installation)

After completing the above steps, verify that the installation was successful by running the following command in your terminal:

```
nikogin --version
```

### 5. Keeping NikoGin updated

[](#5-keeping-nikogin-updated)

Since the project is still in the development phase and there are frequent changes, you will need to pull the latest changes and bug fixes periodically. You can easily do this by running Composer's global `update` command:

```
composer global update nikolad/nikogin
```

Usage
-----

[](#usage)

### Create a New Plugin

[](#create-a-new-plugin)

Run the following command to generate a new WordPress plugin:

```
nikogin create
```

Note: if no path is provided it will default to current working directory.

### Example:

[](#example)

```
nikogin create 'My First PopArt plugin' PA '~/PhpStormProjects/project123'
```

Note: NikoGin uses kebab-case for the name of the root plugin directory, so in our case 'My First PopArt plugin' will be created in my-first-popart-plugin directory.

### Description:

[](#description)

- Creates a structured directory for the plugin.
- Generates essential classes like:
    - `Plugin.php`
    - `ServiceProviderManager.php`
    - Other necessary components.
- Automatically runs `composer install` to set up dependencies.

---

### Create a Controller

[](#create-a-controller)

```
nikogin make:controller
```

Available Types:

There are three options for the `` argument:

```
rest – Creates a REST API controller.
menu – Creates a Menu controller.
submenu – Creates a Submenu controller.

```

### Examples

[](#examples)

#### 1. Example for Rest Controller directly from wp-content

[](#1-example-for-rest-controller-directly-from-wp-content)

```
nikogin make:controller ExampleRestController rest example-plugin
```

#### 2. Example for Menu Controller from root of project

[](#2-example-for-menu-controller-from-root-of-project)

```
nikogin make:controller ExampleMenuController menu wp-content/example-plugin
```

#### 3. Example for Submenu Controller

[](#3-example-for-submenu-controller)

```
nikogin make:controller ExampleSubmenuController submenu example-plugin
```

### Description:

[](#description-1)

- Creates a directory for Controller type if it's not created already.
- Generates essential class logic

---

### Create a Migration

[](#create-a-migration)

```
nikogin make:migration
```

### Example

[](#example-1)

```
nikogin make:migration Example example-plugin
```

### Description:

[](#description-2)

- Creates Migration with filled name and skeleton for creating schema
- name of table we be constructed based on wp-prefix\_plugin-prefix\_migration-name (wp\_ep\_example)

---

### Create a Provider

[](#create-a-provider)

```
nikogin make:provider
```

### Example

[](#example-2)

```
nikogin make:provider Example example-plugin
```

### Description:

[](#description-3)

- Creates Provider which is automatically attached to ProviderManager
- Ability to override base register() method

---

### Create a Listener

[](#create-a-listener)

```
nikogin make:listener    optional
```

### Example

[](#example-3)

```
nikogin make:listener PostSave save_post example action --args=2 --priority=10
```

### Description:

[](#description-4)

- Creates a Listener for Wordpress action or filter
- Has ability to define number of arguments and priority level
- Utilize handle method as callback on action/filter trigger

---

### Create a Cron

[](#create-a-cron)

```
nikogin make:cron
```

### Example

[](#example-4)

```
nikogin make:cron ExampleCron exampledir
```

### Description:

[](#description-5)

- Creates a Cron action for Wordpress

---

### Create a Repository

[](#create-a-repository)

```
nikogin make:repository
```

### Example

[](#example-5)

```
nikogin make:repository ExampleName example_table example/
```

### Description:

[](#description-6)

- Creates a Repository for given table

---

### Create a Shortcode

[](#create-a-shortcode)

```
nikogin make:shortcode
```

### Example

[](#example-6)

```
nikogin make:shortcode ExampleName example_action example/
```

### Description:

[](#description-7)

- Creates a Shortcode for given action

---

### Create a Middleware

[](#create-a-middleware)

```
nikogin make:middleware
```

### Example

[](#example-7)

```
nikogin make:middleware ExampleName example/
```

### Description:

[](#description-8)

- Creates a Middleware for wordpress router

---

Incoming
--------

[](#incoming)

This is list of incoming features and commands :
**BE**

- Jobs (Depending on WooCommerce Action Scheduler (subject to change), WordPress background processes)
- WordPress component extension (Ability to easily extend any WordPress component as WpTable ) (Subject to change)
- Commands (Extend WP CLI, create commands)
- Seeders
- Support Elements ( as Symfony d/dd etc ... )
- Routes Model/PostType binding (Idea here is to bind Post Object if we provide route with /product/{id} , id would return Post object)
    **FE**
    Add rest of starter kits : twig, vanilla and any other idea we have **Exclude**
    When creating plugin idea is to prompt user with yes/no if user want to exclude some foundation. Example user is creating Plugin for Rest routes where he will just handle data from request, for this theoretically, classes like Controller, Repository , Cron, Jobs can handle task which leave space to remove rest of unused classes and to make Core simpler. We can add option parameter in create command like this

```
nikogin create --exclude
```

---

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

[](#contributing)

Contributions are welcome! Feel free to submit issues and pull requests.

License
-------

[](#license)

This project is licensed under the MIT License.

---

**Stay Updated:** Follow updates and improvements to the package. Happy coding!

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance63

Regular maintenance activity

Popularity4

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity17

Early-stage or recently created project

 Bus Factor1

Top contributor holds 51.8% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/8ee658c10b7a85b06f5b8ca6d2947655029d33d936d02ef9a617687be69b9370?d=identicon)[NikolaD01](/maintainers/NikolaD01)

---

Top Contributors

[![nikoladPopArtStudio](https://avatars.githubusercontent.com/u/146175553?v=4)](https://github.com/nikoladPopArtStudio "nikoladPopArtStudio (29 commits)")[![NikolaD01](https://avatars.githubusercontent.com/u/119043830?v=4)](https://github.com/NikolaD01 "NikolaD01 (19 commits)")[![aleksak-popart](https://avatars.githubusercontent.com/u/153736789?v=4)](https://github.com/aleksak-popart "aleksak-popart (8 commits)")

### Embed Badge

![Health badge](/badges/nikolad-nikogin/health.svg)

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

###  Alternatives

[laravel/telescope

An elegant debug assistant for the Laravel framework.

5.2k67.8M190](/packages/laravel-telescope)[spiral/roadrunner

RoadRunner: High-performance PHP application server and process manager written in Go and powered with plugins

8.4k12.2M84](/packages/spiral-roadrunner)[nolimits4web/swiper

Most modern mobile touch slider and framework with hardware accelerated transitions

41.8k177.2k1](/packages/nolimits4web-swiper)[laravel/dusk

Laravel Dusk provides simple end-to-end testing and browser automation.

1.9k36.7M255](/packages/laravel-dusk)[laravel/prompts

Add beautiful and user-friendly forms to your command-line applications.

708181.8M591](/packages/laravel-prompts)[cakephp/chronos

A simple API extension for DateTime.

1.4k47.7M119](/packages/cakephp-chronos)

PHPackages © 2026

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