chat: fixes to cli parser and increased page size in hook

This commit is contained in:
Logan Allen 2019-11-14 13:21:46 -08:00
parent a97e36d6d6
commit 223fc8c5b4
2 changed files with 19 additions and 19 deletions

View File

@ -365,9 +365,11 @@
;~ (glue ace)
(tag %create)
security
path
(punt ;~(pfix ace glyph))
(punt ;~(pfix ace ;~(pose (cold %| bar) (cold %& pad))))
;~ plug
path
(punt ;~(pfix ace glyph))
(punt ;~(pfix ace (fuss 'y' 'n')))
==
==
;~((glue ace) (tag %delete) path)
;~((glue ace) (tag %invite) rw path ships)
@ -375,9 +377,11 @@
::
;~ (glue ace)
(tag %join)
targ
(punt ;~(pfix ace glyph))
(punt ;~(pfix ace ;~(pose (cold %| bar) (cold %& pad))))
;~ plug
targ
(punt ;~(pfix ace glyph))
(punt ;~(pfix ace (fuss 'y' 'n')))
==
==
;~((glue ace) (tag %leave) targ)
::
@ -637,7 +641,7 @@
?(%channel %mailbox) ~
?(%village %journal) [our-self ~ ~]
==
?~(allow-history %.y u.allow-history)
(fall allow-history %.y)
==
:: +delete: delete local chats
::
@ -705,7 +709,7 @@
:: gives ugly %chat-hook-reap
%^ act %do-join %chat-view
:- %chat-view-action
[%join ship.target path.target ?~(ask-history %.y u.ask-history)]
[%join ship.target path.target (fall ask-history %.y)]
:: +leave: unsync & destroy mailbox
::
::TODO allow us to "mute" local chats using this

View File

@ -196,11 +196,7 @@
?~ box !!
:_ this
:- [ost.bol %diff %chat-update [%create (slav %p i.pax) pax]]
?:
?&
?=(^ backlog-start)
(~(got by allow-history) pax)
==
?: ?&(?=(^ backlog-start) (~(got by allow-history) pax))
(paginate-messages pax u.box u.backlog-start)
~
::
@ -215,7 +211,7 @@
|- ^- (list move)
?~ envelopes.mailbox
moves
?: (lte end 500)
?: (lte end 5.000)
=. moves
%+ snoc moves
%- messages-move
@ -225,12 +221,12 @@
%+ snoc moves
%- messages-move
:^ path start
(add start 500)
(scag 500 `(list envelope)`envelopes.mailbox)
=: start (add start 500)
end (sub end 500)
(add start 5.000)
(scag 5.000 `(list envelope)`envelopes.mailbox)
=: start (add start 5.000)
end (sub end 5.000)
==
$(envelopes.mailbox (slag 500 `(list envelope)`envelopes.mailbox))
$(envelopes.mailbox (slag 5.000 `(list envelope)`envelopes.mailbox))
::
++ messages-move
|= [=path start=@ud end=@ud envelopes=(list envelope)]