Skip to content

Commit

Permalink
Fix build errors
Browse files Browse the repository at this point in the history
- Fix `package.json` to include missing dependencies
- Fix the error TS6133 by removing unused `React` import
- Update release workflow to handle .dmg file renaming
  • Loading branch information
DrumRobot committed Oct 27, 2024
1 parent 7f3b23c commit 4d3ac22
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 20 deletions.
28 changes: 9 additions & 19 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
with:
profile: minimal
override: true

- name: Add binary sources
run: |
rustup target add aarch64-apple-darwin
Expand Down Expand Up @@ -67,24 +67,14 @@ jobs:
${{ runner.os }}-cargo-build-
- name: Build application
run: npm run tauri build -- universal-apple-darwin

- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: colima-gui-macos
path: src-tauri/target/release/bundle/dmg/*.dmg
if-no-files-found: error
run: npm run tauri build -- --target universal-apple-darwin

release:
runs-on: ubuntu-latest
needs: build

steps:
- name: Download artifact from build
uses: actions/download-artifact@v4
- name: Glob match
uses: tj-actions/glob@v22
id: glob
with:
name: colima-gui-macos
files: |
**/*.dmg
- name: Create release
id: create_release
Expand All @@ -105,6 +95,6 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: src-tauri/target/release/bundle/dmg/*.dmg
asset_name: colima-gui-macos-${{ github.ref }}.dmg
asset_path: ${{ steps.glob.outputs.paths }}
asset_name: colima-gui-macos-${{ github.ref_name }}.dmg
asset_content_type: application/x-apple-diskimage
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
"tauri": "tauri"
},
"dependencies": {
"@emotion/styled": "^11.13.0",
"@mui/material": "^6.1.5",
"@tauri-apps/api": "^1.5.6",
"ansi-to-react": "^6.1.6",
"react": "^17.0.2",
Expand Down
2 changes: 1 addition & 1 deletion src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useState, useEffect, useRef } from 'react';
import { useState, useEffect, useRef } from 'react';
import './App.css';
import { invoke } from '@tauri-apps/api/tauri';
import { listen } from '@tauri-apps/api/event';
Expand Down

0 comments on commit 4d3ac22

Please sign in to comment.