Skip to content
Open
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
63 changes: 63 additions & 0 deletions .github/workflows/build-macos-statusbar.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
name: Build macOS Status Bar

on:
push:
branches: [main]
paths: ['macos-app-source/**']
pull_request:
branches: [main]
paths: ['macos-app-source/**']

jobs:
build-macos-app:
name: Build macOS Status Bar App
runs-on: macos-14
if: contains(github.event.head_commit.message, '[macos]') || github.event_name == 'pull_request'

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Xcode
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '15.4'

- name: Cache Swift packages
uses: actions/cache@v4
with:
path: macos-app-source/.build
key: ${{ runner.os }}-spm-${{ hashFiles('macos-app-source/Package.resolved') }}
restore-keys: ${{ runner.os }}-spm-

- name: Build Swift package
run: |
cd macos-app-source
swift build -c release

- name: Build app bundle
run: |
cd macos-app-source
chmod +x scripts/build_app.sh
./scripts/build_app.sh

- name: Copy app to macos-app directory
run: |
rm -rf macos-app/*
cp -R macos-app-source/dist/* macos-app/

- name: Commit updated app bundle
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add macos-app/
git diff --staged --quiet || git commit -m "Update macOS status bar app bundle [skip ci]"
git push

- name: Upload app artifact
uses: actions/upload-artifact@v4
with:
name: copilot-statusbar-macos-${{ github.sha }}
path: macos-app/
retention-days: 30
13 changes: 13 additions & 0 deletions macos-app-source/.github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# These are supported funding model platforms

github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
53 changes: 53 additions & 0 deletions macos-app-source/.github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
---
name: Bug Report
about: Report a bug or issue with the Copilot Status Bar app
title: '[BUG] '
labels: ['bug']
assignees: ''

---

## πŸ› Bug Description
A clear and concise description of what the bug is.

## πŸ”„ Steps to Reproduce
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

## βœ… Expected Behavior
A clear and concise description of what you expected to happen.

## πŸ“± Actual Behavior
What actually happened instead.

## πŸ–₯️ Environment
- **macOS Version**: [e.g. macOS 14.1 Sonoma]
- **App Version**: [e.g. v1.0.0 - check About in the menu]
- **Copilot API Version**: [if known]

## πŸ“Š Status Information
- **API Status Shown**: [Running/Stopped/Error/Unknown]
- **Actual API Status**: [if you know it's different]
- **Port Being Used**: [default 4141 or custom]

## πŸ“ Console Output
If applicable, paste any relevant console output or error messages:
```
[Paste console output here]
```

## πŸ“Έ Screenshots
If applicable, add screenshots to help explain your problem.

## πŸ” Additional Context
Add any other context about the problem here.

## πŸ₯ Troubleshooting Tried
- [ ] Restarted the app
- [ ] Manually refreshed status
- [ ] Checked System Settings permissions
- [ ] Verified Copilot API is accessible via `curl localhost:4141/v1/models`
- [ ] Other: ___________
38 changes: 38 additions & 0 deletions macos-app-source/.github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
name: Feature Request
about: Suggest a new feature or enhancement
title: '[FEATURE] '
labels: ['enhancement']
assignees: ''

---

## πŸš€ Feature Request

### πŸ’‘ Feature Description
A clear and concise description of the feature you'd like to see added.

### 🎯 Problem or Use Case
What problem does this feature solve? What use case does it enable?

### πŸ”§ Proposed Solution
Describe how you envision this feature working.

### 🎨 UI/UX Considerations
How should this feature integrate with the existing menu/interface?

### πŸ“‹ Alternatives Considered
Describe any alternative solutions or features you've considered.

### 🌟 Priority
How important is this feature to you?
- [ ] Nice to have
- [ ] Would be helpful
- [ ] Important for my workflow
- [ ] Critical/blocking

### πŸ”— Related Issues
Link any related issues or discussions.

### πŸ“ Additional Context
Add any other context, mockups, or examples about the feature request.
143 changes: 143 additions & 0 deletions macos-app-source/.github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,143 @@
name: Build and Release

on:
push:
branches: [ main, develop ]
tags: [ 'v*' ]
pull_request:
branches: [ main ]

env:
PRODUCT_NAME: CopilotStatusBar
APP_DISPLAY_NAME: "Copilot Status Bar"

jobs:
build:
name: Build macOS App
runs-on: macos-14

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Xcode
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '15.4'

- name: Cache Swift packages
uses: actions/cache@v4
with:
path: .build
key: ${{ runner.os }}-spm-${{ hashFiles('Package.resolved') }}
restore-keys: ${{ runner.os }}-spm-

- name: Build Swift package
run: |
swift build -c release

- name: Run tests
run: |
swift test --parallel
continue-on-error: true # Tests optional for now

- name: Build app bundle
run: |
chmod +x scripts/build_app.sh
./scripts/build_app.sh

- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: copilot-status-bar-${{ github.sha }}
path: dist/
retention-days: 30

release:
name: Create Release
needs: build
runs-on: macos-14
if: startsWith(github.ref, 'refs/tags/v')

permissions:
contents: write

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Xcode
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '15.4'

- name: Build release
run: |
chmod +x scripts/build_app.sh
./scripts/build_app.sh

- name: Create DMG (if script exists)
run: |
if [ -f "scripts/create_dmg.sh" ]; then
chmod +x scripts/create_dmg.sh
./scripts/create_dmg.sh
fi
continue-on-error: true

- name: Create ZIP archive
run: |
cd dist
zip -r "Copilot Status Bar.zip" "Copilot Status Bar.app"

- name: Generate changelog
id: changelog
run: |
echo "CHANGELOG<<EOF" >> $GITHUB_OUTPUT
echo "## What's Changed" >> $GITHUB_OUTPUT
git log --pretty=format:"- %s" $(git describe --tags --abbrev=0 HEAD^)..HEAD >> $GITHUB_OUTPUT
echo "" >> $GITHUB_OUTPUT
echo "EOF" >> $GITHUB_OUTPUT

- name: Create Release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref_name }}
release_name: Copilot Status Bar ${{ github.ref_name }}
body: |
${{ steps.changelog.outputs.CHANGELOG }}

## Download
- **Recommended**: Download `Copilot Status Bar.zip` and extract the app
- **Requirements**: macOS 14.0+ (Sonoma or newer)

## Installation
1. Download and extract the ZIP file
2. Move `Copilot Status Bar.app` to your Applications folder
3. Right-click and select "Open" to bypass Gatekeeper (first launch only)
4. Look for the terminal icon in your menu bar

draft: false
prerelease: false

- name: Upload ZIP to release
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./dist/Copilot Status Bar.zip
asset_name: Copilot Status Bar.zip
asset_content_type: application/zip

- name: Upload DMG to release (if exists)
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./dist/Copilot Status Bar.dmg
asset_name: Copilot Status Bar.dmg
asset_content_type: application/octet-stream
continue-on-error: true
Loading