linthis 0.0.12__tar.gz → 0.0.13__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (288) hide show
  1. {linthis-0.0.12 → linthis-0.0.13}/Cargo.lock +1 -1
  2. {linthis-0.0.12 → linthis-0.0.13}/Cargo.toml +1 -1
  3. {linthis-0.0.12 → linthis-0.0.13}/PKG-INFO +1 -1
  4. {linthis-0.0.12 → linthis-0.0.13}/pyproject.toml +1 -1
  5. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/cpp.rs +1 -8
  6. {linthis-0.0.12 → linthis-0.0.13}/src/cli/init.rs +2 -2
  7. {linthis-0.0.12 → linthis-0.0.13}/src/cli/runner.rs +2 -3
  8. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/converters/eslint.rs +6 -5
  9. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/converters/prettier.rs +9 -9
  10. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/mod.rs +1 -1
  11. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/parsers/prettier.rs +33 -33
  12. {linthis-0.0.12 → linthis-0.0.13}/src/config/mod.rs +1 -0
  13. {linthis-0.0.12 → linthis-0.0.13}/src/fixers/cpplint.rs +8 -11
  14. {linthis-0.0.12 → linthis-0.0.13}/src/fixers/source.rs +3 -5
  15. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/cpp.rs +1 -1
  16. {linthis-0.0.12 → linthis-0.0.13}/src/interactive/menu.rs +0 -16
  17. {linthis-0.0.12 → linthis-0.0.13}/src/interactive/nolint.rs +4 -4
  18. {linthis-0.0.12 → linthis-0.0.13}/src/lib.rs +4 -6
  19. {linthis-0.0.12 → linthis-0.0.13}/src/lsp/diagnostics.rs +1 -1
  20. {linthis-0.0.12 → linthis-0.0.13}/src/lsp/document.rs +5 -0
  21. {linthis-0.0.12 → linthis-0.0.13}/src/main.rs +2 -3
  22. {linthis-0.0.12 → linthis-0.0.13}/src/tui/ui.rs +1 -0
  23. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/common.rs +2 -0
  24. {linthis-0.0.12 → linthis-0.0.13}/.github/workflows/release.yml +0 -0
  25. {linthis-0.0.12 → linthis-0.0.13}/.gitignore +0 -0
  26. {linthis-0.0.12 → linthis-0.0.13}/.readthedocs.yaml +0 -0
  27. {linthis-0.0.12 → linthis-0.0.13}/CHANGELOG.md +0 -0
  28. {linthis-0.0.12 → linthis-0.0.13}/README.md +0 -0
  29. {linthis-0.0.12 → linthis-0.0.13}/defaults/.clang-tidy +0 -0
  30. {linthis-0.0.12 → linthis-0.0.13}/defaults/config.toml +0 -0
  31. {linthis-0.0.12 → linthis-0.0.13}/dev.sh +0 -0
  32. {linthis-0.0.12 → linthis-0.0.13}/docs/assets/README.md +0 -0
  33. {linthis-0.0.12 → linthis-0.0.13}/docs/assets/favicon.svg +0 -0
  34. {linthis-0.0.12 → linthis-0.0.13}/docs/assets/logo.svg +0 -0
  35. {linthis-0.0.12 → linthis-0.0.13}/docs/assets/preview.html +0 -0
  36. {linthis-0.0.12 → linthis-0.0.13}/docs/config-cli-design.md +0 -0
  37. {linthis-0.0.12 → linthis-0.0.13}/docs/development/changelog.md +0 -0
  38. {linthis-0.0.12 → linthis-0.0.13}/docs/development/changelog.zh.md +0 -0
  39. {linthis-0.0.12 → linthis-0.0.13}/docs/development/contributing.md +0 -0
  40. {linthis-0.0.12 → linthis-0.0.13}/docs/development/contributing.zh.md +0 -0
  41. {linthis-0.0.12 → linthis-0.0.13}/docs/development/roadmap.md +0 -0
  42. {linthis-0.0.12 → linthis-0.0.13}/docs/development/roadmap.zh.md +0 -0
  43. {linthis-0.0.12 → linthis-0.0.13}/docs/editors/vscode.md +0 -0
  44. {linthis-0.0.12 → linthis-0.0.13}/docs/editors/vscode.zh.md +0 -0
  45. {linthis-0.0.12 → linthis-0.0.13}/docs/features/auto-sync.md +0 -0
  46. {linthis-0.0.12 → linthis-0.0.13}/docs/features/auto-sync.zh.md +0 -0
  47. {linthis-0.0.12 → linthis-0.0.13}/docs/features/git-hooks.md +0 -0
  48. {linthis-0.0.12 → linthis-0.0.13}/docs/features/git-hooks.zh.md +0 -0
  49. {linthis-0.0.12 → linthis-0.0.13}/docs/features/plugins.md +0 -0
  50. {linthis-0.0.12 → linthis-0.0.13}/docs/features/plugins.zh.md +0 -0
  51. {linthis-0.0.12 → linthis-0.0.13}/docs/features/self-update.md +0 -0
  52. {linthis-0.0.12 → linthis-0.0.13}/docs/features/self-update.zh.md +0 -0
  53. {linthis-0.0.12 → linthis-0.0.13}/docs/features/watch-mode.md +0 -0
  54. {linthis-0.0.12 → linthis-0.0.13}/docs/features/watch-mode.zh.md +0 -0
  55. {linthis-0.0.12 → linthis-0.0.13}/docs/getting-started/configuration.md +0 -0
  56. {linthis-0.0.12 → linthis-0.0.13}/docs/getting-started/configuration.zh.md +0 -0
  57. {linthis-0.0.12 → linthis-0.0.13}/docs/getting-started/installation.md +0 -0
  58. {linthis-0.0.12 → linthis-0.0.13}/docs/getting-started/installation.zh.md +0 -0
  59. {linthis-0.0.12 → linthis-0.0.13}/docs/getting-started/quickstart.md +0 -0
  60. {linthis-0.0.12 → linthis-0.0.13}/docs/getting-started/quickstart.zh.md +0 -0
  61. {linthis-0.0.12 → linthis-0.0.13}/docs/index.md +0 -0
  62. {linthis-0.0.12 → linthis-0.0.13}/docs/index.zh.md +0 -0
  63. {linthis-0.0.12 → linthis-0.0.13}/docs/init-hooks-design.md +0 -0
  64. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/cpp.md +0 -0
  65. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/cpp.zh.md +0 -0
  66. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/csharp.md +0 -0
  67. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/csharp.zh.md +0 -0
  68. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/dart.md +0 -0
  69. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/dart.zh.md +0 -0
  70. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/go.md +0 -0
  71. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/go.zh.md +0 -0
  72. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/index.md +0 -0
  73. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/index.zh.md +0 -0
  74. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/java.md +0 -0
  75. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/java.zh.md +0 -0
  76. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/javascript.md +0 -0
  77. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/javascript.zh.md +0 -0
  78. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/kotlin.md +0 -0
  79. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/kotlin.zh.md +0 -0
  80. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/lua.md +0 -0
  81. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/lua.zh.md +0 -0
  82. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/objc.md +0 -0
  83. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/objc.zh.md +0 -0
  84. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/php.md +0 -0
  85. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/php.zh.md +0 -0
  86. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/python.md +0 -0
  87. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/python.zh.md +0 -0
  88. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/ruby.md +0 -0
  89. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/ruby.zh.md +0 -0
  90. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/rust.md +0 -0
  91. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/rust.zh.md +0 -0
  92. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/scala.md +0 -0
  93. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/scala.zh.md +0 -0
  94. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/shell.md +0 -0
  95. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/shell.zh.md +0 -0
  96. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/swift.md +0 -0
  97. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/swift.zh.md +0 -0
  98. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/typescript.md +0 -0
  99. {linthis-0.0.12 → linthis-0.0.13}/docs/languages/typescript.zh.md +0 -0
  100. {linthis-0.0.12 → linthis-0.0.13}/docs/plan-ruff-integration.md +0 -0
  101. {linthis-0.0.12 → linthis-0.0.13}/docs/reference/cli.md +0 -0
  102. {linthis-0.0.12 → linthis-0.0.13}/docs/reference/cli.zh.md +0 -0
  103. {linthis-0.0.12 → linthis-0.0.13}/docs/reference/configuration.md +0 -0
  104. {linthis-0.0.12 → linthis-0.0.13}/docs/reference/configuration.zh.md +0 -0
  105. {linthis-0.0.12 → linthis-0.0.13}/docs/requirements.txt +0 -0
  106. {linthis-0.0.12 → linthis-0.0.13}/docs/tasks.md +0 -0
  107. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/.gitignore +0 -0
  108. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/PUBLISHING.md +0 -0
  109. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/PUBLISHING.zh.md +0 -0
  110. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/README.md +0 -0
  111. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/build.gradle.kts +0 -0
  112. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/docs/images/settings.png +0 -0
  113. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/docs/images/tools-menu.png +0 -0
  114. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/gradle/wrapper/gradle-wrapper.jar +0 -0
  115. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/gradle/wrapper/gradle-wrapper.properties +0 -0
  116. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/gradle.properties +0 -0
  117. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/gradlew +0 -0
  118. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/gradlew.bat +0 -0
  119. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/settings.gradle.kts +0 -0
  120. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/LinthisLanguageClient.kt +0 -0
  121. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/LinthisLanguageServerFactory.kt +0 -0
  122. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/LinthisStartupListener.kt +0 -0
  123. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/LinthisStreamConnectionProvider.kt +0 -0
  124. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/actions/LinthisFormatAction.kt +0 -0
  125. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/actions/LinthisLintAction.kt +0 -0
  126. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/listeners/LinthisDocumentListener.kt +0 -0
  127. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/listeners/LinthisFileOpenListener.kt +0 -0
  128. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/settings/LinthisSettings.kt +0 -0
  129. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/settings/LinthisSettingsConfigurable.kt +0 -0
  130. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/kotlin/com/mojeter/linthis/plugin/util/LinthisExecutor.kt +0 -0
  131. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/resources/META-INF/plugin.xml +0 -0
  132. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/resources/images/settings.png +0 -0
  133. {linthis-0.0.12 → linthis-0.0.13}/jetbrains-linthis/src/main/resources/messages/LinthisBundle.properties +0 -0
  134. {linthis-0.0.12 → linthis-0.0.13}/mkdocs.yml +0 -0
  135. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/LICENSE +0 -0
  136. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/PUBLISHING.md +0 -0
  137. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/PUBLISHING.zh.md +0 -0
  138. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/README.md +0 -0
  139. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/doc/linthis.txt +0 -0
  140. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/lua/linthis/config.lua +0 -0
  141. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/lua/linthis/init.lua +0 -0
  142. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/plugin/linthis.vim +0 -0
  143. {linthis-0.0.12 → linthis-0.0.13}/nvim-linthis/test.sh +0 -0
  144. {linthis-0.0.12 → linthis-0.0.13}/scripts/release.sh +0 -0
  145. {linthis-0.0.12 → linthis-0.0.13}/src/benchmark.rs +0 -0
  146. {linthis-0.0.12 → linthis-0.0.13}/src/cache/hash.rs +0 -0
  147. {linthis-0.0.12 → linthis-0.0.13}/src/cache/mod.rs +0 -0
  148. {linthis-0.0.12 → linthis-0.0.13}/src/cache/storage.rs +0 -0
  149. {linthis-0.0.12 → linthis-0.0.13}/src/cache/types.rs +0 -0
  150. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/csharp.rs +0 -0
  151. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/dart.rs +0 -0
  152. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/go.rs +0 -0
  153. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/java.rs +0 -0
  154. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/kotlin.rs +0 -0
  155. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/lua.rs +0 -0
  156. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/mod.rs +0 -0
  157. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/php.rs +0 -0
  158. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/python.rs +0 -0
  159. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/ruby.rs +0 -0
  160. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/rust.rs +0 -0
  161. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/scala.rs +0 -0
  162. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/shell.rs +0 -0
  163. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/swift.rs +0 -0
  164. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/traits.rs +0 -0
  165. {linthis-0.0.12 → linthis-0.0.13}/src/checkers/typescript.rs +0 -0
  166. {linthis-0.0.12 → linthis-0.0.13}/src/cli/cache.rs +0 -0
  167. {linthis-0.0.12 → linthis-0.0.13}/src/cli/commands.rs +0 -0
  168. {linthis-0.0.12 → linthis-0.0.13}/src/cli/doctor.rs +0 -0
  169. {linthis-0.0.12 → linthis-0.0.13}/src/cli/fix.rs +0 -0
  170. {linthis-0.0.12 → linthis-0.0.13}/src/cli/helpers.rs +0 -0
  171. {linthis-0.0.12 → linthis-0.0.13}/src/cli/hook.rs +0 -0
  172. {linthis-0.0.12 → linthis-0.0.13}/src/cli/mod.rs +0 -0
  173. {linthis-0.0.12 → linthis-0.0.13}/src/cli/paths.rs +0 -0
  174. {linthis-0.0.12 → linthis-0.0.13}/src/cli/plugin.rs +0 -0
  175. {linthis-0.0.12 → linthis-0.0.13}/src/cli/recheck.rs +0 -0
  176. {linthis-0.0.12 → linthis-0.0.13}/src/cli/report.rs +0 -0
  177. {linthis-0.0.12 → linthis-0.0.13}/src/cli/watch.rs +0 -0
  178. {linthis-0.0.12 → linthis-0.0.13}/src/config/cli.rs +0 -0
  179. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/converters/mod.rs +0 -0
  180. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/converters/python.rs +0 -0
  181. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/detect.rs +0 -0
  182. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/parsers/eslint.rs +0 -0
  183. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/parsers/mod.rs +0 -0
  184. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/parsers/python.rs +0 -0
  185. {linthis-0.0.12 → linthis-0.0.13}/src/config/migrate/validate.rs +0 -0
  186. {linthis-0.0.12 → linthis-0.0.13}/src/fixers/mod.rs +0 -0
  187. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/csharp.rs +0 -0
  188. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/dart.rs +0 -0
  189. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/go.rs +0 -0
  190. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/java.rs +0 -0
  191. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/kotlin.rs +0 -0
  192. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/lua.rs +0 -0
  193. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/mod.rs +0 -0
  194. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/php.rs +0 -0
  195. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/python.rs +0 -0
  196. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/ruby.rs +0 -0
  197. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/rust.rs +0 -0
  198. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/scala.rs +0 -0
  199. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/shell.rs +0 -0
  200. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/swift.rs +0 -0
  201. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/traits.rs +0 -0
  202. {linthis-0.0.12 → linthis-0.0.13}/src/formatters/typescript.rs +0 -0
  203. {linthis-0.0.12 → linthis-0.0.13}/src/interactive/editor.rs +0 -0
  204. {linthis-0.0.12 → linthis-0.0.13}/src/interactive/mod.rs +0 -0
  205. {linthis-0.0.12 → linthis-0.0.13}/src/interactive/quickfix.rs +0 -0
  206. {linthis-0.0.12 → linthis-0.0.13}/src/lsp/mod.rs +0 -0
  207. {linthis-0.0.12 → linthis-0.0.13}/src/lsp/server.rs +0 -0
  208. {linthis-0.0.12 → linthis-0.0.13}/src/plugin/auto_sync.rs +0 -0
  209. {linthis-0.0.12 → linthis-0.0.13}/src/plugin/cache.rs +0 -0
  210. {linthis-0.0.12 → linthis-0.0.13}/src/plugin/config_manager.rs +0 -0
  211. {linthis-0.0.12 → linthis-0.0.13}/src/plugin/fetcher.rs +0 -0
  212. {linthis-0.0.12 → linthis-0.0.13}/src/plugin/loader.rs +0 -0
  213. {linthis-0.0.12 → linthis-0.0.13}/src/plugin/manifest.rs +0 -0
  214. {linthis-0.0.12 → linthis-0.0.13}/src/plugin/mod.rs +0 -0
  215. {linthis-0.0.12 → linthis-0.0.13}/src/plugin/registry.rs +0 -0
  216. {linthis-0.0.12 → linthis-0.0.13}/src/presets/mod.rs +0 -0
  217. {linthis-0.0.12 → linthis-0.0.13}/src/reports/consistency.rs +0 -0
  218. {linthis-0.0.12 → linthis-0.0.13}/src/reports/html.rs +0 -0
  219. {linthis-0.0.12 → linthis-0.0.13}/src/reports/mod.rs +0 -0
  220. {linthis-0.0.12 → linthis-0.0.13}/src/reports/statistics.rs +0 -0
  221. {linthis-0.0.12 → linthis-0.0.13}/src/reports/templates.rs +0 -0
  222. {linthis-0.0.12 → linthis-0.0.13}/src/reports/trends.rs +0 -0
  223. {linthis-0.0.12 → linthis-0.0.13}/src/rules/config.rs +0 -0
  224. {linthis-0.0.12 → linthis-0.0.13}/src/rules/custom_checker.rs +0 -0
  225. {linthis-0.0.12 → linthis-0.0.13}/src/rules/filter.rs +0 -0
  226. {linthis-0.0.12 → linthis-0.0.13}/src/rules/mod.rs +0 -0
  227. {linthis-0.0.12 → linthis-0.0.13}/src/self_update.rs +0 -0
  228. {linthis-0.0.12 → linthis-0.0.13}/src/templates/linter_configs.rs +0 -0
  229. {linthis-0.0.12 → linthis-0.0.13}/src/templates/mod.rs +0 -0
  230. {linthis-0.0.12 → linthis-0.0.13}/src/templates/plugin_templates.rs +0 -0
  231. {linthis-0.0.12 → linthis-0.0.13}/src/templates/readme.rs +0 -0
  232. {linthis-0.0.12 → linthis-0.0.13}/src/tui/app.rs +0 -0
  233. {linthis-0.0.12 → linthis-0.0.13}/src/tui/event.rs +0 -0
  234. {linthis-0.0.12 → linthis-0.0.13}/src/tui/mod.rs +0 -0
  235. {linthis-0.0.12 → linthis-0.0.13}/src/tui/widgets/file_tree.rs +0 -0
  236. {linthis-0.0.12 → linthis-0.0.13}/src/tui/widgets/help.rs +0 -0
  237. {linthis-0.0.12 → linthis-0.0.13}/src/tui/widgets/issue_list.rs +0 -0
  238. {linthis-0.0.12 → linthis-0.0.13}/src/tui/widgets/mod.rs +0 -0
  239. {linthis-0.0.12 → linthis-0.0.13}/src/tui/widgets/status_bar.rs +0 -0
  240. {linthis-0.0.12 → linthis-0.0.13}/src/utils/language.rs +0 -0
  241. {linthis-0.0.12 → linthis-0.0.13}/src/utils/mod.rs +0 -0
  242. {linthis-0.0.12 → linthis-0.0.13}/src/utils/output.rs +0 -0
  243. {linthis-0.0.12 → linthis-0.0.13}/src/utils/types.rs +0 -0
  244. {linthis-0.0.12 → linthis-0.0.13}/src/utils/unicode.rs +0 -0
  245. {linthis-0.0.12 → linthis-0.0.13}/src/utils/walker.rs +0 -0
  246. {linthis-0.0.12 → linthis-0.0.13}/src/watch/debounce.rs +0 -0
  247. {linthis-0.0.12 → linthis-0.0.13}/src/watch/mod.rs +0 -0
  248. {linthis-0.0.12 → linthis-0.0.13}/src/watch/notifications.rs +0 -0
  249. {linthis-0.0.12 → linthis-0.0.13}/src/watch/state.rs +0 -0
  250. {linthis-0.0.12 → linthis-0.0.13}/src/watch/watcher.rs +0 -0
  251. {linthis-0.0.12 → linthis-0.0.13}/test-plugin-check/README.md +0 -0
  252. {linthis-0.0.12 → linthis-0.0.13}/test-plugin-check/linthis-plugin.toml +0 -0
  253. {linthis-0.0.12 → linthis-0.0.13}/tests/cli_tests.rs +0 -0
  254. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/python/bad.py +0 -0
  255. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/python/good.py +0 -0
  256. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/python/unformatted.py +0 -0
  257. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/rust/bad.rs +0 -0
  258. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/test-plugin/linthis-plugin.toml +0 -0
  259. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/test-plugin/python/ruff.toml +0 -0
  260. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/test-plugin/rust/clippy.toml +0 -0
  261. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/test-plugin/rust/rustfmt.toml +0 -0
  262. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/us1/good.rs +0 -0
  263. {linthis-0.0.12 → linthis-0.0.13}/tests/fixtures/us1/unformatted.rs +0 -0
  264. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/cache_tests.rs +0 -0
  265. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/check_tests.rs +0 -0
  266. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/config_tests.rs +0 -0
  267. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/error_tests.rs +0 -0
  268. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/format_tests.rs +0 -0
  269. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/language_tests.rs +0 -0
  270. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/mod.rs +0 -0
  271. {linthis-0.0.12 → linthis-0.0.13}/tests/integration/plugin_tests.rs +0 -0
  272. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/.gitignore +0 -0
  273. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/.linthis.toml +0 -0
  274. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/.vscodeignore +0 -0
  275. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/CHANGELOG.md +0 -0
  276. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/LICENSE +0 -0
  277. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/PUBLISHING.md +0 -0
  278. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/PUBLISHING.zh.md +0 -0
  279. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/README.md +0 -0
  280. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/icon.png +0 -0
  281. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/package-lock.json +0 -0
  282. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/package.json +0 -0
  283. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/src/extension.ts +0 -0
  284. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/src/test/runTest.ts +0 -0
  285. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/src/test/suite/extension.test.ts +0 -0
  286. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/src/test/suite/index.ts +0 -0
  287. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/tsconfig.json +0 -0
  288. {linthis-0.0.12 → linthis-0.0.13}/vscode-linthis/webpack.config.js +0 -0
