lib/shelly/cli/main.rb in shelly-0.1.32 vs lib/shelly/cli/main.rb in shelly-0.1.33

- old
+ new

@@ -202,10 +202,14 @@ say_error "Visit: #{app.edit_billing_url}", :with_exit => false when "payment_declined" say_error "Not starting. Invoice for cloud '#{app}' was declined." end exit 1 + rescue Client::LockedException => e + say_error "Deployment is currently blocked:", :with_exit => false + say_error e[:message] + exit 1 end desc "setup", "Set up git remotes for deployment on Shelly Cloud" long_desc %{ Set up git remotes for deployment on Shelly Cloud. @@ -343,9 +347,13 @@ say_error "Cloud #{app} is not running", :with_exit => false say "Start your cloud with `shelly start --cloud #{app}`" exit 1 else raise end + rescue Client::LockedException => e + say_error "Deployment is currently blocked:", :with_exit => false + say_error e[:message] + exit 1 end desc "open", "Open application page in browser" method_option :cloud, :type => :string, :aliases => "-c", :desc => "Specify cloud" def open