Jump to content
Ketarin forum

Raising an error when aborting a batch setup script


lujomu
 Share

Recommended Posts

Hi!

 

I am quite certain this must have come up before, but I can't find any relevant topic.
 
I am trying to abort a batch setup script. I have tried the following lines:
exit 1
exit 2
exit 3
exit /B 1
exit /B 2
exit /B 3
But no matter what, Ketarin always prompts "{App}: Installed successfully".
 
For good meassure I tried the C# equivalent:
Abort( "Something went wrong!");
And this yields a nice "{App}: Setup failed (Something went wrong!)" message.
 
Could someone please enlighten me - what am I missing?
 
Cheers,
lujomu
Link to comment
Share on other sites

I used exactly that single line as test script. And it does work for the application specific pre-update command, but I am talking about the application specific setup command (http://wiki.ketarin.org/index.php/Setup_instructions).

 

As this seems to work for some commands but not for others, I checked them each individually (Ketarin v1.7.1.434):

 

C# test script:



Abort("Error");


C# test script results:


  • Default pre-update command in settings: Throws error.
  • Application specific pre-update command: Throws error.
  • Default post-update command in settings: Throws error.
  • Application specific post-update command: Throws error.
  • Command to execute after updating all applications: No error.
  • Application specific setup command: Throws error.


Batch test script:



exit 1



Batch test script results:


  • Default pre-update command in settings: Throws error.
  • Application specific pre-update command: Throws error.
  • Default post-update command in settings: No error.
  • Application specific post-update command: Throws error.
  • Command to execute after updating all applications: No error.
  • Application specific setup command: No error.

 

As the results differ for both kind of scripts, I doubt this is intentional.

Can someone else reproduce this? Might this be a bug?

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 months later...

I'm not aware of any "Abort" functionality. Whatever that it, it's not meant to be supported to results are pretty much undefined.

 

Exit codes are not currently checked in setup instructions, so that is rather a feature request than a bug to fix ;)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.