PHPackages                             kigamba/laravel-tinker-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. [File &amp; Storage](/categories/file-storage)
4. /
5. kigamba/laravel-tinker-tools

ActiveLibrary[File &amp; Storage](/categories/file-storage)

kigamba/laravel-tinker-tools
============================

Use short class names in an Artisan tinker session -&gt; Supports php 5

v1.1.1(8y ago)0341MITPHPPHP &gt;=5.6.4

Since May 21Pushed 8y agoCompare

[ Source](https://github.com/Kigamba/laravel-tinker-tools)[ Packagist](https://packagist.org/packages/kigamba/laravel-tinker-tools)[ Docs](https://github.com/Kigamba/laravel-tinker-tools)[ RSS](/packages/kigamba-laravel-tinker-tools/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (2)Versions (5)Used By (1)

Use short class names in an Artisan Tinker session
==================================================

[](#use-short-class-names-in-an-artisan-tinker-session)

[![Latest Version on Packagist](https://camo.githubusercontent.com/335df4c1308f72f606f5b7487758987d1dcb0d5a0cb62cb2433afe8b6cd7369d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7370617469652f6c61726176656c2d74696e6b65722d746f6f6c732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spatie/laravel-tinker-tools)[![Build Status](https://camo.githubusercontent.com/39abe35a30225dd3617fdcb8f81299e6bf09aebc880b96b10d22b38a220754eb/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f7370617469652f6c61726176656c2d74696e6b65722d746f6f6c732f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/spatie/laravel-tinker-tools)[![StyleCI](https://camo.githubusercontent.com/43553dd2b5c4b9b02e7d59b672dd1dbf3a14cffa137816a0138ac580f2944f5d/68747470733a2f2f7374796c6563692e696f2f7265706f732f39313938303439352f736869656c643f6272616e63683d6d6173746572)](https://styleci.io/repos/91980495)[![Quality Score](https://camo.githubusercontent.com/3edde95e72a1f79a6d45667d9ee122fe6af39033f27ed60fa13ecbaabdbd10a5/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f7370617469652f6c61726176656c2d74696e6b65722d746f6f6c732e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/spatie/laravel-tinker-tools)[![Total Downloads](https://camo.githubusercontent.com/9076ec1ba407bbb8f13ff6ea3b4c6d0c0a136a8ef1f5fae8d53df9821821a89e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7370617469652f6c61726176656c2d74696e6b65722d746f6f6c732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/spatie/laravel-tinker-tools)

When using Artisan's Tinker command it can be quite bothersome having to type the fully qualified classname to do something simple.

This Package requires &gt;= PHP 5.0 . The parent package only support PHP 7.0

Feel free to hit me up in case you have a problem using it

```
\App\Models\NewsItem::first();
```

This package contains a class that, when fully installed let's you use the short class names:

```
NewsItem::first();
```

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

[](#installation)

First install the package via Composer:

```
composer require kigamba/laravel-tinker-tools
```

Next, create a file named `.psysh.php` in the root of your Laravel app with this content:

```
