From 198f7004ae3cf6f8b6a0bf9641a028070f24a204 Mon Sep 17 00:00:00 2001 From: Hongjun Li <103014488+returnToInnocence@users.noreply.github.com> Date: Tue, 27 Feb 2024 12:53:29 +0800 Subject: [PATCH] chore: refine the hg-style.xml specification (#2457) - Change the maximum wrap text length for XML to 120 (via `hg-style.xml`) - Add a blank line between method definitions, inner class definitions, and static code blocks (via `hg-style.xml`) - Add `
` tags to Javadoc blank lines (via `hg-style.xml`)
- `.xml` file leaves a blank line at the end (via `.editorconfig`)
- Class declaration requires a blank line before and after each line (via `hg-style.xml`)
- Javadoc line comment not in line (via `hg-style.xml`)
- `.properties` file leaves empty lines (via `hg-style.xml`)
- `.yaml` file braces `{}`, brackets `[]` remove spaces (via `hg-style.xml`)
---
.editorconfig | 3 +++
hugegraph-style.xml | 30 +++++++++++++++++++++++++++---
2 files changed, 30 insertions(+), 3 deletions(-)
diff --git a/.editorconfig b/.editorconfig
index 740928132a..67bf0e4487 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -25,3 +25,6 @@ insert_final_newline = true
[*.{java,xml,py}]
indent_style = space
indent_size = 4
+
+[*.{java,xml}]
+continuation_indent_size = 8
diff --git a/hugegraph-style.xml b/hugegraph-style.xml
index 8536d5154c..84b4d27460 100644
--- a/hugegraph-style.xml
+++ b/hugegraph-style.xml
@@ -22,6 +22,8 @@