Calling shell scripts
Hello,
I (rather a NSIS newbie) want to do some things in an existing MySQL database installation using NSIS. In detail, I ask the user for the root password of the database installation, the connection and the name of some database the system should create on that installation afterwards.
Now I want to check some things on leaving a function. First, are connection string and password correct? Second, does the database which should be created afterwards already exist (which would be bad)?
My idea so far is doing this using some simple shell scrips. E.g. I want to run a shell script in the leave function, trying to connect using the data the user entered. If it succeeds, ok, if not I want to present an error.
My question is: Is using shell scripts for this a good idea, or is there a better one maybe? And, if I use shell scripts, how do I manage and call them? The documentation of Exec tells me that "Note that the file specified must exist on the target system, not the compiling system.". This would mean that I would have to transfer my shell script first to the installation system somehow. I think it would be better, if I would be able to tell NSIS "there is the script, pack it into the executable and call it in this situation". Is something like this possible? How would you solve this problem?
Thanks for any hints!