enom/pharmon 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

enom/pharmon

Composer 安装命令:

composer require enom/pharmon

包简介

PHP directory watch script inspired by remy/nodemon

README 文档

README

Inspired by nodemon. For use during development of a PHP based application.

Pharmon will watch the files in the directory in which Pharmon was started, and if any files change, Pharmon will automatically restart your PHP application.

Warning current release uses system() to execute commands.

Build StyleCI

Installation

Globally installing Pharmon.

composer global require enom/pharmon

You will need to add Composer's bin directory to your PATH in ~/.bash_profile (or ~/.bashrc) by adding the following line:

export PATH=~/.composer/vendor/bin:$PATH

Usage

Watches directories and runs commands on file changes.

pharmon
# Runs `php index.php` and watches the current directory

Useful for linting and testing. You can specify one or more directories to watch by using the -w flag and one or more commands to execute with the -x flag:

pharmon -w src/ -w tests/ -x 'composer run test'
# Runs `composer run test` and watches the specified directories

You can also get the absolute file path that triggered the change using @ in your command string:

pharmon -w src/ -x 'composer run lint:file @'
# Runs (e.g.) `composer run lint:file /var/www/pharmon/src/Pharmon/Watcher.php`

The @ symbol can be escaped in your command string which will prevent the replacement from hapening:

pharmon -w dist/ -e js,css -x 'scp @ deploy\@env.host:@'
# Runs (e.g.) `scp /var/www/dist/app.js deploy@env.host:/var/www/dist/app.js`

Limitations

PHP doesn't come with multithreading support enabled by default so there's no way to listen for both filesystem events and manual restarts(#9).

Development

Please make sure composer run standard and composer run test are both passing before pushing.

enom/pharmon 适用场景与选型建议

enom/pharmon 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 97 次下载、GitHub Stars 达 0, 最近一次更新时间为 2018 年 05 月 31 日, 在 PHP 生态内属于活跃度较高的组件。

我们在过去多个企业项目中使用过 enom/pharmon 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 enom/pharmon 我们能提供哪些服务?
定制开发 / 二次开发

基于 enom/pharmon 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 97
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: Apache-2.0
  • 更新时间: 2018-05-31