int-72h / oftoast1

(DEPRECATED) Open Fortress frontend using TVN.
GNU General Public License v3.0
6 stars 10 forks source link

[QUESTION] Why do we write to a temp file in CLI? #8

Closed AyeTSG closed 2 years ago

AyeTSG commented 2 years ago

https://github.com/int-72h/oflauncher-rei/blob/cb7963086bb1b46d6299722b7bbdd4d1651200af/cli.py#L48

Just curious, why are we writing to a temp file when downloading from a toast repository? Wouldn't it be more efficient to just download to the end location instead?

int-72h commented 2 years ago

This is for atomicity- if your computer shuts town halfway through it isn't in a state between the revisions.