Skip to content

2751 ability to export sqlite database on android #2339

2751 ability to export sqlite database on android

2751 ability to export sqlite database on android #2339

name: Bundle size diff
on:
pull_request:
paths:
- "client/**"
jobs:
build-base:
name: Build base
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
ref: ${{ github.base_ref }}
- name: Install dependencies
run: cd ./client && rm -rf node_modules && yarn install --frozen-lockfile
env:
NODE_AUTH_TOKEN: ${{secrets.TOKEN_REPO}}
- name: Build
run: cd ./client && yarn build-stats
- name: Upload base stats.json
uses: actions/upload-artifact@v2
with:
name: base
path: ./client/packages/host/dist/stats.json
retention-days: 3
build-pr:
name: Build PR
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install dependencies
run: cd ./client && rm -rf node_modules && yarn install --frozen-lockfile
env:
NODE_AUTH_TOKEN: ${{secrets.TOKEN_REPO}}
- name: Build
run: cd ./client && yarn build-stats
- name: Upload base stats.json
uses: actions/upload-artifact@v2
with:
name: pr
path: ./client/packages/host/dist/stats.json
retention-days: 3
report:
name: Generate report
runs-on: ubuntu-latest
needs: [build-base, build-pr]
steps:
- name: Checkout PR
uses: actions/checkout@v2
- name: Download base stats
uses: actions/download-artifact@v2
with:
name: base
path: base
- name: Download PR stats
uses: actions/download-artifact@v2
with:
name: pr
path: pr
- name: Get diff
id: get-diff
uses: NejcZdovc/bundle-size-diff@v1
with:
base_path: "./base/stats.json"
pr_path: "./pr/stats.json"
- name: Comment
uses: NejcZdovc/comment-pr@v1
with:
file: "comment.md"
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
OLD: ${{steps.get-diff.outputs.base_file_string}}
NEW: ${{steps.get-diff.outputs.pr_file_string}}
DIFF: ${{steps.get-diff.outputs.diff_file_string}}
DIFF_PERCENT: ${{steps.get-diff.outputs.percent}}