phpmnd icon indicating copy to clipboard operation
phpmnd copied to clipboard

[WIP] Add a `self-update` command to update local phpmnd.phar from Github releases

Open padraic opened this issue 8 years ago • 3 comments

  • Adds a self-update command (not loaded unless running a phar). Also self-update --check (check if new version) and self-update --rollback (revert to previous version).
  • Renames default phpmnd command to run (bash script edited to inject so phpmnd works exactly as-is).
  • Some remapping to allow --help and --version/-V as expected.
  • Updates are linked to stable Github releases (no version constraints included).
  • Dependency to padraic/phar-updater added.
  • PHP_CodeSniffer add to exclude list when creating a PHAR.

Noted as WIP for feedback. Having a run command - there's probably a better way to have a default command (where $_SERVER['argv'] isn't manipulated outside of symfony/console). This also omits the self-update command from --help.

Works, but may need some tidying for those two points.

padraic avatar May 06 '17 17:05 padraic

I need to take a better look on this :)

povils avatar May 07 '17 21:05 povils

Thanks for the review @povils - made some changes. Missed your comment on the text colouring if you have specific colour codes to fit in with your preferred theme.

padraic avatar May 07 '17 22:05 padraic

@povils Pretty much done, but I may add a few changes towards the weekend to take advantage of a new phar-updater release expected shortly, and someone may know if the fugly argv function has a more...elegant solution.

padraic avatar May 16 '17 20:05 padraic