1

I want to be able to run something like this:

clean; run; or shorter (X; r)

continue; ev $my_var; ev $other_var or shorter (c; ev $my_var)

Or it can be much more complicated one-liner ;)

How can i do this?

Mikl
  • 673
  • 9
  • 19
  • currently only 0A (line feed) supported as separator… wondering, do other debuggers support other separators too? – bwoebi Sep 12 '15 at 14:31
  • @bwoebi i'm not sure this will be a correct example, but for me, mysql client console is nearly perfect interactive shell. It has `DELIMITER` command to change it's value in current session by user. And feature like `pager _less_` which prints the results via PAGER (_less_ for example). Because when you print large object, it's very complicated to read it's content which takes at least 10 pages (screens), shell cool pager like _less_ could help, it's search feature is awesome. I'll be really happy to have those features. – Mikl Sep 13 '15 at 07:05
  • 1
    I see, but the difference between Mysql and PHP is that `;` (except for the rare case where you create stored procedures) isn't needed in queries. In PHP however you might quickly write `ev (function($big){ unset($big["recursive_dep"]); return $big;})($array)` (PHP 7 syntax)… and quickly have some `;` in your code added… mhm… TBH, The only real delimiter is `#` (as it never will be needed in short PHP code because comments). sounds like a great idea. … the pager … you imagine that like `pager ev $big_array` / `set pager less`? Sounds great… Will have to figure out how that works though ;-) – bwoebi Sep 13 '15 at 09:01
  • @bwoebi, i'm glad to hear this. In addition `set delimiter X` will be cool to have, it would give to user unlimited freedom in customization :) – Mikl Sep 13 '15 at 17:29

1 Answers1

1

Use the # sign as delimiter. Introduced via http://git.php.net/?p=php-src.git;a=commit;h=adcabcc125094dae8fe1b62dca267e3fa302907d. (PHP 7 only)

Example: ev get_defined_vars() # clean # run.

bwoebi
  • 23,637
  • 5
  • 58
  • 79
  • Note that I didn't add a `set delimiter`, but that's only because there's really no other unicode char without special meaning. (especially in `ev`) – bwoebi Sep 17 '15 at 21:00
  • How about php 5.6? Would i be able to use it in 5.6? – Mikl Sep 18 '15 at 17:16
  • No, I'm not going to add new features in the 5.6 branch. Only 7.0 because it's not yet released, sorry. – bwoebi Sep 18 '15 at 20:04