From b94744f387deebe8382be7e658fe5d16b11f2189 Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Fri, 24 Feb 2023 13:04:39 +0100 Subject: [PATCH 01/10] Adding code style --- checkstyle-suppressions.xml | 7 +++ checkstyle.xml | 110 ++++++++++++++++++++++++++++++++++++ pom.xml | 5 +- 3 files changed, 120 insertions(+), 2 deletions(-) create mode 100644 checkstyle-suppressions.xml create mode 100644 checkstyle.xml diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml new file mode 100644 index 0000000000..239a3f0c6b --- /dev/null +++ b/checkstyle-suppressions.xml @@ -0,0 +1,7 @@ + + + + + \ No newline at end of file diff --git a/checkstyle.xml b/checkstyle.xml new file mode 100644 index 0000000000..2234c241c6 --- /dev/null +++ b/checkstyle.xml @@ -0,0 +1,110 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/pom.xml b/pom.xml index 88f178f935..e59da4052f 100644 --- a/pom.xml +++ b/pom.xml @@ -306,11 +306,12 @@ + true - duraspace-checkstyle/checkstyle.xml + checkstyle.xml - vitro-checkstyle/checkstyle-suppressions.xml + checkstyle-suppressions.xml UTF-8 true From 6bdb28919b570bfc300a4d47cab65193bcf8d21e Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Fri, 24 Feb 2023 13:37:53 +0100 Subject: [PATCH 02/10] Small correction of code style --- checkstyle.xml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/checkstyle.xml b/checkstyle.xml index 2234c241c6..832aa6fe45 100644 --- a/checkstyle.xml +++ b/checkstyle.xml @@ -11,7 +11,8 @@ Vitro CodeStyle Requirements 4. Maximum line length is 100 characters (except for long URLs, packages or imports) 5. No trailing spaces allowed (except in comments) 6. Tokens should be surrounded by whitespace (see http://checkstyle.sourceforge.net/config_whitespace.html#WhitespaceAround) - 7. Each source file must include our license header (validated separately by license-maven-plugin, see pom.xml) + 7. Each line of code can only include one statement. This also means each variable declaration must be on its own line + 8. Each source file must include our license header (validated separately by license-maven-plugin, see pom.xml) For more information on CheckStyle configurations below, see: http://checkstyle.sourceforge.net/checks.html --> @@ -104,7 +105,5 @@ For more information on CheckStyle configurations below, see: http://checkstyle. - - \ No newline at end of file From bc3acf7a2d78a5a0f39ea328ceb4f785407bcdd8 Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Tue, 28 Feb 2023 11:47:29 +0100 Subject: [PATCH 03/10] Putting under comments checkstyle rules --- checkstyle-suppressions.xml | 2 +- checkstyle.xml | 150 ++++++++++++++++++------------------ pom.xml | 1 - 3 files changed, 76 insertions(+), 77 deletions(-) diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml index 239a3f0c6b..74e914bd6a 100644 --- a/checkstyle-suppressions.xml +++ b/checkstyle-suppressions.xml @@ -4,4 +4,4 @@ "http://checkstyle.sourceforge.net/dtds/suppressions_1_2.dtd"> - \ No newline at end of file + diff --git a/checkstyle.xml b/checkstyle.xml index 832aa6fe45..879fc29cc0 100644 --- a/checkstyle.xml +++ b/checkstyle.xml @@ -22,88 +22,88 @@ For more information on CheckStyle configurations below, see: http://checkstyle. - - - - + + + + - - - - - + + + + + - - - - - - + + + + + + - - + + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - + + - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - + + + + + + + - - - - - - - - - - - - - + + + + + + + + + + + + + + - - - - - - - \ No newline at end of file + + + + + + + diff --git a/pom.xml b/pom.xml index e59da4052f..53c31ae192 100644 --- a/pom.xml +++ b/pom.xml @@ -306,7 +306,6 @@ - true checkstyle.xml From b0d4f7ebf37aa9b6a83cc2da5883d89e0199179b Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Mon, 6 Mar 2023 15:10:02 +0100 Subject: [PATCH 04/10] include checks and suppressions (excluding files) --- checkstyle-suppressions.xml | 6 +- checkstyle.xml | 148 ++++++++++++++++++------------------ 2 files changed, 79 insertions(+), 75 deletions(-) diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml index 74e914bd6a..8f6219dd0b 100644 --- a/checkstyle-suppressions.xml +++ b/checkstyle-suppressions.xml @@ -3,5 +3,9 @@ "-//Puppy Crawl//DTD Suppressions 1.2//EN" "http://checkstyle.sourceforge.net/dtds/suppressions_1_2.dtd"> - + + + + + diff --git a/checkstyle.xml b/checkstyle.xml index 879fc29cc0..a501fdf4c5 100644 --- a/checkstyle.xml +++ b/checkstyle.xml @@ -22,88 +22,88 @@ For more information on CheckStyle configurations below, see: http://checkstyle. - - - - + + + + - - - - - + + + + + - - - - - - + + + + + + - - - + + - - - - - - - + + + + + + + - - - - - - - + + + + + + + - - + + - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - + + + + + + + - - - - - - - - - - - - - - + + + + + + + + + + + + + - - - - - - + + + + + + From 78c36ac8afe7b427e2ef12feea77474ab6230edc Mon Sep 17 00:00:00 2001 From: Ivan Mrsulja Date: Fri, 16 Jun 2023 09:44:37 +0200 Subject: [PATCH 05/10] Added checkstyle suppressions. --- checkstyle-suppressions.xml | 1294 ++++++++++++++++++++++++++++++++++- 1 file changed, 1293 insertions(+), 1 deletion(-) diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml index 8f6219dd0b..15ee4a28ff 100644 --- a/checkstyle-suppressions.xml +++ b/checkstyle-suppressions.xml @@ -8,4 +8,1296 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From 8c9ddf39fb07030be72f371bba9c772b1550bd17 Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Fri, 16 Jun 2023 11:33:05 +0200 Subject: [PATCH 06/10] suppression defined at the level of a Java file --- checkstyle-suppressions.xml | 2588 +++++++++++++++++------------------ 1 file changed, 1291 insertions(+), 1297 deletions(-) diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml index 15ee4a28ff..7a2aa3d305 100644 --- a/checkstyle-suppressions.xml +++ b/checkstyle-suppressions.xml @@ -3,1301 +3,1295 @@ "-//Puppy Crawl//DTD Suppressions 1.2//EN" "http://checkstyle.sourceforge.net/dtds/suppressions_1_2.dtd"> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From 470885623bb1d74af17a7df47de11ea393368bfe Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Fri, 16 Jun 2023 11:56:51 +0200 Subject: [PATCH 07/10] adding JFactTBoxReasonerTest in the suppression --- checkstyle-suppressions.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml index 7a2aa3d305..9cbcfecd2f 100644 --- a/checkstyle-suppressions.xml +++ b/checkstyle-suppressions.xml @@ -1228,6 +1228,7 @@ + From ab8190853fbd5e93a9a5408b7db1b1f74efd61c1 Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Fri, 16 Jun 2023 12:02:35 +0200 Subject: [PATCH 08/10] replacement of tabs with spaces in a property file --- home/src/main/resources/config/example.developer.properties | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/home/src/main/resources/config/example.developer.properties b/home/src/main/resources/config/example.developer.properties index dcac9c0057..3100529887 100644 --- a/home/src/main/resources/config/example.developer.properties +++ b/home/src/main/resources/config/example.developer.properties @@ -82,8 +82,8 @@ # developer.searchEngine.enable = false # developer.searchEngine.addStackTrace = false # developer.searchEngine.addResults = false -# developer.searchEngine.queryRestriction = .* -# developer.searchEngine.stackRestriction = .* +# developer.searchEngine.queryRestriction = .* +# developer.searchEngine.stackRestriction = .* #------------------------------------------------------------------------------ From 9e372909bcc25f0fdf2cf293fb20e0179ca344af Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Wed, 28 Jun 2023 11:04:35 +0200 Subject: [PATCH 09/10] increasing the max line length to 120 --- checkstyle.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/checkstyle.xml b/checkstyle.xml index a501fdf4c5..bd000cf760 100644 --- a/checkstyle.xml +++ b/checkstyle.xml @@ -8,7 +8,7 @@ Vitro CodeStyle Requirements 1. 4-space indents for Java. NO TABS ALLOWED. 2. One true brace style. Braces required on all blocks. 3. Do not use wildcard imports (e.g. import java.util.*). Duplicated or unused imports also not allowed. - 4. Maximum line length is 100 characters (except for long URLs, packages or imports) + 4. Maximum line length is 120 characters (except for long URLs, packages or imports) 5. No trailing spaces allowed (except in comments) 6. Tokens should be surrounded by whitespace (see http://checkstyle.sourceforge.net/config_whitespace.html#WhitespaceAround) 7. Each line of code can only include one statement. This also means each variable declaration must be on its own line @@ -44,10 +44,10 @@ For more information on CheckStyle configurations below, see: http://checkstyle. with @SuppressWarnings. See also SuppressWarningsHolder below --> - + - + From 96d9e565325b3d7eef0dd81e4247670c3cceebaa Mon Sep 17 00:00:00 2001 From: Dragan Ivanovic Date: Wed, 23 Aug 2023 10:26:10 +0200 Subject: [PATCH 10/10] Adding java and javax packages at the beggining of imports --- checkstyle.xml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/checkstyle.xml b/checkstyle.xml index bd000cf760..45249ebb89 100644 --- a/checkstyle.xml +++ b/checkstyle.xml @@ -74,7 +74,9 @@ For more information on CheckStyle configurations below, see: http://checkstyle. - + + +