Commit b9c6088
committed
fix: Improve dependency parsing and logging
This commit refines the logic for parsing dependencies from Gradle build files and improves the associated logging for better debugging.
**Key Changes:**
* **Improved Regex for Alias Dependencies:**
* The regular expression in `ProjectAnalyzerRepositoryImpl.kt` used for finding unprefixed aliases (e.g., `implementation(compose.ui)`) has been made more specific.
* The new regex (`\(\s*([a-zA-Z_][\w.]+)\s*\)`) now correctly captures only valid alias paths, ignoring function calls with string literals like `project(":module")` or `files("...")`.
* **Enhanced Logging and Filtering:**
* Conditions for matching unprefixed aliases now explicitly ignore paths starting with `project` and `files` to prevent them from being incorrectly treated as library aliases.
* The debug log for "not found" unprefixed aliases has been updated to log the entire regex match group, providing more context for troubleshooting parsing errors.1 parent dbe57eb commit b9c6088
File tree
1 file changed
+7
-4
lines changed- composeApp/src/jvmMain/kotlin/com/meet/dev/analyzer/data/repository/project
1 file changed
+7
-4
lines changedLines changed: 7 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
174 | 174 | | |
175 | 175 | | |
176 | 176 | | |
177 | | - | |
| 177 | + | |
178 | 178 | | |
179 | 179 | | |
180 | 180 | | |
| |||
309 | 309 | | |
310 | 310 | | |
311 | 311 | | |
312 | | - | |
313 | | - | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
314 | 315 | | |
315 | 316 | | |
316 | 317 | | |
| |||
341 | 342 | | |
342 | 343 | | |
343 | 344 | | |
344 | | - | |
| 345 | + | |
| 346 | + | |
345 | 347 | | |
346 | 348 | | |
347 | 349 | | |
| |||
536 | 538 | | |
537 | 539 | | |
538 | 540 | | |
| 541 | + | |
539 | 542 | | |
540 | 543 | | |
541 | 544 | | |
| |||
0 commit comments