Formatting check in test workflow - #9
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR introduces a formatting check to the GitHub Actions test workflow to ensure code consistency. The changes include formatting adjustments to Swift source files and package configuration, along with adding automated formatting validation.
- Adds a new formatting job to the GitHub Actions workflow that runs
swift formatand checks for formatting differences - Applies code formatting fixes to existing Swift source files and Package.swift
- Creates a shell script to handle the formatting process
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| Sources/MemberwiseInitializerMacros/MemberwiseInitializerMacro.swift | Reformats long lines by breaking them across multiple lines for better readability |
| Sources/MemberwiseInitializer/MemberwiseInitializer.swift | Splits macro declaration across multiple lines |
| Package.swift | Adds trailing commas to dependency and target arrays for consistency |
| .github/workflows/test.yml | Adds new formatting job that validates code formatting |
| .github/format.sh | Creates shell script to run swift format recursively |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
| #!/bin/sh | ||
| set -e | ||
|
|
||
| cd .. |
There was a problem hiding this comment.
The script changes to the parent directory with cd .., but this will likely navigate outside the repository root when executed from .github/. This should be cd "$(dirname "$0")/.." to properly navigate to the repository root relative to the script's location.
| cd .. | |
| cd "$(dirname "$0")/.." |
No description provided.