{"id":472870,"date":"2024-05-09T04:40:44","date_gmt":"2024-05-09T03:40:44","guid":{"rendered":"https:\/\/blog.jetbrains.com\/?post_type=qodana&#038;p=472870"},"modified":"2024-05-09T05:54:22","modified_gmt":"2024-05-09T04:54:22","slug":"qodana-2024-1-release","status":"publish","type":"qodana","link":"https:\/\/blog.jetbrains.com\/zh-hans\/qodana\/2024\/05\/qodana-2024-1-release\/","title":{"rendered":"\u4f7f\u7528 Qodana 2024.1 \u5728 IntelliJ IDEA \u4e2d\u521b\u5efa\u81ea\u5b9a\u4e49\u4ee3\u7801\u68c0\u67e5\u548c\u6267\u884c\u5176\u4ed6\u64cd\u4f5c"},"content":{"rendered":"<p>\u81ea 2023 \u5e74 7 \u6708\u6b63\u5f0f\u5546\u4e1a\u53d1\u5e03\u4ee5\u6765\uff0cJetBrains Qodana \u4e00\u76f4\u662f\u4ee3\u7801\u8d28\u91cf\u9886\u57df\u7684\u70ed\u95e8\u8bdd\u9898\u3002<\/p>\n<p>Qodana \u662f\u9762\u5411\u56e2\u961f\u7684\u5b98\u65b9 JetBrains \u9759\u6001\u4ee3\u7801\u5206\u6790\u5e73\u53f0\uff0c\u4e0e JetBrains IDE \u548c\u56e2\u961f\u5de5\u5177\u9ad8\u5ea6\u517c\u5bb9\u3002\u5b83\u8fd8\u5305\u542b\u4e00\u7cfb\u5217\u72ec\u7279\u68c0\u67e5\uff0c\u5168\u7a0b\u63d0\u4f9b<strong>\u51fa\u8272\u7684\u5ba2\u6237\u652f\u6301<\/strong>\u3002<\/p>\n<p>Qodana \u7684\u5168\u7403\u91c7\u7528\u6807\u5fd7\u7740\u63a8\u51fa\u65b0\u529f\u80fd\u548c\u66f4\u65b0\u7684\u6700\u4f73\u65f6\u673a\uff0c\u8ba9\u56e2\u961f\u5728\u9700\u6c42\u6b63\u76db\u7684\u884c\u4e1a\u4e2d\u7ef4\u62a4\u8f6f\u4ef6\u8d28\u91cf\u3002<\/p>\n<p>\u65e0\u8bba\u60a8\u662f\u60f3\u4e3a\u56e2\u961f\u521b\u5efa\u81ea\u5b9a\u4e49\u68c0\u67e5\u3001\u9ed8\u8ba4\u5ba1\u6838\u8bb8\u53ef\u8bc1\u4ee5\u8fbe\u5230\u6216\u4fdd\u6301\u5408\u89c4\uff0c\u8fd8\u662f\u66f4\u8f7b\u677e\u5730\u6d4f\u89c8\u4ee3\u7801\u5206\u6790\u7ed3\u679c\uff0cQodana \u7684 2024.1 \u7248\u672c\u90fd\u80fd\u5e2e\u60a8\u641e\u5b9a\u3002<\/p>\n<p align=\"center\"><a class=\"jb-download-button\" title=\"\u8bd5\u7528 Qodana\" href=\"https:\/\/qodana.cloud\/onboarding?licensePlan=TRIAL_ULTIMATE_PLUS\" target=\"_blank\" rel=\"noopener noreferrer\"><i class=\"download-icon\"><\/i>\u8bd5\u7528 Qodana<\/a><\/p>\n<p><!--more--><\/p>\n<p><strong>\u8df3\u8f6c\u5230\uff1a<\/strong><\/p>\n<p><a href=\"#FlexInspect\">FlexInspect<\/a><br \/><a href=\"#Diff-analysis\">\u9002\u7528\u4e8e qodana-dotnet \u7684\u5dee\u5f02\u5206\u6790<\/a><br \/><a href=\"#License-Audit\">\u5f00\u7bb1\u5373\u542f\u7528\u7684\u8bb8\u53ef\u8bc1\u5ba1\u6838<\/a><br \/><a href=\"#Gitlab-code-quality\">GitLab \u4ee3\u7801\u8d28\u91cf\u548c BitBucket \u4ee3\u7801\u6d1e\u5bdf\u652f\u6301<\/a><br \/><a href=\"#Improved-UX\">IDE \u63d2\u4ef6 UX \u6539\u8fdb<\/a><br \/><a href=\"#Default-linter-choice\">\u672a\u901a\u8fc7 qodana.yaml \u5b9a\u4e49\u65f6\u7684\u9ed8\u8ba4 linter \u9009\u62e9<\/a><br \/><a href=\"#Custom-name\">\u9002\u7528\u4e8e qodana.yaml \u914d\u7f6e\u6587\u4ef6\u7684\u81ea\u5b9a\u4e49\u540d\u79f0<\/a><br \/><a href=\"#Book-demo\">\u9884\u8ba2\u6f14\u793a<\/a><\/p>\n<h2 id=\"FlexInspect\" class=\"wp-block-heading\"><strong>FlexInspect \u2013 \u7f16\u5199\u81ea\u5b9a\u4e49\u68c0\u67e5\u7684\u65b0\u65b9\u5f0f<\/strong><\/h2>\n<p>\u6bcf\u4e2a\u56e2\u961f\u5728\u4ee3\u7801\u8d28\u91cf\u65b9\u9762\u90fd\u6709\u72ec\u7279\u7684\u9700\u6c42\u3002 \u76ee\u524d\uff0c\u8fd8\u6ca1\u6709\u54ea\u6b3e\u4ee3\u7801\u8d28\u91cf\u5de5\u5177\u9ed8\u8ba4\u6db5\u76d6\u6240\u6709\u89c4\u5219\uff0c\u8fd9\u5c31\u53ef\u80fd\u7ed9\u5177\u6709\u7279\u5b9a\u9700\u6c42\u7684\u56e2\u961f\u7559\u4e0b\u7a7a\u767d\u3002<\/p>\n<p>\u501f\u52a9 Qodana \u7684 <strong>FlexInspect<\/strong><em>\uff0c<\/em>\u60a8\u53ef\u4ee5\u4e3a\u60f3\u5728\u4ee3\u7801\u6216\u4ed3\u5e93\u4e2d\u5f3a\u5236\u6267\u884c\u7684\u89c4\u5219\u521b\u5efa\u81ea\u5b9a\u4e49\u4ee3\u7801\u68c0\u67e5\u3002 \u7136\u540e\uff0c\u60a8\u53ef\u4ee5\u5728 IntelliJ IDEA \u4e2d\u9488\u5bf9\u9879\u76ee\u8fd0\u884c\u8fd9\u4e9b\u68c0\u67e5\uff0c\u6216\u8005\u5728 CI\/CD \u7ba1\u9053\u4e2d\u4f7f\u7528 Qodana \u8fd0\u884c\u68c0\u67e5\u3002<\/p>\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" loading=\"lazy\" class=\"wp-image-467620\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2024\/04\/FlexInspect-Kotlin-when-with-else-for-sealed-class_dark-1.png\" alt=\"Qodana \u4e2d\u7684\u81ea\u5b9a\u4e49\u4ee3\u7801\u68c0\u67e5\u3002 \" width=\"3584\" height=\"2042\" \/><figcaption class=\"wp-element-caption\">FlexInspect \u2013 Qodana \u4e2d\u7684\u81ea\u5b9a\u4e49\u4ee3\u7801\u68c0\u67e5\u3002<\/figcaption><\/figure>\n<p>\u7531\u6b64\uff0c\u60a8\u53ef\u4ee5\u5feb\u901f\u9ad8\u6548\u5730\u8bc6\u522b\u4ee3\u7801\u5e93\u548c\u56e2\u961f\u7684\u7279\u6709\u95ee\u9898\u3002<\/p>\n<p>\u9075\u5faa\u4ee5\u4e0b\u6b65\u9aa4\uff0c\u5728 IntelliJ IDEA \u5185\u4f7f\u7528 Kotlin <a href=\"https:\/\/plugins.jetbrains.com\/docs\/intellij\/code-inspections.html\" target=\"_blank\" rel=\"noopener\">IntelliJ API<\/a> \u7f16\u5199\u81ea\u5b9a\u4e49\u68c0\u67e5\uff1a<\/p>\n<ul>\n<li>\u8bbf\u95ee\u6e90\u4ee3\u7801\u7684\u62bd\u8c61\u8bed\u6cd5\u6811 (AST)\u3002<\/li>\n<li>\u5728\u4ee3\u7801\u4e0a\u5b9e\u65f6\u8c03\u8bd5\u65b0\u68c0\u67e5\u3002<\/li>\n<li>\u89c2\u5bdf\u65b0\u7684\u81ea\u5b9a\u4e49\u68c0\u67e5\u7684\u5b9e\u9645\u8fd0\u4f5c\u60c5\u51b5\uff0c\u5305\u62ec\u5bf9\u4e0d\u7b26\u5408\u9884\u671f\u884c\u4e3a\u7684\u4ee3\u7801\u6bb5\u7684\u9ad8\u4eae\u663e\u793a\u3002<\/li>\n<\/ul>\n<p>\u901a\u8fc7\u6b64\u529f\u80fd\uff0c\u60a8<strong>\u53ef\u4ee5\u8bbf\u95ee PSI\uff08\u6240\u6709 IntelliJ \u548c Qodana \u68c0\u67e5\u4f7f\u7528\u7684 API\uff09<\/strong>\uff0c\u5e76\u5b9e\u73b0\u60a8\u53ef\u80fd\u9700\u8981\u7684\u989d\u5916\u81ea\u5b9a\u4e49\u68c0\u67e5\u3002<\/p>\n<p>\u4e0b\u9762\u5c55\u793a\u4e86\u5982\u4f55\u4f7f\u7528 IntelliJ IDEA PSI \u67e5\u770b\u5668\u8bbf\u95ee\u4ee3\u7801\u7684 AST\uff1a<\/p>\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" loading=\"lazy\" class=\"wp-image-467631\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2024\/04\/PSIViewer-dark-1.png\" alt=\"\u7528\u4e8e\u4ee3\u7801\u5ba1\u67e5\u4e2d\u7684\u81ea\u5b9a\u4e49\u68c0\u67e5\u548c\u63d0\u9ad8\u4ee3\u7801\u8d28\u91cf\u7684 PSI \u67e5\u770b\u5668\" width=\"3214\" height=\"1668\" \/><\/p>\n<figcaption class=\"wp-element-caption\">PSI \u67e5\u770b\u5668\u3002<\/figcaption>\n<\/figure>\n<p>FlexInspect \u53ef\u7528\u4e8e\u5206\u6790\u591a\u79cd\u8bed\u8a00\u7684\u4ee3\u7801\uff0c\u5305\u62ec Java\u3001Kotlin\u3001JavaScript\u3001TypeScript\u3001PHP\u3001Go\u3001Python\u3001Ruby\u3001SQL\u3001XML\u3001CSS\u3001YAML\u3001JSON\u3001shell \u548c Dockerfile\u3002 \u6211\u4eec\u6b63\u5728\u79ef\u6781\u589e\u52a0\u652f\u6301\u7684\u8bed\u8a00\uff0c\u656c\u8bf7\u671f\u5f85\uff01<\/p>\n<p><strong>\u8bf7\u6ce8\u610f<\/strong>\uff1a\u53ea\u6709\u5728 Kotlin \u4e2d\u7f16\u5199\u4ee3\u7801\u624d\u80fd\u5b9e\u73b0\u81ea\u5b9a\u4e49\u68c0\u67e5\uff0c\u56e0\u6b64\u60a8\u9700\u8981\u4f7f\u7528 IntelliJ IDEA Ultimate\u3002<\/p>\n<p>\u6b64\u5916\uff0c\u7531\u4e8e\u8fd9\u662f FlexInspect \u7684\u7b2c\u4e00\u4e2a\u7248\u672c\uff0c\u5982\u679c\u60a8\u9047\u5230\u95ee\u9898\uff0c\u8bf7\u968f\u65f6\u8054\u7cfb\u6211\u4eec\u7684\u652f\u6301\u56e2\u961f\u3002 \u8bf7\u53d1\u9001\u7535\u5b50\u90ae\u4ef6\u81f3 qodana-support@jetbrains.com \u4e0e\u6211\u4eec\u8054\u7cfb\uff0c\u6216\u8005\u5411 <a href=\"https:\/\/youtrack.jetbrains.com\/issues\/QD\" target=\"_blank\" rel=\"noopener\">Qodana \u95ee\u9898\u8ddf\u8e2a\u5668<\/a>\u63d0\u4ea4 bug \u62a5\u544a\u3002<\/p>\n<h2 id=\"Diff-analysis\" class=\"wp-block-heading\"><strong>Qodana for .NET \u4e2d\u65b0\u589e\u7684\u5dee\u5f02\u5206\u6790<\/strong><\/h2>\n<p>\u73b0\u5728\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528 QDnet linter \u6839\u636e\u9700\u8981\u5206\u6790\u5408\u5e76\u4e0e\u62c9\u53d6\u8bf7\u6c42\uff0c\u4e0d\u5fc5\u626b\u63cf\u6574\u4e2a\u4ee3\u7801\u5e93\u3002<\/p>\n<p>\u4f7f\u7528\u6b64\u6a21\u5f0f\u5bf9\u66f4\u6539\u96c6\uff08\u5408\u5e76\u6216\u62c9\u53d6\u8bf7\u6c42\uff09\u8fd0\u884c\u589e\u91cf\u6216\u5dee\u5f02\u5206\u6790\u3002 \u5bf9\u4e8e <code>qodana-github-action<\/code> \u7684\u7528\u6237\uff0c\u8fd9\u9879\u66f4\u6539\u5c06\u81ea\u52a8\u751f\u6548\u3002<\/p>\n<p><strong>\u5982\u4f55\u4f7f\u7528\uff1a<\/strong><\/p>\n<p>\u201c\u6211\u521a\u521a\u5b8c\u6210\u63d0\u4ea4\uff0c\u60f3\u8981\u5206\u6790\u4e00\u4e0b\u66f4\u6539\u3002\u201d<\/p>\n<pre class=\"EnlighterJSRAW\">qodana scan --diff-start=$GIT_START_HASH<\/pre>\n<p>\u201c\u6211\u60f3\u5206\u6790\u4e24\u6b21\u63d0\u4ea4\u4e4b\u95f4\u7684\u4e00\u7ec4\u66f4\u6539\u3002\u201d<\/p>\n<pre class=\"EnlighterJSRAW\">qodana scan --diff-start=$GIT_HASH_START --diff-end=$GIT_HASH_END<\/pre>\n<p>\u201c\u6211\u6b63\u5728\u4e3a CI \u8fd0\u884c\u4f7f\u7528 Qodana GitHub \u64cd\u4f5c\u3002\u201d<\/p>\n<p>\u5b83\u5c06\u81ea\u52a8\u8fd0\u4f5c\u3002<\/p>\n<p><strong>\u8bf7\u6ce8\u610f<\/strong>\uff1a\u8fd9\u9879\u529f\u80fd\u4ec5\u53d7\u4ed8\u8d39 Qodana for .NET linter \u652f\u6301\uff0c\u4e0d\u53d7 Qodana for .NET Community linter \u652f\u6301\u3002<\/p>\n<h2 id=\"License-Audit\" class=\"wp-block-heading\"><strong>\u9ed8\u8ba4\u542f\u7528\u7684\u8bb8\u53ef\u8bc1\u5ba1\u6838<\/strong><\/h2>\n<p>\u5982\u679c\u6ca1\u6709\u5408\u9002\u7684\u5de5\u5177\uff0c\u5408\u89c4\u6027\u53ef\u80fd\u4f1a\u6210\u4e3a\u4e00\u4e2a\u5927\u96be\u9898\uff0c\u800c\u8fd9\u4e5f\u662f\u6211\u4eec\u7684\u8bb8\u53ef\u8bc1\u5ba1\u6838\u529f\u80fd\u5982\u6b64\u53d7\u7528\u6237\u6b22\u8fce\u7684\u90e8\u5206\u539f\u56e0\u3002 \u73b0\u5728\uff0c<strong>License Audit<\/strong>\uff08\u8bb8\u53ef\u8bc1\u5ba1\u6838\uff09\u529f\u80fd\u9ed8\u8ba4\u542f\u7528\uff08\u5982\u679c\u60a8\u62e5\u6709 Ultimate Plus \u8bb8\u53ef\u8bc1\uff0c\u8fd9\u662f\u901a\u5e38\u652f\u6301\u6b64\u529f\u80fd\u7684\u552f\u4e00\u8bb8\u53ef\u8bc1\uff09\u3002<\/p>\n<p>Qodana \u627e\u5230\u7684\u9879\u76ee\u4f9d\u8d56\u9879\u8bb8\u53ef\u8bc1\u4fe1\u606f\u5c06\u81ea\u52a8\u663e\u793a\u5728 Qodana Cloud \u4e2d\u9879\u76ee\u7684 <em>License Audit<\/em>\uff08\u8bb8\u53ef\u8bc1\u5ba1\u6838\uff09\u6807\u7b7e\u9875\u4e0a\uff0c\u65e0\u9700\u914d\u7f6e\u5206\u6790\u5373\u53ef\u8fd0\u884c\u3002<\/p>\n<p>\u73b0\u6709\u7684 <strong>License Audit<\/strong>\uff08\u8bb8\u53ef\u8bc1\u5ba1\u6838\uff09\u7528\u6237\u53ef\u4ee5\u5728 <strong>Qodana Cloud UI<\/strong> \u6807\u7b7e\u9875\u4e2d\u67e5\u770b\u5ba1\u6838\u95ee\u9898\uff0c\u800c\u4e0d\u662f\u5728\u6574\u4f53\u95ee\u9898\u5217\u8868\u4e2d\u3002 \u5982\u679c\u60a8\u548c\u60a8\u7684\u56e2\u961f\u60f3\u7ee7\u7eed\u5728\u6574\u4f53\u95ee\u9898\u4e2d\u770b\u5230\u8bb8\u53ef\u8bc1\u95ee\u9898\uff0c\u8bf7<a href=\"https:\/\/www.jetbrains.com\/help\/qodana\/2024.1\/license-audit.html#license-audit-running-feature\" target=\"_blank\" rel=\"noopener\">\u66f4\u65b0\u914d\u7f6e<\/a>\u3002<\/p>\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" loading=\"lazy\" class=\"wp-image-467585\" src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2024\/04\/Untitled-6.png\" alt=\"\u4ee3\u7801\u5ba1\u67e5\u4e2d\u4fdd\u8bc1\u4ee3\u7801\u5b89\u5168\u7684\u8bb8\u53ef\u8bc1\u5ba1\u6838\u3002 \" width=\"2498\" height=\"1222\" \/><\/p>\n<figcaption class=\"wp-element-caption\">Qodana \u8bb8\u53ef\u8bc1\u5ba1\u6838\u3002<\/figcaption>\n<\/figure>\n<h2 id=\"Gitlab-code-quality\" class=\"wp-block-heading\"><strong>GitLab \u4ee3\u7801\u8d28\u91cf\u548c BitBucket \u4ee3\u7801\u6d1e\u5bdf\u652f\u6301\uff08\u62c9\u53d6\u8bf7\u6c42\u88c5\u9970\uff09<\/strong><\/h2>\n<p>\u4ece 2024.1 \u5f00\u59cb\uff0cQodana linter \u652f\u6301\u9002\u7528\u4e8e BitBucket Pipelines \u548c GitLab CI \u7684\u62c9\u53d6\u8bf7\u6c42\u88c5\u9970\u3002 \u6b64\u524d\uff0c\u8fd9\u9879\u529f\u80fd\u4ec5\u9002\u7528\u4e8e GitHub Actions\u3002<\/p>\n<p>\u73b0\u5728\uff0c\u5bf9\u4e8e GitHub Actions\u3001GitLab CI \u548c BitBucket Pipelines\uff0c\u901a\u8fc7\u62c9\u53d6\u6216\u5408\u5e76\u8bf7\u6c42\u754c\u9762\u4e2d\u5bf9\u4ee3\u7801\u8d28\u91cf\u7684\u76f4\u63a5\u81ea\u52a8\u5316\u6d1e\u5bdf\uff0cQodana \u80fd\u591f\u589e\u5f3a\u4ee3\u7801\u5ba1\u67e5\u3002<\/p>\n<p>\u5f97\u76ca\u4e8e\u8fd9\u79cd\u96c6\u6210\uff0c\u60a8\u53ef\u4ee5\u76f4\u63a5\u4ece\u62c9\u53d6\u6216\u5408\u5e76\u8bf7\u6c42\u8bbf\u95ee\u68c0\u6d4b\u5230\u95ee\u9898\u7684\u5177\u4f53\u4ee3\u7801\u884c\uff0c\u5e76\u83b7\u53d6\u95ee\u9898\u7684\u63cf\u8ff0\u548c\u53ef\u80fd\u7684\u89e3\u51b3\u65b9\u6848\u6216\u5efa\u8bae\u3002<\/p>\n<p><strong>\u5982\u4f55\u542f\u7528\u8be5\u529f\u80fd\uff1a<\/strong><\/p>\n<ul>\n<li><a href=\"https:\/\/support.atlassian.com\/bitbucket-cloud\/docs\/code-insights\/\" target=\"_blank\" rel=\"noopener\">BitBucket \u4ee3\u7801\u6d1e\u5bdf<\/a>\uff1a\u65e0\u9700\u989d\u5916\u914d\u7f6e\uff0c\u5c06 linter \u66f4\u65b0\u5230 2024.1 \u7248\u672c\u5373\u53ef\u3002<\/li>\n<li><a href=\"https:\/\/docs.gitlab.com\/ee\/ci\/testing\/code_quality.html\" target=\"_blank\" rel=\"noopener\">GitLab \u4ee3\u7801\u8d28\u91cf<\/a>\uff1a\u9700\u8981\u989d\u5916\u914d\u7f6e\uff08\u6307\u5b9a\u62a5\u544a\u6587\u4ef6\u4f4d\u7f6e\uff09\u3002<\/li>\n<\/ul>\n<p>\u00a0\u00a0\u00a0\u00a0\u811a\u672c\uff1a<\/p>\n<pre class=\"EnlighterJSRAW\"> - qodana --results-dir=$CI_PROJECT_DIR\/.qodana\/results\n            --cache-dir=$CI_PROJECT_DIR\/.qodana\/cache<\/pre>\n<p>\u00a0\u00a0\u5de5\u4ef6\uff1a<\/p>\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u62a5\u544a\uff1a<\/p>\n<pre class=\"EnlighterJSRAW\">     codequality: .qodana\/results\/gl-code-quality-report.json<\/pre>\n<figure class=\"wp-block-video\"><video controls src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2024\/04\/064bfeae-6c61-45bb-9ec4-0865b17ffd3c.mp4\"><\/video><\/p>\n<figcaption class=\"wp-element-caption\">BitBucket example. <\/figcaption>\n<\/figure>\n<h2 id=\"Default-linter-choice\" class=\"wp-block-heading\"><strong>\u672a\u901a\u8fc7 qodana.yaml \u5b9a\u4e49\u65f6\u7684\u9ed8\u8ba4 linter \u9009\u62e9<\/strong><\/h2>\n<p>\u6211\u4eec\u6b63\u5728\u5bf9 JVM \u548c Python \u9879\u76ee\u7684\u9ed8\u8ba4 linter \u9009\u62e9\u505a\u51fa\u66f4\u6539\u3002 \u4e3a\u4e86\u5411\u7528\u6237\u63d0\u4f9b\u529f\u80fd\u4e30\u5bcc\u7684\u5148\u8fdb\u5206\u6790\u529f\u80fd\uff0cQodana \u5c06\u9ed8\u8ba4\u4f7f\u7528\u6211\u4eec linter \u7684 Ultimate \u7248\u672c \u2013 JVM \u9879\u76ee\u4e3a QDJVM\uff0cPython \u9879\u76ee\u4e3a QDPY\uff0c\u800c\u4e0d\u662f Community \u7248\u672c\uff08\u5206\u522b\u4e3a QDJVMC \u548c QDPYC\uff09\u3002<\/p>\n<p>\u7ecf\u8fc7\u8fd9\u9879\u66f4\u6539\uff0c\u5982\u679c\u60a8\u7684 qodana.yaml \u914d\u7f6e\u672a\u6307\u5b9a\u5177\u4f53\u7684 linter \u7248\u672c\uff0c\u4e5f\u672a\u63d0\u4f9b Qodana Cloud \u4ee4\u724c\uff0c\u5c06\u81ea\u52a8\u4f7f\u7528 Ultimate \u7248\u672c\uff0c\u8ba9\u60a8\u4f53\u9a8c Qodana \u7684\u5168\u90e8\u529f\u80fd\u3002<\/p>\n<p>\u5982\u679c\u60a8\u66f4\u559c\u6b22 Community \u7248\u672c\uff0c\u5219\u9700\u8981\u5728 qodana.yaml \u6587\u4ef6\u4e2d\u660e\u786e\u5b9a\u4e49\uff0c\u907f\u514d\u5347\u7ea7\u5230 Qodana 2024.1 \u540e\u51fa\u73b0\u4e2d\u65ad\u3002<\/p>\n<h2 id=\"Improved-UX\" class=\"wp-block-heading\"><strong>\u9002\u7528\u4e8e IDE \u63d2\u4ef6\u7684\u6539\u8fdb UX<\/strong><\/h2>\n<ol>\n<li>Qodana \u9ad8\u4eae\u663e\u793a\u4e0d\u518d\u91cd\u590d IDE \u7684\u9ad8\u4eae\u663e\u793a\u3002 \u5982\u679c IDE \u5df2\u7ecf\u9ad8\u4eae\u663e\u793a Qodana \u62a5\u544a\u4e2d\u7684\u67d0\u4e2a\u95ee\u9898\uff0c\u5219 Qodana \u63d2\u4ef6\u4e0d\u4f1a\u518d\u5c1d\u8bd5\u9ad8\u4eae\u663e\u793a\u3002<\/li>\n<li>\u4fee\u6b63 Qodana \u62a5\u544a\u4e2d\u5217\u51fa\u7684\u4e00\u4e2a\u95ee\u9898\u6216\u8c03\u6574\u76f8\u5173\u4ee3\u7801\u6bb5\u65f6\uff0cQodana \u63d2\u4ef6\u4f1a\u81ea\u52a8\u5c06\u62a5\u544a\u4e2d\u95ee\u9898\u7684\u72b6\u6001\u66f4\u65b0\u4e3a <em>Fixed<\/em>\uff08\u5df2\u4fee\u6b63 \u2013 \u5982\u679c\u5df2\u4fee\u6b63\uff09\u6216 <em>Not found<\/em>\uff08\u627e\u4e0d\u5230 \u2013 \u5982\u679c\u76f8\u5173\u4ee3\u7801\u6bb5\u88ab\u79fb\u9664\uff09\u3002\n<p>\u8fd9\u6837\uff0c\u60a8\u53ef\u4ee5\u7acb\u5373\u770b\u5230\u62a5\u544a\u4e2d\u7684\u54ea\u4e9b\u95ee\u9898\u5df2\u7ecf\u89e3\u51b3\uff0c\u54ea\u4e9b\u95ee\u9898\u8fd8\u9700\u8981\u5904\u7406\u3002<\/p>\n<\/li>\n<\/ol>\n<figure class=\"wp-block-video\"><video controls src=\"https:\/\/blog.jetbrains.com\/wp-content\/uploads\/2024\/04\/qodana_fixed_upd_dark.mov\"><\/video><\/p>\n<figcaption class=\"wp-element-caption\">IDE plugin improvements. <\/figcaption>\n<\/figure>\n<h2 class=\"wp-block-heading\"><strong>\u6309\u95ee\u9898\u4e25\u91cd\u6027\u914d\u7f6e\u8d28\u91cf\u95e8<\/strong><\/h2>\n<p>\u60a8\u5e94\u8be5\u4e0d\u4f1a\u60f3\u56e0\u4e3a\u4f4e\u4e25\u91cd\u6027\u95ee\u9898\u5bfc\u81f4\u6784\u5efa\u5931\u8d25\u3002 \u73b0\u5728\uff0c\u60a8\u53ef\u4ee5\u5fae\u8c03\u6784\u5efa\u5931\u8d25\u3002<\/p>\n<p>\u9664 <a href=\"https:\/\/www.jetbrains.com\/help\/qodana\/qodana-dotnet-community.html\" target=\"_blank\" rel=\"noopener\">Qodana Community for .NET<\/a> \u4e4b\u5916\u7684\u6240\u6709 <a href=\"https:\/\/www.jetbrains.com\/help\/qodana\/linters.html\" target=\"_blank\" rel=\"noopener\">linter<\/a> \u90fd\u5141\u8bb8\u60a8\u4e3a\u6bcf\u4e2a<a href=\"https:\/\/www.jetbrains.com\/help\/qodana\/faq.html#faq-severities\" target=\"_blank\" rel=\"noopener\">\u95ee\u9898\u4e25\u91cd\u6027<\/a>\u914d\u7f6e\u5355\u72ec\u7684\u8d28\u91cf\u95e8\uff0c\u5e76\u4e14\u4ec5\u8d85\u8fc7\u4e00\u9879\u8bbe\u7f6e\u9650\u5236\uff08\u5305\u62ec<a href=\"https:\/\/www.jetbrains.com\/help\/qodana\/quality-gate.html#quality-gate-project-threshold\" target=\"_blank\" rel=\"noopener\">\u95ee\u9898\u603b\u6570<\/a>\uff09\u5c31\u4f1a\u5bfc\u81f4\u6784\u5efa\u5931\u8d25\u3002 \u4ee5\u4e0b\u662f <a href=\"https:\/\/www.jetbrains.com\/help\/qodana\/qodana-yaml.html\" target=\"_blank\" rel=\"noopener\">qodana.yaml<\/a> \u4e25\u91cd\u6027\u914d\u7f6e\u7684\u793a\u4f8b\uff1a<\/p>\n<pre class=\"EnlighterJSRAW\">failureConditions:\n  severityThresholds:\n    any:  # Total problems\n    critical:  # Critical and other severities\n    high: \n    moderate: \n    low: \n    info: <\/pre>\n<h2 id=\"Custom-name\" class=\"wp-block-heading\"><strong>\u9002\u7528\u4e8e\u81ea\u5b9a\u4e49 <\/strong><strong>qodana.yaml<\/strong><strong> \u6587\u4ef6\u7684\u53c2\u6570<\/strong><\/h2>\n<p>\u7248\u672c 2024.1 \u7b80\u5316\u4e86\u5728\u540c\u4e00\u4ed3\u5e93\u4e0a\u4f7f\u7528\u4e0d\u540c\u914d\u7f6e\u8fd0\u884c Qodana \u6784\u5efa\u7684\u6d41\u7a0b\u3002<\/p>\n<p>\u5728\u5148\u524d\u7684\u7248\u672c\u4e2d\uff0cQodana linter \u4f7f\u7528 qodana.yaml \u6587\u4ef6\u4fdd\u7559\u914d\u7f6e\u5e76\u5b9a\u4e49 linter \u7684\u884c\u4e3a\u65b9\u5f0f\uff08\u5305\u62ec\u8fd0\u884c\u7684\u68c0\u67e5\u96c6\u3001\u5e94\u5206\u6790\u7684\u6587\u4ef6\u5939\u548c\u6587\u4ef6\u7b49\uff09\u3002<\/p>\n<p>\u8981\u4f7f\u7528\u4e0d\u540c\u7684\u914d\u7f6e\u901a\u8fc7 linter \u8fd0\u884c CI \u4f5c\u4e1a\uff0c\u60a8\u9700\u8981\u66ff\u6362 qodana.yaml \u6587\u4ef6\u3002<\/p>\n<p>\u6b64\u5916\uff0c\u4e3e\u4f8b\u6765\u8bf4\uff0c\u5982\u679c\u60a8\u6709\u4e00\u4e2a\u5305\u542b JavaScript\u3001PHP \u548c Python \u7684\u5355\u4ed3\u5e93\uff0c\u5e76\u4e14\u4e3a\u6bcf\u4e2a linter \u8fd0\u884c\u4e09\u4e2a\u5404\u81ea\u7684\u4f5c\u4e1a\uff0c\u90a3\u4e48\u60a8\u53ef\u80fd\u5e0c\u671b\u4f7f\u7528\u4e0d\u540c\u7684 qodana.yaml \u6587\u4ef6\uff0c\u8fd9\u5728\u8fc7\u53bb\u65e0\u6cd5\u5b9e\u73b0\u3002<\/p>\n<p>\u4ece Qodana 2024.1 \u5f00\u59cb\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528\u4efb\u4f55\u6587\u4ef6\u540d\u5e76\u5c06\u5176\u4f5c\u4e3a\u53c2\u6570\u4f20\u9012\u3002 \u6240\u6709 linter \u73b0\u5728\u90fd\u63d0\u4f9b\u540d\u4e3a <code>config<\/code> \u7684\u53ef\u9009\u53c2\u6570\uff0c\u5141\u8bb8\u60a8\u5c06\u4efb\u4f55\u6587\u4ef6\u4f5c\u4e3a\u914d\u7f6e\u4f20\u9012\u3002<\/p>\n<p><strong>\u7528\u6cd5\u793a\u4f8b<\/strong>\uff1a<\/p>\n<pre class=\"EnlighterJSRAW\">#qodana-cli\nqodana scan --config custom.qodana.yaml\n\n#qodana docker\ndocker run \\\n  -v :\/data\/project \\\n  -v :\/data\/results \\\n  jetbrains\/qodana-jvm:2024.1 \\\n  --config .qodana\/license-check.qodana.yaml<\/pre>\n<p>\u4ee5\u4e0a\u662f\u76ee\u524d\u6700\u91cd\u8981\u7684\u51e0\u5927\u4eae\u70b9\uff0c\u8fd8\u6709\u66f4\u591a\u5373\u5c06\u5230\u6765\u3002 \u5982\u679c\u60a8\u60f3\u63a8\u8350\u65b0\u529f\u80fd\u6216\u65b0\u7279\u6027\uff0c\u8bf7\u5728 <a href=\"https:\/\/youtrack.jetbrains.com\/issues\/QD\" target=\"_blank\" rel=\"noopener\">Qodana YouTrack \u9762\u677f<\/a>\u4e0a\u544a\u8bc9\u6211\u4eec\u3002 \u60a8\u53ef\u4ee5\u9605\u8bfb\u5b8c\u6574\u7684 <a href=\"https:\/\/www.jetbrains.com\/help\/qodana\/new-in-2024-1.html\" target=\"_blank\" rel=\"noopener\">Qodana 2024.1 \u53d1\u5e03\u6587\u6863<\/a>\u4e86\u89e3\u66f4\u591a\u4fe1\u606f\u3002<\/p>\n<p align=\"center\"><a class=\"jb-download-button\" title=\"\u5b89\u6392 Qodana \u6f14\u793a\" href=\"https:\/\/www.jetbrains.com\/qodana\/request-a-demo\/\" target=\"_blank\" rel=\"noopener noreferrer\"><i class=\"download-icon\"><\/i>\u5b89\u6392 Qodana \u6f14\u793a<\/a><\/p>\n\n\n<p><\/p>\n\n\n\n<p>\u672c\u535a\u6587\u82f1\u6587\u539f\u4f5c\u8005\uff1a<\/p>\n\n\n    <div class=\"about-author \">\n        <div class=\"about-author__box\">\n            <div class=\"row\">\n                <div class=\"about-author__box-img\">\n                    <img decoding=\"async\" src=\"https:\/\/secure.gravatar.com\/avatar\/?s=200&#038;r=g\" width=\"200\" height=\"200\" alt=\"\" loading=\"lazy\"  class=\"avatar avatar-200 wp-user-avatar wp-user-avatar-200 photo avatar-default\">\n                <\/div>\n                <div class=\"about-author__box-text\">\n                                                        <\/div>\n            <\/div>\n        <\/div>\n    <\/div>\n","protected":false},"author":1297,"featured_media":467609,"comment_status":"closed","ping_status":"closed","template":"","categories":[6711,4089,947,7119,6815,4113,1065,907],"tags":[228,2547,8472,8473],"cross-post-tag":[],"acf":[],"_links":{"self":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/qodana\/472870"}],"collection":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/qodana"}],"about":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/types\/qodana"}],"author":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/users\/1297"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/comments?post=472870"}],"version-history":[{"count":9,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/qodana\/472870\/revisions"}],"predecessor-version":[{"id":472888,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/qodana\/472870\/revisions\/472888"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/media\/467609"}],"wp:attachment":[{"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/media?parent=472870"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/categories?post=472870"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/tags?post=472870"},{"taxonomy":"cross-post-tag","embeddable":true,"href":"https:\/\/blog.jetbrains.com\/zh-hans\/wp-json\/wp\/v2\/cross-post-tag?post=472870"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}