From b18925b73ce74e66eeb6ef104ad6b9b82cd2cfa8 Mon Sep 17 00:00:00 2001
From: sij <sij@sij.law>
Date: Fri, 17 Jan 2025 22:01:57 +0000
Subject: [PATCH] Update deps

---
 deps | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/deps b/deps
index f7de0a3..0de290d 100755
--- a/deps
+++ b/deps
@@ -322,11 +322,17 @@ def subcmd_ls(args):
                         help='Recurse into subfolders.')
     parser.add_argument('path', nargs='?', default='.',
                         help='File or directory to scan. Default is current directory.')
-    known_args, _ = parser.parse_known_args(args)
+    known_args, remaining_args = parser.parse_known_args(args)
 
     path = known_args.path
     recurse = known_args.recurse
 
+    # Ensure the path exists and handle imports accordingly
+    if not os.path.exists(path):
+        print(f"Error: Path does not exist: {path}")
+        return
+
+    # Call the import finder with the specified options
     imports = find_imports_in_path(path, recurse=recurse)
     if imports:
         print("Imports found:")
@@ -335,6 +341,7 @@ def subcmd_ls(args):
     else:
         print("No Python imports found (or none that require external packages).")
 
+
 ############################
 # Main
 ############################