alpha.yml 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. name: Alpha CI
  2. on:
  3. push:
  4. branches: [alpha]
  5. env:
  6. CARGO_INCREMENTAL: 0
  7. RUST_BACKTRACE: short
  8. jobs:
  9. release:
  10. strategy:
  11. fail-fast: false
  12. matrix:
  13. os: [windows-latest, ubuntu-latest, macos-latest]
  14. runs-on: ${{ matrix.os }}
  15. if: startsWith(github.repository, 'zzzgydi')
  16. steps:
  17. - name: Checkout repository
  18. uses: actions/checkout@v2
  19. - name: Install Rust
  20. uses: actions-rs/toolchain@v1
  21. with:
  22. toolchain: stable
  23. profile: minimal
  24. override: true
  25. - name: Rust Cache
  26. uses: Swatinem/rust-cache@v2
  27. with:
  28. workspaces: src-tauri
  29. - name: Install Node
  30. uses: actions/setup-node@v1
  31. with:
  32. node-version: 16
  33. - name: Install Dependencies (ubuntu only)
  34. if: matrix.os == 'ubuntu-latest'
  35. run: |
  36. sudo apt-get update
  37. sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf
  38. - name: Get yarn cache dir path
  39. id: yarn-cache-dir-path
  40. run: echo "::set-output name=dir::$(yarn cache dir)"
  41. - name: Yarn Cache
  42. uses: actions/cache@v2
  43. id: yarn-cache
  44. with:
  45. path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
  46. key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
  47. restore-keys: |
  48. ${{ runner.os }}-yarn-
  49. - name: Yarn install and check
  50. run: |
  51. yarn install --network-timeout 1000000
  52. yarn run check
  53. - name: Tauri build
  54. uses: tauri-apps/tauri-action@0
  55. env:
  56. GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
  57. TAURI_PRIVATE_KEY: ${{ secrets.TAURI_PRIVATE_KEY }}
  58. TAURI_KEY_PASSWORD: ${{ secrets.TAURI_KEY_PASSWORD }}
  59. with:
  60. tagName: alpha
  61. releaseName: "Clash Verge Alpha"
  62. releaseBody: "Alpha Version (include debug)"
  63. releaseDraft: false
  64. includeDebug: true
  65. prerelease: true
  66. # - name: Portable Bundle
  67. # if: matrix.os == 'windows-latest'
  68. # run: |
  69. # yarn run portable
  70. # env:
  71. # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}