yta-programming-env 0.3.1__tar.gz → 0.3.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {yta_programming_env-0.3.1 → yta_programming_env-0.3.2}/PKG-INFO +1 -1
- {yta_programming_env-0.3.1 → yta_programming_env-0.3.2}/pyproject.toml +1 -1
- {yta_programming_env-0.3.1 → yta_programming_env-0.3.2}/src/yta_programming_env/__init__.py +11 -1
- {yta_programming_env-0.3.1 → yta_programming_env-0.3.2}/LICENSE +0 -0
- {yta_programming_env-0.3.1 → yta_programming_env-0.3.2}/README.md +0 -0
|
@@ -54,7 +54,6 @@ class Environment:
|
|
|
54
54
|
)
|
|
55
55
|
)
|
|
56
56
|
|
|
57
|
-
|
|
58
57
|
@staticmethod
|
|
59
58
|
def get_current_project_env(
|
|
60
59
|
variable: str,
|
|
@@ -72,3 +71,14 @@ class Environment:
|
|
|
72
71
|
ParameterValidator.validate_mandatory_string('variable', variable, do_accept_empty = False)
|
|
73
72
|
|
|
74
73
|
return Environment.get_current_project_env_dict(env_filename).get(variable, default_value)
|
|
74
|
+
|
|
75
|
+
@staticmethod
|
|
76
|
+
def get_env(
|
|
77
|
+
variable: str,
|
|
78
|
+
default_value: Union[str, bool, float, int, None] = None,
|
|
79
|
+
):
|
|
80
|
+
"""
|
|
81
|
+
Get the `variable` from the `os` environment by doing
|
|
82
|
+
a `os.getenv(variable)`.
|
|
83
|
+
"""
|
|
84
|
+
return os.getenv(variable, default_value)
|
|
File without changes
|
|
File without changes
|