feat: C# linter/formatter 環境を構築#95
Merged
Merged
Conversation
- StyleCop.Analyzers を Directory.Build.props で全プロジェクトに適用 - SA1401 (public フィールド禁止) → error - SA1400 (アクセス修飾子省略禁止) → error - SA1201 (メンバー順序) → error(StyleCop 標準に統一) - .editorconfig に命名規則・StyleCop 診断設定を追加 - private フィールドの _camelCase プレフィックス強制 - file-scoped namespace の強制 - CSharpier を dotnet local tool として登録 (.config/dotnet-tools.json) - CONTRIBUTING.md のメンバー順序規約を StyleCop SA1201 標準に更新 - GitHub Actions lint ワークフローを追加 (.github/workflows/lint.yml) - CSharpier フォーマットチェック - StyleCop アナライザーによるビルドチェック https://claude.ai/code/session_017NQxLFbtXNm8ktmUoydMad
StyleCop SA1201 の標準順序(Fields → Constructors → Properties → Methods)に 合わせて以下のファイルのメンバー順序を修正: - Promete/Angle.cs - Promete/Rect.cs - Promete/RectInt.cs - Promete/Graphics/FrameBuffer.cs - Promete/Graphics/FrameBufferManager.cs https://claude.ai/code/session_017NQxLFbtXNm8ktmUoydMad
- オールマンスタイルから K&R スタイル(開き括弧を同一行)へ移行 - CSharpier によるフォーマット自動化の手順を CONTRIBUTING.md に記載 - 既存コードは `dotnet csharpier .` で一括整形が必要 https://claude.ai/code/session_017NQxLFbtXNm8ktmUoydMad
StyleCop SA1201 の標準順序(Fields → Constructors → Properties → Methods)に 合わせて以下のファイルのメンバー順序を修正: - Promete/Coroutines/Coroutine.cs - Promete/Graphics/Fonts/Font.cs - Promete/Input/KeyEventArgs.cs - Promete/Input/KeyPressEventArgs.cs - Promete/Nodes/MaskedContainer.cs - Promete/Windowing/CompatibleWindow.cs - Promete/Windowing/Headless/DummyInputContext.cs - Promete/Windowing/Headless/HeadlessWindow.cs - Promete/Backends/GL/OpenGLDesktopGameView.cs - Promete/Backends/Headless/HeadlessGameView.cs - Promete/Backends/SilkNetCommon/SilkNetCommonTimeProvider.cs - Promete.ImGui/ImGuiPlugin.cs - Promete.MeltySynth/MeltySynthAudioSource.cs https://claude.ai/code/session_017NQxLFbtXNm8ktmUoydMad
- Promete/Graphics/FrameBuffer.cs - Promete/Nodes/Container.cs https://claude.ai/code/session_017NQxLFbtXNm8ktmUoydMad
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://claude.ai/code/session_017NQxLFbtXNm8ktmUoydMad