当前位置: 首页 > 后端技术 > PHP

PHP代码-psysh调试代码片段工具

时间:2023-03-29 19:28:17 PHP

官网https://psysh.org/Github地址https://github.com/bobthecow/...安装使用wgetinstall$wgethttps://git.io/psysh$chmod+xpsysh$./psyshuseComposer安装$composergrequirepsy/psysh:@stable$psyshCommandwtf打印最近的错误信息historydisplayexecutioncommandclearclearcommanddocdisplayfunctionusedocumentdumpprintvariablelsdisplayvariableshowdisplayfunctionconstantclassmethoddoccommand需要安装的文件到本地PsySH文档存储在~/.local/share/psysh/中。(windows系统存放在C:\Users\{用户名}\AppData\Roaming\PsySH\)$cd~/.local/share$mkdirpsysh$cdpsydh$wgethttp://psysh.org/manual/zh/php_manual.sqliteConfigurationOsx~/.config/psysh/config.php(或C:\Users\{USER}\AppData\Roaming\PsySH\config.phponWindows)。[new\Psy\Command\ParseCommand,],'defaultIncludes'=>[__DIR__.'/include/bootstrap.php',//这里可以加载你常用的类库],'startupMessage'=>sprintf('%s',shell_exec('uptime')),];