1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768 |
- From 27d6039270fe98df9a6b49ca53324b9acf8a7264 Mon Sep 17 00:00:00 2001
- From: Luke Shumaker <lukeshu@parabola.nu>
- Date: Wed, 25 May 2016 12:28:30 -0400
- Subject: [PATCH 4/7] FSDG: os-release: Default ID to "gnu-linux" instead of
- "linux"
- As far as I can tell, no code in this repository actually uses the ID
- field, so this is just a man page change.
- ---
- man/check-os-release-simple.py | 2 +-
- man/check-os-release.py | 2 +-
- man/check-os-release.sh | 2 +-
- man/os-release.xml | 2 +-
- 4 files changed, 4 insertions(+), 4 deletions(-)
- diff --git a/man/check-os-release-simple.py b/man/check-os-release-simple.py
- index 9ad899a814..63ea424891 100644
- --- a/man/check-os-release-simple.py
- +++ b/man/check-os-release-simple.py
- @@ -7,6 +7,6 @@ os_release = platform.freedesktop_os_release()
- pretty_name = os_release.get('PRETTY_NAME', 'GNU/Linux')
- print(f'Running on {pretty_name!r}')
-
- -if 'fedora' in [os_release.get('ID', 'linux'),
- +if 'fedora' in [os_release.get('ID', 'gnu-linux'),
- *os_release.get('ID_LIKE', '').split()]:
- print('Looks like Fedora!')
- diff --git a/man/check-os-release.py b/man/check-os-release.py
- index 373b77ed06..09aebd7a4f 100644
- --- a/man/check-os-release.py
- +++ b/man/check-os-release.py
- @@ -32,6 +32,6 @@ os_release = dict(read_os_release())
- pretty_name = os_release.get('PRETTY_NAME', 'GNU/Linux')
- print(f'Running on {pretty_name!r}')
-
- -if 'debian' in [os_release.get('ID', 'linux'),
- +if 'debian' in [os_release.get('ID', 'gnu-linux'),
- *os_release.get('ID_LIKE', '').split()]:
- print('Looks like Debian!')
- diff --git a/man/check-os-release.sh b/man/check-os-release.sh
- index 084647a38b..c02b4e6743 100644
- --- a/man/check-os-release.sh
- +++ b/man/check-os-release.sh
- @@ -6,6 +6,6 @@ test -e /etc/os-release && os_release='/etc/os-release' || os_release='/usr/lib/
-
- echo "Running on ${PRETTY_NAME:-GNU/Linux}"
-
- -if [ "${ID:-linux}" = "debian" ] || [ "${ID_LIKE#*debian*}" != "${ID_LIKE}" ]; then
- +if [ "${ID:-gnu-linux}" = "debian" ] || [ "${ID_LIKE#*debian*}" != "${ID_LIKE}" ]; then
- echo "Looks like Debian!"
- fi
- diff --git a/man/os-release.xml b/man/os-release.xml
- index f5167c6af0..e5a797489c 100644
- --- a/man/os-release.xml
- +++ b/man/os-release.xml
- @@ -159,7 +159,7 @@
- <listitem><para>A lower-case string (no spaces or other characters outside of 0–9, a–z, ".", "_"
- and "-") identifying the operating system, excluding any version information and suitable for
- processing by scripts or usage in generated filenames. If not set, a default of
- - <literal>ID=linux</literal> may be used. Note that even though this string may not include
- + <literal>ID=gnu-linux</literal> may be used. Note that even though this string may not include
- characters that require shell quoting, quoting may nevertheless be used.</para>
-
- <para>Examples: <literal>ID=fedora</literal>, <literal>ID=debian</literal>.</para></listitem>
- --
- 2.45.2
|