Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
73 changes: 73 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: 'Bug Report'
description: 'Report a bug to help us improve Commander'
labels:
- 'kind/bug'
- 'status/need-triage'
body:
- type: 'markdown'
attributes:
value: |-
> [!IMPORTANT]
> Thanks for taking the time to fill out this bug report!
>
> Please search **[existing issues](https://github.com/autohandai/commander/issues)** to see if an issue already exists for the bug you encountered.

- type: 'textarea'
id: 'problem'
attributes:
label: 'What happened?'
description: 'A clear and concise description of what the bug is.'
validations:
required: true

- type: 'textarea'
id: 'expected'
attributes:
label: 'What did you expect to happen?'
validations:
required: true

- type: 'textarea'
id: 'steps'
attributes:
label: 'Steps to reproduce'
description: 'Provide detailed steps to reproduce the issue.'
placeholder: |-
1. Go to '...'
2. Click on '...'
3. Run command '...'
4. See error
validations:
required: true

- type: 'textarea'
id: 'info'
attributes:
label: 'System information'
description: 'Please provide your system information. Include OS version, Commander version, and any relevant environment details.'
value: |-
<details>

```
OS: [e.g., macOS 14.5, Windows 11, Ubuntu 22.04]
Commander Version: [e.g., 1.0.0]
Node Version: [if applicable]
Bun Version: [if applicable]
```

</details>
validations:
required: true

- type: 'textarea'
id: 'logs'
attributes:
label: 'Error logs'
description: 'If applicable, paste any error messages or logs here.'
render: 'shell'

- type: 'textarea'
id: 'additional-context'
attributes:
label: 'Anything else we need to know?'
description: 'Add any other context about the problem here, such as screenshots or configuration files.'
41 changes: 41 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: 'Feature Request'
description: 'Suggest an idea for Commander'
labels:
- 'kind/enhancement'
- 'status/need-triage'
body:
- type: 'markdown'
attributes:
value: |-
> [!IMPORTANT]
> Thanks for taking the time to suggest an enhancement!
>
> Please search **[existing issues](https://github.com/autohandai/commander/issues)** to see if a similar feature has already been requested.

- type: 'textarea'
id: 'feature'
attributes:
label: 'What would you like to be added?'
description: 'A clear and concise description of the enhancement.'
validations:
required: true

- type: 'textarea'
id: 'rationale'
attributes:
label: 'Why is this needed?'
description: 'A clear and concise description of why this enhancement is needed and what problem it solves.'
validations:
required: true

- type: 'textarea'
id: 'alternatives'
attributes:
label: 'Alternative solutions'
description: 'Have you considered any alternative solutions or workarounds?'

- type: 'textarea'
id: 'additional-context'
attributes:
label: 'Additional context'
description: 'Add any other context, screenshots, or examples about the feature request here.'
89 changes: 79 additions & 10 deletions .github/workflows/tauri-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ name: CI
on:
push:
branches: [ main ]
tags: [ 'v*.*.*' ]
pull_request:
branches: [ main ]

jobs:
test:
Expand Down Expand Up @@ -40,12 +40,32 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ macos-13, macos-14, windows-latest ]
os: [ ubuntu-latest, macos-13, macos-14 ]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Determine build metadata
id: metadata
shell: bash
run: |
if [ "${{ github.event_name }}" = "pull_request" ]; then
BUILD_ID="pr${{ github.event.number }}-${{ github.run_attempt }}"
else
BUILD_ID="${{ github.run_number }}"
fi
echo "COMMANDER_BUILD_ID=$BUILD_ID" >> "$GITHUB_ENV"
echo "build_id=$BUILD_ID" >> "$GITHUB_OUTPUT"

- name: Inject build metadata version
id: set_version
shell: bash
run: |
BUILD_VERSION=$(node scripts/ci-set-version.mjs)
echo "BUILD_VERSION=$BUILD_VERSION" >> "$GITHUB_ENV"
echo "build_version=$BUILD_VERSION" >> "$GITHUB_OUTPUT"

- name: Setup Rust
uses: dtolnay/rust-toolchain@stable

Expand All @@ -54,6 +74,13 @@ jobs:
with:
bun-version: latest

- name: Install Linux build dependencies
if: startsWith(matrix.os, 'ubuntu')
run: |
sudo apt-get update
sudo apt-get install -y build-essential curl wget file libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev patchelf pkg-config
sudo apt-get install -y libwebkit2gtk-4.1-dev || sudo apt-get install -y libwebkit2gtk-4.0-dev

- name: Cache cargo registry
uses: actions/cache@v4
with:
Expand All @@ -74,14 +101,56 @@ jobs:
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: tauri-bundles-${{ runner.os }}-${{ runner.arch }}
name: commander-${{ steps.set_version.outputs.build_version }}-${{ matrix.os }}-${{ runner.arch }}
path: src-tauri/target/release/bundle/**

# Optional: signing & notarization (provide secrets to enable)
# env:
# TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
# TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
# APPLE_ID: ${{ secrets.APPLE_ID }}
# APPLE_PASSWORD: ${{ secrets.APPLE_PASSWORD }}
# APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
release:
name: Release artifacts
needs: build
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Compute release version
id: release_version
run: |
BASE_VERSION=$(jq -r '.version' src-tauri/tauri.conf.json)
BASE_VERSION=${BASE_VERSION%%+*}
RELEASE_VERSION="$BASE_VERSION+build.${{ github.run_number }}"
echo "RELEASE_VERSION=$RELEASE_VERSION" >> "$GITHUB_ENV"
echo "release_version=$RELEASE_VERSION" >> "$GITHUB_OUTPUT"

- name: Download artifacts
uses: actions/download-artifact@v4
with:
path: dist

- name: Collect release assets
run: node scripts/collect-release-assets.mjs dist release

- name: Generate checksums
shell: bash
run: |
cd release
shopt -s nullglob
files=(*)
if [ ${#files[@]} -gt 0 ]; then
sha256sum "${files[@]}" > SHA256SUMS.txt
fi

- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
tag_name: v${{ steps.release_version.outputs.release_version }}
name: Commander ${{ steps.release_version.outputs.release_version }}
draft: false
prerelease: false
files: |
release/*
body: |
## Commander ${{ steps.release_version.outputs.release_version }}
- Automated build for macOS (Intel & Apple Silicon) and Linux.
- SHA256 checksums included in `SHA256SUMS.txt`.

Loading
Loading