fix fmt #125
This file contains hidden or 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: build | |
| on: | |
| push: | |
| branches: | |
| - master | |
| paths-ignore: | |
| - '**.md' | |
| - '**.png' | |
| - '**cd.yml' | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v1 | |
| - name: Setup toolchain | |
| uses: dtolnay/rust-toolchain@master | |
| with: | |
| toolchain: stable | |
| targets: wasm32-unknown-unknown | |
| components: rust-src | |
| - name: Install webkit2gtk for Tauri | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf | |
| - uses: jetli/wasm-pack-action@v0.4.0 | |
| with: | |
| # Optional version of wasm-pack to install(eg. '0.9.1', 'latest') | |
| version: 'latest' | |
| - uses: jetli/trunk-action@v0.4.0 | |
| with: | |
| # Optional version of trunk to install(eg. 'v0.16.0', 'latest') | |
| version: 'latest' | |
| - name: Build | |
| run: | | |
| cp .env.example .env | |
| cd crates/conduit-wasm && trunk build --public-url=/rust-yew-realworld-example-app/ | |
| - name: cargo fmt & clippy | |
| run: | | |
| cargo fmt --all -- --check | |
| cargo clippy -- --deny=warnings | |
| - name: Run tests | |
| run: | | |
| cd crates/conduit-wasm && wasm-pack test --headless --chrome | |
| - name: Deploy demo | |
| uses: JamesIves/github-pages-deploy-action@v4.2.2 | |
| with: | |
| branch: gh-pages | |
| folder: crates/conduit-wasm/dist | |
| clean: true |