Upgraded workflow
This commit is contained in:
19
.github/workflows/flutter.yml
vendored
19
.github/workflows/flutter.yml
vendored
@@ -28,8 +28,27 @@ jobs:
|
|||||||
- name: Generate oss_licenses.dart
|
- name: Generate oss_licenses.dart
|
||||||
run: flutter pub run flutter_oss_licenses:generate.dart -o lib/presentation/views/about/licenses/oss_licenses.dart
|
run: flutter pub run flutter_oss_licenses:generate.dart -o lib/presentation/views/about/licenses/oss_licenses.dart
|
||||||
|
|
||||||
|
- name: Check for changes
|
||||||
|
id: check_changes
|
||||||
|
run: |
|
||||||
|
if [[ $(git status --porcelain) ]]; then
|
||||||
|
echo "changes_detected=true" >> $GITHUB_OUTPUT
|
||||||
|
else
|
||||||
|
echo "changes_detected=false" >> $GITHUB_OUTPUT
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: Commit Changes
|
||||||
|
if: steps.check_changes.outputs.changes_detected == 'true'
|
||||||
|
run: |
|
||||||
|
git config --global user.name "GitHub Actions"
|
||||||
|
git config --global user.email "actions@github.com"
|
||||||
|
git add .
|
||||||
|
git commit -m "Actions: Licenses updated [skip ci]"
|
||||||
|
git push
|
||||||
|
|
||||||
lint:
|
lint:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
needs: generate_licenses
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|||||||
Reference in New Issue
Block a user