mirror of
https://github.com/ivabus/gui
synced 2025-06-07 15:50:27 +03:00
#109 test tea/action in ci step
This commit is contained in:
parent
777d32b43c
commit
c838041ba4
2 changed files with 28 additions and 56 deletions
82
.github/workflows/ci.yml
vendored
82
.github/workflows/ci.yml
vendored
|
@ -134,45 +134,35 @@ jobs:
|
||||||
# name: linux+aarch64
|
# name: linux+aarch64
|
||||||
container: ${{ matrix.platform.container }}
|
container: ${{ matrix.platform.container }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- uses: pnpm/action-setup@v2
|
|
||||||
with:
|
|
||||||
version: 7
|
|
||||||
- name: setup node
|
|
||||||
uses: actions/setup-node@v1
|
|
||||||
with:
|
|
||||||
node-version: 18
|
|
||||||
cache: 'pnpm'
|
|
||||||
cache-dependency-path: pnpm-lock.yaml
|
|
||||||
- name: install Rust stable
|
|
||||||
uses: actions-rs/toolchain@v1
|
|
||||||
with:
|
|
||||||
toolchain: stable
|
|
||||||
- name: install app dependencies
|
|
||||||
run: pnpm install
|
|
||||||
|
|
||||||
- name: install dependencies (ubuntu only)
|
# will this work on tea? this is not packaged yet?
|
||||||
|
# - name: install dependencies (ubuntu only)
|
||||||
|
# if: matrix.platform.name == 'linux+x86-64'
|
||||||
|
# run: |
|
||||||
|
# sudo apt-get update
|
||||||
|
# sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf pkg-config
|
||||||
|
|
||||||
|
- name: build tauri for MacOS
|
||||||
|
uses: teaxyz/setup@v0
|
||||||
|
if: matrix.platform.name == 'darwin+x86-64' || matrix.platform.name == 'darwin+aarch64'
|
||||||
|
# FROM: https://tauri.app/v1/guides/distribution/sign-macos
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
ENABLE_CODE_SIGNING: ${{ secrets.GUI_APPLE_CERTIFICATE }}
|
||||||
|
APPLE_CERTIFICATE: ${{ secrets.GUI_APPLE_CERTIFICATE }}
|
||||||
|
APPLE_CERTIFICATE_PASSWORD: ${{ secrets.GUI_APPLE_CERTIFICATE_PASSWORD }}
|
||||||
|
APPLE_SIGNING_IDENTITY: ${{ secrets.APPLE_SIGNING_IDENTITY }}
|
||||||
|
APPLE_ID: ${{ secrets.APPLE_ID }}
|
||||||
|
APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
|
||||||
|
with:
|
||||||
|
target: build
|
||||||
|
|
||||||
|
- name: build tauri for Linux
|
||||||
|
uses: teaxyz/setup@v0
|
||||||
if: matrix.platform.name == 'linux+x86-64'
|
if: matrix.platform.name == 'linux+x86-64'
|
||||||
run: |
|
# TODO: https://tauri.app/v1/guides/distribution/sign-linux
|
||||||
sudo apt-get update
|
run: pnpm build:gui
|
||||||
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf pkg-config
|
|
||||||
|
|
||||||
- uses: Swatinem/rust-cache@v2
|
|
||||||
with:
|
|
||||||
# The prefix cache key, this can be changed to start a new cache manually.
|
|
||||||
# default: "v0-rust"
|
|
||||||
prefix-key: ${{ matrix.platform.name }}
|
|
||||||
shared-key: ci
|
|
||||||
cache-targets: false
|
|
||||||
|
|
||||||
- name: Cache Tauri Target
|
|
||||||
uses: actions/cache@v3
|
|
||||||
with:
|
|
||||||
path: |
|
|
||||||
./modules/gui/src-tauri/target
|
|
||||||
key: ${{ matrix.platform.name }}-build-target
|
|
||||||
restore-keys: |
|
|
||||||
${{ matrix.platform.name }}-build-target
|
|
||||||
|
|
||||||
- name: build platform output
|
- name: build platform output
|
||||||
id: build_platform
|
id: build_platform
|
||||||
|
@ -187,24 +177,6 @@ jobs:
|
||||||
echo "build_platform=$BUILD_PLATFORM" >> $GITHUB_OUTPUT
|
echo "build_platform=$BUILD_PLATFORM" >> $GITHUB_OUTPUT
|
||||||
echo "extension=$EXTENSION" >> $GITHUB_OUTPUT
|
echo "extension=$EXTENSION" >> $GITHUB_OUTPUT
|
||||||
|
|
||||||
- name: test build tauri for MacOS
|
|
||||||
if: matrix.platform.name == 'darwin+x86-64' || matrix.platform.name == 'darwin+aarch64'
|
|
||||||
# FROM: https://tauri.app/v1/guides/distribution/sign-macos
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
ENABLE_CODE_SIGNING: ${{ secrets.GUI_APPLE_CERTIFICATE }}
|
|
||||||
APPLE_CERTIFICATE: ${{ secrets.GUI_APPLE_CERTIFICATE }}
|
|
||||||
APPLE_CERTIFICATE_PASSWORD: ${{ secrets.GUI_APPLE_CERTIFICATE_PASSWORD }}
|
|
||||||
APPLE_SIGNING_IDENTITY: ${{ secrets.APPLE_SIGNING_IDENTITY }}
|
|
||||||
APPLE_ID: ${{ secrets.APPLE_ID }}
|
|
||||||
APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
|
|
||||||
run: pnpm build:gui
|
|
||||||
|
|
||||||
- name: test build tauri for Linux
|
|
||||||
if: matrix.platform.name == 'linux+x86-64'
|
|
||||||
# TODO: https://tauri.app/v1/guides/distribution/sign-linux
|
|
||||||
run: pnpm build:gui
|
|
||||||
|
|
||||||
- name: zip .app for MacOS
|
- name: zip .app for MacOS
|
||||||
if: matrix.platform.name == 'darwin+x86-64' || matrix.platform.name == 'darwin+aarch64'
|
if: matrix.platform.name == 'darwin+x86-64' || matrix.platform.name == 'darwin+aarch64'
|
||||||
run: |
|
run: |
|
||||||
|
|
|
@ -3,7 +3,7 @@ import Fuse from 'fuse.js';
|
||||||
|
|
||||||
import type { Package, Review, AirtablePost } from '@tea/ui/types';
|
import type { Package, Review, AirtablePost } from '@tea/ui/types';
|
||||||
import type { GUIPackage } from '$libs/types';
|
import type { GUIPackage } from '$libs/types';
|
||||||
// TODO: figure out a better structure for managing states maybe turn them into separate files?
|
|
||||||
|
|
||||||
import { getPackages, getFeaturedPackages, getPackageReviews, getAllPosts } from '@api';
|
import { getPackages, getFeaturedPackages, getPackageReviews, getAllPosts } from '@api';
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue