From 343874cff5b042f2837b82ef88940b9eb9caabd9 Mon Sep 17 00:00:00 2001 From: Jonghyo Lee Date: Tue, 31 Dec 2024 09:40:54 +0900 Subject: [PATCH] . --- .editorconfig | 60 +++++++++---------- .github/dependabot.yml | 13 ++++ .github/workflows/SonarCloud.yml | 30 +++------- .gitignore | 7 ++- Directory.Build.props | 8 +++ .../EncodingConverter.Tests.csproj | 3 - .../EncodingConverter.VisualStudio.csproj | 1 - EncodingConverter/EncodingConverter.csproj | 4 -- README.md | 2 +- 9 files changed, 65 insertions(+), 63 deletions(-) create mode 100644 Directory.Build.props diff --git a/.editorconfig b/.editorconfig index 853d2f2..956dac4 100644 --- a/.editorconfig +++ b/.editorconfig @@ -941,62 +941,62 @@ cpp_generate_documentation_comments = xml # Visual C++ 서식 설정 cpp_indent_braces = false -cpp_indent_multi_line_relative_to = statement_begin +cpp_indent_multi_line_relative_to = innermost_parenthesis cpp_indent_within_parentheses = indent cpp_indent_preserve_within_parentheses = true -cpp_indent_case_contents = false -cpp_indent_case_labels = false +cpp_indent_case_contents = true +cpp_indent_case_labels = true cpp_indent_case_contents_when_block = false -cpp_indent_lambda_braces_when_parameter = false -cpp_indent_goto_labels = none -cpp_indent_preprocessor = none +cpp_indent_lambda_braces_when_parameter = true +cpp_indent_goto_labels = one_left +cpp_indent_preprocessor = leftmost_column cpp_indent_access_specifiers = false -cpp_indent_namespace_contents = false -cpp_indent_preserve_comments = false -cpp_new_line_before_open_brace_namespace = ignore -cpp_new_line_before_open_brace_type = ignore -cpp_new_line_before_open_brace_function = ignore -cpp_new_line_before_open_brace_block = ignore -cpp_new_line_before_open_brace_lambda = ignore -cpp_new_line_scope_braces_on_separate_lines = false +cpp_indent_namespace_contents = true +cpp_indent_preserve_comments = true +cpp_new_line_before_open_brace_namespace = same_line +cpp_new_line_before_open_brace_type = same_line +cpp_new_line_before_open_brace_function = same_line +cpp_new_line_before_open_brace_block = same_line +cpp_new_line_before_open_brace_lambda = same_line +cpp_new_line_scope_braces_on_separate_lines = true cpp_new_line_close_brace_same_line_empty_type = true cpp_new_line_close_brace_same_line_empty_function = true cpp_new_line_before_catch = false cpp_new_line_before_else = false cpp_new_line_before_while_in_do_while = false -cpp_space_before_function_open_parenthesis = ignore +cpp_space_before_function_open_parenthesis = remove cpp_space_within_parameter_list_parentheses = false cpp_space_between_empty_parameter_list_parentheses = false -cpp_space_after_keywords_in_control_flow_statements = false +cpp_space_after_keywords_in_control_flow_statements = true cpp_space_within_control_flow_statement_parentheses = false cpp_space_before_lambda_open_parenthesis = false cpp_space_within_cast_parentheses = false cpp_space_after_cast_close_parenthesis = false cpp_space_within_expression_parentheses = false -cpp_space_before_block_open_brace = false +cpp_space_before_block_open_brace = true cpp_space_between_empty_braces = false cpp_space_before_initializer_list_open_brace = false -cpp_space_within_initializer_list_braces = false +cpp_space_within_initializer_list_braces = true cpp_space_preserve_in_initializer_list = false cpp_space_before_open_square_bracket = false cpp_space_within_square_brackets = false cpp_space_before_empty_square_brackets = false cpp_space_between_empty_square_brackets = false -cpp_space_group_square_brackets = false +cpp_space_group_square_brackets = true cpp_space_within_lambda_brackets = false cpp_space_between_empty_lambda_brackets = false cpp_space_before_comma = false -cpp_space_after_comma = false -cpp_space_remove_around_member_operators = false -cpp_space_before_inheritance_colon = false -cpp_space_before_constructor_colon = false -cpp_space_remove_before_semicolon = false -cpp_space_after_semicolon = false -cpp_space_remove_around_unary_operator = false -cpp_space_around_binary_operator = ignore -cpp_space_around_assignment_operator = ignore -cpp_space_pointer_reference_alignment = ignore -cpp_space_around_ternary_operator = ignore +cpp_space_after_comma = true +cpp_space_remove_around_member_operators = true +cpp_space_before_inheritance_colon = true +cpp_space_before_constructor_colon = true +cpp_space_remove_before_semicolon = true +cpp_space_after_semicolon = true +cpp_space_remove_around_unary_operator = true +cpp_space_around_binary_operator = insert +cpp_space_around_assignment_operator = insert +cpp_space_pointer_reference_alignment = right +cpp_space_around_ternary_operator = insert cpp_use_unreal_engine_macro_formatting = false cpp_wrap_preserve_blocks = never diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 000fcdf..004544c 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -30,3 +30,16 @@ updates: separator: _ reviewers: - na1307 + + - package-ecosystem: github-actions + directory: / + schedule: + interval: monthly + time: "12:00" + timezone: Asia/Seoul + assignees: + - na1307 + pull-request-branch-name: + separator: _ + reviewers: + - na1307 diff --git a/.github/workflows/SonarCloud.yml b/.github/workflows/SonarCloud.yml index e2aff4c..2fa09db 100644 --- a/.github/workflows/SonarCloud.yml +++ b/.github/workflows/SonarCloud.yml @@ -19,11 +19,6 @@ jobs: - uses: actions/checkout@v4 with: fetch-depth: 0 - - name: Set up JDK 21 - uses: actions/setup-java@v4 - with: - java-version: 21 - distribution: temurin - name: Setup .NET uses: actions/setup-dotnet@v4 - name: Cache NuGet @@ -34,19 +29,12 @@ jobs: restore-keys: ${{ runner.os }}-sonar-nuget- - name: Install Tools run: dotnet tool restore - - name: SonarScanner Begin - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - run: dotnet sonarscanner begin /k:"na1307_EncodingConverter" /o:"na1307" /d:sonar.token="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io" /d:sonar.cs.vscoveragexml.reportsPaths=coverage.xml /d:sonar.scanner.skipJreProvisioning=true - - name: Restore dependencies - run: dotnet restore - - name: Build - run: dotnet build --no-restore --no-incremental -p:CreateVsixContainer=false -p:DeployExtension=false - - name: Test - run: dotnet coverage collect 'dotnet test --no-build --verbosity normal' -f xml -o 'coverage.xml' - - name: SonarScanner End - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - run: dotnet sonarscanner end /d:sonar.token="${{ secrets.SONAR_TOKEN }}" + - name: SonarScanner for .NET + uses: na1307/dotnet-sonarscanner-cloud@v1 + with: + sonar-token: ${{ secrets.SONAR_TOKEN }} + additional-properties: -d:sonar.cs.vscoveragexml.reportsPaths=coverage.xml + build-commands: | + dotnet restore + dotnet build --no-restore --no-incremental -p:CreateVsixContainer=false -p:DeployExtension=false + dotnet coverage collect 'dotnet test --no-build --verbosity normal' -f xml -o 'coverage.xml' diff --git a/.gitignore b/.gitignore index 3e2921f..a212c2a 100644 --- a/.gitignore +++ b/.gitignore @@ -76,6 +76,7 @@ StyleCopReport.xml # Files built by Visual Studio *_i.c +*_i.h *_p.c *_h.h *.ilk @@ -402,7 +403,7 @@ FodyWeavers.xsd # JetBrains Rider *.sln.iml -.idea +.idea/ ## ## Visual studio for Mac @@ -426,7 +427,7 @@ test-results/ *.dmg *.app -# content below from: https://github.com/github/gitignore/blob/master/Global/macOS.gitignore +# content below from: https://github.com/github/gitignore/blob/main/Global/macOS.gitignore # General .DS_Store .AppleDouble @@ -455,7 +456,7 @@ Network Trash Folder Temporary Items .apdisk -# content below from: https://github.com/github/gitignore/blob/master/Global/Windows.gitignore +# content below from: https://github.com/github/gitignore/blob/main/Global/Windows.gitignore # Windows thumbnail cache files Thumbs.db ehthumbs.db diff --git a/Directory.Build.props b/Directory.Build.props new file mode 100644 index 0000000..d20d1eb --- /dev/null +++ b/Directory.Build.props @@ -0,0 +1,8 @@ + + + Encoding Converter + + + true + + diff --git a/EncodingConverter.Tests/EncodingConverter.Tests.csproj b/EncodingConverter.Tests/EncodingConverter.Tests.csproj index 6f50cd4..551c7c0 100644 --- a/EncodingConverter.Tests/EncodingConverter.Tests.csproj +++ b/EncodingConverter.Tests/EncodingConverter.Tests.csproj @@ -1,7 +1,4 @@  - - true - net9.0 false diff --git a/EncodingConverter.VisualStudio/EncodingConverter.VisualStudio.csproj b/EncodingConverter.VisualStudio/EncodingConverter.VisualStudio.csproj index ce1116f..f1d73f6 100644 --- a/EncodingConverter.VisualStudio/EncodingConverter.VisualStudio.csproj +++ b/EncodingConverter.VisualStudio/EncodingConverter.VisualStudio.csproj @@ -7,7 +7,6 @@ true EncodingConverter Encoding Converter for Visual Studio - Encoding Converter 2.0.0.0 2.0.0 2.0 diff --git a/EncodingConverter/EncodingConverter.csproj b/EncodingConverter/EncodingConverter.csproj index 4a32c41..b375dd1 100644 --- a/EncodingConverter/EncodingConverter.csproj +++ b/EncodingConverter/EncodingConverter.csproj @@ -1,7 +1,4 @@  - - true - netstandard2.0 false @@ -9,7 +6,6 @@ true EncodingConverter.Core Encoding Converter - Encoding Converter 1 1.0.0 1.0 diff --git a/README.md b/README.md index cbb0b97..ec3ceac 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ # Encoding Converter Encoding Converter makes it easy to convert the encoding of a file. -Visual Studio Extension is avaliable. +Visual Studio Extension is avaliable. A File Explorer shell extension was also planned, but was canceled.