PHPackages                             tradzero/gokure-hyperf-tinker - 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. [CLI &amp; Console](/categories/cli)
4. /
5. tradzero/gokure-hyperf-tinker

ActiveLibrary[CLI &amp; Console](/categories/cli)

tradzero/gokure-hyperf-tinker
=============================

A Powerful REPL for the Hyperf framework.

01PHP

Since Nov 14Pushed 1y agoCompare

[ Source](https://github.com/tradzero/gokure-hyperf-tinker)[ Packagist](https://packagist.org/packages/tradzero/gokure-hyperf-tinker)[ RSS](/packages/tradzero-gokure-hyperf-tinker/feed)WikiDiscussions main Synced today

READMEChangelogDependenciesVersions (2)Used By (0)

Hyperf Tinker
=============

[](#hyperf-tinker)

[![Build Status](https://github.com/gokure/hyperf-tinker/actions/workflows/tests.yml/badge.svg)](https://github.com/gokure/hyperf-tinker/actions)[![Latest Stable Version](https://camo.githubusercontent.com/8c01891b7d43883eb87e3bf3aa85b891e35fe891bd50267f5c373aee86ffa102/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f676f6b7572652f6879706572662d74696e6b65722e737667)](https://packagist.org/packages/gokure/hyperf-tinker)[![Total Downloads](https://camo.githubusercontent.com/b3808a9f228f640cc92ad7e15a92676a36a458efa14b2ea68162ce527db309e4/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f676f6b7572652f6879706572662d74696e6b65722e737667)](https://packagist.org/packages/gokure/hyperf-tinker)[![GitHub license](https://camo.githubusercontent.com/c991d2deb5f428f5cee96a1c33b4a50dda46c844bf85a60c673508de41b17eec/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f676f6b7572652f6879706572662d74696e6b6572)](LICENSE)

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

[](#installation)

```
composer require gokure/hyperf-tinker
```

Publish Config
--------------

[](#publish-config)

```
php bin/hyperf.php vendor:publish gokure/hyperf-tinker
```

Usage
-----

[](#usage)

```
php bin/hyperf.php tinker
```

Commnads
--------

[](#commnads)

- run command

```
>>> $a=1
=> 1
>>> $a
=> 1
>>> define('VERSION', 'v1.0.1')
=> true
>>> VERSION
=> "v1.0.1"
>>>
```

- The help command

```
>>> help
  help       Show a list of commands. Type `help [foo]` for information about [foo].      Aliases: ?
  ls         List local, instance or class variables, methods and constants.              Aliases: dir
  dump       Dump an object or primitive.
  doc        Read the documentation for an object, class, constant, method or property.   Aliases: rtfm, man
  show       Show the code for an object, class, constant, method or property.
  wtf        Show the backtrace of the most recent exception.                             Aliases: last-exception, wtf?
  whereami   Show where you are in the code.
  throw-up   Throw an exception or error out of the Psy Shell.
  timeit     Profiles with a timer.
  trace      Show the current call stack.
  buffer     Show (or clear) the contents of the code input buffer.                       Aliases: buf
  clear      Clear the Psy Shell screen.
  edit       Open an external editor. Afterwards, get produced code in input buffer.
  sudo       Evaluate PHP code, bypassing visibility restrictions.
  history    Show the Psy Shell history.                                                  Aliases: hist
  exit       End the current session and return to caller.                                Aliases: quit, q
```

- get hyperf env

```
>>> env("APP_NAME")
=> "skeleton"
>>>
```

- query db

```
>>> $user = App\Model\User::find(1)
=> App\Model\User {#84118
     id: 1,
     name: "Gang Wu",
     email: "gokure@gmail.com",
     created_at: "2019-03-12 19:07:08",
     updated_at: "2021-01-25 10:35:22"
   }
```

- class alias auto-load

```
>>> $user = User::find(1)
[!] Aliasing 'User' to 'App\Model\User' for this Tinker session.
=> App\Model\User {#84120
     id: 1,
     name: "Gang Wu",
     email: "gokure@gmail.com",
     created_at: "2019-03-12 19:07:08",
     updated_at: "2021-01-25 10:35:22"
   }
>>> collect([1, 2])
=> Hyperf\Utils\Collection {#84084
     all: [
       1,
       2,
     ],
   }
```

Supported Versions
------------------

[](#supported-versions)

VersionHyperf VersionPhp VersionStatus2.x^3.0&gt;=8.0Mainstream support1.x^1.0|^2.0&lt;=7.2|^8.0|^8.1Security fixes support

###  Health Score

14

—

LowBetter than 1% of packages

Maintenance29

Infrequent updates — may be unmaintained

Popularity1

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity19

Early-stage or recently created project

 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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/13845447?v=4)[tradzero](/maintainers/tradzero)[@tradzero](https://github.com/tradzero)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/tradzero-gokure-hyperf-tinker/health.svg)

```
[![Health](https://phpackages.com/badges/tradzero-gokure-hyperf-tinker/health.svg)](https://phpackages.com/packages/tradzero-gokure-hyperf-tinker)
```

###  Alternatives

[illuminate/console

The Illuminate Console package.

13046.0M6.5k](/packages/illuminate-console)[styleci/cli

The CLI tool for StyleCI

71470.5k9](/packages/styleci-cli)[winbox/args

Windows command-line formatter

20720.9k21](/packages/winbox-args)[tomatophp/filament-artisan

Simple but yet powerful library for running some artisan commands for FilamentPHP

3275.4k1](/packages/tomatophp-filament-artisan)

PHPackages © 2026

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