aboutsummaryrefslogtreecommitdiff
path: root/store/works/python/cru/system.py
diff options
context:
space:
mode:
authorYuqian Yang <crupest@crupest.life>2025-09-04 14:34:37 +0800
committerYuqian Yang <crupest@crupest.life>2025-09-04 14:34:37 +0800
commit97b51e84b81d3afa62f316769bfea614e5b1aefc (patch)
tree2aec3195c1e4fcf3b09a2659f1526253fa5a7fa4 /store/works/python/cru/system.py
parent94e018f503d4a656c7f7d5b86ce3a47babfadd8d (diff)
downloadcrupest-97b51e84b81d3afa62f316769bfea614e5b1aefc.tar.gz
crupest-97b51e84b81d3afa62f316769bfea614e5b1aefc.tar.bz2
crupest-97b51e84b81d3afa62f316769bfea614e5b1aefc.zip
chore: delete works from work tree.
Diffstat (limited to 'store/works/python/cru/system.py')
-rw-r--r--store/works/python/cru/system.py23
1 files changed, 0 insertions, 23 deletions
diff --git a/store/works/python/cru/system.py b/store/works/python/cru/system.py
deleted file mode 100644
index f321717..0000000
--- a/store/works/python/cru/system.py
+++ /dev/null
@@ -1,23 +0,0 @@
-import os.path
-import re
-
-
-def check_debian_derivative_version(name: str) -> None | str:
- if not os.path.isfile("/etc/os-release"):
- return None
- with open("/etc/os-release", "r") as f:
- content = f.read()
- if f"ID={name}" not in content:
- return None
- m = re.search(r'VERSION_ID="(.+)"', content)
- if m is None:
- return None
- return m.group(1)
-
-
-def check_ubuntu_version() -> None | str:
- return check_debian_derivative_version("ubuntu")
-
-
-def check_debian_version() -> None | str:
- return check_debian_derivative_version("debian")