Closed tsloughter closed 3 years ago
could this new option eliminate the need for #3? if the dir is empty or the build failed for some reason the user can fix it by supplying --force
also, would it not be simpler to just delete the install dir if --force
is supplied? i would find it odd for these different named directories to appear out of nowhere
I was wondering that too about #3 but I think it makes sense to skip requiring the -f
if its completely empty.
The reason I didn't want -f
to delete the install is then if the compilation fails it would result in losing that previous build.
I guess we could instead only delete it after configure and make
have successfully completed and make the assumptiong that if those suceeded it is very unlikely that make install
would fail, so the failure case is very unlikely at that point.
The reason I didn't want -f to delete the install is then if the compilation fails it would result in losing that previous build.
I don't see as that big of an issue, the user already accepted that possible outcome by passing in --force
, this is saying to erlup
: "i know what i'm doing, stop trying to be so protective"
Yea, I'd just find it annoying if it happened to me :). So I'd do the delete after make
has completed successfully and that is the best of both worlds.
so to sum up:
erlup build <id> --force
Oh, no. I meant that it does not create a backup, it deletes the existing dir (like you suggested) but only after make
, before make install
is called. So a change to the build steps.
ah right, got it
There should be an option to
build
that allows you to force the installation of a new OTP with the same name as an existing one.The previous install in the directory should be moved to a new name in the same directory (to prevent potentially crossing partitions which would be a major slow down) so that it can be put back if the compilation of the new install fails.