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
1 change: 1 addition & 0 deletions examples/localcowork/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
# Text model API endpoint (OpenAI-compatible). Set by start-model.sh.
# Default when using LFM2 via llama-server: http://localhost:8080/v1
# Default when using Ollama: http://localhost:11434/v1
# Default when using LM Studio: http://localhost:1234/v1
# LOCALCOWORK_MODEL_ENDPOINT=http://localhost:8080/v1

# Vision model endpoint (for AI-powered OCR — optional, falls back to Tesseract)
Expand Down
14 changes: 14 additions & 0 deletions examples/localcowork/.git-hooks/pre-commit
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,20 @@ fi

WARNINGS=()

# ── Check 0: Shell scripts pass shellcheck ───────────────────────────────────

for file in $STAGED_FILES; do
case "$file" in
*.sh)
if command -v shellcheck >/dev/null 2>&1; then
if ! shellcheck -s bash "$file" >/dev/null 2>&1; then
WARNINGS+=("shellcheck failed for $file (run: shellcheck -s bash $file)")
fi
fi
;;
esac
done
Comment on lines +33 to +43
Copy link

Copilot AI Mar 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Iterating with for file in $STAGED_FILES will break on filenames containing whitespace/globs due to word-splitting. Treat staged files as a newline-delimited list (read loop) or an array, and consider running shellcheck against the staged blob (not the working tree) so the hook validates exactly what will be committed.

Copilot uses AI. Check for mistakes.

# ── Check 1: Source files changed but PROGRESS.yaml not staged ──────────────

HAS_SOURCE_CHANGES=false
Expand Down
20 changes: 20 additions & 0 deletions examples/localcowork/.github/workflows/shellcheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Shellcheck

on:
push:
paths:
- "**.sh"
pull_request:
paths:
- "**.sh"
Comment on lines +1 to +9
Copy link

Copilot AI Mar 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GitHub Actions workflows are only picked up from the repository root at .github/workflows/. Placing this file under examples/localcowork/.github/workflows/ means CI won’t run. Move it to .github/workflows/shellcheck.yml (and keep example-specific docs elsewhere if needed).

Copilot uses AI. Check for mistakes.

jobs:
shellcheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Run shellcheck
uses: ludeeus/action-shellcheck@master
Copy link

Copilot AI Mar 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using an action reference pinned to @master is a supply-chain risk and can lead to nondeterministic CI behavior. Pin to a tagged release (or a full commit SHA) to ensure reproducible and auditable builds.

Suggested change
uses: ludeeus/action-shellcheck@master
uses: ludeeus/action-shellcheck@2.0.0

Copilot uses AI. Check for mistakes.
env:
SHELLCHECK_OPTS: "-s bash -S error"
45 changes: 45 additions & 0 deletions src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
[package]
name = "localcowork"
version = "0.1.0"
description = "LocalCowork — on-device AI agent desktop app"
authors = ["LocalCowork Contributors"]
license = "MIT"
edition = "2021"
rust-version = "1.77"

[build-dependencies]
tauri-build = { version = "2", features = [] }

[dependencies]
tauri = { version = "2", features = ["devtools"] }
tauri-plugin-shell = "2"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
serde_yaml = "0.9"
tokio = { version = "1", features = ["full"] }
anyhow = "1"
thiserror = "2"
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["json", "env-filter"] }
uuid = { version = "1", features = ["v4"] }
chrono = { version = "0.4", features = ["serde"] }
reqwest = { version = "0.12", features = ["json", "stream"] }
rusqlite = { version = "0.32", features = ["bundled"] }
futures = "0.3"
dirs = "6"
sysinfo = "0.33"
sha2 = "0.10"
tauri-plugin-dialog = "2"

[dev-dependencies]
tempfile = "3"

[features]
default = ["custom-protocol"]
custom-protocol = ["tauri/custom-protocol"]

[profile.release]
strip = true
lto = true
codegen-units = 1
panic = "abort"
3 changes: 3 additions & 0 deletions src-tauri/build.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fn main() {
tauri_build::build();
}
15 changes: 15 additions & 0 deletions src-tauri/capabilities/default.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"identifier": "default",
"description": "Default capabilities for LocalCowork",
"windows": ["main"],
"permissions": [
"core:default",
"shell:allow-open",
"shell:allow-execute",
"shell:allow-spawn",
"shell:allow-stdin-write",
"dialog:default",
"dialog:allow-open",
"dialog:allow-save"
]
}
19 changes: 19 additions & 0 deletions src-tauri/entitlements.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
"http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<!-- Allow spawning child processes (Node.js/Python MCP servers) -->
<key>com.apple.security.cs.allow-unsigned-executable-memory</key>
<true/>
<!-- Allow loading external dynamic libraries (Python packages, Node modules) -->
<key>com.apple.security.cs.disable-library-validation</key>
<true/>
<!-- Allow outbound network connections (localhost Ollama API) -->
<key>com.apple.security.network.client</key>
<true/>
<!-- Allow read/write to user-selected files (via open/save dialogs) -->
<key>com.apple.security.files.user-selected.read-write</key>
<true/>
</dict>
</plist>
Binary file added src-tauri/icons/128x128.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src-tauri/icons/128x128@2x.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src-tauri/icons/32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src-tauri/icons/icon.icns
Binary file not shown.
Binary file added src-tauri/icons/icon.ico
Binary file not shown.
3 changes: 3 additions & 0 deletions src-tauri/mcp-servers.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"servers": {}
}
Loading