Skip to content

Commit

Permalink
ci: add validate file encoding and min version update
Browse files Browse the repository at this point in the history
Signed-off-by: Jeremy Andrews <[email protected]>
  • Loading branch information
ABC2015 committed Dec 18, 2024
1 parent fd24348 commit 0417424
Showing 1 changed file with 21 additions and 1 deletion.
22 changes: 21 additions & 1 deletion .github/workflows/validation-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,26 @@ jobs:
echo "✅ All developer-made commit messages follow the convention."
fi
validate-file-encoding:
name: Validate File Encoding
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Validate File Encoding
run: |
echo "Validating file encoding..."
NON_UTF8_FILES=$(find . -type f -exec file -i {} + | grep -v "charset=utf-8" || true)
if [ -n "$NON_UTF8_FILES" ]; then
echo "❌ The following files are not UTF-8 encoded:"
echo "$NON_UTF8_FILES"
exit 1
else
echo "✅ All files are UTF-8 encoded."
fi
validate-dart-sdk-version:
runs-on: ubuntu-latest
steps:
Expand All @@ -100,7 +120,7 @@ jobs:
echo "$PUBSPEC_FILES"
# Define the minimum required Dart SDK version
MINIMUM_VERSION="3.5.4"
MINIMUM_VERSION="3.6.0"
ALL_VALID="true"
# Iterate over each pubspec.yaml file
Expand Down

0 comments on commit 0417424

Please sign in to comment.