Merge pull request #149 from WalletConnect/chores/bug_fixes_and_enhan… #50
Workflow file for this run
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: Publish to pub.dev | |
on: | |
workflow_dispatch: | |
push: | |
tags: | |
- 'v[0-9]+.[0-9]+.[0-9]+*' | |
jobs: | |
publish: | |
name: Publish release to pub.dev | |
permissions: | |
id-token: write | |
runs-on: ubuntu-latest | |
steps: | |
# Checkout the repo | |
- uses: actions/checkout@v3 | |
# Setup Dart SDK | |
- uses: dart-lang/setup-dart@v1 | |
# Install Flutter | |
- name: Install Flutter | |
uses: subosito/flutter-action@v2 | |
with: | |
channel: "stable" | |
architecture: x64 | |
# Get package dependencies and generate files | |
- name: Get package dependencies and generate files | |
run: | | |
flutter pub get | |
flutter pub run build_runner build --delete-conflicting-outputs | |
# Get example app dependencies and generate files | |
- name: Get example app dependencies and generate files | |
working-directory: example | |
run: | | |
flutter pub get | |
flutter pub run build_runner build --delete-conflicting-outputs | |
# Check Publish | |
- name: Check Publish Warnings | |
run: flutter pub publish --dry-run | |
# Publish | |
- name: Publish Package | |
run: flutter pub publish -f | |
# Notify | |
- name: Notify Channel | |
uses: slackapi/[email protected] | |
env: | |
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} | |
SLACK_WEBHOOK_TYPE: 'INCOMING_WEBHOOK' | |
with: | |
payload: |- | |
{ | |
"text":"🚀 Web3Modal Flutter *${{ github.ref_name }}* was just published at https://pub.dev/packages/web3modal_flutter" | |
} |