Bruce Wayne 1 anno fa
parent
commit
225943fa7a
3 ha cambiato i file con 7 aggiunte e 4 eliminazioni
  1. 2 2
      .editorconfig
  2. 0 1
      .gitattributes
  3. 5 1
      .github/workflows/CI.yaml

+ 2 - 2
.editorconfig

@@ -11,7 +11,7 @@ indent_style = space
 tab_width = 4
 
 # 新行首选项
-end_of_line = crlf
+end_of_line = lf
 insert_final_newline = true
 
 [*.bat]
@@ -130,7 +130,7 @@ csharp_style_inlined_variable_declaration = true:warning
 csharp_style_pattern_local_over_anonymous_function = true
 csharp_style_prefer_index_operator = true:warning
 csharp_style_prefer_null_check_over_type_check = true:warning
-csharp_style_prefer_range_operator = true:warning
+csharp_style_prefer_range_operator = false:none
 csharp_style_throw_expression = true
 csharp_style_unused_value_assignment_preference = discard_variable
 csharp_style_unused_value_expression_statement_preference = discard_variable

+ 0 - 1
.gitattributes

@@ -1 +0,0 @@
-*.cs eol=crlf

+ 5 - 1
.github/workflows/CI.yaml

@@ -7,7 +7,7 @@ env:
 
 jobs:
   check_format:
-    runs-on: windows-latest
+    runs-on: ubuntu-latest
     steps:
       - name: Setup .NET
         uses: actions/setup-dotnet@v4
@@ -83,6 +83,8 @@ jobs:
     needs: [test, check_format]
     if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/') }}
     runs-on: ubuntu-latest
+    permissions:
+      packages: write
     strategy:
       matrix:
         PackageName:
@@ -110,6 +112,8 @@ jobs:
   release:
     needs: [build, nuget]
     runs-on: ubuntu-latest
+    permissions:
+      contents: write
 
     steps:
       - uses: actions/download-artifact@v4