aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/project/os.py
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--project/os.py13
1 files changed, 5 insertions, 8 deletions
diff --git a/project/os.py b/project/os.py
index 4ddf703..199086f 100644
--- a/project/os.py
+++ b/project/os.py
@@ -3,17 +3,14 @@
# For details, see https://github.com/egor-tensin/cmake-common
# Distributed under the MIT License.
-from enum import Enum
+from enum import auto, StrEnum
import platform
-class OS(Enum):
- WINDOWS = "Windows"
- LINUX = "Linux"
- MACOS = "macOS"
-
- def __str__(self):
- return str(self.value)
+class OS(StrEnum):
+ WINDOWS = auto()
+ LINUX = auto()
+ MACOS = auto()
@staticmethod
def current():