Skip to content

Commit

Permalink
vm_data.py-dist: Update documentation about host version re patterns
Browse files Browse the repository at this point in the history
This change specifies that raw strings must be used for the host version
regular expression patterns in vm_data.py (i.e. r"PATTERN"). This
corrects warning about invalid escaped sequences.

Signed-off-by: Thierry Escande <[email protected]>
  • Loading branch information
tescande committed Mar 4, 2024
1 parent 017403a commit 265e754
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions vm_data.py-dist
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@

# If a vm is meant to be used only on a given host version, the version can be specified
# through a tuple entry with (vm_filename, host_version) as:
# "small_vm": ("alpine-minimal-3.12.0.xva", "8\.3\.")
# "small_vm": ("alpine-minimal-3.12.0.xva", r"8\.3\.")

# The host version specified for a vm is matched using re.match(), so valid patterns
# can be "8\.2\.1", "8\.[23]\.", or "(9\.0|8\.2)".
# must be defined as raw strings: r"8\.2\.1", r"8\.[23]\.", or r"(9\.0|8\.2)".

# If host version is not specified, the vm filename will be used whatever the host version

Expand All @@ -23,7 +23,7 @@

# Same as "single", a vm can be bound to a given host version:
# "all": ["alpine-minimal-3.12.0.xva",
# ("alpine-uefi-minimal-efitools-3.12.0.xva", "8\.2\."),
# ("alpine-uefi-minimal-efitools-3.12.0.xva", r"8\.2\."),
# ...],

VMS = {
Expand Down

0 comments on commit 265e754

Please sign in to comment.