Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eepm
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
eepm
Commits
37774ff0
Commit
37774ff0
authored
May 29, 2023
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
distr_info: fix ID_LIKE support, update tests
parent
25ccdd49
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
39 additions
and
13 deletions
+39
-13
distr_info
bin/distr_info
+11
-3
etalon.txt
tests/etc/ALTServer/etalon.txt
+1
-1
etalon.txt
tests/etc/MOS/etalon.txt
+1
-1
etalon.txt
tests/etc/MOSDesktop/etalon.txt
+1
-0
etalon.txt
tests/etc/MOSPanel/etalon.txt
+1
-0
os-release
tests/etc/MOSPanel/etc/os-release
+22
-0
etalon.txt
tests/etc/openSUSE/etalon.txt
+0
-1
lsb-release
tests/etc/openSUSE/etc/lsb-release
+0
-5
test_distr_info.sh
tests/test_distr_info.sh
+2
-2
No files found.
bin/distr_info
View file @
37774ff0
...
...
@@ -314,7 +314,7 @@ normalize_name()
"ROSA Chrome Desktop"
)
echo
"ROSA"
;;
"MOS Desktop"
)
"MOS Desktop"
|
"MOS Panel"
)
echo
"ROSA"
;;
"ROSA Enterprise Linux Desktop"
)
...
...
@@ -375,7 +375,13 @@ if distro os-release ; then
# set by os-release:
#PRETTY_NAME
VENDOR_ID
=
"
$ID
"
[
-n
"
$ID_LIKE
"
]
&&
VENDOR_ID
=
"
$ID_LIKE
"
case
"
$VENDOR_ID
"
in
ubuntu|reld|rhel|astra
)
;;
*
)
[
-n
"
$ID_LIKE
"
]
&&
VENDOR_ID
=
"
$(
echo
"
$ID_LIKE
"
|
cut
-d
" "
-f1
)
"
;;
esac
DISTRIB_FULL_RELEASE
=
"
$DISTRIB_RELEASE
"
DISTRIB_CODENAME
=
"
$VERSION_CODENAME
"
...
...
@@ -436,6 +442,8 @@ case "$DISTRIB_ID" in
"ALTServer"
)
DISTRIB_ID
=
"ALTLinux"
DISTRIB_CODENAME
=
"
$(
echo
p
$DISTRIB_RELEASE
|
sed
-e
's|\..*||'
)
"
# TODO: change p10 to 10
DISTRIB_RELEASE
=
"
$DISTRIB_CODENAME
"
;;
"ALTSPWorkstation"
)
DISTRIB_ID
=
"ALTLinux"
...
...
@@ -460,7 +468,7 @@ case "$DISTRIB_ID" in
DISTRIB_RELEASE
=
"Sisyphus"
DISTRIB_CODENAME
=
"
$DISTRIB_RELEASE
"
;;
"ROSA"
|
"MOSDesktop"
)
"ROSA"
|
"MOSDesktop"
|
"MOSPanel"
)
DISTRIB_FULL_RELEASE
=
"
$DISTRIB_CODENAME
"
DISTRIB_CODENAME
=
"
$DISTRIB_RELEASE
"
;;
...
...
tests/etc/ALTServer/etalon.txt
View file @
37774ff0
ALT
Server/
10 alt/p10
ALT
Linux/p
10 alt/p10
tests/etc/MOS/etalon.txt
View file @
37774ff0
MOC/10 alt/
10
ALTLinux/p10 alt/p
10
tests/etc/MOSDesktop/etalon.txt
0 → 100644
View file @
37774ff0
ROSA/2021.1 rosa/2021.1
tests/etc/MOSPanel/etalon.txt
0 → 100644
View file @
37774ff0
ROSA/2021.1 rosa/2021.1
tests/etc/MOSPanel/etc/os-release
0 → 100644
View file @
37774ff0
# Standard values
# Specification: https://www.freedesktop.org/software/systemd/man/os-release.html
NAME="MOS Panel"
ID=mos
ID_LIKE=rosa
PRETTY_NAME="MOS Panel 12"
CPE_NAME="cpe:/o:mos:rosa:2021.1"
META_CLASS=panel
VARIANT_ID=mos-panel
ANSI_COLOR="1;43"
VERSION="12"
VERSION_ID=2021.1
VERSION_CODENAME=12
HOME_URL="http://os.mos.ru"
LOGO=mos
BUG_REPORT_URL="https://os.mos.ru/git"
# ROSA-specific values
ROSA_OS_BRANCH=mos
ROSA_OS_PLATFORM="rosa2021.1"
ROSA_OS_PLATFORM_INTEGER=202110
ROSA_OS_TYPE=panel
ROSA_OS_VERSION=12
tests/etc/openSUSE/etalon.txt
deleted
100644 → 0
View file @
25ccdd49
openSUSE Tumbleweed/20161014 opensuse tumbleweed/20161014
tests/etc/openSUSE/etc/lsb-release
deleted
100644 → 0
View file @
25ccdd49
LSB_VERSION="core-2.0-noarch:core-3.2-noarch:core-4.0-noarch:core-2.0-x86_64:core-3.2-x86_64:core-4.0-x86_64"
DISTRIB_ID="openSUSE Tumbleweed"
DISTRIB_RELEASE="20161014"
DISTRIB_CODENAME=""
DISTRIB_DESCRIPTION="openSUSE Tumbleweed"
tests/test_distr_info.sh
View file @
37774ff0
...
...
@@ -15,9 +15,9 @@ for ROOTDIR in $(ls -1d etc/*) ; do
fi
le
=
"
$(
cat
$ROOTDIR
/etalon.txt 2>/dev/null
)
"
if
[
"
$le
"
=
"
$idstr
"
]
;
then
printf
"%23s -> %
2
0s : %s
\n
"
"
$(
basename
$ROOTDIR
)
"
"
$idstr
"
"OK"
printf
"%23s -> %
3
0s : %s
\n
"
"
$(
basename
$ROOTDIR
)
"
"
$idstr
"
"OK"
else
printf
"%23s -> %
2
0s : %s
\n
"
"
$(
basename
$ROOTDIR
)
"
"
$idstr
"
"FAIL (expect
$le
)"
printf
"%23s -> %
3
0s : %s
\n
"
"
$(
basename
$ROOTDIR
)
"
"
$idstr
"
"FAIL (expect
$le
)"
fi
done
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment