pstaender/ssshell
Composer 安装命令:
composer require pstaender/ssshell
包简介
ssshell is a REPL for SilverStripe. Runs on top of PsySH 🚀
README 文档
README
REPL for SilverStripe running on Psy Shell 🚀
Install
Install in your current project with:
$ composer require --dev pstaender/ssshell
Usage
To use ssshell just type ./vendor/bin/ssshell (or ssshell if its installed globally) in your project folder and you can start using the shell:
Psy Shell v0.12.9 (PHP 8.4.8 — cli) by Justin Hileman
Loading dev environment (SilverStripe CMS: 6.0.0)
>
Command Line Options
You can use most of psyshs' cli arguments. Type psysh -h for help.
Requirements
ssshell runs on SilverStripe v6.
For SilverStripe v4 and v5 you can use the ss4 / ss5-branches or use the corresponding versions.
Features
Namespaces and views of objects and lists
ssshell comes with a set of frequent used namespaces for convenient REPL handling.
By default all DataObjects, DataLists, ArrayLists and Query objects will be displayed in a human-readable fashion.
As example, creating a SilverStripe User would be:
> Member::create(['Email' => 'editor', 'Password' => 'password'])->write() => 1 > Member::get()->first() => SilverStripe\Security\Member {#3229 +ClassName: "SilverStripe\Security\Member", +LastEdited: "2019-07-01 11:34:54", +Created: "2019-07-01 11:34:54", +Email: "editor", +Password: "$2y$10$9b5f51921992948f40cf7uHeqjQLuG9Bnqf4sq54TBnsB80CmwJhC", +PasswordEncryption: "blowfish", +Salt: "10$9b5f51921992948f40cf75", +Locale: "en_US", +FailedLoginCount: 0, +ID: 1, +RecordClassName: "SilverStripe\Security\Member", +LoggedPasswords: [ [ "ClassName" => "SilverStripe\Security\MemberPassword", "LastEdited" => "2019-07-01 11:34:54", "Created" => "2019-07-01 11:34:54", "Password" => "$2y$10$9b5f51921992948f40cf7uHeqjQLuG9Bnqf4sq54TBnsB80CmwJhC", "Salt" => "10$9b5f51921992948f40cf75", "PasswordEncryption" => "blowfish", "MemberID" => 1, "ID" => 1, "RecordClassName" => "SilverStripe\Security\MemberPassword", ], ], +RememberLoginHashes: [], +LinkTracking: [], +FileTracking: [], +Groups: [], }
Sake command
You can use all familiar sake commands:
> sake db:build Building database SS_test using SilverStripe\ORM\Connect\MySQL 8.0.16 ---------------------------------------------------------------------------- Creating database tables * File (0 records) * SiteConfig (1 records) …
> sake dev/tasks SILVERSTRIPE DEVELOPMENT TOOLS: Tasks -------------------------- * Migrate SiteTree Linking Task: sake dev/tasks/MigrateSiteTreeLinkingTask * Database Migrations: sake dev/tasks/MigrationTask …
Flush command
> flush
Same effect when using sake with ?flush.
Static Command
View available static properties / methods of classes.
Displays static properties and methods:
> static SilverStripe\Control\Director
Display a static property:
> static SilverStripe\Control\Director $current_page
Display a static method:
> static SilverStripe\Control\Director test …
pstaender/ssshell 适用场景与选型建议
pstaender/ssshell 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 4.42k 次下载、GitHub Stars 达 6, 最近一次更新时间为 2019 年 07 月 01 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「debug」 「console」 「shell」 「silverstripe」 「REPL」 「Tinker」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 pstaender/ssshell 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 pstaender/ssshell 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 pstaender/ssshell 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
This class provides you with an easy-to-use interface to progress bars.
Debug your SimpleBus EventBus and CommandBus
nice output for debug functions for PHP 5.3
A Laravel package to retrieve data from Google Search Console
Additional artisan commands for Laravel
AMWSCAN (Antimalware Scanner) is a php antimalware/antivirus scanner console script written in php for scan your project. This can work on php projects and a lot of others platform.
统计信息
- 总下载量: 4.42k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 6
- 点击次数: 27
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: BSD-3-Clause
- 更新时间: 2019-07-01