From 4698c9873f255dffe10683456f41b24591991953 Mon Sep 17 00:00:00 2001 From: Lewis Cowles Date: Wed, 16 Oct 2024 04:55:50 +0100 Subject: [PATCH] chore: nicer error message for windows users --- sh.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sh.py b/sh.py index 4a83a3ac..2976d6a5 100644 --- a/sh.py +++ b/sh.py @@ -28,7 +28,10 @@ from collections.abc import Mapping import errno -import fcntl +try: + import fcntl +except ImportError: + raise RuntimeError("This only works on *nix systems. Try Docker?") import gc import getpass import glob as glob_module