mirror of
https://github.com/ilyakooo0/urbit.git
synced 2025-01-07 23:51:22 +03:00
hood save/load mechanism
This commit is contained in:
parent
42926b7bb4
commit
dbeed2d723
@ -72,6 +72,12 @@
|
|||||||
~? ?=(^ saw) [%kiln-overload-lame u.saw]
|
~? ?=(^ saw) [%kiln-overload-lame u.saw]
|
||||||
[~ +>]
|
[~ +>]
|
||||||
::
|
::
|
||||||
|
++ poke-hood-load
|
||||||
|
|= dat/hood-part
|
||||||
|
?> =(our src)
|
||||||
|
~& loaded+-.dat
|
||||||
|
[~ %_(+> lac (~(put by lac) -.dat dat))]
|
||||||
|
::
|
||||||
++ coup-drum-phat (wrap take-coup-phat):from-drum
|
++ coup-drum-phat (wrap take-coup-phat):from-drum
|
||||||
++ coup-helm-hi (wrap coup-hi):from-helm
|
++ coup-helm-hi (wrap coup-hi):from-helm
|
||||||
++ diff-sole-effect-drum-phat (wrap diff-sole-effect-phat):from-drum
|
++ diff-sole-effect-drum-phat (wrap diff-sole-effect-phat):from-drum
|
||||||
@ -136,6 +142,7 @@
|
|||||||
++ poke-kiln-unmount (wrap poke-unmount):from-kiln
|
++ poke-kiln-unmount (wrap poke-unmount):from-kiln
|
||||||
++ poke-kiln-unsync (wrap poke-unsync):from-kiln
|
++ poke-kiln-unsync (wrap poke-unsync):from-kiln
|
||||||
++ poke-womb-invite (wrap poke-invite):from-womb
|
++ poke-womb-invite (wrap poke-invite):from-womb
|
||||||
|
++ poke-womb-save (wrap poke-save):from-womb
|
||||||
++ poke-womb-obey (wrap poke-obey):from-womb
|
++ poke-womb-obey (wrap poke-obey):from-womb
|
||||||
++ poke-womb-claim (wrap poke-claim):from-womb
|
++ poke-womb-claim (wrap poke-claim):from-womb
|
||||||
++ poke-womb-do-claim (wrap poke-do-claim):from-womb
|
++ poke-womb-do-claim (wrap poke-do-claim):from-womb
|
||||||
|
16
gen/hood/load.hoon
Normal file
16
gen/hood/load.hoon
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
::
|
||||||
|
:::: /hoon/load/hood/gen
|
||||||
|
::
|
||||||
|
/? 310
|
||||||
|
/+ womb
|
||||||
|
::
|
||||||
|
::::
|
||||||
|
!:
|
||||||
|
:- %say
|
||||||
|
|= $: {now/@da eny/@uvI byk/beak}
|
||||||
|
{{dap/term $~} $~}
|
||||||
|
==
|
||||||
|
^- {$hood-load ?(part:womb)}
|
||||||
|
?+ dap ~|(unknown-backup+dap !!)
|
||||||
|
$womb [%hood-load .^(part:womb %cx (tope byk /womb-part/bak/hood/app))]
|
||||||
|
==
|
14
gen/hood/save.hoon
Normal file
14
gen/hood/save.hoon
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
::
|
||||||
|
:::: /hoon/save/hood/gen
|
||||||
|
::
|
||||||
|
/? 310
|
||||||
|
::
|
||||||
|
::::
|
||||||
|
!:
|
||||||
|
:- %say
|
||||||
|
|= $: {now/@da eny/@uvI byk/beak}
|
||||||
|
{{dap/term $~} $~}
|
||||||
|
==
|
||||||
|
?+ dap ~|(unknown-backup+dap !!)
|
||||||
|
$womb [%womb-save (tope byk /womb-part/bak/hood/app)]
|
||||||
|
==
|
@ -110,6 +110,7 @@
|
|||||||
|% :: arvo structures
|
|% :: arvo structures
|
||||||
++ card ::
|
++ card ::
|
||||||
$% {$flog wire flog} ::
|
$% {$flog wire flog} ::
|
||||||
|
{$info wire @p @tas nori} :: fs write (backup)
|
||||||
:: {$wait $~} :: delay acknowledgment
|
:: {$wait $~} :: delay acknowledgment
|
||||||
{$poke wire pear} :: app RPC
|
{$poke wire pear} :: app RPC
|
||||||
{$next wire p/ring} :: update private key
|
{$next wire p/ring} :: update private key
|
||||||
@ -503,6 +504,11 @@
|
|||||||
?> =(our src) :: me only
|
?> =(our src) :: me only
|
||||||
.(boss who)
|
.(boss who)
|
||||||
::
|
::
|
||||||
|
++ poke-save :: write backup
|
||||||
|
|= pax/path
|
||||||
|
=< abet
|
||||||
|
(emit %info /backup [our (foal pax [%womb-part !>(`part`+:abet)])])
|
||||||
|
::
|
||||||
++ poke-rekey :: extend will
|
++ poke-rekey :: extend will
|
||||||
|= $~
|
|= $~
|
||||||
=< abet
|
=< abet
|
||||||
|
Loading…
Reference in New Issue
Block a user