mirror of
https://github.com/urbit/shrub.git
synced 2024-12-19 16:51:42 +03:00
Merge pull request #2280 from urbit/m/chat-cli-perms
chat-cli: remove r/w specifiers for invite and banish
This commit is contained in:
commit
610474795f
@ -49,8 +49,8 @@
|
|||||||
:: create chat
|
:: create chat
|
||||||
[%create nu-security path (unit glyph) (unit ?)]
|
[%create nu-security path (unit glyph) (unit ?)]
|
||||||
[%delete path] :: delete chat
|
[%delete path] :: delete chat
|
||||||
[%invite ?(%r %w %rw) path (set ship)] :: allow
|
[%invite path (set ship)] :: allow
|
||||||
[%banish ?(%r %w %rw) path (set ship)] :: disallow
|
[%banish path (set ship)] :: disallow
|
||||||
::
|
::
|
||||||
[%join target (unit glyph) (unit ?)] :: join target
|
[%join target (unit glyph) (unit ?)] :: join target
|
||||||
[%leave target] :: nuke target
|
[%leave target] :: nuke target
|
||||||
@ -368,8 +368,8 @@
|
|||||||
::
|
::
|
||||||
[%create leaf+";create [type] /chat-name (glyph)"]
|
[%create leaf+";create [type] /chat-name (glyph)"]
|
||||||
[%delete leaf+";delete /chat-name"]
|
[%delete leaf+";delete /chat-name"]
|
||||||
[%invite leaf+";invite [rw | r | w] /chat-name ~ships"]
|
[%invite leaf+";invite /chat-name ~ships"]
|
||||||
[%banish leaf+";banish [rw | r | w] /chat-name ~ships"]
|
[%banish leaf+";banish /chat-name ~ships"]
|
||||||
::
|
::
|
||||||
[%bind leaf+";bind [glyph] ~ship/chat-name"]
|
[%bind leaf+";bind [glyph] ~ship/chat-name"]
|
||||||
[%unbind leaf+";unbind [glyph]"]
|
[%unbind leaf+";unbind [glyph]"]
|
||||||
@ -485,8 +485,8 @@
|
|||||||
==
|
==
|
||||||
==
|
==
|
||||||
;~((glue ace) (tag %delete) path)
|
;~((glue ace) (tag %delete) path)
|
||||||
;~((glue ace) (tag %invite) rw path ships)
|
;~((glue ace) (tag %invite) path ships)
|
||||||
;~((glue ace) (tag %banish) rw path ships)
|
;~((glue ace) (tag %banish) path ships)
|
||||||
::
|
::
|
||||||
;~ (glue ace)
|
;~ (glue ace)
|
||||||
(tag %join)
|
(tag %join)
|
||||||
@ -585,10 +585,6 @@
|
|||||||
::
|
::
|
||||||
++ security
|
++ security
|
||||||
(perk %channel %village ~)
|
(perk %channel %village ~)
|
||||||
:: +rw: read, write, or read-write
|
|
||||||
::
|
|
||||||
++ rw
|
|
||||||
(perk %rw %r %w ~)
|
|
||||||
::
|
::
|
||||||
:: +glyph: shorthand character
|
:: +glyph: shorthand character
|
||||||
::
|
::
|
||||||
@ -789,25 +785,15 @@
|
|||||||
:: +change-permission: modify permissions on a local chat
|
:: +change-permission: modify permissions on a local chat
|
||||||
::
|
::
|
||||||
++ change-permission
|
++ change-permission
|
||||||
|= [allow=? rw=?(%r %w %rw) =path ships=(set ship)]
|
|= [allow=? =path ships=(set ship)]
|
||||||
^- (quip card state)
|
^- (quip card state)
|
||||||
:_ all-state
|
:_ all-state
|
||||||
=; cards=(list card)
|
=; card=(unit card)
|
||||||
?. allow cards
|
%+ weld (drop card)
|
||||||
%+ weld cards
|
?. allow ~
|
||||||
%+ turn ~(tap in ships)
|
%+ turn ~(tap in ships)
|
||||||
(cury invite-card path)
|
(cury invite-card path)
|
||||||
%+ murn
|
|
||||||
^- (list term)
|
|
||||||
?- rw
|
|
||||||
%r [%read ~]
|
|
||||||
%w [%write ~]
|
|
||||||
%rw [%read %write ~]
|
|
||||||
==
|
|
||||||
|= =term
|
|
||||||
^- (unit card)
|
|
||||||
=. path
|
=. path
|
||||||
=- (snoc `^path`- term)
|
|
||||||
[%chat (target-to-path our-self path)]
|
[%chat (target-to-path our-self path)]
|
||||||
:: whitelist: empty if no matching permission, else true if whitelist
|
:: whitelist: empty if no matching permission, else true if whitelist
|
||||||
::
|
::
|
||||||
@ -829,7 +815,7 @@
|
|||||||
%- some
|
%- some
|
||||||
%^ act %do-permission %group-store
|
%^ act %do-permission %group-store
|
||||||
:- %group-action
|
:- %group-action
|
||||||
!>
|
!> ^- group-action
|
||||||
?: =(u.whitelist allow)
|
?: =(u.whitelist allow)
|
||||||
[%add ships path]
|
[%add ships path]
|
||||||
[%remove ships path]
|
[%remove ships path]
|
||||||
|
Loading…
Reference in New Issue
Block a user