Compare commits
No commits in common. "34c6ea1a8bea9247e3295c33293ff78722cb8dea" and "d2d761deb57df93cf935c7422f20f91db12b28f6" have entirely different histories.
34c6ea1a8b
...
d2d761deb5
63
.github/workflows/checkstyle.xml
vendored
63
.github/workflows/checkstyle.xml
vendored
@ -1,63 +0,0 @@
|
|||||||
<?xml version="1.0"?>
|
|
||||||
<!DOCTYPE module PUBLIC
|
|
||||||
"-//Puppy Crawl//DTD Check Configuration 1.3//EN"
|
|
||||||
"https://checkstyle.org/dtds/configuration_1_3.dtd">
|
|
||||||
|
|
||||||
<module name="Checker">
|
|
||||||
<!-- 设置换行符 -->
|
|
||||||
<property name="lineSeparator" value="lf"/>
|
|
||||||
|
|
||||||
<!-- 检查文件头部 -->
|
|
||||||
<module name="FileTabCharacter">
|
|
||||||
<property name="eachLine" value="true"/>
|
|
||||||
</module>
|
|
||||||
|
|
||||||
<!-- 检查文件的末尾是否有换行符 -->
|
|
||||||
<module name="NewlineAtEndOfFile"/>
|
|
||||||
|
|
||||||
<!-- 检查缩进是否使用空格而不是 Tab -->
|
|
||||||
<module name="Checker">
|
|
||||||
<property name="fileExtensions" value="java"/>
|
|
||||||
<module name="Indentation">
|
|
||||||
<property name="basicOffset" value="4"/>
|
|
||||||
<property name="braceAdjustment" value="0"/>
|
|
||||||
<property name="caseIndent" value="4"/>
|
|
||||||
<property name="throwsIndent" value="4"/>
|
|
||||||
<property name="lineWrappingIndentation" value="4"/>
|
|
||||||
</module>
|
|
||||||
</module>
|
|
||||||
|
|
||||||
<!-- 检查代码中的注释 -->
|
|
||||||
<module name="Checker">
|
|
||||||
<property name="fileExtensions" value="java"/>
|
|
||||||
<module name="TreeWalker">
|
|
||||||
<module name="JavadocMethod"/>
|
|
||||||
<module name="JavadocVariable"/>
|
|
||||||
<module name="JavadocStyle"/>
|
|
||||||
</module>
|
|
||||||
</module>
|
|
||||||
|
|
||||||
<!-- 检查空白行 -->
|
|
||||||
<module name="Checker">
|
|
||||||
<property name="fileExtensions" value="java"/>
|
|
||||||
<module name="TreeWalker">
|
|
||||||
<module name="EmptyLineSeparator">
|
|
||||||
<property name="tokens" value="CLASS_DEF,INTERFACE_DEF,ENUM_DEF,METHOD_DEF,CTOR_DEF"/>
|
|
||||||
</module>
|
|
||||||
</module>
|
|
||||||
</module>
|
|
||||||
|
|
||||||
<!-- 检查行长度 -->
|
|
||||||
<module name="Checker">
|
|
||||||
<property name="fileExtensions" value="java"/>
|
|
||||||
<module name="TreeWalker">
|
|
||||||
<module name="LineLength">
|
|
||||||
<property name="max" value="120"/>
|
|
||||||
<property name="ignorePattern" value="^import .*"/>
|
|
||||||
</module>
|
|
||||||
</module>
|
|
||||||
</module>
|
|
||||||
|
|
||||||
<!-- 其他规则可以根据需要添加 -->
|
|
||||||
|
|
||||||
</module>
|
|
4
.github/workflows/code-check.yaml
vendored
4
.github/workflows/code-check.yaml
vendored
@ -30,5 +30,5 @@ jobs:
|
|||||||
- name: Super-linter
|
- name: Super-linter
|
||||||
uses: super-linter/super-linter@v6.3.1
|
uses: super-linter/super-linter@v6.3.1
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.MyGitHubToken }}
|
# To report GitHub Actions status checks
|
||||||
CHECKSTYLE_FILTER_PATH: ".github/workflows/checkstyle.xml"
|
GITHUB_TOKEN: ${{ secrets.MyGitHubToken }}
|
24
Jenkinsfile
vendored
Normal file
24
Jenkinsfile
vendored
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
pipeline {
|
||||||
|
environment {
|
||||||
|
QODANA_TOKEN=credentials('qodana-token')
|
||||||
|
}
|
||||||
|
agent {
|
||||||
|
docker {
|
||||||
|
args '''
|
||||||
|
-v "${WORKSPACE}":/data/project
|
||||||
|
--entrypoint=""
|
||||||
|
'''
|
||||||
|
image 'jetbrains/qodana-jvm'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stages {
|
||||||
|
stage('Qodana') {
|
||||||
|
when {
|
||||||
|
branch 'feature'
|
||||||
|
}
|
||||||
|
steps {
|
||||||
|
sh '''qodana'''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
41
qodana.yaml
Normal file
41
qodana.yaml
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
#-------------------------------------------------------------------------------#
|
||||||
|
# Qodana analysis is configured by qodana.yaml file #
|
||||||
|
# https://www.jetbrains.com/help/qodana/qodana-yaml.html #
|
||||||
|
#-------------------------------------------------------------------------------#
|
||||||
|
version: "1.0"
|
||||||
|
#Specify inspection profile for code analysis
|
||||||
|
profile:
|
||||||
|
name: qodana.starter
|
||||||
|
#Enable inspections
|
||||||
|
#include:
|
||||||
|
# - name: <SomeEnabledInspectionId>
|
||||||
|
#Disable inspections
|
||||||
|
#exclude:
|
||||||
|
# - name: <SomeDisabledInspectionId>
|
||||||
|
# paths:
|
||||||
|
# - <path/where/not/run/inspection>
|
||||||
|
projectJDK: 17 #(Applied in CI/CD pipeline)
|
||||||
|
#Execute shell command before Qodana execution (Applied in CI/CD pipeline)
|
||||||
|
#bootstrap: sh ./prepare-qodana.sh
|
||||||
|
#Install IDE plugins before Qodana execution (Applied in CI/CD pipeline)
|
||||||
|
#plugins:
|
||||||
|
# - id: <plugin.id> #(plugin id can be found at https://plugins.jetbrains.com)
|
||||||
|
#Specify Qodana linter for analysis (Applied in CI/CD pipeline)
|
||||||
|
linter: jetbrains/qodana-jvm:latest
|
||||||
|
include:
|
||||||
|
- name: ClassLoaderInstantiation
|
||||||
|
- name: NonThreadSafeLazyInitialization
|
||||||
|
- name: DoubleBraceInitialization
|
||||||
|
- name: JavaLangImport
|
||||||
|
- name: UNUSED_IMPORT
|
||||||
|
- name: SamePackageImport
|
||||||
|
- name: ArgNamesErrorsInspection
|
||||||
|
- name: ArgNamesWarningsInspection
|
||||||
|
- name: AssertMessageNotString
|
||||||
|
- name: EqualsCalledOnEnumConstant
|
||||||
|
- name: ListIndexOfReplaceableByContains
|
||||||
|
- name: ObjectsEqualsCanBeSimplified
|
||||||
|
- name: SizeReplaceableByIsEmpty
|
||||||
|
- name: ArrayCreationWithoutNewKeyword
|
||||||
|
exclude:
|
||||||
|
- name: VulnerableLibrariesLocal
|
@ -7,6 +7,7 @@ import org.springframework.scheduling.annotation.EnableScheduling;
|
|||||||
@SpringBootApplication
|
@SpringBootApplication
|
||||||
@EnableScheduling
|
@EnableScheduling
|
||||||
public class JslOrganizeInternalOaApplication {
|
public class JslOrganizeInternalOaApplication {
|
||||||
|
// debug
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
SpringApplication.run(JslOrganizeInternalOaApplication.class, args);
|
SpringApplication.run(JslOrganizeInternalOaApplication.class, args);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user