chat-cli: Match store and hook's path handling
Now prefixes the host ship to the path, and parses it back out, only
when appropriate.
::
++ target-to-path
|= target
- path
- ::TODO
- :: [(scot %p ship) path]
+ [(scot %p ship) path]
:: +path-to-target: deduces a target from a mailbox path
::
++ path-to-target
[our-self path]
=+ who=(slaw %p i.path)
?~ who [our-self path]
- [u.who path]
+ [u.who t.path]
:: +poke-noun: debug helpers
::
++ poke-noun
|= [=wire upd=chat-update]
^- (quip move _this)
?+ -.upd [~ this]
- %create (notice-create (path-to-target path.upd))
+ %create (notice-create +.upd)
%delete [[(show-delete:sh-out (path-to-target path.upd)) ~] this]
%message (read-envelope (path-to-target path.upd) envelope.upd)
==
