Skip to content

Commit 3ba8cf4

Browse files
author
Dai Hung PHAM
committed
fix & delete no used code
1 parent 1d8caaa commit 3ba8cf4

File tree

1 file changed

+1
-20
lines changed

1 file changed

+1
-20
lines changed

src/gitingest/parse_query.py

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -190,20 +190,6 @@ def extract_valid_url(source: str) -> Union[str, None]:
190190

191191
return None
192192

193-
def _parse_path(path: str) -> dict[str, Any]:
194-
"""Parse a local file path."""
195-
# Normalize path separators and make absolute, remove trailing slashes
196-
normalized_path = os.path.abspath(os.path.normpath(path.rstrip('\\/')))
197-
198-
return {
199-
"local_path": normalized_path,
200-
"slug": os.path.basename(normalized_path),
201-
"subpath": "/",
202-
"id": str(uuid.uuid4()),
203-
"url": None,
204-
}
205-
206-
import re
207193

208194
def parse_query(
209195
source: str,
@@ -264,7 +250,7 @@ def parse_query(
264250

265251
# Add user-defined ignore patterns
266252
if ignore_patterns:
267-
parsed_ignore = parse_patterns(ignore_patterns)
253+
parsed_ignore = _parse_patterns(ignore_patterns)
268254
final_ignore_patterns.extend(parsed_ignore)
269255

270256

@@ -286,11 +272,6 @@ def parse_query(
286272

287273

288274

289-
290-
291-
292-
293-
294275
### 📝 **Parse .gitignore**
295276
def parse_gitignore(gitignore_path: str) -> list[str]:
296277
"""

0 commit comments

Comments
 (0)