5

I've the installer in EXE format (mt5setup.exe) and I'd like to download it and automate the installation process on Appveyor CI. On Linux I would normally use xdotool.

Since this installer doesn't have any silent flags to use, how can I automate the installation process headlessly?

4
  • Best idea coming to my mind: autoitscript.com/site/autoit (but out of this, writing this as an answer would be too long or link only) Commented Feb 28, 2017 at 17:39
  • Brief answer how to use it would be fine. Commented Feb 28, 2017 at 17:40
  • There's no brief answer, this mean watching the install and writing the script, the tool examples are good I think and just quoting the doc doesn't sound an answer to me :/. Commented Feb 28, 2017 at 17:42
  • 1
    And another option could be chocolatey.org (again, answering mean installing your linked software or quoting the doc. Commented Feb 28, 2017 at 17:44

1 Answer 1

4

The installation of Windows application can be automated using AutoHotkey (AHK), similar as Winetricks does this for all common apps which support.

Here is example of AHK script which aims to install mentioned application:

Run, mt5setup.exe WinWait, MetaTrader 5 Setup ControlClick, Button1 Sleep 100 ControlClick, Button3 WinWait, MetaTrader 5 Setup, Installation successfully completed ControlClick, Button4 Process, Wait, terminal.exe Process, Close, terminal.exe 

To integrate it with CI, AHK needs to be installed by downloading ZIP file, uncompressing it and passing the above AHK script. Suggested appveyor.yml file:

install: - curl -sLo https://www.metatrader5.com/en/download - curl -sLo http://www.autohotkey.com/download/AutoHotkey104805.zip - unzip *.zip before_test: - dir test_script: - AutoHotkey.exe install.ahk build: off platform: x86 

where install.ahk is the file to contain above AHK script which can be dynamically generated or downloaded from some repository.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.