|
15 | 15 | - "*.md" |
16 | 16 |
|
17 | 17 | jobs: |
18 | | - build: |
| 18 | + ci: |
19 | 19 | runs-on: ${{ matrix.os }} |
20 | 20 | strategy: |
21 | 21 | matrix: |
22 | 22 | os: [ubuntu-latest, windows-latest, macos-latest] |
23 | 23 |
|
24 | | - env: |
25 | | - DATABASE_URL: "postgresql://opencut:opencut@localhost:5432/opencut" |
26 | | - BETTER_AUTH_SECRET: "supersecret" |
27 | | - NEXT_PUBLIC_SITE_URL: "http://localhost:3000" |
28 | | - UPSTASH_REDIS_REST_URL: "https://your-upstash-redis-url" |
29 | | - UPSTASH_REDIS_REST_TOKEN: "your-upstash-redis-token" |
30 | | - NEXT_PUBLIC_MARBLE_API_URL: "https://placeholder.example.com" |
31 | | - MARBLE_WORKSPACE_KEY: "placeholder" |
32 | | - FREESOUND_CLIENT_ID: "placeholder" |
33 | | - FREESOUND_API_KEY: "placeholder" |
34 | | - |
35 | 24 | steps: |
36 | 25 | - name: Checkout repository |
37 | 26 | uses: actions/checkout@v4 |
38 | | - |
39 | | - - name: Install Rust wasm target |
40 | | - run: rustup target add wasm32-unknown-unknown |
41 | | - |
42 | | - - name: Install wasm-pack |
43 | | - uses: jetli/wasm-pack-action@v0.4.0 |
44 | 27 | with: |
45 | | - version: latest |
46 | | - |
47 | | - - name: Cache Rust build artifacts |
48 | | - uses: actions/cache@v4 |
49 | | - with: |
50 | | - path: | |
51 | | - ~/.cargo/registry |
52 | | - ~/.cargo/git |
53 | | - target |
54 | | - key: ${{ runner.os }}-cargo-${{ hashFiles('Cargo.lock') }} |
55 | | - |
56 | | - - name: Build WASM |
57 | | - run: wasm-pack build rust/wasm --target bundler --out-dir pkg |
| 28 | + fetch-depth: 0 |
58 | 29 |
|
59 | | - - name: Install Bun |
60 | | - uses: oven-sh/setup-bun@735343b667d3e6f658f44d0eca948eb6282f2b76 |
| 30 | + - name: Setup toolchain |
| 31 | + uses: moonrepo/setup-toolchain@v0 |
61 | 32 | with: |
62 | | - bun-version: 1.2.18 |
63 | | - |
64 | | - - name: Cache Bun modules |
65 | | - uses: actions/cache@v4 |
66 | | - with: |
67 | | - path: ~/.bun/install/cache |
68 | | - key: ${{ runner.os }}-bun-1.2.18-${{ hashFiles('apps/web/bun.lock') }} |
69 | | - |
70 | | - - name: Install dependencies |
71 | | - working-directory: apps/web |
72 | | - run: bun install |
73 | | - |
74 | | - - name: Build |
75 | | - working-directory: apps/web |
76 | | - run: bun run build |
| 33 | + auto-install: true |
| 34 | + auto-setup: true |
77 | 35 |
|
78 | | - - name: Run tests |
79 | | - working-directory: apps/web |
80 | | - run: echo "No tests implemented yet" |
81 | | - continue-on-error: true |
| 36 | + - name: Run CI |
| 37 | + run: moon ci |
0 commit comments