Skip to content

Commit

Permalink
refactor pipelines
Browse files Browse the repository at this point in the history
  • Loading branch information
tilucasoli committed Jul 24, 2024
1 parent 2a9a7bb commit 85d3ef0
Show file tree
Hide file tree
Showing 3 changed files with 97 additions and 17 deletions.
31 changes: 31 additions & 0 deletions .github/actions/fvm/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: "Setup FVM"
description: "Install and setup FVM"

inputs:
flutter-version:
description: 'Flutter version'
required: false
default: ""

runs:
using: "composite"
steps:
- name: Install FVM
shell: bash
run: |
curl -fsSL https://fvm.app/install.sh | bash
fvm use ${{ inputs.flutter-version }} --force
- uses: kuhnroyal/flutter-fvm-config-action@v2
id: fvm-config-action

- uses: subosito/flutter-action@v2
with:
flutter-version: ${{ steps.fvm-config-action.outputs.FLUTTER_VERSION }}
channel: ${{ steps.fvm-config-action.outputs.FLUTTER_CHANNEL }}

- name: Flutter version
shell: bash
run: flutter --version

34 changes: 17 additions & 17 deletions .github/actions/test/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,24 +54,24 @@ runs:
run: melos run test
shell: bash

- name: Install DCM
if: ${{ inputs.run-dcm }}
uses: CQLabs/setup-dcm@v1
with:
github_token: ${{ inputs.token }}
folders: packages/*/lib
# - name: Install DCM
# if: ${{ inputs.run-dcm }}
# uses: CQLabs/setup-dcm@v1
# with:
# github_token: ${{ inputs.token }}
# folders: packages/*/lib

- name: Run DCM
if: ${{ inputs.run-dcm }}
uses: CQLabs/dcm-action@v1
with:
github_token: ${{ inputs.token }}
ci_key: oss
email: oss
folders: .
fatal_style: true
fatal_performance: true
fatal_warnings: true
# - name: Run DCM
# if: ${{ inputs.run-dcm }}
# uses: CQLabs/dcm-action@v1
# with:
# github_token: ${{ inputs.token }}
# ci_key: oss
# email: oss
# folders: .
# fatal_style: true
# fatal_performance: true
# fatal_warnings: true

- name: Run fixes
run: melos run fix
Expand Down
49 changes: 49 additions & 0 deletions .github/workflows/analyze.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Analyze Workflow

on:
push:
pull_request_target:
branches: [main]
paths-ignore:
- 'scripts/**'
- 'website/**'
- 'assets/**'

jobs:
dcm:
name: DCM
runs-on: ubuntu-latest
steps:
- name: Checkout mix repo
uses: actions/checkout@v4

- name: Setup FVM
uses: ./.github/actions/fvm/

- name: Setup Melos
uses: bluefireteam/melos-action@v3

- name: Run build runner
shell: bash
run: melos run brb

- name: Install DCM
if: ${{ inputs.run-dcm }}
uses: CQLabs/setup-dcm@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
folders: packages/*/lib
ci_key: oss
email: oss
fatal_style: true
fatal_performance: true
fatal_warnings: true

- name: dart analyze
run: melos run --no-select analyze
shell: bash

- name: Run custom_lint
run: melos run custom_lint_analyze
shell: bash

0 comments on commit 85d3ef0

Please sign in to comment.