Update title #357
This file contains 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
name: Main | |
on: | |
push: | |
branches: [main] | |
pull_request: {} | |
jobs: | |
validate-renovate-config: | |
uses: BlindfoldedSurgery/renovate-config/.github/workflows/validate.yml@main | |
check-format: | |
name: Check Format | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out repo | |
uses: actions/checkout@v4 | |
- uses: asdf-vm/actions/install@v3 | |
- name: Check lib formatting | |
run: dart format lib --set-exit-if-changed --output=none | |
lint: | |
name: Lint | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out repo | |
uses: actions/checkout@v4 | |
- uses: asdf-vm/actions/install@v3 | |
- name: Get dependencies | |
run: flutter pub get | |
- name: Run Analysis | |
run: flutter analyze --fatal-infos | |
build: | |
name: Build Web Package | |
runs-on: ubuntu-latest | |
needs: [check-format, lint] | |
steps: | |
- name: Check out repo | |
uses: actions/checkout@v4 | |
- uses: asdf-vm/actions/install@v3 | |
- name: Get dependencies | |
run: flutter pub get | |
- name: Build web package | |
run: flutter build web | |
- name: Store build result | |
uses: actions/upload-artifact@v4 | |
with: | |
name: web-app | |
path: build/web | |
deploy: | |
runs-on: ubuntu-latest | |
needs: build | |
concurrency: production | |
container: rclone/rclone:1.68 | |
steps: | |
- uses: actions/download-artifact@v4 | |
with: | |
name: web-app | |
- name: Save rclone config | |
env: | |
CONFIG: | | |
[r2] | |
type = s3 | |
provider = Cloudflare | |
access_key_id = ${{ secrets.AWS_ACCESS_KEY_ID }} | |
secret_access_key = ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
endpoint = ${{ secrets.S3_ENDPOINT }} | |
run: | | |
mkdir -p /config/rclone | |
echo "$CONFIG" > /config/rclone/rclone.conf | |
- name: Copy web package to bucket | |
run: rclone sync $PWD r2:${{ secrets.S3_BUCKET_NAME }}/ |