Skip to content
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

ci: update workflows #926

Merged
merged 3 commits into from
Nov 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Every request must be reviewed and accepted by:

* @halildurmus
50 changes: 32 additions & 18 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,43 @@
'ci':
ci:
- changed-files:
- any-glob-to-any-file:
- .github/**
- codecov.yml
- any-glob-to-any-file:
- .github/**
- cliff.toml
- codecov.yml
- lefthook.yml

'docs':
documentation:
- changed-files:
- any-glob-to-any-file:
- packages/win32/doc/*
- website/docs/**
- CONTRIBUTING.md
- README.md
- any-glob-to-any-file:
- packages/win32/doc/*
- website/docs/**
- CONTRIBUTING.md
- PUBLISHING.md
- README.md

'examples':
example:
- changed-files:
- any-glob-to-any-file: examples/**
- any-glob-to-any-file: examples/**

'p: generator':
'external dependency':
- head-branch: [^dependabot]

'package: generator':
- changed-files:
- any-glob-to-any-file: packages/generator/**

'package: win32':
- changed-files:
- any-glob-to-any-file: packages/generator/**
- any-glob-to-any-file: packages/win32/**

release:
- head-branch: [^release, release]

'p: win32':
test:
- changed-files:
- any-glob-to-any-file: packages/win32/**
- any-glob-to-all-files:
- test/**

'website':
website:
- changed-files:
- any-glob-to-any-file: website/**
- any-glob-to-any-file: website/**
15 changes: 15 additions & 0 deletions .github/labels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
- name: com
color: '8C9FDB'
description: Issue with COM support

- name: 'package: generator'
color: '2FE436'
description: Issue with package:generator

- name: 'package: win32'
color: '2FE436'
description: Issue with package:win32

- name: website
color: '006b75'
description: Issue with https://win32.pub
24 changes: 12 additions & 12 deletions .github/workflows/code_generation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,25 @@ name: Check Code Generation

on:
pull_request:
branches: [main]
paths:
- '.github/workflows/code_generation.yml'
- 'packages/generator/bin/**'
- 'packages/generator/lib/**'
- 'packages/generator/analysis_options.yaml'
- 'packages/generator/pubspec.yaml'
- .github/workflows/code_generation.yml
- packages/generator/bin/**
- packages/generator/lib/**
- packages/generator/pubspec.yaml
- tools/generate.cmd
push:
branches: [main]
paths:
- '.github/workflows/code_generation.yml'
- 'packages/generator/bin/**'
- 'packages/generator/lib/**'
- 'packages/generator/analysis_options.yaml'
- 'packages/generator/pubspec.yaml'
- .github/workflows/code_generation.yml
- packages/generator/bin/**
- packages/generator/lib/**
- packages/generator/pubspec.yaml
- tools/generate.cmd

jobs:
check_generation:
build:
runs-on: windows-2019

steps:
- name: 📚 Git Checkout
uses: actions/checkout@v4
Expand Down
51 changes: 26 additions & 25 deletions .github/workflows/dart_examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,42 @@ name: Dart Examples

on:
pull_request:
branches: [main]
paths:
- '.github/workflows/dart_examples.yml'
- 'analysis_options.yaml'
- 'pubspec.yaml'
- 'examples/manifest/**'
- 'examples/notepad/**'
- 'examples/shell_notify_icon/**'
- 'examples/tetris/**'
- 'examples/*.dart'
- 'packages/win32/lib/**'
- 'packages/win32/analysis_options.yaml'
- 'packages/win32/pubspec.yaml'
- .github/workflows/dart_examples.yml
- analysis_options.yaml
- pubspec.yaml
- examples/com_interop/*
- examples/manifest/**
- examples/notepad/**
- examples/shell_notify_icon/**
- examples/tetris/**
- examples/*.dart
- packages/win32/lib/**
- packages/win32/analysis_options.yaml
- packages/win32/pubspec.yaml
push:
branches: [main]
paths:
- '.github/workflows/dart_examples.yml'
- 'analysis_options.yaml'
- 'pubspec.yaml'
- 'examples/manifest/**'
- 'examples/notepad/**'
- 'examples/shell_notify_icon/**'
- 'examples/tetris/**'
- 'examples/*.dart'
- 'packages/win32/lib/**'
- 'packages/win32/analysis_options.yaml'
- 'packages/win32/pubspec.yaml'
- .github/workflows/dart_examples.yml
- analysis_options.yaml
- pubspec.yaml
- examples/com_interop/*
- examples/manifest/**
- examples/notepad/**
- examples/shell_notify_icon/**
- examples/tetris/**
- examples/*.dart
- packages/win32/lib/**
- packages/win32/analysis_options.yaml
- packages/win32/pubspec.yaml

jobs:
build:
uses: halildurmus/workflows/.github/workflows/dart_package.yml@main
uses: halildurmus/workflows/.github/workflows/dart.yml@main
with:
# Exclude the 'explorer', 'service_manager_cli', and 'task_manager'
# directories when analyzing and formatting the Dart files. They are
# analyzed and formatted in their own workflows below.
# analyzed and formatted in their own workflows.
analyze_directories: $(find . -type f -not \( -path .*explorer/* -prune \) -not \( -path .*service_manager_cli/* -prune \) -not \( -path .*task_manager/* -prune \) -name '*.dart' -print)
format_directories: $(find . -type f -not \( -path .*explorer/* -prune \) -not \( -path .*service_manager_cli/* -prune \) -not \( -path .*task_manager/* -prune \) -name '*.dart' -print)
run_tests: false
Expand Down
45 changes: 23 additions & 22 deletions .github/workflows/dart_package_examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,31 +2,30 @@ name: Dart Package Examples

on:
pull_request:
branches: [main]
paths:
- '.github/workflows/dart_package_examples.yml'
- 'analysis_options.yaml'
- 'pubspec.yaml'
- 'examples/service_manager_cli/bin/**'
- 'examples/service_manager_cli/lib/**'
- 'examples/service_manager_cli/analysis_options.yaml'
- 'examples/service_manager_cli/pubspec.yaml'
- 'packages/win32/lib/**'
- 'packages/win32/analysis_options.yaml'
- 'packages/win32/pubspec.yaml'
- .github/workflows/dart_package_examples.yml
- analysis_options.yaml
- pubspec.yaml
- examples/service_manager_cli/bin/**
- examples/service_manager_cli/lib/**
- examples/service_manager_cli/analysis_options.yaml
- examples/service_manager_cli/pubspec.yaml
- packages/win32/lib/**
- packages/win32/analysis_options.yaml
- packages/win32/pubspec.yaml
push:
branches: [main]
paths:
- '.github/workflows/dart_package_examples.yml'
- 'analysis_options.yaml'
- 'pubspec.yaml'
- 'examples/service_manager_cli/bin/**'
- 'examples/service_manager_cli/lib/**'
- 'examples/service_manager_cli/analysis_options.yaml'
- 'examples/service_manager_cli/pubspec.yaml'
- 'packages/win32/lib/**'
- 'packages/win32/analysis_options.yaml'
- 'packages/win32/pubspec.yaml'
- .github/workflows/dart_package_examples.yml
- analysis_options.yaml
- pubspec.yaml
- examples/service_manager_cli/bin/**
- examples/service_manager_cli/lib/**
- examples/service_manager_cli/analysis_options.yaml
- examples/service_manager_cli/pubspec.yaml
- packages/win32/lib/**
- packages/win32/analysis_options.yaml
- packages/win32/pubspec.yaml

jobs:
build:
Expand All @@ -35,7 +34,9 @@ jobs:
example:
- service_manager_cli

uses: halildurmus/workflows/.github/workflows/dart_package.yml@main
uses: halildurmus/workflows/.github/workflows/dart.yml@main
with:
analyze_directories: bin lib
format_directories: bin lib
run_tests: false
working_directory: examples/${{ matrix.example }}
53 changes: 27 additions & 26 deletions .github/workflows/flutter_examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,34 @@ name: Flutter Examples

on:
pull_request:
branches: [main]
paths:
- '.github/workflows/flutter_examples.yml'
- 'analysis_options.yaml'
- 'pubspec.yaml'
- 'examples/explorer/lib/**'
- 'examples/explorer/analysis_options.yaml'
- 'examples/explorer/pubspec.yaml'
- 'examples/task_manager/lib/**'
- 'examples/task_manager/analysis_options.yaml'
- 'examples/task_manager/pubspec.yaml'
- 'packages/win32/lib/**'
- 'packages/win32/analysis_options.yaml'
- 'packages/win32/pubspec.yaml'
- .github/workflows/flutter_examples.yml
- analysis_options.yaml
- pubspec.yaml
- examples/explorer/lib/**
- examples/explorer/analysis_options.yaml
- examples/explorer/pubspec.yaml
- examples/task_manager/lib/**
- examples/task_manager/analysis_options.yaml
- examples/task_manager/pubspec.yaml
- packages/win32/lib/**
- packages/win32/analysis_options.yaml
- packages/win32/pubspec.yaml
push:
branches: [main]
paths:
- '.github/workflows/flutter_examples.yml'
- 'analysis_options.yaml'
- 'pubspec.yaml'
- 'examples/explorer/lib/**'
- 'examples/explorer/analysis_options.yaml'
- 'examples/explorer/pubspec.yaml'
- 'examples/task_manager/lib/**'
- 'examples/task_manager/analysis_options.yaml'
- 'examples/task_manager/pubspec.yaml'
- 'packages/win32/lib/**'
- 'packages/win32/analysis_options.yaml'
- 'packages/win32/pubspec.yaml'
- .github/workflows/flutter_examples.yml
- analysis_options.yaml
- pubspec.yaml
- examples/explorer/lib/**
- examples/explorer/analysis_options.yaml
- examples/explorer/pubspec.yaml
- examples/task_manager/lib/**
- examples/task_manager/analysis_options.yaml
- examples/task_manager/pubspec.yaml
- packages/win32/lib/**
- packages/win32/analysis_options.yaml
- packages/win32/pubspec.yaml

jobs:
build:
Expand All @@ -40,7 +39,9 @@ jobs:
- explorer
- task_manager

uses: halildurmus/workflows/.github/workflows/flutter_package.yml@main
uses: halildurmus/workflows/.github/workflows/flutter.yml@main
with:
analyze_directories: lib
format_directories: lib
run_tests: false
working_directory: examples/${{ matrix.example }}
51 changes: 24 additions & 27 deletions .github/workflows/generator.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,30 @@ name: generator

on:
pull_request:
branches: [main]
paths:
- '.github/workflows/generator.yml'
- 'analysis_options.yaml'
- 'codecov.yml'
- 'pubspec.yaml'
- 'packages/generator/bin/**'
- 'packages/generator/example/**'
- 'packages/generator/lib/**'
- 'packages/generator/test/**'
- 'packages/generator/analysis_options.yaml'
- 'packages/generator/pubspec.yaml'
- .github/workflows/generator.yml
- analysis_options.yaml
- codecov.yml
- pubspec.yaml
- packages/generator/bin/**
- packages/generator/example/**
- packages/generator/lib/**
- packages/generator/test/**
- packages/generator/analysis_options.yaml
- packages/generator/pubspec.yaml
push:
branches: [main]
paths:
- '.github/workflows/generator.yml'
- 'analysis_options.yaml'
- 'codecov.yml'
- 'pubspec.yaml'
- 'packages/generator/bin/**'
- 'packages/generator/example/**'
- 'packages/generator/lib/**'
- 'packages/generator/test/**'
- 'packages/generator/analysis_options.yaml'
- 'packages/generator/pubspec.yaml'
schedule:
# Run every day at 4:00 AM UTC.
- cron: '0 4 * * *'
- .github/workflows/generator.yml
- analysis_options.yaml
- codecov.yml
- pubspec.yaml
- packages/generator/bin/**
- packages/generator/example/**
- packages/generator/lib/**
- packages/generator/test/**
- packages/generator/analysis_options.yaml
- packages/generator/pubspec.yaml

jobs:
build:
Expand All @@ -49,13 +45,14 @@ jobs:
- os: windows-2019
sdk: stable

uses: halildurmus/workflows/.github/workflows/dart_package.yml@main
uses: halildurmus/workflows/.github/workflows/dart.yml@main
with:
analyze_directories: bin example lib test
check_coverage: ${{ matrix.sdk == 'main' }}
codecov_flags: generator
dart_sdk: ${{ matrix.sdk }}
run_tests: ${{ matrix.sdk != 'main' }}
format_directories: bin example lib test
runs_on: ${{ matrix.os }}
upload_coverage: ${{ matrix.sdk == 'main' }}
working_directory: packages/generator
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
Loading