69 lines
2.5 KiB
Diff
69 lines
2.5 KiB
Diff
--- source/python/distro_info.py 2021-11-04 15:27:37.000000000 -0600
|
|
+++ source/python/distro_info.py_fix 2022-04-06 10:20:39.217365952 -0500
|
|
@@ -1,3 +1,4 @@
|
|
+# Copyright (C) 2021, Trisquel GNU/Linux developers <trisquel-devel@listas.trisquel.info>
|
|
# Copyright (C) 2009-2012, Benjamin Drung <bdrung@debian.org>
|
|
#
|
|
# Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -12,7 +13,7 @@
|
|
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
|
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|
|
|
-"""provides information about Ubuntu's and Debian's distributions"""
|
|
+"""provides information about Trisquel's and Debian's distributions"""
|
|
|
|
import csv
|
|
import datetime
|
|
@@ -100,7 +101,7 @@
|
|
|
|
class DistroInfo:
|
|
"""Base class for distribution information.
|
|
- Use DebianDistroInfo or UbuntuDistroInfo instead of using this directly.
|
|
+ Use DebianDistroInfo or TrisquelDistroInfo instead of using this directly.
|
|
"""
|
|
|
|
def __init__(self, distro):
|
|
@@ -311,14 +312,14 @@
|
|
]
|
|
|
|
|
|
-class UbuntuDistroInfo(DistroInfo):
|
|
- """provides information about Ubuntu's distributions"""
|
|
+class TrisquelDistroInfo(DistroInfo):
|
|
+ """provides information about Trisquel's distributions"""
|
|
|
|
def __init__(self):
|
|
- super().__init__("Ubuntu")
|
|
+ super().__init__("Trisquel")
|
|
|
|
def lts(self, date=None, result="codename"):
|
|
- """Get latest long term support (LTS) Ubuntu distribution based on the
|
|
+ """Get latest long term support (LTS) Trisquel distribution based on the
|
|
given date."""
|
|
if date is None:
|
|
date = self._date
|
|
@@ -337,7 +338,7 @@
|
|
return "LTS" in distros[0].version
|
|
|
|
def supported(self, date=None, result="codename"):
|
|
- """Get list of all supported Ubuntu distributions based on the given
|
|
+ """Get list of all supported Trisquel distributions based on the given
|
|
date."""
|
|
if date is None:
|
|
date = self._date
|
|
@@ -347,15 +348,3 @@
|
|
if date <= x.eol or (x.eol_server is not None and date <= x.eol_server)
|
|
]
|
|
return distros
|
|
-
|
|
- def supported_esm(self, date=None, result="codename"):
|
|
- """Get list of all ESM supported Ubuntu distributions based on the
|
|
- given date."""
|
|
- if date is None:
|
|
- date = self._date
|
|
- distros = [
|
|
- self._format(result, x)
|
|
- for x in self._avail(date)
|
|
- if x.eol_esm is not None and date <= x.eol_esm
|
|
- ]
|
|
- return distros
|