@@ -1208,7 +1208,7 @@ dependencies = [
1208
1208
 
1209
1209
  [[package]]
1210
1210
  name = "linthis"
1211
- version = "0.0.12"
1211
+ version = "0.0.13"
1212
1212
  dependencies = [
1213
1213
  "anyhow",
1214
1214
  "async-trait",
@@ -1,6 +1,6 @@
1
1
  [package]
2
2
  name = "linthis"
3
- version = "0.0.12"
3
+ version = "0.0.13"
4
4
  edition = "2021"
5
5
  authors = ["zhlinh"]
6
6
  description = "A fast, cross-platform multi-language linter and formatter"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: linthis
3
- Version: 0.0.12
3
+ Version: 0.0.13
4
4
  Classifier: Development Status :: 3 - Alpha
5
5
  Classifier: Environment :: Console
6
6
  Classifier: Intended Audience :: Developers
@@ -4,7 +4,7 @@ build-backend = "maturin"
4
4
 
5
5
  [project]
6
6
  name = "linthis"
7
- version = "0.0.12"
7
+ version = "0.0.13"
8
8
  description = "A fast, cross-platform multi-language linter and formatter"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.8"
@@ -18,6 +18,7 @@ use std::process::Command;
18
18
 
19
19
  /// Cpplint configuration for different languages
20
20
  #[derive(Debug, Clone)]
21
+ #[derive(Default)]
21
22
  pub struct CpplintConfig {
22
23
  /// Line length limit
23
24
  pub linelength: Option<u32>,
@@ -25,14 +26,6 @@ pub struct CpplintConfig {
25
26
  pub filter: Option<String>,
26
27
  }
27
28
 
28
- impl Default for CpplintConfig {
29
- fn default() -> Self {
30
- Self {
31
- linelength: None,
32
- filter: None,
33
- }
34
- }
35
- }
36
29
 
37
30
  /// C/C++ checker using clang-tidy (preferred) or cpplint.
38
31
  pub struct CppChecker {
@@ -65,7 +65,7 @@ fn handle_config_migrate(
65
65
 
66
66
  // Parse tool filter
67
67
  let tool_filter = match from_tool.as_ref() {
68
- Some(t) => match Tool::from_str(t) {
68
+ Some(t) => match Tool::parse(t) {
69
69
  Some(tool) => Some(tool),
70
70
  None => {
71
71
  eprintln!(
@@ -147,7 +147,7 @@ fn handle_config_migrate(
147
147
  println!();
148
148
  println!("{}", "Suggestions:".bold());
149
149
  for suggestion in &result.suggestions {
150
- println!(" {} {}", "💡", suggestion);
150
+ println!(" 💡 {}", suggestion);
151
151
  }
152
152
  }
153
153
 
@@ -55,13 +55,12 @@ pub fn perform_self_update(self_update_config: Option<&linthis::self_update::Sel
55
55
  let latest = manager.get_latest_version().unwrap_or_else(|| "unknown".to_string());
56
56
 
57
57
  // Prompt user if needed
58
- if config.should_prompt() {
59
- if !manager.prompt_user(&current, &latest) {
58
+ if config.should_prompt()
59
+ && !manager.prompt_user(&current, &latest) {
60
60
  // User declined, update timestamp to avoid repeated prompts
61
61
  let _ = manager.update_last_check_time();
62
62
  return false;
63
63
  }
64
- }
65
64
 
66
65
  // Perform upgrade
67
66
  match manager.upgrade() {
@@ -88,11 +88,12 @@ pub(crate) fn convert(
88
88
 
89
89
  /// Generate ESLint JavaScript config file content
90
90
  fn generate_eslint_js(config: &ESLintConfig) -> String {
91
- let mut lines = Vec::new();
92
- lines.push("// Migrated from existing ESLint config by linthis".to_string());
93
- lines.push("// Review and adjust as needed".to_string());
94
- lines.push(String::new());
95
- lines.push("module.exports = {".to_string());
91
+ let mut lines = vec![
92
+ "// Migrated from existing ESLint config by linthis".to_string(),
93
+ "// Review and adjust as needed".to_string(),
94
+ String::new(),
95
+ "module.exports = {".to_string(),
96
+ ];
96
97
 
97
98
  // Add env
98
99
  if !config.env.is_empty() {
@@ -59,15 +59,15 @@ pub(crate) fn convert(
59
59
 
60
60
  /// Generate Prettier JavaScript config file content
61
61
  fn generate_prettier_js(config: &prettier::PrettierConfig) -> String {
62
- let mut lines = Vec::new();
63
- lines.push("// Migrated from existing Prettier config by linthis".to_string());
64
- lines.push("// Review and adjust as needed".to_string());
65
- lines.push(String::new());
66
- lines.push("module.exports = ".to_string());
67
- lines.push(config.to_js_object());
68
- lines.push(";".to_string());
69
-
70
- lines.join("\n")
62
+ [
63
+ "// Migrated from existing Prettier config by linthis",
64
+ "// Review and adjust as needed",
65
+ "",
66
+ "module.exports = ",
67
+ &config.to_js_object(),
68
+ ";",
69
+ ]
70
+ .join("\n")
71
71
  }
72
72
 
73
73
  #[cfg(test)]
@@ -44,7 +44,7 @@ impl Tool {
44
44
  }
45
45
 
46
46
  /// Parse tool from string
47
- pub fn from_str(s: &str) -> Option<Self> {
47
+ pub fn parse(s: &str) -> Option<Self> {
48
48
  match s.to_lowercase().as_str() {
49
49
  "eslint" => Some(Tool::ESLint),
50
50
  "prettier" => Some(Tool::Prettier),
@@ -158,39 +158,39 @@ fn parse_js(content: &str) -> Result<PrettierConfig, String> {
158
158
  }
159
159
 
160
160
  fn extract_prettier_config(value: &serde_json::Value) -> Result<PrettierConfig, String> {
161
- let mut config = PrettierConfig::default();
162
-
163
- config.tab_width = value
164
- .get("tabWidth")
165
- .and_then(|v| v.as_u64())
166
- .map(|n| n as u32);
167
- config.use_tabs = value
168
- .get("useTabs")
169
- .and_then(|v| v.as_bool())
170
- .unwrap_or(false);
171
- config.semi = value.get("semi").and_then(|v| v.as_bool());
172
- config.single_quote = value.get("singleQuote").and_then(|v| v.as_bool());
173
- config.trailing_comma = value
174
- .get("trailingComma")
175
- .and_then(|v| v.as_str())
176
- .map(String::from);
177
- config.bracket_spacing = value.get("bracketSpacing").and_then(|v| v.as_bool());
178
- config.print_width = value
179
- .get("printWidth")
180
- .and_then(|v| v.as_u64())
181
- .map(|n| n as u32);
182
- config.arrow_parens = value
183
- .get("arrowParens")
184
- .and_then(|v| v.as_str())
185
- .map(String::from);
186
- config.end_of_line = value
187
- .get("endOfLine")
188
- .and_then(|v| v.as_str())
189
- .map(String::from);
190
- config.prose_wrap = value
191
- .get("proseWrap")
192
- .and_then(|v| v.as_str())
193
- .map(String::from);
161
+ let config = PrettierConfig {
162
+ tab_width: value
163
+ .get("tabWidth")
164
+ .and_then(|v| v.as_u64())
165
+ .map(|n| n as u32),
166
+ use_tabs: value
167
+ .get("useTabs")
168
+ .and_then(|v| v.as_bool())
169
+ .unwrap_or(false),
170
+ semi: value.get("semi").and_then(|v| v.as_bool()),
171
+ single_quote: value.get("singleQuote").and_then(|v| v.as_bool()),
172
+ trailing_comma: value
173
+ .get("trailingComma")
174
+ .and_then(|v| v.as_str())
175
+ .map(String::from),
176
+ bracket_spacing: value.get("bracketSpacing").and_then(|v| v.as_bool()),
177
+ print_width: value
178
+ .get("printWidth")
179
+ .and_then(|v| v.as_u64())
180
+ .map(|n| n as u32),
181
+ arrow_parens: value
182
+ .get("arrowParens")
183
+ .and_then(|v| v.as_str())
184
+ .map(String::from),
185
+ end_of_line: value
186
+ .get("endOfLine")
187
+ .and_then(|v| v.as_str())
188
+ .map(String::from),
189
+ prose_wrap: value
190
+ .get("proseWrap")
191
+ .and_then(|v| v.as_str())
192
+ .map(String::from),
193
+ };
194
194
 
195
195
  Ok(config)
196
196
  }
@@ -719,6 +719,7 @@ fn find_similar_field(input: &str, candidates: &[&str]) -> Option<String> {
719
719
  }
720
720
 
721
721
  /// Calculate Levenshtein distance between two strings
722
+ #[allow(clippy::needless_range_loop)]
722
723
  fn levenshtein_distance(a: &str, b: &str) -> usize {
723
724
  let a_chars: Vec<char> = a.chars().collect();
724
725
  let b_chars: Vec<char> = b.chars().collect();
@@ -140,7 +140,7 @@ impl CpplintFixer {
140
140
 
141
141
  // Run pip install with progress output
142
142
  let mut child = match Command::new(pip_cmd)
143
- .args(&["install", "cpplint", "--upgrade"])
143
+ .args(["install", "cpplint", "--upgrade"])
144
144
  .stdout(Stdio::piped())
145
145
  .stderr(Stdio::piped())
146
146
  .spawn()
@@ -155,7 +155,7 @@ impl CpplintFixer {
155
155
  // Read and display output
156
156
  if let Some(stderr) = child.stderr.take() {
157
157
  let reader = BufReader::new(stderr);
158
- for line in reader.lines().flatten() {
158
+ for line in reader.lines().map_while(Result::ok) {
159
159
  // Filter and display relevant progress information
160
160
  if line.contains("Collecting")
161
161
  || line.contains("Downloading")
@@ -398,11 +398,10 @@ impl CpplintFixer {
398
398
  }
399
399
  modified = true;
400
400
  }
401
- } else if self.config.header_guard_mode == HeaderGuardMode::PragmaOnce {
402
- if self.convert_to_pragma_once(&mut lines) {
401
+ } else if self.config.header_guard_mode == HeaderGuardMode::PragmaOnce
402
+ && self.convert_to_pragma_once(&mut lines) {
403
403
  modified = true;
404
404
  }
405
- }
406
405
  }
407
406
  "readability/todo" => {
408
407
  if self.fix_todo_from_error(&mut lines, error) {
@@ -631,7 +630,7 @@ impl CpplintFixer {
631
630
 
632
631
  // Add #endif at the end
633
632
  // Ensure there's an empty line before #endif
634
- if !lines.last().map_or(true, |l| l.trim().is_empty()) {
633
+ if !lines.last().is_none_or(|l| l.trim().is_empty()) {
635
634
  lines.push(String::new());
636
635
  }
637
636
  lines.push(format!("#endif // {}", guard_name));
@@ -854,9 +853,7 @@ impl CpplintFixer {
854
853
  loop {
855
854
  // Find next // starting from search_start
856
855
  let rest = &line[search_start..];
857
- let Some(rel_pos) = rest.find("//") else {
858
- return None;
859
- };
856
+ let rel_pos = rest.find("//")?;
860
857
 
861
858
  let abs_pos = search_start + rel_pos;
862
859
  let before_comment = &line[..abs_pos];
@@ -963,7 +960,7 @@ impl CpplintFixer {
963
960
 
964
961
  // Find the position of the lone semicolon (only whitespace before it)
965
962
  // Pattern: start with whitespace, then a semicolon, optionally followed by comment or whitespace
966
- if let Some(re) = Regex::new(r"^(\s*);(\s*(?://.*)?)?$").ok() {
963
+ if let Ok(re) = Regex::new(r"^(\s*);(\s*(?://.*)?)?$") {
967
964
  if let Some(caps) = re.captures(line) {
968
965
  let indent = caps.get(1).map(|m| m.as_str()).unwrap_or("");
969
966
  let suffix = caps.get(2).map(|m| m.as_str()).unwrap_or("");
@@ -1038,7 +1035,7 @@ impl CpplintFixer {
1038
1035
  // Use regex to find = without proper spacing
1039
1036
  // Match: not preceded by space + = + not followed by space or =
1040
1037
  // But avoid ==, !=, <=, >=, +=, -=, etc.
1041
- if let Some(re) = Regex::new(r"([^\s=!<>+\-*/%&|^])=([^=\s])").ok() {
1038
+ if let Ok(re) = Regex::new(r"([^\s=!<>+\-*/%&|^])=([^=\s])") {
1042
1039
  let result = re.replace_all(line, "$1 = $2").to_string();
1043
1040
  if result != *line {
1044
1041
  lines[line_idx] = result;
@@ -92,9 +92,7 @@ impl SourceFixer {
92
92
  loop {
93
93
  // Find next // starting from search_start
94
94
  let rest = &line[search_start..];
95
- let Some(rel_pos) = rest.find("//") else {
96
- return None;
97
- };
95
+ let rel_pos = rest.find("//")?;
98
96
 
99
97
  let abs_pos = search_start + rel_pos;
100
98
  let before_comment = &line[..abs_pos];
@@ -217,8 +215,8 @@ impl SourceFixer {
217
215
 
218
216
  let stdout = String::from_utf8_lossy(&output.stdout);
219
217
  for line in stdout.lines() {
220
- if line.starts_with("author ") {
221
- return Some(line[7..].to_string());
218
+ if let Some(author) = line.strip_prefix("author ") {
219
+ return Some(author.to_string());
222
220
  }
223
221
  }
224
222
 
@@ -521,7 +521,7 @@ impl CppFormatter {
521
521
  if bytes[i] == b'N' && bytes[i + 1] == b'S' {
522
522
  let next_char = bytes[i + 2];
523
523
  // Check if next char is uppercase A-Z (ASCII 65-90)
524
- if (b'A'..=b'Z').contains(&next_char) {
524
+ if next_char.is_ascii_uppercase() {
525
525
  // Make sure it's not part of a longer identifier before "NS"
526
526
  // (i.e., NS should be at word boundary)
527
527
  if i == 0 || !is_identifier_char(bytes[i - 1]) {
@@ -695,22 +695,6 @@ fn read_line() -> String {
695
695
  #[cfg(test)]
696
696
  mod tests {
697
697
  use super::*;
698
- use crate::Language;
699
- use std::path::PathBuf;
700
-
701
- fn make_test_issue(severity: Severity) -> LintIssue {
702
- LintIssue::new(
703
- PathBuf::from("test.cpp"),
704
- 42,
705
- "Test message".to_string(),
706
- severity,
707
- )
708
- .with_column(10)
709
- .with_code("TEST001".to_string())
710
- .with_source("test-linter".to_string())
711
- .with_language(Language::Cpp)
712
- .with_code_line(" int x = 42;".to_string())
713
- }
714
698
 
715
699
  #[test]
716
700
  fn test_interactive_result_default() {
@@ -122,8 +122,8 @@ pub fn add_nolint_comment(issue: &LintIssue) -> NolintResult {
122
122
  let mut found_idx = None;
123
123
  let mut best_match_score: i32 = 0;
124
124
 
125
- for i in search_start..search_end {
126
- let line_trimmed = lines[i].trim();
125
+ for (i, line) in lines.iter().enumerate().skip(search_start).take(search_end - search_start) {
126
+ let line_trimmed = line.trim();
127
127
 
128
128
  // Calculate base similarity score
129
129
  let base_score: i32 = if line_trimmed == expected_trimmed {
@@ -143,7 +143,7 @@ pub fn add_nolint_comment(issue: &LintIssue) -> NolintResult {
143
143
  };
144
144
 
145
145
  // Apply distance penalty (prefer lines closer to original position)
146
- let distance = if i > line_idx { i - line_idx } else { line_idx - i } as i32;
146
+ let distance = i.abs_diff(line_idx) as i32;
147
147
  let score = base_score - (distance * 5);
148
148
 
149
149
  // Only consider matches with good score (>= 400 for high confidence)
@@ -151,7 +151,7 @@ pub fn add_nolint_comment(issue: &LintIssue) -> NolintResult {
151
151
  best_match_score = score;
152
152
  found_idx = Some(i);
153
153
  eprintln!("[DEBUG] Found match at line {}: base_score={}, distance={}, final_score={}, content={:?}",
154
- i + 1, base_score, distance, score, lines[i]);
154
+ i + 1, base_score, distance, score, line);
155
155
  }
156
156
  }
157
157
 
@@ -192,7 +192,7 @@ pub enum LintisError {
192
192
  #[error("Cache error ({operation}): {message}")]
193
193
  Cache { operation: String, message: String },
194
194
 
195
- #[error("Tool not available: {tool} ({language})")]
195
+ #[error("Tool not available: {tool} ({language}). {install_hint}")]
196
196
  ToolNotAvailable {
197
197
  tool: String,
198
198
  language: String,
@@ -443,7 +443,7 @@ impl Language {
443
443
  if bytes[i] == b'N' && bytes[i + 1] == b'S' {
444
444
  let next_char = bytes[i + 2];
445
445
  // Check if next char is uppercase A-Z (ASCII 65-90)
446
- if (b'A'..=b'Z').contains(&next_char) {
446
+ if next_char.is_ascii_uppercase() {
447
447
  // Make sure it's not part of a longer identifier before "NS"
448
448
  // (i.e., NS should be at word boundary)
449
449
  if i == 0 || !Self::is_identifier_char(bytes[i - 1]) {
@@ -1338,10 +1338,8 @@ pub fn run(options: &RunOptions) -> Result<RunResult> {
1338
1338
  .collect();
1339
1339
 
1340
1340
  // Add format results
1341
- for format_result in format_results {
1342
- if let Some(fr) = format_result {
1343
- result.add_format_result(fr);
1344
- }
1341
+ for fr in format_results.into_iter().flatten() {
1342
+ result.add_format_result(fr);
1345
1343
  }
1346
1344
  }
1347
1345
  // Clear progress line
@@ -110,7 +110,7 @@ mod tests {
110
110
  assert_eq!(diag.range.start.character, 4); // 0-indexed
111
111
  assert_eq!(diag.severity, Some(DiagnosticSeverity::WARNING));
112
112
  assert_eq!(diag.code, Some(NumberOrString::String("W0612".to_string())));
113
- assert_eq!(diag.source, Some("ruff".to_string()));
113
+ assert_eq!(diag.source, Some("linthis-ruff".to_string()));
114
114
  assert!(diag.message.contains("Unused variable"));
115
115
  }
116
116
 
@@ -20,8 +20,10 @@ use tower_lsp::lsp_types::Url;
20
20
  #[derive(Debug, Clone)]
21
21
  pub struct DocumentState {
22
22
  /// The URI of the document.
23
+ #[allow(dead_code)]
23
24
  pub uri: Url,
24
25
  /// The file path on disk.
26
+ #[allow(dead_code)]
25
27
  pub path: PathBuf,
26
28
  /// The document version (incremented on each change).
27
29
  pub version: i32,
@@ -82,18 +84,21 @@ impl DocumentManager {
82
84
  }
83
85
 
84
86
  /// Get the state of a document.
87
+ #[allow(dead_code)]
85
88
  pub async fn get(&self, uri: &Url) -> Option<DocumentState> {
86
89
  let docs = self.documents.read().await;
87
90
  docs.get(uri).cloned()
88
91
  }
89
92
 
90
93
  /// Get the file path for a document URI.
94
+ #[allow(dead_code)]
91
95
  pub async fn get_path(&self, uri: &Url) -> Option<PathBuf> {
92
96
  let docs = self.documents.read().await;
93
97
  docs.get(uri).map(|s| s.path.clone())
94
98
  }
95
99
 
96
100
  /// Get all open document URIs.
101
+ #[allow(dead_code)]
97
102
  pub async fn all_uris(&self) -> Vec<Url> {
98
103
  let docs = self.documents.read().await;
99
104
  docs.keys().cloned().collect()
@@ -259,8 +259,8 @@ fn main() -> ExitCode {
259
259
  if std::fs::create_dir_all(&lang_dir).is_ok() {
260
260
  let target = lang_dir.join(filename);
261
261
  // Always update to latest plugin config
262
- if std::fs::copy(&config.config_path, &target).is_ok() {
263
- if cli.verbose {
262
+ if std::fs::copy(&config.config_path, &target).is_ok()
263
+ && cli.verbose {
264
264
  eprintln!(
265
265
  " - {}/{}: {} -> .linthis/configs/{}/{}",
266
266
  config.language,
@@ -270,7 +270,6 @@ fn main() -> ExitCode {
270
270
  filename.to_string_lossy()
271
271
  );
272
272
  }
273
- }
274
273
  }
275
274
  }
276
275
  }
@@ -95,6 +95,7 @@ pub fn border_style(focused: bool) -> Style {
95
95
  }
96
96
 
97
97
  /// Format a file path for display
98
+ #[allow(dead_code)]
98
99
  pub fn format_path(path: &std::path::Path, max_len: usize) -> String {
99
100
  let s = path.display().to_string();
100
101
  if s.len() <= max_len {
@@ -1,5 +1,7 @@
1
1
  //! Common test utilities for integration tests.
2
2
 
3
+ #![allow(dead_code)]
4
+
3
5
  use std::path::Path;
4
6
  use std::process::{Command, Output};
5
7
  use tempfile::TempDir;
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes