-
Notifications
You must be signed in to change notification settings - Fork 1
Release 3.3 Build 63 #207
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Release 3.3 Build 63 #207
Conversation
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
Comment on lines
12
to
65
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| fetch-depth: 0 | ||
|
|
||
| - name: Install SwiftLint | ||
| run: | | ||
| # Download and install SwiftLint using the correct URL for Linux AMD64 | ||
| SWIFTLINT_VERSION="0.61.0" | ||
| echo "Installing SwiftLint $SWIFTLINT_VERSION..." | ||
|
|
||
| curl -L -o swiftlint.zip "https://github.com/realm/SwiftLint/releases/download/${SWIFTLINT_VERSION}/swiftlint_linux_amd64.zip" | ||
| unzip swiftlint.zip | ||
| chmod +x swiftlint | ||
| sudo mv swiftlint /usr/local/bin/ | ||
|
|
||
| # Verify installation | ||
| echo "SwiftLint installed successfully:" | ||
| swiftlint version | ||
|
|
||
| - name: Run SwiftLint | ||
| run: | | ||
| # Get list of changed Swift files in specific folders, properly handling spaces | ||
| echo "🔍 Collecting Swift files to lint..." | ||
|
|
||
| # Collect all Swift files to lint | ||
| files_to_lint="" | ||
| file_count=0 | ||
|
|
||
| # Use git diff to get changed files, handling spaces with null-termination | ||
| # Filter for Swift files only in the specified directories | ||
| while IFS= read -r -d '' file; do | ||
| if [ -f "$file" ]; then | ||
| files_to_lint="$files_to_lint\"$file\" " | ||
| file_count=$((file_count + 1)) | ||
| fi | ||
| done < <(git diff --name-only --diff-filter=ACM origin/${{ github.base_ref }}...HEAD -z | \ | ||
| grep -z '\.swift$' | \ | ||
| grep -zE '^(Eatery Blue/|EateryGetAPI/|EateryModel/)') | ||
|
|
||
| echo "📝 Found $file_count Swift files to lint" | ||
|
|
||
| if [ $file_count -eq 0 ]; then | ||
| echo "✅ No Swift files to lint in the specified directories" | ||
| exit 0 | ||
| fi | ||
|
|
||
| echo "" | ||
| echo "🚀 Running SwiftLint on all files..." | ||
| echo "" | ||
|
|
||
| # Run SwiftLint on all files at once with clean output | ||
| eval "swiftlint lint --strict --quiet --config .swiftlint.yml $files_to_lint" |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions
Actions job or workflow does not limit the permissions of the GITHUB_TOKEN. Consider setting an explicit permissions block, using the following as a minimal starting point: {{contents: read}}
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.
No description provided.