ashb commented on a change in pull request #16110:
URL: https://github.com/apache/airflow/pull/16110#discussion_r640502152



##########
File path: airflow/utils/platform_utils.py
##########
@@ -0,0 +1,16 @@
+import platform
+
+def is_windows() -> bool:
+    """
+    Returns true if executing system is Windows
+    """
+    return platform.system() == 'Windows'
+
+def choose_by_platform(posix_option, windows_option):
+    """
+    Returns either POSIX or Windows option based on executing platform
+    :param posix_option: Option for POSIX system (e.g. path to executable)
+    :param posix_option: Option for Windows system (e.g. path to executable)
+    :returns: Choice based on platform
+    """
+    return windows_option if is_windows() else posix_option

Review comment:
       New line missing at end of file.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to