From 82040394ad09fe086d127100080470144c3a82c1 Mon Sep 17 00:00:00 2001 From: gkze Date: Thu, 13 Apr 2023 12:25:38 -0700 Subject: [PATCH] Updates --- .vscode/settings.default.json | 4 ---- .vscode/settings.template.json | 3 +++ powerk8s.py | 6 +++--- 3 files changed, 6 insertions(+), 7 deletions(-) delete mode 100644 .vscode/settings.default.json create mode 100644 .vscode/settings.template.json diff --git a/.vscode/settings.default.json b/.vscode/settings.default.json deleted file mode 100644 index f26305d..0000000 --- a/.vscode/settings.default.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "files.associations": {".envrc": "dotenv"}, - "python.formatting.provider": "black" -} diff --git a/.vscode/settings.template.json b/.vscode/settings.template.json new file mode 100644 index 0000000..b7368ca --- /dev/null +++ b/.vscode/settings.template.json @@ -0,0 +1,3 @@ +{ + "python.formatting.provider": "black" +} diff --git a/powerk8s.py b/powerk8s.py index cd42875..c9025eb 100644 --- a/powerk8s.py +++ b/powerk8s.py @@ -8,7 +8,7 @@ from __future__ import annotations from dataclasses import asdict, dataclass, field -from enum import StrEnum +from enum import Enum from typing import Any, Mapping, Sequence from kubernetes import config # type: ignore @@ -17,7 +17,7 @@ KUBERNETES_LOGO: str = "\U00002388 " -class SegmentArg(StrEnum): +class SegmentArg(Enum): """All possible Powerline segment argument types for Powerk8s.""" SHOW_KUBERNETES_LOGO = "show_kube_logo" @@ -26,7 +26,7 @@ class SegmentArg(StrEnum): SHOW_DEFAULT_NAMESPACE = "show_default_namespace" -class HighlightGroup(StrEnum): +class HighlightGroup(Enum): """All possible highlight groups for Powerk8s.""" KUBERNETES_CLUSTER_ALERT = "kubernetes_cluster:alert"