They're not reliably available and are now causing CI failures. Instead
use libloot for the test cases that used 7z, and update it because older
versions of libloot incorrectly use "ProductVERSION " instead of
"ProductVersion".
It returns true if the path is a directory that can be read, or if
it is not a directory and can be opened as a file in read-only mode.
This is being added to allow conditions to guard against trying to
read the version of an executable that exists but is unreadable,
e.g. any of the official game executables for games installed
through the Microsoft Store or Xbox app.
The Windows test for evaling with an unreadable file doesn't use a
file that's unreadable for the same reason as what's motivating this
new function, but the error that is handled when checking the file
is the same kind (permission denied).
This makes the comparison between a numeric and a non-numeric release ID
more granular, by trying to parse leading digits in a non-numeric
release ID as a number and comparing it against the numeric ID. If the
two differ, their ordering is used as the ID ordering. If they're equal,
the non-numeric ID is considered greater so long as it has a non-zero
length suffix after the numeric leading digits. This means that
the version
0.78b is correctly considered to be less than the version 0.86, which
was not previously the case.
Pre-release IDs are not affected to avoid not conforming to the Semver
spec, which states that numeric pre-release IDs are always less than
non-numeric pre-release IDs. As non-numeric release IDs are not allowed
in semver, this commit's changes don't change the behaviour for semver
version comparisons.
If an installed plugin has a .ghost extension, remove it before trying
to match the filename against the given regex. This makes functions that
take paths and functions that take regexes behave the same way for
ghosted plugins.
- Don't recursively check .ghost file extensions: plugin.esp.ghost.ghost
is not a valid plugin filename.
- Only add a .ghost file extension if the path that does not exist has
an unghosted plugin file extension.