mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-18 12:22:10 +03:00
28 lines
721 B
Plaintext
28 lines
721 B
Plaintext
|
:: Input twitter keys
|
||
|
/+ sh-utils
|
||
|
!:
|
||
|
|_ [hide vat=wain]
|
||
|
++ prompts
|
||
|
`(list cord)`~['App token: ' 'App secret: ' 'User token: ' 'User secret: ' '']
|
||
|
++ peek ,_prompt/[(snag (lent vat) prompts) %text '']
|
||
|
++ posh
|
||
|
|= [@ * %txt p=cord]
|
||
|
=. vat [p vat]
|
||
|
?. =(4 (lent vat)) `+>.$
|
||
|
%.(+< (add-exit ,_`+>.$))
|
||
|
::
|
||
|
++ part
|
||
|
=. vat (flop vat) :: put into order of entry
|
||
|
?. ?=([@ @ @ @ ~] vat)
|
||
|
~|([%keys-missing vat] !!)
|
||
|
=+ =< aut=[[utok usec] atok asec]
|
||
|
`[atok=cord asec=cord utok=cord usec=cord ~]`vat
|
||
|
|= ost=bone
|
||
|
:_ ~
|
||
|
:^ ost %pass /out
|
||
|
[%g %mess serv our %twit-do !>([%auth aut])]
|
||
|
::
|
||
|
++ poke--args (listen-in . (add-nice ,_`.))
|
||
|
++ serv [our /twit]
|
||
|
--
|