From ebb6715aadd7a82968c6ace8955ffe735a715543 Mon Sep 17 00:00:00 2001 From: Tim Byrne Date: Mon, 21 Feb 2022 14:01:08 -0600 Subject: [PATCH] Reduce supported labels for architecture --- test/test_alt.py | 2 +- test/test_unit_score_file.py | 2 +- yadm | 2 +- yadm.1 | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/test/test_alt.py b/test/test_alt.py index 6d14f65..ddaf374 100644 --- a/test/test_alt.py +++ b/test/test_alt.py @@ -82,7 +82,7 @@ def test_relative_link(runner, paths, yadm_alt): @pytest.mark.parametrize('suffix', [ '##default', '##default,e.txt', '##default,extension.txt', - '##a.$tst_arch', '##arch.$tst_arch', '##architecture.$tst_arch', + '##a.$tst_arch', '##arch.$tst_arch', '##o.$tst_sys', '##os.$tst_sys', '##d.$tst_distro', '##distro.$tst_distro', '##f.$tst_distro_family', '##distro_family.$tst_distro_family', diff --git a/test/test_unit_score_file.py b/test/test_unit_score_file.py index 539831b..a63246a 100644 --- a/test/test_unit_score_file.py +++ b/test/test_unit_score_file.py @@ -7,7 +7,7 @@ CONDITION = { 'modifier': 0, }, 'arch': { - 'labels': ['a', 'arch', 'architecture'], + 'labels': ['a', 'arch'], 'modifier': 1, }, 'system': { diff --git a/yadm b/yadm index 22343ed..40fa224 100755 --- a/yadm +++ b/yadm @@ -189,7 +189,7 @@ function score_file() { if [[ "$label" =~ ^(default)$ ]]; then score=$((score + 0)) # variable conditions - elif [[ "$label" =~ ^(a|arch|architecture)$ ]]; then + elif [[ "$label" =~ ^(a|arch)$ ]]; then if [ "$value" = "$local_arch" ]; then score=$((score + 1)) else diff --git a/yadm.1 b/yadm.1 index d8bcad4..94ad229 100644 --- a/yadm.1 +++ b/yadm.1 @@ -518,7 +518,7 @@ Valid if the value matches the OS. OS is calculated by running .BR "uname -s" . .TP -.BR architecture , " arch" , " a +.BR arch , " a Valid if the value matches the architecture. Architecture is calculated by running .BR "uname -m" .