[tools] winetest: Split the Windows 10 page by version.

Francois Gouget fgouget at codeweavers.com
Wed Apr 14 11:48:48 CDT 2021


Yay!
The Windows 10 pages are more manageable now.

Of course the reports for the old builds are still all bunched into the 
Win10 group which is a bit ugly.

So I'm proposing the attached script to migrate them to the new 
Windows 10 groups. That changes the URL of individual reports though.

For instance https://test.winehq.org/data/.../win10_cw-gtx560-1709-64/version.html
will become  https://test.winehq.org/data/.../win1709_cw-gtx560-1709-64/version.html

So if any one has put links to individual reports in a bug report or an 
email the links will break (they will break in about 60 days anyway).

So here's how to move the old Windows 10 reports to their new groups if 
we want to:

    cd winetest/data
    renamedirs --dry-run   # ... check the output
    renamedirs             # for real now
    gather --update-all    # rebuilds the group index files
    build-index            # rebuilds the main index


Note: I did not really test this script. I handled the migration of my 
      winetest instance the heavy-handed way by requeuing all the 
      reports.
      But I did run it with --dry-run against the winehq tree and the 
      output looked ok.

-- 
Francois Gouget <fgouget at codeweavers.com>
-------------- next part --------------
#!/bin/sh

dry_run=""
[ "$1" = "--dry-run" ] && dry_run="1"

if [ ! -f "index.html" -o ! -f "errors.html" ]
then
    echo "chdir to the data directory" >&2
    exit 1
fi

find . -name report | while read r
do
    r=$(dirname "$r") # strip the trailing /report
    dir=$(dirname "$r")
    src=$(basename "$r")
    case "$src" in
	win8_newtb-*|win8_cw-*)
            # Renaming the Windows 8.1 reports does not change the group they
            # appear in but gets them to be labeled as the correct 'win81'
            # rather than 'win8' (we don't currently have any Windows 8.0 test
            # configuration).
   	    dst=$(echo "$src" | sed -e 's/^win8_/win81_/')
	    ;;
	win10_newtb-*v1507*|win10_*-1507-*)
	    dst=$(echo "$src" | sed -e 's/^win10_/win1507_/')
	    ;;
	win10_newtb-*v1607*|win10_*-1607-*)
	    dst=$(echo "$src" | sed -e 's/^win10_/win1607_/')
	    ;;
	win10_newtb-*v1709*|win10_*-1709-*)
	    dst=$(echo "$src" | sed -e 's/^win10_/win1709_/')
	    ;;
	win10_newtb-*v1809*|win10_*-1809-*)
	    dst=$(echo "$src" | sed -e 's/^win10_/win1809_/')
	    ;;
	win10_newtb-*v1909*|win10_*-1909-*)
	    dst=$(echo "$src" | sed -e 's/^win10_/win1909_/')
	    ;;
	win10_newtb-w10pro64*)
	    dst=$(echo "$src" | sed -e 's/^win10_/win2004_/')
	    ;;
	win10_newtb-w1064*|win10_fgtb-w10pro64*)
	    dst=$(echo "$src" | sed -e 's/^win10_/win2009_/')
	    ;;
	*)
	    dst=""
	    ;;
    esac
    if [ -n "$dst" ]
    then
	echo "mv $r $dir/$dst"
	[ -z "$dry_run" ] && mv "$r" "$dir/$dst"
    fi
done


More information about the wine-devel mailing list