Skip to content
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
31 changes: 13 additions & 18 deletions .github/workflows/deploy-web.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,31 +3,26 @@ on:
push:
branches: [main]

permissions:
contents: write

jobs:
build:
name: Build Web
env:
my_secret: ${{secrets.commit_secret}}
name: Build and deploy web example
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: subosito/flutter-action@v1
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
channel: "stable"
- run: flutter config --enable-web
- run: flutter clean
- run: flutter pub get
- run: |
- name: Build example web app
run: |
dart compile js ./web/e2ee.worker.dart -o ./example/web/e2ee.worker.dart.js
cd example
flutter build web --release --base-href /client-sdk-flutter/
cd build/web
git init
git config --global user.email duanweiwei1982@gmail.com
git config --global user.name cloudwebrtc
git status
git remote add origin https://${{secrets.commit_secret}}@github.com/livekit/client-sdk-flutter.git
git checkout -b gh-pages
git add --all
git commit -m "update"
git push origin gh-pages -f
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./example/build/web
27 changes: 27 additions & 0 deletions .github/workflows/publish-docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Publish docs
on:
push:
branches: [main]
workflow_dispatch:

permissions:
contents: read

jobs:
publish-docs:
name: Publish docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
channel: "stable"
- run: flutter pub get
- name: Generate dartdoc
run: dart doc
- name: Upload to S3
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DOCS_DEPLOY_AWS_ACCESS_KEY }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DOCS_DEPLOY_AWS_API_SECRET }}
AWS_DEFAULT_REGION: "us-east-1"
run: aws s3 cp doc/api/ s3://${{ secrets.DOCS_DEPLOY_BUCKET }}/client-sdk-flutter/ --recursive