From a843082d511f7c53bea88aa3430a49412e2a1694 Mon Sep 17 00:00:00 2001 From: Andrew Davis Date: Fri, 8 Aug 2025 13:51:54 +1000 Subject: [PATCH] boxman: don't say setup when not running a full setup It's a bit confusing to pass /nosetup and have it spit out: > Box created, will now run setup Change the messaging slightly to avoid confusion --- lib/Dobby/BoxManager.pm | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/Dobby/BoxManager.pm b/lib/Dobby/BoxManager.pm index 9dc72ed..181b7e5 100644 --- a/lib/Dobby/BoxManager.pm +++ b/lib/Dobby/BoxManager.pm @@ -173,10 +173,11 @@ async sub create_droplet ($self, $spec) { } } + my $message = $spec->run_custom_setup ? "Box created, will now run setup. Your box is: " + : "Box created, will now unlock. Your box is: "; if ($spec->run_standard_setup or $spec->run_custom_setup) { $self->handle_message( - "Box created, will now run setup. Your box is: " - . $self->_format_droplet($droplet) + $message . $self->_format_droplet($droplet) ); return await $self->_setup_droplet( @@ -326,7 +327,10 @@ async sub _setup_droplet ($self, $spec, $droplet, $key_file) { $self->handle_log([ "result of ssh: %s", Process::Status->new($exitcode)->as_string ]); if ($exitcode == 0) { - $self->handle_message("Box ($droplet->{name}) is now set up!"); + $self->handle_message( + $spec->run_custom_setup ? "Box ($droplet->{name}) is now set up!" + : "Box ($droplet->{name}) is ready!" + ); return; }