So this time I've done things in the right order: first publish the code and then announce it.
So here's wt-daily, a script to "orchestrate all the daily WineTest runs and related tasks."
Here's the 'quickstart guide':
git clone https://github.com/fgouget/wt-daily.git cd wt-daily vi wt-daily.config In this file set the following environment variables: email="your email address here" tag="a-tag" desc="A description of your system for Wine developers" shutdown="suspend"
Then when you know you won't be needing your computer for a while, just type ./wt-daily. This will update and rebuild Wine, run the tests and finally suspend your machine.
It's that simple!
If you'd rather not suspend your machine you can set shutdown to "poweroff", "reboot" or even leave it out to keep the computer on.
By default wt-daily will ask for your green light before starting the tests. So you can start it while still using the computer and click 'Ok' once you take off. To have the tests run automatically (e.g. from cron), pass --auto-test on the command line or set default_options="--auto-test" in the configuration file.
If you have a 64-bit system then you can also set the {tag,desc}wow32 and {tag,desc}wow64 variables to run the tests in a mixed 32/64-bit WinePrefix. If you have a Mac, set the {tag,desc}mac variables to run the tests using the Mac driver instead of (or in addition to) X11.
The script should work on OS/X though I have obviously not tested it in a long time. I'ĺl be happy to get feedback on that, particularly in the form of patches.
Now you can totally stop reading here. But there's a ton more that the script can do. Read on if you want to discover more.
You can have the script start an application that will prevent the tests from running until you close it. I used that to run the tests on a MythTV client box. Wine would get updated and rebuilt in the background while I was watching TV and once that was done the script would run the tests and finally power off the computer.
You can also take an image of a suitably configured Windows partition and have wt-daily restore that image to the partition, reboot to Windows which will automatically run WineTest (you'll find the batch script for that in the repository), then reboot back to Linux (or shutdown the computer).
This functionality is used on the cw1-hd6800 and xw2-gtx560 CodeWeavers boxes to run the tests on Linux, then Windows 8.1 and then Windows 10. All automatically. The script actually runs every hour and skips the tests (and rebooting) if nothing changed since the last run.
I also have this Windows image thing set up on my fg-acer64 laptop but there I interactively select which Windows image to restore, with a choice of Windows 8, 8.1 and 10 (or nothing if I don't feel like going through a reboot).
You can also extend wt-daily to add non Wine tasks. For instance on my laptops it runs another script that synchronizes the Documents folder with my desktop and runs 'git fetch --all' in all my Git repositories. This way the next time I go offline everything is up to date.
The repository also contains a number or scripts that you may find useful in your own automation tasks as they support not just Linux but OS/X too.
wt-image Creates, checks, restores or reboots to a disk image.
wt-bot Update, build and check the Wine source code, and run the tests. wt-make Seeks to automatically fully use CPU and I/O parallelism when running make.
wt-ask Asks a simple Yes/No question to the user. wt-notify Displays a notification to the user. wt-power Powers off, reboots, suspends or hibernates the computer. wt-screensaver Controls the screensaver. In particular it can prevent it from triggering. wt-nice Runs the specified command with the lowest possible CPU and I/O priority.
On Fri, 18 Sep 2015, Francois Gouget wrote: [...]
So here's wt-daily, a script to "orchestrate all the daily WineTest runs and related tasks."
I have made some updates to the wt-daily suite of scripts. In particular if you have been running wt-daily you have to update it so it knows how to get the Gecko and Mono installers from the new URLs.
Here are the changelog highlights:
* First and formost the download URLs of the Wine Gecko and Mono installers have been updated. They are still direct downloads for now. I should probably use the PHP download URLs eventually.
* wt-daily now verifies the addon installer checksums to be sure not to use broken files (such as the 404 page of the old URLs).
* wt-daily now supports self-update. This can be used to ensure the scripts will keep working unattended, even if further updates are needed to deal with Wine changes. Note that this assumes you trust whoever administrates or has commit access to the upstream Git repository (which would be GitHub and me respectively), and thus is disabled by default. To enable it set self_update="true" in the configuration file.
* If the build fails wt-daily will now clean the tree and try again. This should take care of the very rare cases where Wine's build system gets confused after a source update.
* The --no-fetch option has been renamed to --no-update. The former would still rebase the source which the latter does not. This makes it possible to intentionally run the tests against an older commitid (e.g. to fill in some gaps). This should be the only backward-incompatible change and since it would most likely not make sense using it in automated contexts I expect this will not cause trouble.
Here's the slightly updated 'quickstart guide':
git clone https://github.com/fgouget/wt-daily.git cd wt-daily vi wt-daily.config In this file set the following environment variables: email="your email address here" tag="a-tag" desc="A description of your system for Wine developers" shutdown="suspend" self_update="true" # See security implications!
Cheers,