diff --git a/.github/workflows/desktop.yml b/.github/workflows/desktop.yml new file mode 100644 index 00000000..c5940d8b --- /dev/null +++ b/.github/workflows/desktop.yml @@ -0,0 +1,385 @@ +name: Desktop app + +# The CraftBot desktop app in desktop/ (Rust + Tauri), built on the +# launcher's core (launcher/core/). +# +# On pushes and pull requests: test and build it on every platform it ships +# for. On a v* tag: build the installers, sign them where the signing +# secrets exist (the same ones the Release workflow uses for the setup +# window), and attach them to that tag's release once the Release workflow +# has published it. It runs apart from Release so a failure here never holds +# up the rest of a release. + +on: + push: + # Branch pushes need naming as soon as tags are: with tags alone, GitHub + # runs the workflow for tags only. Paths are not checked for tags. + branches: + - "**" + tags: + - "v*" + paths: + - "desktop/**" + - "launcher/core/**" + - ".cargo/config.toml" + - "app/provision/python_downloads.json" + - ".github/workflows/desktop.yml" + pull_request: + paths: + - "desktop/**" + - "launcher/core/**" + - ".cargo/config.toml" + - "app/provision/python_downloads.json" + - ".github/workflows/desktop.yml" + workflow_dispatch: + +permissions: + contents: write + +env: + CARGO_TERM_COLOR: always + TAURI_CLI: "@tauri-apps/cli@2.12.6" + # The CraftBot release the app installs (launcher/core/build.rs). + CRAFTBOT_VERSION: ${{ startsWith(github.ref, 'refs/tags/v') && github.ref_name || '' }} + +jobs: + linux: + name: Linux ${{ matrix.arch }} + # The oldest Ubuntu with WebKitGTK 4.1: packages built here install on + # it and everything newer. + runs-on: ${{ matrix.runner }} + strategy: + fail-fast: false + matrix: + include: + - arch: x86_64 + runner: ubuntu-22.04 + - arch: aarch64 + runner: ubuntu-22.04-arm + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Build prerequisites + run: | + sudo apt-get update + sudo apt-get install -y libwebkit2gtk-4.1-dev libayatana-appindicator3-dev \ + librsvg2-dev libxdo-dev libssl-dev file patchelf + + - name: Set up Rust + uses: dtolnay/rust-toolchain@stable + with: + components: rustfmt, clippy + + - name: Cache cargo + uses: Swatinem/rust-cache@v2 + with: + workspaces: desktop + prefix-key: desktop-${{ matrix.runner }} + + - name: Lint + working-directory: desktop + run: | + cargo fmt -- --check + cargo clippy --release --all-targets -- -D warnings + + - name: Set up Node (Tauri CLI) + uses: actions/setup-node@v4 + with: + node-version: 22 + + - name: Test + working-directory: desktop + run: cargo test --release + + - name: Build + working-directory: desktop + run: | + set -euo pipefail + version="${CRAFTBOT_VERSION#v}" + config="{\"version\":\"${version:-0.1.0}\"}" + npx --yes "$TAURI_CLI" build --bundles deb rpm appimage --config "$config" + + - name: Package + run: | + set -euo pipefail + mkdir -p dist + b=desktop/target/release/bundle + cp "$b"/deb/*.deb "dist/CraftBot-linux-${{ matrix.arch }}.deb" + cp "$b"/rpm/*.rpm "dist/CraftBot-linux-${{ matrix.arch }}.rpm" + cp "$b"/appimage/*.AppImage "dist/CraftBot-linux-${{ matrix.arch }}.AppImage" + ls -la dist/ + + - name: Upload + uses: actions/upload-artifact@v4 + with: + name: desktop-linux-${{ matrix.arch }} + path: dist/* + + windows: + name: Windows + runs-on: windows-latest + outputs: + signed: ${{ steps.sign-state.outputs.signed }} + env: + HAS_SIGNING: ${{ secrets.AZURE_TENANT_ID != '' && secrets.AZURE_CLIENT_ID != '' && secrets.AZURE_CLIENT_SECRET != '' && secrets.TRUSTED_SIGNING_ENDPOINT != '' && secrets.TRUSTED_SIGNING_ACCOUNT != '' && secrets.TRUSTED_SIGNING_PROFILE != '' }} + defaults: + run: + shell: bash + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Set up Rust + uses: dtolnay/rust-toolchain@stable + + - name: Cache cargo + uses: Swatinem/rust-cache@v2 + with: + workspaces: desktop + prefix-key: desktop-windows-latest + + - name: Set up Node (Tauri CLI) + uses: actions/setup-node@v4 + with: + node-version: 22 + + - name: Test + working-directory: desktop + run: cargo test --release + + - name: Version + run: | + version="${CRAFTBOT_VERSION#v}" + echo "APP_CONFIG={\"version\":\"${version:-0.1.0}\"}" >> "$GITHUB_ENV" + + # The app is signed before it is packed into the installer, and the + # installer after: Smart App Control checks both. + - name: Build + working-directory: desktop + run: npx --yes "$TAURI_CLI" build --no-bundle --config "$APP_CONFIG" + + - name: Sign the app + if: env.HAS_SIGNING == 'true' && startsWith(github.ref, 'refs/tags/v') + uses: azure/artifact-signing-action@v2 + with: + azure-tenant-id: ${{ secrets.AZURE_TENANT_ID }} + azure-client-id: ${{ secrets.AZURE_CLIENT_ID }} + azure-client-secret: ${{ secrets.AZURE_CLIENT_SECRET }} + endpoint: ${{ secrets.TRUSTED_SIGNING_ENDPOINT }} + signing-account-name: ${{ secrets.TRUSTED_SIGNING_ACCOUNT }} + certificate-profile-name: ${{ secrets.TRUSTED_SIGNING_PROFILE }} + files: ${{ github.workspace }}\desktop\target\release\craftbot-desktop.exe + file-digest: SHA256 + timestamp-rfc3161: http://timestamp.acs.microsoft.com + timestamp-digest: SHA256 + + - name: Bundle + working-directory: desktop + run: npx --yes "$TAURI_CLI" bundle --bundles nsis --config "$APP_CONFIG" + + - name: Package + run: | + set -euo pipefail + mkdir -p dist + cp desktop/target/release/bundle/nsis/*-setup.exe dist/CraftBot-windows-setup.exe + ls -la dist/ + + - name: Sign the installer + if: env.HAS_SIGNING == 'true' && startsWith(github.ref, 'refs/tags/v') + uses: azure/artifact-signing-action@v2 + with: + azure-tenant-id: ${{ secrets.AZURE_TENANT_ID }} + azure-client-id: ${{ secrets.AZURE_CLIENT_ID }} + azure-client-secret: ${{ secrets.AZURE_CLIENT_SECRET }} + endpoint: ${{ secrets.TRUSTED_SIGNING_ENDPOINT }} + signing-account-name: ${{ secrets.TRUSTED_SIGNING_ACCOUNT }} + certificate-profile-name: ${{ secrets.TRUSTED_SIGNING_PROFILE }} + files: ${{ github.workspace }}\dist\CraftBot-windows-setup.exe + file-digest: SHA256 + timestamp-rfc3161: http://timestamp.acs.microsoft.com + timestamp-digest: SHA256 + + - name: Record signing state + id: sign-state + run: | + if [ "$HAS_SIGNING" = "true" ] && [[ "$GITHUB_REF" == refs/tags/v* ]]; then + echo "signed=true" >> "$GITHUB_OUTPUT" + else + echo "signed=false" >> "$GITHUB_OUTPUT" + fi + + - name: Upload + uses: actions/upload-artifact@v4 + with: + name: desktop-windows + path: dist/* + + macos: + name: macOS (universal) + runs-on: macos-15 + outputs: + notarized: ${{ steps.notarize-state.outputs.notarized }} + env: + HAS_CERT: ${{ secrets.MACOS_CERT_P12_BASE64 != '' && secrets.MACOS_CERT_PASSWORD != '' }} + HAS_NOTARY: ${{ secrets.APPLE_ID != '' && secrets.APPLE_TEAM_ID != '' && secrets.APPLE_APP_PASSWORD != '' }} + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Set up Rust + uses: dtolnay/rust-toolchain@stable + with: + targets: aarch64-apple-darwin,x86_64-apple-darwin + + - name: Cache cargo + uses: Swatinem/rust-cache@v2 + with: + workspaces: desktop + prefix-key: desktop-macos-15 + + - name: Set up Node (Tauri CLI) + uses: actions/setup-node@v4 + with: + node-version: 22 + + - name: Test + working-directory: desktop + run: cargo test --release + + - name: Import the Developer ID certificate + if: env.HAS_CERT == 'true' && startsWith(github.ref, 'refs/tags/v') + env: + MACOS_CERT_P12_BASE64: ${{ secrets.MACOS_CERT_P12_BASE64 }} + MACOS_CERT_PASSWORD: ${{ secrets.MACOS_CERT_PASSWORD }} + run: | + set -euo pipefail + keychain="$RUNNER_TEMP/signing.keychain-db" + keychain_password="$(openssl rand -base64 24)" + security create-keychain -p "$keychain_password" "$keychain" + security set-keychain-settings -lut 21600 "$keychain" + security unlock-keychain -p "$keychain_password" "$keychain" + printf '%s' "$MACOS_CERT_P12_BASE64" | base64 --decode > "$RUNNER_TEMP/cert.p12" + security import "$RUNNER_TEMP/cert.p12" -k "$keychain" \ + -P "$MACOS_CERT_PASSWORD" -T /usr/bin/codesign + rm -f "$RUNNER_TEMP/cert.p12" + security set-key-partition-list -S apple-tool:,apple:,codesign: \ + -s -k "$keychain_password" "$keychain" >/dev/null + security list-keychains -d user -s "$keychain" \ + $(security list-keychains -d user | tr -d '"') + identity="$(security find-identity -v -p codesigning "$keychain" \ + | awk -F'"' '/Developer ID Application/ {print $2; exit}')" + if [ -z "$identity" ]; then + echo "::error::the certificate holds no 'Developer ID Application' identity" + exit 1 + fi + echo "MACOS_SIGN_IDENTITY=$identity" >> "$GITHUB_ENV" + + # With a Developer ID identity Tauri signs with the hardened runtime + # and, given the Apple ID variables, notarizes and staples the app. + # Without one it is ad-hoc signed ("-"). + - name: Build + working-directory: desktop + env: + NOTARY_APPLE_ID: ${{ secrets.APPLE_ID }} + NOTARY_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }} + NOTARY_PASSWORD: ${{ secrets.APPLE_APP_PASSWORD }} + run: | + set -euo pipefail + export APPLE_SIGNING_IDENTITY="${MACOS_SIGN_IDENTITY:--}" + if [ -n "${MACOS_SIGN_IDENTITY:-}" ] && [ "$HAS_NOTARY" = "true" ]; then + export APPLE_ID="$NOTARY_APPLE_ID" APPLE_TEAM_ID="$NOTARY_TEAM_ID" APPLE_PASSWORD="$NOTARY_PASSWORD" + fi + version="${CRAFTBOT_VERSION#v}" + npx --yes "$TAURI_CLI" build --target universal-apple-darwin --bundles app dmg \ + --config "{\"version\":\"${version:-0.1.0}\"}" + + - name: Record notarization state + id: notarize-state + run: | + if [ -n "${MACOS_SIGN_IDENTITY:-}" ] && [ "$HAS_NOTARY" = "true" ]; then + echo "notarized=true" >> "$GITHUB_OUTPUT" + else + echo "notarized=false" >> "$GITHUB_OUTPUT" + fi + + - name: Package + run: | + set -euo pipefail + mkdir -p dist + cp desktop/target/universal-apple-darwin/release/bundle/dmg/*.dmg dist/CraftBot-macos.dmg + ls -la dist/ + + - name: Remove the signing keychain + if: always() && env.HAS_CERT == 'true' && startsWith(github.ref, 'refs/tags/v') + run: security delete-keychain "$RUNNER_TEMP/signing.keychain-db" || true + + - name: Upload + uses: actions/upload-artifact@v4 + with: + name: desktop-macos + path: dist/* + + # On a tag: wait for the Release workflow to publish the release, then add + # the installers and a section about them to its notes. + attach: + name: Attach to the release + if: startsWith(github.ref, 'refs/tags/v') + needs: [linux, windows, macos] + runs-on: ubuntu-latest + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GH_REPO: ${{ github.repository }} + TAG: ${{ github.ref_name }} + WINDOWS_SIGNED: ${{ needs.windows.outputs.signed }} + MACOS_NOTARIZED: ${{ needs.macos.outputs.notarized }} + steps: + - name: Download the installers + uses: actions/download-artifact@v4 + with: + path: dist + pattern: desktop-* + merge-multiple: true + + - name: Wait for the release + run: | + for _ in $(seq 1 120); do + gh release view "$TAG" >/dev/null 2>&1 && exit 0 + sleep 30 + done + echo "::error::the release for $TAG did not appear within an hour" + exit 1 + + - name: Upload and describe + run: | + set -euo pipefail + gh release upload "$TAG" dist/* --clobber + gh release view "$TAG" --json body -q .body > notes.md + if ! grep -q '^### CraftBot app' notes.md; then + { + echo + echo '### CraftBot app' + echo + echo 'CraftBot in its own window, with a tray icon. It installs CraftBot the first' + echo 'time you open it, starts it when it is not running, and keeps it running in' + echo 'the background when you close the window.' + echo + echo '| Computer | Download |' + echo '|---|---|' + echo '| Windows 10 or 11 | `CraftBot-windows-setup.exe` |' + echo '| macOS 12 or later, Apple silicon or Intel | `CraftBot-macos.dmg` |' + echo '| Linux, x86_64 | `CraftBot-linux-x86_64.AppImage`, `.deb` or `.rpm` |' + echo '| Linux, ARM64 | `CraftBot-linux-aarch64.AppImage`, `.deb` or `.rpm` |' + if [ "$WINDOWS_SIGNED" != "true" ]; then + echo + echo 'The Windows app is not code-signed: if SmartScreen stops it, select' + echo '**More info**, then **Run anyway**.' + fi + if [ "$MACOS_NOTARIZED" != "true" ]; then + echo + echo 'The macOS app is not notarized: after the first attempt to open it, select' + echo '**Open Anyway** in **System Settings > Privacy & Security**.' + fi + } >> notes.md + gh release edit "$TAG" --notes-file notes.md + fi diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 6cc56a83..fe874ab7 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -403,7 +403,7 @@ jobs: set -euo pipefail # The oldest macOS the binary is built for is the one the launcher # checks for, from the same constant. - MACOSX_DEPLOYMENT_TARGET="$(sed -n 's/^pub const MIN_MACOS: &str = "\(.*\)";/\1/p' src/preflight.rs)" + MACOSX_DEPLOYMENT_TARGET="$(sed -n 's/^pub const MIN_MACOS: &str = "\(.*\)";/\1/p' core/src/preflight.rs)" export MACOSX_DEPLOYMENT_TARGET echo "MACOSX_DEPLOYMENT_TARGET=$MACOSX_DEPLOYMENT_TARGET" cargo build --release --target aarch64-apple-darwin diff --git a/app/ui_layer/browser/frontend/src/store/index.ts b/app/ui_layer/browser/frontend/src/store/index.ts index 51dbaac0..9a93dbd9 100644 --- a/app/ui_layer/browser/frontend/src/store/index.ts +++ b/app/ui_layer/browser/frontend/src/store/index.ts @@ -26,6 +26,7 @@ import uiReducer from './slices/uiSlice' import { socketMiddleware } from './socket/socketMiddleware' import './socket/versionWatch' import './socket/readReceipts' +import './socket/desktopNotifications' import { createUiPersistenceMiddleware, loadPersistedUiState } from './uiState' // Redux Toolkit's development-only safety checks walk the state on every diff --git a/app/ui_layer/browser/frontend/src/store/socket/desktopNotifications.ts b/app/ui_layer/browser/frontend/src/store/socket/desktopNotifications.ts new file mode 100644 index 00000000..74969880 --- /dev/null +++ b/app/ui_layer/browser/frontend/src/store/socket/desktopNotifications.ts @@ -0,0 +1,44 @@ +import { register } from './messageRegistry' +import type { ChatMessage } from '../../types' + +// In the CraftBot desktop app (desktop/), an agent reply, question or error +// that arrives while the window is in the background becomes a system +// notification. The app routes the standard Notification API to native +// notifications; in a browser this module does nothing, so the browser UI +// gains no permission prompt. +const inDesktopApp = typeof window !== 'undefined' && '__TAURI_INTERNALS__' in window + +// One notification per message: a reply can be delivered more than once +// (streamed draft, then final; reconciliation after a reconnect). +const notified = new Set() + +function preview(text: string): string { + return text + .replace(/```[\s\S]*?```/g, ' ') + .replace(/[`*_#>~[\]]/g, '') + .replace(/\s+/g, ' ') + .trim() + .slice(0, 180) +} + +export function shouldNotify(m: ChatMessage, focused: boolean): boolean { + if (focused) return false + if (m.style !== 'agent' && m.style !== 'error') return false + // A draft still being written, or a progress note in the middle of a run + // (the run goes on): wait for what the agent actually hands back. + if (m.streaming || (m.continueWork && !m.isQuestion)) return false + return !!m.messageId && !!preview(m.content || '') +} + +if (inDesktopApp) { + register('chat_message', (data) => { + const m = data as ChatMessage + if (!shouldNotify(m, document.hasFocus()) || notified.has(m.messageId)) return + notified.add(m.messageId) + try { + new Notification('CraftBot', { body: preview(m.content) }) + } catch { + // No notifications on this system: the message is in the chat anyway. + } + }) +} diff --git a/craftbot.py b/craftbot.py index edb381a1..20e6e54a 100644 --- a/craftbot.py +++ b/craftbot.py @@ -704,17 +704,89 @@ def _build_run_args(extra: List[str], service_mode: bool = True) -> List[str]: def _open_browser_detached(url: str) -> None: - """Open the UI in the user's browser. + """Open the UI: in the CraftBot desktop app when it is installed, else in + the user's browser. cmd_start only calls this once run.py has reported the UI as reachable (ui.json), so there is nothing left to poll for. """ + if _open_desktop_app(): + return try: webbrowser.open(url) except Exception as e: print(f" {DIM}Could not open a browser ({e}). Open {url} yourself.{RESET}") +# CRAFTBOT_DESKTOP_APP names the desktop app's executable, or turns the +# hand-over off ("0", "off") so the UI opens in the browser as before. +_DESKTOP_APP_ENV = "CRAFTBOT_DESKTOP_APP" + + +def _desktop_app() -> Optional[List[str]]: + """The command that opens the CraftBot desktop app (desktop/), if it is + installed where its installers put it.""" + override = os.environ.get(_DESKTOP_APP_ENV, "").strip() + if override.lower() in ("0", "off", "no", "false"): + return None + if override: + return [override] if os.path.isfile(override) else None + if _PLATFORM == "darwin": + for root in ("/Applications", os.path.expanduser("~/Applications")): + bundle = os.path.join(root, "CraftBot.app") + if os.path.isdir(bundle): + return ["open", "-a", bundle, "--args"] + return None + if _PLATFORM == "win32": + local = os.environ.get("LOCALAPPDATA") or os.path.expanduser(r"~\AppData\Local") + exe = os.path.join(local, "CraftBot", "craftbot-desktop.exe") + return [exe] if os.path.isfile(exe) else None + found = shutil.which("craftbot-desktop") + return [found] if found else None + + +def _open_desktop_app() -> bool: + """Hand over to the desktop app, telling it which CraftBot this is: a + source checkout is driven exactly like an installed copy. The app shows + this CraftBot's UI, or starts it first. False when there is no app.""" + if IS_FROZEN: + return False + command = _desktop_app() + if not command: + return False + command = command + [ + "--dir", + BASE_DIR, + "--python", + _installed_python(), + f"--state-root={paths.STATE_ROOT.resolve()}", + ] + try: + if _PLATFORM == "win32": + flags = subprocess.DETACHED_PROCESS | subprocess.CREATE_NEW_PROCESS_GROUP + subprocess.Popen( + command, + creationflags=flags, + stdin=subprocess.DEVNULL, + stdout=subprocess.DEVNULL, + stderr=subprocess.DEVNULL, + close_fds=True, + ) + else: + subprocess.Popen( + command, + start_new_session=True, + stdin=subprocess.DEVNULL, + stdout=subprocess.DEVNULL, + stderr=subprocess.DEVNULL, + close_fds=True, + ) + return True + except OSError as e: + print(f" {DIM}Could not open the CraftBot app ({e}).{RESET}") + return False + + _CLI_RETIRED = ( "The CLI was replaced by the terminal edition.\n" " Run it in this terminal: python run.py --tui\n" diff --git a/desktop/.gitignore b/desktop/.gitignore new file mode 100644 index 00000000..8e2c03da --- /dev/null +++ b/desktop/.gitignore @@ -0,0 +1,3 @@ +target/ +# Generated by tauri-build on every build. +gen/ diff --git a/desktop/Cargo.lock b/desktop/Cargo.lock new file mode 100644 index 00000000..8befe230 --- /dev/null +++ b/desktop/Cargo.lock @@ -0,0 +1,5965 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 4 + +[[package]] +name = "adler2" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa" + +[[package]] +name = "aho-corasick" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c982642fa9e8606056828ee9a8505737230110bb1099153c79efe865c59d12ba" +dependencies = [ + "memchr", +] + +[[package]] +name = "alloc-no-stdlib" +version = "3.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2fb6cfd47bf496ff64095c20eaba0c201404ee38714d4142fcfa1dc334fcc7a" + +[[package]] +name = "alloc-stdlib" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b5c1865780388bfa186411ab5f247819487fc4864c6e9c3106611fa347586e1" +dependencies = [ + "alloc-no-stdlib", +] + +[[package]] +name = "android_system_properties" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae221649c9976a6f6c56ae1facf410f3ddb33cc661c4b7b61020a912d4237fbc" +dependencies = [ + "libc", +] + +[[package]] +name = "anyhow" +version = "1.0.105" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2cb931c189b85683d69a5cfad41d4d418671e1ac413dd209f3f2fc31e3cfd902" + +[[package]] +name = "arbitrary" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3bc62ac97cc33321f50863d514c3bc38a453947a8f9e781137e47c7401020aed" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "async-broadcast" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "435a87a52755b8f27fcf321ac4f04b2802e337c8c4872923137471ec39c37532" +dependencies = [ + "event-listener", + "event-listener-strategy", + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "async-channel" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "924ed96dd52d1b75e9c1a3e6275715fd320f5f9439fb5a4a11fa51f4221158d2" +dependencies = [ + "concurrent-queue", + "event-listener-strategy", + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "async-executor" +version = "1.14.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f426a31126c735126297bc5ea7a521263c9faff4f63ca415267ee625651c4f37" +dependencies = [ + "async-task", + "concurrent-queue", + "fastrand", + "futures-lite", + "pin-project-lite", + "slab", +] + +[[package]] +name = "async-io" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "456b8a8feb6f42d237746d4b3e9a178494627745c3c56c6ea55d92ba50d026fc" +dependencies = [ + "autocfg", + "cfg-if", + "concurrent-queue", + "futures-io", + "futures-lite", + "parking", + "polling", + "rustix", + "slab", + "windows-sys 0.61.2", +] + +[[package]] +name = "async-lock" +version = "3.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0876700b0d007ad25d5508865a4259c3af9af6d296bf663a0d586d0bc3369f6f" +dependencies = [ + "event-listener", + "event-listener-strategy", + "pin-project-lite", +] + +[[package]] +name = "async-process" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc50921ec0055cdd8a16de48773bfeec5c972598674347252c0399676be7da75" +dependencies = [ + "async-channel", + "async-io", + "async-lock", + "async-signal", + "async-task", + "blocking", + "cfg-if", + "event-listener", + "futures-lite", + "rustix", +] + +[[package]] +name = "async-recursion" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f8abc12baad266b1c8cec146854c195b5864b4221d4b2ca7296a7ae82d9e451" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "async-signal" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52b5aaafa020cf5053a01f2a60e8ff5dccf550f0f77ec54a4e47285ac2bab485" +dependencies = [ + "async-io", + "async-lock", + "atomic-waker", + "cfg-if", + "futures-core", + "futures-io", + "rustix", + "signal-hook-registry", + "slab", + "windows-sys 0.61.2", +] + +[[package]] +name = "async-task" +version = "4.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de" + +[[package]] +name = "async-trait" +version = "0.1.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "82f6aeea286b8eb4dd3431a1be1b59d290ace00f5bfd8e2a159bc2a05e2c1667" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "atk" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "241b621213072e993be4f6f3a9e4b45f65b7e6faad43001be957184b7bb1824b" +dependencies = [ + "atk-sys", + "glib", + "libc", +] + +[[package]] +name = "atk-sys" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c5e48b684b0ca77d2bbadeef17424c2ea3c897d44d566a1617e7e8f30614d086" +dependencies = [ + "glib-sys", + "gobject-sys", + "libc", + "system-deps", +] + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "auto-launch" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "17918dba7ecf78b9a14507ec9f984e7977d13fad87dc86d61038980a45d128cf" +dependencies = [ + "dirs 6.0.0", + "os_info", + "smappservice-rs", + "thiserror 2.0.21", + "windows-registry", + "windows-result", +] + +[[package]] +name = "autocfg" +version = "1.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53" + +[[package]] +name = "base64" +version = "0.21.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" + +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + +[[package]] +name = "base64" +version = "0.23.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac07cdecf99051d9a5238b80f35af32cdeba5b336e55d957b318b50137e18da5" + +[[package]] +name = "bit-set" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3" +dependencies = [ + "bit-vec 0.8.0", +] + +[[package]] +name = "bit-set" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56d87354e4229f54a44f7bf2435906a4656dba36026ab6eaca629a2c436a691c" +dependencies = [ + "bit-vec 0.10.2", +] + +[[package]] +name = "bit-vec" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7" + +[[package]] +name = "bit-vec" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72503af1e72be411d74ca45cd6b309878fcb35354e252fc2a3a8bda3a97082a0" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ded4057c258ba199e2d26386d3af3780957ecaee6c4ef4041c6b4b8b97c0b06" +dependencies = [ + "serde_core", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block-buffer" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2f6c7dbe95a6ed67ad9f18e57daf93a2f034c524b99fd2b76d18fdfeb6660aa" +dependencies = [ + "hybrid-array", +] + +[[package]] +name = "block2" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cdeb9d870516001442e364c5220d3574d2da8dc765554b4a617230d33fa58ef5" +dependencies = [ + "objc2", +] + +[[package]] +name = "blocking" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a70e4329df6cb94385eed412ec92375c3cdd8a6e502493d1229b6414e4036dfa" +dependencies = [ + "async-channel", + "async-task", + "futures-io", + "futures-lite", + "piper", +] + +[[package]] +name = "brotli" +version = "9.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9071f285ed78f04f37d675abaaef5de7689e2f30a216c8dc6795465d81910a13" +dependencies = [ + "alloc-no-stdlib", + "alloc-stdlib", + "brotli-decompressor", +] + +[[package]] +name = "brotli-decompressor" +version = "6.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "664148598c930650998ef56df301329ffe7b4cdb02d49b2a3fca3bcaf2185bcb" +dependencies = [ + "alloc-no-stdlib", + "alloc-stdlib", +] + +[[package]] +name = "bs58" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bf88ba1141d185c399bee5288d850d63b8369520c1eafc32a0430b5b6c287bf4" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "bumpalo" +version = "3.20.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87a0cf66fd1eb2fb7b822cb78370d82303750809bc6ba855f3f58e517d3238db" + +[[package]] +name = "bytemuck" +version = "1.25.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95832e849adfb21180ccb6826a99da14e5d266ae5c2e668e1602cf234f153797" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "byteorder-lite" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f1fe948ff07f4bd06c30984e69f5b4899c516a3ef74f34df92a2df2ab535495" + +[[package]] +name = "bytes" +version = "1.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "776dfebd015e2d8732c684a2c71003674ccb49457b539b9e82151ba38e96dd7c" +dependencies = [ + "serde", +] + +[[package]] +name = "cairo-rs" +version = "0.18.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ca26ef0159422fb77631dc9d17b102f253b876fe1586b03b803e63a309b4ee2" +dependencies = [ + "bitflags 2.13.2", + "cairo-sys-rs", + "glib", + "libc", + "once_cell", + "thiserror 1.0.69", +] + +[[package]] +name = "cairo-sys-rs" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "685c9fa8e590b8b3d678873528d83411db17242a73fccaed827770ea0fedda51" +dependencies = [ + "glib-sys", + "libc", + "system-deps", +] + +[[package]] +name = "camino" +version = "1.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbbad30e4b4c14a39e3cc8aed085a12a327257c316619c93581e017bc52be591" +dependencies = [ + "serde_core", +] + +[[package]] +name = "cargo-platform" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e35af189006b9c0f00a064685c727031e3ed2d8020f7ba284d78cc2671bd36ea" +dependencies = [ + "serde", +] + +[[package]] +name = "cargo_metadata" +version = "0.19.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd5eb614ed4c27c5d706420e4320fbe3216ab31fa1c33cd8246ac36dae4479ba" +dependencies = [ + "camino", + "cargo-platform", + "semver", + "serde", + "serde_json", + "thiserror 2.0.21", +] + +[[package]] +name = "cargo_toml" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "82f4b26e751e711a5302649417f2da046dce6391b2ea30a4820f37462314f0b9" +dependencies = [ + "semver", + "serde", + "toml 1.2.3+spec-1.1.0", +] + +[[package]] +name = "cc" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95e45cf2980b2d467be49a9ed942c9179b701063a7ca3d037de7ee9bd67f8d66" +dependencies = [ + "find-msvc-tools", + "shlex", +] + +[[package]] +name = "cesu8" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" + +[[package]] +name = "cfb" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a347dcabdae9c31b0825fd6a8bed285ec9c2acb89c47827126d52fa4f59cece3" +dependencies = [ + "fnv", + "uuid", + "web-time", +] + +[[package]] +name = "cfg-expr" +version = "0.15.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d067ad48b8650848b989a59a86c6c36a995d02d2bf778d45c3c5d57bc2718f02" +dependencies = [ + "smallvec", + "target-lexicon", +] + +[[package]] +name = "cfg-if" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e7648175b45a9a48536d676f68d918270699102aa8dab5496df06904c914600" + +[[package]] +name = "cfg_aliases" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f079e83a288787bcd14a6aea84cee5c87a67c5a3e660c30f557a3d24761b3527" + +[[package]] +name = "chacha20" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "65c35e4b699c7e15ccbe7ee35c005e4fc0a278d22238a2857e6ce2dadeda1b06" +dependencies = [ + "cfg-if", + "cpufeatures 0.3.1", + "rand_core", +] + +[[package]] +name = "chrono" +version = "0.4.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1aa79e62e7697b8e29b513a68abacf485adcd1fe8284a4316c5ae868e6633327" +dependencies = [ + "iana-time-zone", + "num-traits", + "serde", + "windows-link", +] + +[[package]] +name = "combine" +version = "4.6.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4356eba6976435498d05a311ee9fc486da3bc81c200d3f0d7dd9703b41913f92" +dependencies = [ + "bytes", + "memchr", +] + +[[package]] +name = "concurrent-queue" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "const-oid" +version = "0.10.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "be95d4a884358a21a199689323c29e9256b4a1b315e22f183d155422041d3a9a" + +[[package]] +name = "cookie" +version = "0.18.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d55f2d6c30eeec7d5c6f98bd4395d4abb1895629eab97ee6522d340623615f8a" +dependencies = [ + "time", + "version_check", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2a6cd9ae233e7f62ba4e9353e81a88df7fc8a5987b8d445b4d90c879bd156f6" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" + +[[package]] +name = "core-graphics" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "064badf302c3194842cf2c5d61f56cc88e54a759313879cdf03abdd27d0c3b97" +dependencies = [ + "bitflags 2.13.2", + "core-foundation 0.10.1", + "core-graphics-types", + "foreign-types 0.5.0", + "libc", +] + +[[package]] +name = "core-graphics-types" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d44a101f213f6c4cdc1853d4b78aef6db6bdfa3468798cc1d9912f4735013eb" +dependencies = [ + "bitflags 2.13.2", + "core-foundation 0.10.1", + "libc", +] + +[[package]] +name = "cpufeatures" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280" +dependencies = [ + "libc", +] + +[[package]] +name = "cpufeatures" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ca28b0ae3115b884660db4118d803791fd6756b6e88f39c0f3f7859060d7566" +dependencies = [ + "libc", +] + +[[package]] +name = "craftbot-desktop" +version = "0.1.0" +dependencies = [ + "auto-launch", + "craftbot-launcher-core", + "gtk", + "serde", + "serde_json", + "tauri", + "tauri-build", + "tauri-plugin-dialog", + "tauri-plugin-notification", + "tauri-plugin-opener", + "tauri-plugin-single-instance", + "tauri-plugin-window-state", + "tempfile", + "webkit2gtk", +] + +[[package]] +name = "craftbot-launcher-core" +version = "0.1.0" +dependencies = [ + "dirs 6.0.0", + "flate2", + "fs4", + "libc", + "native-tls", + "serde", + "serde_json", + "sha2 0.10.9", + "tar", + "ureq", + "windows-sys 0.59.0", + "zip", +] + +[[package]] +name = "crc32fast" +version = "1.5.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd9ae8fcb3ea71b0b26338b4ffb13006bb175de8fd07921089a906ce7e5e6945" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-channel" +version = "0.5.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "98b0cc327b5bc766e7fda9c9260cc0fa81b43a8e240440422dff70788e3f9ef1" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a31eee39dddec8330830986fcd7625edb5a24ec90ea038215273bbc3adb08ac6" + +[[package]] +name = "crypto-common" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "crypto-common" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce6e4c961d6cd6c9a86db418387425e8bdeaf05b3c8bc1411e6dca4c252f1453" +dependencies = [ + "hybrid-array", +] + +[[package]] +name = "cssparser" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c9cdaae01d5ed7882b04d795e7f752f46ff52d2fa3b50a20d28c464510bba98" +dependencies = [ + "cssparser-macros", + "dtoa-short", + "itoa", + "phf 0.13.1", + "smallvec", +] + +[[package]] +name = "cssparser" +version = "0.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "11119743ad110e8c1bdccd930d7f5c30c99e5fc76a7b63ec9807e84eef0c5f59" +dependencies = [ + "cssparser-macros", + "dtoa-short", + "itoa", + "phf 0.14.0", + "smallvec", +] + +[[package]] +name = "cssparser-macros" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d045de693cb712d0b22c6a64be5b953f67b3ce00ab5ad3dd5d8b441886ab8e1a" +dependencies = [ + "quote", + "syn 3.0.10", +] + +[[package]] +name = "ctor" +version = "1.0.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ea691ed9f36489d087419b8b2ba3ef27d89621380b4178c73e2445a379e4e0f4" +dependencies = [ + "link-section", +] + +[[package]] +name = "darling" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed17f5901b6630b993ca003def43f2f8ef4014fc13b047b57aad617ff32bc2ec" +dependencies = [ + "darling_core", + "darling_macro", +] + +[[package]] +name = "darling_core" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6837e2cf7485aaae18f86181d2f0e9a7ed297a025e220aeabf63fdebd3a2ddff" +dependencies = [ + "ident_case", + "proc-macro2", + "quote", + "strsim", + "syn 3.0.10", +] + +[[package]] +name = "darling_macro" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ac7135c3ef02b2f7833bbeb1be5ba7f966dcde8a87c6b87f65a778d71a02785" +dependencies = [ + "darling_core", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "dbus" +version = "0.9.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ab69f03cc8c4340c9c8e315114e1658e6775a9b16a04357973aa21cec22b32e" +dependencies = [ + "libc", + "libdbus-sys", + "windows-sys 0.61.2", +] + +[[package]] +name = "deranged" +version = "0.5.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e9de72ce2ad1f90dc62fa25f0f430ef85eb4b0d8fa0be4f30373bc40a21d28e" +dependencies = [ + "serde_core", +] + +[[package]] +name = "derive_arbitrary" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b034bd7d5f032402a2479444dcc6f74e36a03f31854d41680fb240ef682a1ac" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "derive_more" +version = "2.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d751e9e49156b02b44f9c1815bcb94b984cdcc4396ecc32521c739452808b134" +dependencies = [ + "derive_more-impl", +] + +[[package]] +name = "derive_more-impl" +version = "2.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "799a97264921d8623a957f6c3b9011f3b5492f557bbb7a5a19b7fa6d06ba8dcb" +dependencies = [ + "proc-macro2", + "quote", + "rustc_version", + "syn 2.0.119", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer 0.10.4", + "crypto-common 0.1.7", +] + +[[package]] +name = "digest" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1dd6dbb5841937940781866fa1281a1ff7bd3bf827091440879f9994983d5c2" +dependencies = [ + "block-buffer 0.12.1", + "const-oid", + "crypto-common 0.2.2", +] + +[[package]] +name = "dirs" +version = "6.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3e8aa94d75141228480295a7d0e7feb620b1a5ad9f12bc40be62411e38cce4e" +dependencies = [ + "dirs-sys", +] + +[[package]] +name = "dirs" +version = "7.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d57d423b3c82e89b9a24ca3091fee61f456a26edbd28d26c65906f4bc1dcd8f" +dependencies = [ + "dirs-sys", +] + +[[package]] +name = "dirs-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e01a3366d27ee9890022452ee61b2b63a67e6f13f58900b651ff5665f0bb1fab" +dependencies = [ + "libc", + "option-ext", + "redox_users", + "windows-sys 0.61.2", +] + +[[package]] +name = "dispatch2" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e0e367e4e7da84520dedcac1901e4da967309406d1e51017ae1abfb97adbd38" +dependencies = [ + "bitflags 2.13.2", + "block2", + "libc", + "objc2", +] + +[[package]] +name = "displaydoc" +version = "0.2.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6232dd377dcc64799954cbd3a9bb882e9cdc1308ccd87b1c098f1fb2eaf82a8" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "dlopen2" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e2c5bd4158e66d1e215c49b837e11d62f3267b30c92f1d171c4d3105e3dc4d4" +dependencies = [ + "dlopen2_derive", + "libc", + "once_cell", + "winapi", +] + +[[package]] +name = "dlopen2_derive" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fbbb781877580993a8707ec48672673ec7b81eeba04cfd2310bd28c08e47c8f" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "dom_query" +version = "0.28.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fac5fca71e65e94cc718a6e2af65d6e0f9c6027751c2aa562fbb5087fda639bc" +dependencies = [ + "bit-set 0.8.0", + "cssparser 0.37.0", + "foldhash", + "html5ever 0.39.0", + "precomputed-hash", + "selectors 0.38.0", + "tendril", +] + +[[package]] +name = "dom_query" +version = "0.30.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b35b4f772a1a8b88e5545a67c2d3a62a93d4edccc5a68f2145fe52e39c96d275" +dependencies = [ + "bit-set 0.11.1", + "cssparser 0.38.0", + "foldhash", + "html5ever 0.40.1", + "precomputed-hash", + "selectors 0.41.0", + "tendril", +] + +[[package]] +name = "dpi" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8b14ccef22fc6f5a8f4d7d768562a182c04ce9a3b3157b91390b52ddfdf1a76" +dependencies = [ + "serde", +] + +[[package]] +name = "dtoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c3cf4824e2d5f025c7b531afcb2325364084a16806f6d47fbc1f5fbd9960590" + +[[package]] +name = "dtoa-short" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd1511a7b6a56299bd043a9c167a6d2bfb37bf84a6dfceaba651168adfb43c87" +dependencies = [ + "dtoa", +] + +[[package]] +name = "dunce" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" + +[[package]] +name = "dyn-clone" +version = "1.0.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d0881ea181b1df73ff77ffaaf9c7544ecc11e82fba9b5f27b262a3c73a332555" + +[[package]] +name = "embed-resource" +version = "3.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6168487b5e7eb2673e6efe1200b1848016e436a6ca0b8031bf04bd9d493a249f" +dependencies = [ + "cc", + "memchr", + "rustc_version", + "toml 1.2.3+spec-1.1.0", + "vswhom", + "winreg", +] + +[[package]] +name = "embed_plist" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" + +[[package]] +name = "endi" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "66b7e2430c6dff6a955451e2cfc438f09cea1965a9d6f87f7e3b90decc014099" + +[[package]] +name = "enumflags2" +version = "0.7.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1027f7680c853e056ebcec683615fb6fbbc07dbaa13b4d5d9442b146ded4ecef" +dependencies = [ + "enumflags2_derive", + "serde", +] + +[[package]] +name = "enumflags2_derive" +version = "0.7.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67c78a4d8fdf9953a5c9d458f9efe940fd97a0cab0941c075a813ac594733827" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "equivalent" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00d174d5400e5e8fd687ad1049e2f578285fa914201b1af7e8b112a4546bd826" + +[[package]] +name = "erased-serde" +version = "0.4.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e59b668157f32d3459d4bd634861a06ffa2503a461ca5f0916b9f0252605e66" +dependencies = [ + "serde", + "serde_core", + "typeid", +] + +[[package]] +name = "errno" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e35d6e78f4cebb90e51d543db8fe41528851d6deeef6ef21ebd4bfdc1e784776" +dependencies = [ + "libc", + "windows-sys 0.61.2", +] + +[[package]] +name = "event-listener" +version = "5.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a23add41df1562121a9393cb065eab5146a1242410f23a644851e90cfd669d2" +dependencies = [ + "parking", + "pin-project-lite", +] + +[[package]] +name = "event-listener-strategy" +version = "0.5.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8be9f3dfaaffdae2972880079a491a1a8bb7cbed0b8dd7a347f668b4150a3b93" +dependencies = [ + "event-listener", + "pin-project-lite", +] + +[[package]] +name = "fastrand" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da7c62ceae207dd37ea5b845da6a0696c799f85e97da1ab5b7910be3c1c80223" + +[[package]] +name = "fdeflate" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e6853b52649d4ac5c0bd02320cddc5ba956bdb407c4b75a2c6b75bf51500f8c" +dependencies = [ + "simd-adler32", +] + +[[package]] +name = "field-offset" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38e2275cc4e4fc009b0669731a1e5ab7ebf11f469eaede2bab9309a5b4d6057f" +dependencies = [ + "memoffset", + "rustc_version", +] + +[[package]] +name = "filetime" +version = "0.2.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e1255e7a9f1902190d4c10a75f2f7f495d3d3ce13e9ba26e6c48683a0f4dbed7" +dependencies = [ + "cfg-if", + "libc", +] + +[[package]] +name = "find-msvc-tools" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3e44f110d1777dc6559a51e7d45083945ded4f1bf3305494350f693b6d20b9c8" + +[[package]] +name = "flate2" +version = "1.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "626d4928326b646e70f65ed36fc7cf9f206bdb68a0019ee7c6b4709da4e084c4" +dependencies = [ + "crc32fast", + "miniz_oxide 0.9.1", + "zlib-rs", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "foldhash" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared 0.1.1", +] + +[[package]] +name = "foreign-types" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d737d9aa519fb7b749cbc3b962edcf310a8dd1f4b67c91c4f83975dbdd17d965" +dependencies = [ + "foreign-types-macros", + "foreign-types-shared 0.3.1", +] + +[[package]] +name = "foreign-types-macros" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ea5190182e6915eb873ddbc16e23b711b6eb1f9c00a0d0a3a91b5f6228475225" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + +[[package]] +name = "foreign-types-shared" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b" + +[[package]] +name = "form_urlencoded" +version = "1.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "afa489199eaffb1211795df1c6236ce1ad0d41a6fa45250add73e3b02420f06e" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "fs4" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8640e34b88f7652208ce9e88b1a37a2ae95227d84abec377ccd3c5cfeb141ed4" +dependencies = [ + "rustix", + "windows-sys 0.59.0", +] + +[[package]] +name = "futures-channel" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1f9e3d69d39e4862ffed03ed071a76f9a13ba1d9109d355b0f0aa6b15e393c4" +dependencies = [ + "futures-core", +] + +[[package]] +name = "futures-core" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92d699e522242e69e3003b94ecc1f960f3a5e015aa7c5d7486e65ad01dd94f5e" + +[[package]] +name = "futures-executor" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "031b47cf1a3c6cc8bc2fc76cd437f521619387907d469316e7c0bc278f1f5432" +dependencies = [ + "futures-core", + "futures-task", + "futures-util", +] + +[[package]] +name = "futures-io" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53c0fa8157de1303bfffdaa1cc2a673bfffb60102f76b0ef4441659124373fed" + +[[package]] +name = "futures-lite" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f78e10609fe0e0b3f4157ffab1876319b5b0db102a2c60dc4626306dc46b44ad" +dependencies = [ + "fastrand", + "futures-core", + "futures-io", + "parking", + "pin-project-lite", +] + +[[package]] +name = "futures-macro" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb9654ba8355388abeb8dcb4fc62f511300867002afc858860463bdd9fe0c44" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "futures-sink" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1944426bf7d03f1d14f708785e4b33efd750b36d48a157b836b3efc15ede8e1d" + +[[package]] +name = "futures-task" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd417de3d1d015fc3bfd2b1ea46dfc7bab72ef86f1cc7cc9c78e728b34a6d1fd" + +[[package]] +name = "futures-util" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0d50a92467f8ba5dd6e3ee5d4bd04d73ab2e4e1c44474a0674821dfce14b79bc" +dependencies = [ + "futures-core", + "futures-io", + "futures-macro", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "slab", +] + +[[package]] +name = "gdk" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9f245958c627ac99d8e529166f9823fb3b838d1d41fd2b297af3075093c2691" +dependencies = [ + "cairo-rs", + "gdk-pixbuf", + "gdk-sys", + "gio", + "glib", + "libc", + "pango", +] + +[[package]] +name = "gdk-pixbuf" +version = "0.18.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "50e1f5f1b0bfb830d6ccc8066d18db35c487b1b2b1e8589b5dfe9f07e8defaec" +dependencies = [ + "gdk-pixbuf-sys", + "gio", + "glib", + "libc", + "once_cell", +] + +[[package]] +name = "gdk-pixbuf-sys" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9839ea644ed9c97a34d129ad56d38a25e6756f99f3a88e15cd39c20629caf7" +dependencies = [ + "gio-sys", + "glib-sys", + "gobject-sys", + "libc", + "system-deps", +] + +[[package]] +name = "gdk-sys" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c2d13f38594ac1e66619e188c6d5a1adb98d11b2fcf7894fc416ad76aa2f3f7" +dependencies = [ + "cairo-sys-rs", + "gdk-pixbuf-sys", + "gio-sys", + "glib-sys", + "gobject-sys", + "libc", + "pango-sys", + "pkg-config", + "system-deps", +] + +[[package]] +name = "gdkwayland-sys" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "140071d506d223f7572b9f09b5e155afbd77428cd5cc7af8f2694c41d98dfe69" +dependencies = [ + "gdk-sys", + "glib-sys", + "gobject-sys", + "libc", + "pkg-config", + "system-deps", +] + +[[package]] +name = "gdkx11" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3caa00e14351bebbc8183b3c36690327eb77c49abc2268dd4bd36b856db3fbfe" +dependencies = [ + "gdk", + "gdkx11-sys", + "gio", + "glib", + "libc", + "x11", +] + +[[package]] +name = "gdkx11-sys" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e2e7445fe01ac26f11601db260dd8608fe172514eb63b3b5e261ea6b0f4428d" +dependencies = [ + "gdk-sys", + "glib-sys", + "libc", + "system-deps", + "x11", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "getrandom" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff2abc00be7fca6ebc474524697ae276ad847ad0a6b3faa4bcb027e9a4614ad0" +dependencies = [ + "cfg-if", + "libc", + "wasi", +] + +[[package]] +name = "getrandom" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd" +dependencies = [ + "cfg-if", + "libc", + "r-efi 5.3.0", + "wasip2", +] + +[[package]] +name = "getrandom" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099" +dependencies = [ + "cfg-if", + "libc", + "r-efi 6.0.0", + "rand_core", +] + +[[package]] +name = "gio" +version = "0.18.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4fc8f532f87b79cbc51a79748f16a6828fb784be93145a322fa14d06d354c73" +dependencies = [ + "futures-channel", + "futures-core", + "futures-io", + "futures-util", + "gio-sys", + "glib", + "libc", + "once_cell", + "pin-project-lite", + "smallvec", + "thiserror 1.0.69", +] + +[[package]] +name = "gio-sys" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "37566df850baf5e4cb0dfb78af2e4b9898d817ed9263d1090a2df958c64737d2" +dependencies = [ + "glib-sys", + "gobject-sys", + "libc", + "system-deps", + "winapi", +] + +[[package]] +name = "glib" +version = "0.18.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "233daaf6e83ae6a12a52055f568f9d7cf4671dabb78ff9560ab6da230ce00ee5" +dependencies = [ + "bitflags 2.13.2", + "futures-channel", + "futures-core", + "futures-executor", + "futures-task", + "futures-util", + "gio-sys", + "glib-macros", + "glib-sys", + "gobject-sys", + "libc", + "memchr", + "once_cell", + "smallvec", + "thiserror 1.0.69", +] + +[[package]] +name = "glib-macros" +version = "0.18.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0bb0228f477c0900c880fd78c8759b95c7636dbd7842707f49e132378aa2acdc" +dependencies = [ + "heck 0.4.1", + "proc-macro-crate 2.0.2", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "glib-sys" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "063ce2eb6a8d0ea93d2bf8ba1957e78dbab6be1c2220dd3daca57d5a9d869898" +dependencies = [ + "libc", + "system-deps", +] + +[[package]] +name = "glob" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4eba85ea1d0a966a983acd07deee566e67395d2d96b6fb39e62b5a833f1eb0b" + +[[package]] +name = "gobject-sys" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0850127b514d1c4a4654ead6dedadb18198999985908e6ffe4436f53c785ce44" +dependencies = [ + "glib-sys", + "libc", + "system-deps", +] + +[[package]] +name = "gtk" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd56fb197bfc42bd5d2751f4f017d44ff59fbb58140c6b49f9b3b2bdab08506a" +dependencies = [ + "atk", + "cairo-rs", + "field-offset", + "futures-channel", + "gdk", + "gdk-pixbuf", + "gio", + "glib", + "gtk-sys", + "gtk3-macros", + "libc", + "pango", + "pkg-config", +] + +[[package]] +name = "gtk-sys" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f29a1c21c59553eb7dd40e918be54dccd60c52b049b75119d5d96ce6b624414" +dependencies = [ + "atk-sys", + "cairo-sys-rs", + "gdk-pixbuf-sys", + "gdk-sys", + "gio-sys", + "glib-sys", + "gobject-sys", + "libc", + "pango-sys", + "system-deps", +] + +[[package]] +name = "gtk3-macros" +version = "0.18.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52ff3c5b21f14f0736fed6dcfc0bfb4225ebf5725f3c0209edeec181e4d73e9d" +dependencies = [ + "proc-macro-crate 1.3.1", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "hashbrown" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" + +[[package]] +name = "hashbrown" +version = "0.17.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "735eaa21a6a5ffb2e84362faaeb90c05ba8e19797ca30428478cb6ea3a4921bc" + +[[package]] +name = "heck" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e17592d60ebacc7d5e169f4663c5f84f9161cc90328abcfe8456f41e4dfcb284" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "html5ever" +version = "0.39.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46a1761807faccc9a19e86944bbf40610014066306f96edcdedc2fb714bcb7b8" +dependencies = [ + "log", + "markup5ever 0.39.0", +] + +[[package]] +name = "html5ever" +version = "0.40.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "456a1a377e608e555d22ddab27ac0114bc7a7b4199078108e34c2aeae6c9b130" +dependencies = [ + "log", + "markup5ever 0.40.0", + "memchr", +] + +[[package]] +name = "http" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "918d3568bebf352712bc2ef3d46a8bcf1a75b373be6539de198e9105cbbf9ce0" +dependencies = [ + "bytes", + "itoa", +] + +[[package]] +name = "http-body" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca2a8f2913ee65f60facd6a5905613afaa448497a0230cc41ce022d93290bc2c" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23169fe34a5fbcdd3f3862e78fb9b6fccd5f02a6dc6f732547005d45631ce71c" +dependencies = [ + "bytes", + "futures-core", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87" + +[[package]] +name = "hybrid-array" +version = "0.4.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "27f864f10dfb56725ce5ce5472bc52252c8f93a4ab86327122cebf62c5f59a17" +dependencies = [ + "typenum", +] + +[[package]] +name = "hyper" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "229c6ff5584df4c6becbfe00567128bac768c8cd32ebc8a8366bd81ed072e8f3" +dependencies = [ + "atomic-waker", + "bytes", + "futures-core", + "http", + "http-body", + "httparse", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + +[[package]] +name = "hyper-util" +version = "0.1.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ddc03d96684f9226b8a787cdb71488417b53ab5ea8fdb1dac946cb9431cc8bff" +dependencies = [ + "base64 0.23.1", + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "httparse", + "hyper", + "ipnet", + "libc", + "percent-encoding", + "pin-project-lite", + "socket2", + "tokio", + "tower-service", + "tracing", +] + +[[package]] +name = "iana-time-zone" +version = "0.1.65" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e31bc9ad994ba00e440a8aa5c9ef0ec67d5cb5e5cb0cc7f8b744a35b389cc470" +dependencies = [ + "android_system_properties", + "core-foundation-sys", + "iana-time-zone-haiku", + "js-sys", + "log", + "wasm-bindgen", + "windows-core", +] + +[[package]] +name = "iana-time-zone-haiku" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" +dependencies = [ + "cc", +] + +[[package]] +name = "ico" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d75e94d66081e4d8dcd098bd8dc5254800fea14a26389b298410158d834de167" +dependencies = [ + "byteorder", + "png", +] + +[[package]] +name = "icu_collections" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe090a42a0d3140fed8c63263ed1fecc02422cb2f4bfe55cd8de2de1b8e105dd" +dependencies = [ + "displaydoc", + "potential_utf", + "utf8_iter", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_locale_core" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "25d29b57c17c6528d0dc4c2141cfa2d08200465acb537a3909c8b9b8a4a984c0" +dependencies = [ + "displaydoc", + "litemap", + "tinystr", + "writeable", + "zerovec", +] + +[[package]] +name = "icu_normalizer" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "404a3b8c486f205c87fe7f23ab6894d84a4ad76d6e4671ae1981ba7def87c599" +dependencies = [ + "icu_collections", + "icu_normalizer_data", + "icu_properties", + "icu_provider", + "smallvec", + "zerovec", +] + +[[package]] +name = "icu_normalizer_data" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20f0088bfb7441f7a37fa0c9e20cb1e9cba1cac6b9ce8cd2a6dc44294f8e8cbc" + +[[package]] +name = "icu_properties" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ea83d991c56158f7cf898bf86436c1dfe7c07ee82fe88951f2695c9f37a379f" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_locale_core", + "icu_properties_data", + "icu_provider", + "zerotrie", + "zerovec", +] + +[[package]] +name = "icu_properties_data" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b98f29af82d02b163fe50161388350e743bb3107cc8e8c2f7314cb505faddfcf" + +[[package]] +name = "icu_provider" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "413099315636c588ee8f011190b329b971a09a8fae9d157e01dcae8379468514" +dependencies = [ + "displaydoc", + "icu_locale_core", + "writeable", + "yoke", + "zerofrom", + "zerotrie", + "zerovec", +] + +[[package]] +name = "ident_case" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" + +[[package]] +name = "idna" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de" +dependencies = [ + "idna_adapter", + "smallvec", + "utf8_iter", +] + +[[package]] +name = "idna_adapter" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714" +dependencies = [ + "icu_normalizer", + "icu_properties", +] + +[[package]] +name = "image" +version = "0.25.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85ab80394333c02fe689eaf900ab500fbd0c2213da414687ebf995a65d5a6104" +dependencies = [ + "bytemuck", + "byteorder-lite", + "moxcms", + "num-traits", + "png", +] + +[[package]] +name = "indexmap" +version = "1.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" +dependencies = [ + "autocfg", + "hashbrown 0.12.3", + "serde", +] + +[[package]] +name = "indexmap" +version = "2.14.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc4e190f5d26ca7051642629da2c52fc03bde85a03197c99408dcd291734c855" +dependencies = [ + "equivalent", + "hashbrown 0.17.2", + "serde", + "serde_core", +] + +[[package]] +name = "infer" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4200d433cbd5178df7797c9c2e75b348b728e39631cf14520d1e2fc424201f4" +dependencies = [ + "cfb", +] + +[[package]] +name = "ipnet" +version = "2.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "791930b43c0d5973160d90a8f3894509f2b273430f5c5c73b668636d0287c5c0" + +[[package]] +name = "is-docker" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "928bae27f42bc99b60d9ac7334e3a21d10ad8f1835a4e12ec3ec0464765ed1b3" +dependencies = [ + "once_cell", +] + +[[package]] +name = "is-wsl" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "173609498df190136aa7dea1a91db051746d339e18476eed5ca40521f02d7aa5" +dependencies = [ + "is-docker", + "once_cell", +] + +[[package]] +name = "itoa" +version = "1.0.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3bd1574e617a9a6c1f8f8181bd7e841e1f20e4277607ef28945765188d6284d4" + +[[package]] +name = "javascriptcore-rs" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca5671e9ffce8ffba57afc24070e906da7fc4b1ba66f2cabebf61bf2ea257fcc" +dependencies = [ + "bitflags 1.3.2", + "glib", + "javascriptcore-rs-sys", +] + +[[package]] +name = "javascriptcore-rs-sys" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af1be78d14ffa4b75b66df31840478fef72b51f8c2465d4ca7c194da9f7a5124" +dependencies = [ + "glib-sys", + "gobject-sys", + "libc", + "system-deps", +] + +[[package]] +name = "jiff" +version = "0.2.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "175dc66334db3b9ab9985bf8b61cfed50dc16d20964bb47f9e479adcae984a7f" +dependencies = [ + "jiff-core 0.1.8", + "jiff-static 0.2.46", + "jiff-tzdb-platform 0.1.3", + "log", + "portable-atomic", + "portable-atomic-util", + "serde_core", + "windows-link", +] + +[[package]] +name = "jiff" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "107f2e89536b6818514025f6787b0d94d819e54fe3b40365275fc753de485b3f" +dependencies = [ + "jiff-core 1.0.2", + "jiff-static 1.0.3", + "jiff-tzdb-platform 1.0.0", + "log", + "portable-atomic", + "portable-atomic-util", + "serde_core", + "windows-link", +] + +[[package]] +name = "jiff-core" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e599b80292e597019b8b3e392de3f4bea2959ddfb8c7dff60e035e9e311a2c1b" +dependencies = [ + "log", +] + +[[package]] +name = "jiff-core" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d44c923edf2bf456a982253f1a9ee1f6e89e421dffd0065d9b9a581da0def58f" +dependencies = [ + "log", +] + +[[package]] +name = "jiff-static" +version = "0.2.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7b1af7547d47354bc438d797e3854601bde8f8d185780c5ba4ab27afa54f1ba" +dependencies = [ + "jiff-core 0.1.8", + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "jiff-static" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4996f71e569e3a3e32b925c28ef8f0027dc30bb1d594b33eeda409eea185f5c8" +dependencies = [ + "jiff-core 1.0.2", + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "jiff-tzdb" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0980fca2cc272465bd60e82397607ba9f33add9e48defd77923301bbd03808f2" + +[[package]] +name = "jiff-tzdb" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "12e71a1b68a875a44a33bb7a1dd84392cb77145a3367a552a3cfe6a4f5cf3afc" + +[[package]] +name = "jiff-tzdb-platform" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "875a5a69ac2bab1a891711cf5eccbec1ce0341ea805560dcd90b7a2e925132e8" +dependencies = [ + "jiff-tzdb 0.1.10", +] + +[[package]] +name = "jiff-tzdb-platform" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc65b284afcfa8f6cf189c7274c805505314a7ab975c60e1f548bff56525420e" +dependencies = [ + "jiff-tzdb 1.0.0", +] + +[[package]] +name = "jni" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a87aa2bb7d2af34197c04845522473242e1aa17c12f4935d5856491a7fb8c97" +dependencies = [ + "cesu8", + "cfg-if", + "combine", + "jni-sys 0.3.1", + "log", + "thiserror 1.0.69", + "walkdir", + "windows-sys 0.45.0", +] + +[[package]] +name = "jni-sys" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41a652e1f9b6e0275df1f15b32661cf0d4b78d4d87ddec5e0c3c20f097433258" +dependencies = [ + "jni-sys 0.4.1", +] + +[[package]] +name = "jni-sys" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6377a88cb3910bee9b0fa88d4f42e1d2da8e79915598f65fb0c7ee14c878af2" +dependencies = [ + "jni-sys-macros", +] + +[[package]] +name = "jni-sys-macros" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38c0b942f458fe50cdac086d2f946512305e5631e720728f2a61aabcd47a6264" +dependencies = [ + "quote", + "syn 2.0.119", +] + +[[package]] +name = "js-sys" +version = "0.3.107" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8dc09d2154098bbf4ef54eab6b117a3c24cbbffe94046b16ee6d6d4510584d3a" +dependencies = [ + "cfg-if", + "futures-util", + "wasm-bindgen", +] + +[[package]] +name = "json-patch" +version = "4.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7421438de105a0827e44fadd05377727847d717c80ce29a229f85fd04c427b72" +dependencies = [ + "jsonptr", + "serde", + "serde_json", + "thiserror 2.0.21", +] + +[[package]] +name = "jsonptr" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a5a3cc660ba5d72bce0b3bb295bf20847ccbb40fd423f3f05b61273672e561fe" +dependencies = [ + "serde", + "serde_json", +] + +[[package]] +name = "keyboard-types" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fbe853b403ae61a04233030ae8a79d94975281ed9770a1f9e246732b534b28d" +dependencies = [ + "bitflags 2.13.2", + "serde", +] + +[[package]] +name = "libappindicator" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "03589b9607c868cc7ae54c0b2a22c8dc03dd41692d48f2d7df73615c6a95dc0a" +dependencies = [ + "glib", + "gtk", + "gtk-sys", + "libappindicator-sys", + "log", +] + +[[package]] +name = "libappindicator-sys" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e9ec52138abedcc58dc17a7c6c0c00a2bdb4f3427c7f63fa97fd0d859155caf" +dependencies = [ + "gtk-sys", + "libloading", + "once_cell", +] + +[[package]] +name = "libc" +version = "0.2.191" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "65cd87c9a6d60536580b316ad985726104730a5151c99845f2490428ef91240a" + +[[package]] +name = "libdbus-sys" +version = "0.2.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "328c4789d42200f1eeec05bd86c9c13c7f091d2ba9a6ea35acdf51f31bc0f043" +dependencies = [ + "pkg-config", +] + +[[package]] +name = "libloading" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b67380fd3b2fbe7527a606e18729d21c6f3951633d0500574c4dc22d2d638b9f" +dependencies = [ + "cfg-if", + "winapi", +] + +[[package]] +name = "libredox" +version = "0.1.25" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61ff90caf6077a803a240f62fdbe88645a890bbca49ef8174c3cb0404362171d" +dependencies = [ + "libc", +] + +[[package]] +name = "link-section" +version = "0.19.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d9aae57673c1a235149777a74d152f3210ebd3e3b13346d2cdb6809e566bd3c" + +[[package]] +name = "linux-raw-sys" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32a66949e030da00e8c7d4434b251670a91556f4144941d37452769c25d58a53" + +[[package]] +name = "litemap" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47d9d19d1d6efa0109d2f65ff4c85cddd50bd572e5a00127ab10987290bcefae" + +[[package]] +name = "lock_api" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "224399e74b87b5f3557511d98dff8b14089b3dadafcab6bb93eab67d3aace965" +dependencies = [ + "scopeguard", +] + +[[package]] +name = "log" +version = "0.4.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d15f86d12da44cd8d4ec3c73984537eb7f4cadcb9776a575a0a8a05ca11005c" + +[[package]] +name = "mac-notification-sys" +version = "0.6.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd604973958ddcc11b561193c0fb96ba146506ef2f231ef2e7c35fd2cbc9beca" +dependencies = [ + "cc", + "log", + "objc2", + "objc2-foundation", + "time", + "uuid", +] + +[[package]] +name = "markup5ever" +version = "0.39.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7122d987ec5f704ee56f6e5b41a7d93722e9aae27ae07cafa4036c4d3f9757de" +dependencies = [ + "log", + "tendril", + "web_atoms 0.2.6", +] + +[[package]] +name = "markup5ever" +version = "0.40.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ab3dc68ac4a0f5719e560136778c1ee716e296030d75dbd4484e37e39e3a842" +dependencies = [ + "log", + "tendril", + "web_atoms 0.3.0", +] + +[[package]] +name = "memchr" +version = "2.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98" + +[[package]] +name = "memoffset" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" +dependencies = [ + "autocfg", +] + +[[package]] +name = "mime" +version = "0.3.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5848f5a9e8117cf94f2f90faac24a87ff81600ff8628c1e3deaab572e76bfa1" + +[[package]] +name = "miniz_oxide" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316" +dependencies = [ + "adler2", + "simd-adler32", +] + +[[package]] +name = "miniz_oxide" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b63fbc4a50860e98e7b2aa7804ded1db5cbc3aff9193adaff57a6931bf7c4b4c" +dependencies = [ + "adler2", + "simd-adler32", +] + +[[package]] +name = "mio" +version = "1.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20521a903f02b0a573cd6840e9d0a5a0cc043d361fe924092cd70f8556cc9c4a" +dependencies = [ + "libc", + "wasi", + "windows-sys 0.61.2", +] + +[[package]] +name = "moxcms" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb85c154ba489f01b25c0d36ae69a87e4a1c73a72631fc6c0eb6dde34a73e44b" +dependencies = [ + "num-traits", + "pxfm", +] + +[[package]] +name = "muda" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cca139e57da4383727f189e43e66e84fa372347027fc996f9f1a007ec0a37996" +dependencies = [ + "crossbeam-channel", + "dpi", + "gtk", + "keyboard-types", + "objc2", + "objc2-app-kit", + "objc2-core-foundation", + "objc2-foundation", + "once_cell", + "png", + "serde", + "thiserror 2.0.21", + "windows-sys 0.61.2", +] + +[[package]] +name = "native-tls" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "465500e14ea162429d264d44189adc38b199b62b1c21eea9f69e4b73cb03bbf2" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe 0.2.2", + "openssl-sys", + "schannel", + "security-framework 3.7.0", + "security-framework-sys", + "tempfile", +] + +[[package]] +name = "ndk" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3f42e7bbe13d351b6bead8286a43aac9534b82bd3cc43e47037f012ebfd62d4" +dependencies = [ + "bitflags 2.13.2", + "jni-sys 0.3.1", + "log", + "ndk-sys", + "num_enum", + "raw-window-handle", + "thiserror 1.0.69", +] + +[[package]] +name = "ndk-context" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "27b02d87554356db9e9a873add8782d4ea6e3e58ea071a9adb9a2e8ddb884a8b" + +[[package]] +name = "ndk-sys" +version = "0.6.0+11769913" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee6cda3051665f1fb8d9e08fc35c96d5a244fb1be711a03b71118828afc9a873" +dependencies = [ + "jni-sys 0.3.1", +] + +[[package]] +name = "new_debug_unreachable" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086" + +[[package]] +name = "nix" +version = "0.31.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bc81ce8148d3b4f3274da811f11cdd824ae661ee4ef732cdb229825cf5be7f7" +dependencies = [ + "bitflags 2.13.2", + "cfg-if", + "cfg_aliases", + "libc", +] + +[[package]] +name = "notify-rust" +version = "4.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57da5b5d3b7809bf71858da5a2818c3404ca4688c02c8abecdda0fcdec235df3" +dependencies = [ + "futures-lite", + "log", + "mac-notification-sys", + "serde", + "tauri-winrt-notification", + "zbus 6.5.0", +] + +[[package]] +name = "num-conv" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "521739c6d2bac4aa25192232afe6841231376b2b26d4d9fae5ecf8ca5772e441" + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "num_enum" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d0bca838442ec211fa11de3a8b0e0e8f3a4522575b5c4c06ed722e005036f26" +dependencies = [ + "num_enum_derive", + "rustversion", +] + +[[package]] +name = "num_enum_derive" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "680998035259dcfcafe653688bf2aa6d3e2dc05e98be6ab46afb089dc84f1df8" +dependencies = [ + "proc-macro-crate 3.5.0", + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "objc2" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08849bbd4767dfae9457696856ae1c84fe4e0281bbe4a7abff2d0e06fb7981f8" +dependencies = [ + "objc2-encode", + "objc2-exception-helper", +] + +[[package]] +name = "objc2-app-kit" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d49e936b501e5c5bf01fda3a9452ff86dc3ea98ad5f283e1455153142d97518c" +dependencies = [ + "bitflags 2.13.2", + "block2", + "objc2", + "objc2-core-foundation", + "objc2-foundation", + "objc2-quartz-core", +] + +[[package]] +name = "objc2-cloud-kit" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73ad74d880bb43877038da939b7427bba67e9dd42004a18b809ba7d87cee241c" +dependencies = [ + "bitflags 2.13.2", + "objc2", + "objc2-foundation", +] + +[[package]] +name = "objc2-core-data" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b402a653efbb5e82ce4df10683b6b28027616a2715e90009947d50b8dd298fa" +dependencies = [ + "objc2", + "objc2-foundation", +] + +[[package]] +name = "objc2-core-foundation" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a180dd8642fa45cdb7dd721cd4c11b1cadd4929ce112ebd8b9f5803cc79d536" +dependencies = [ + "bitflags 2.13.2", + "dispatch2", + "objc2", +] + +[[package]] +name = "objc2-core-graphics" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e022c9d066895efa1345f8e33e584b9f958da2fd4cd116792e15e07e4720a807" +dependencies = [ + "bitflags 2.13.2", + "dispatch2", + "objc2", + "objc2-core-foundation", + "objc2-io-surface", +] + +[[package]] +name = "objc2-core-image" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5d563b38d2b97209f8e861173de434bd0214cf020e3423a52624cd1d989f006" +dependencies = [ + "objc2", + "objc2-foundation", +] + +[[package]] +name = "objc2-core-location" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca347214e24bc973fc025fd0d36ebb179ff30536ed1f80252706db19ee452009" +dependencies = [ + "objc2", + "objc2-foundation", +] + +[[package]] +name = "objc2-core-text" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0cde0dfb48d25d2b4862161a4d5fcc0e3c24367869ad306b0c9ec0073bfed92d" +dependencies = [ + "bitflags 2.13.2", + "objc2", + "objc2-core-foundation", + "objc2-core-graphics", +] + +[[package]] +name = "objc2-encode" +version = "4.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef25abbcd74fb2609453eb695bd2f860d389e457f67dc17cafc8b8cbc89d0c33" + +[[package]] +name = "objc2-exception-helper" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7a1c5fbb72d7735b076bb47b578523aedc40f3c439bea6dfd595c089d79d98a" +dependencies = [ + "cc", +] + +[[package]] +name = "objc2-foundation" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3e0adef53c21f888deb4fa59fc59f7eb17404926ee8a6f59f5df0fd7f9f3272" +dependencies = [ + "bitflags 2.13.2", + "block2", + "libc", + "objc2", + "objc2-core-foundation", +] + +[[package]] +name = "objc2-io-surface" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "180788110936d59bab6bd83b6060ffdfffb3b922ba1396b312ae795e1de9d81d" +dependencies = [ + "bitflags 2.13.2", + "objc2", + "objc2-core-foundation", +] + +[[package]] +name = "objc2-quartz-core" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96c1358452b371bf9f104e21ec536d37a650eb10f7ee379fff67d2e08d537f1f" +dependencies = [ + "bitflags 2.13.2", + "objc2", + "objc2-core-foundation", + "objc2-foundation", +] + +[[package]] +name = "objc2-security" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "709fe137109bd1e8b5a99390f77a7d8b2961dafc1a1c5db8f2e60329ad6d895a" +dependencies = [ + "bitflags 2.13.2", + "objc2", + "objc2-core-foundation", +] + +[[package]] +name = "objc2-service-management" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b213642d6959cc6023ceb1217aa595eaaf09b8094ce95127c103cab611fe65e8" +dependencies = [ + "block2", + "objc2", + "objc2-core-foundation", + "objc2-foundation", + "objc2-security", +] + +[[package]] +name = "objc2-ui-kit" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d87d638e33c06f577498cbcc50491496a3ed4246998a7fbba7ccb98b1e7eab22" +dependencies = [ + "bitflags 2.13.2", + "block2", + "objc2", + "objc2-cloud-kit", + "objc2-core-data", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-core-image", + "objc2-core-location", + "objc2-core-text", + "objc2-foundation", + "objc2-quartz-core", + "objc2-user-notifications", +] + +[[package]] +name = "objc2-user-notifications" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9df9128cbbfef73cda168416ccf7f837b62737d748333bfe9ab71c245d76613e" +dependencies = [ + "objc2", + "objc2-foundation", +] + +[[package]] +name = "objc2-web-kit" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2e5aaab980c433cf470df9d7af96a7b46a9d892d521a2cbbb2f8a4c16751e7f" +dependencies = [ + "bitflags 2.13.2", + "block2", + "objc2", + "objc2-app-kit", + "objc2-core-foundation", + "objc2-foundation", +] + +[[package]] +name = "once_cell" +version = "1.21.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50" + +[[package]] +name = "open" +version = "5.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d8c8b8e725ad26404d6896eb2f064294a0a7b4f1d9120210d85544684c4ca95" +dependencies = [ + "dunce", + "is-wsl", + "libc", +] + +[[package]] +name = "openssl" +version = "0.10.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4de8111e94a56adca7ebfe6c365b6d42f99deb69b74b6becacd4204e2f193aa2" +dependencies = [ + "bitflags 2.13.2", + "cfg-if", + "foreign-types 0.3.2", + "libc", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "openssl-probe" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d05e27ee213611ffe7d6348b942e8f942b37114c00cc03cec254295a4a17852e" + +[[package]] +name = "openssl-probe" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e036b411754132fd6b74e94b74e9a13c5cf606fa93d1885c35860d3060820b1" + +[[package]] +name = "openssl-sys" +version = "0.9.118" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19c413d6ec9ebaf5e1c829d355cb3e9f783778d700f135be0921d52fce3c60ae" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "option-ext" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" + +[[package]] +name = "ordered-stream" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9aa2b01e1d916879f73a53d01d1d6cee68adbb31d6d9177a8cfce093cced1d50" +dependencies = [ + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "os_info" +version = "3.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf20a545b305cf1da722b236b5155c9bb35f1d5ceb28c048bd96ca842f41b5b" +dependencies = [ + "android_system_properties", + "log", + "nix", + "objc2", + "objc2-foundation", + "objc2-ui-kit", + "windows-sys 0.61.2", +] + +[[package]] +name = "pango" +version = "0.18.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ca27ec1eb0457ab26f3036ea52229edbdb74dee1edd29063f5b9b010e7ebee4" +dependencies = [ + "gio", + "glib", + "libc", + "once_cell", + "pango-sys", +] + +[[package]] +name = "pango-sys" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "436737e391a843e5933d6d9aa102cb126d501e815b83601365a948a518555dc5" +dependencies = [ + "glib-sys", + "gobject-sys", + "libc", + "system-deps", +] + +[[package]] +name = "parking" +version = "2.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba" + +[[package]] +name = "parking_lot" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93857453250e3077bd71ff98b6a65ea6621a19bb0f559a85248955ac12c45a1a" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2621685985a2ebf1c516881c026032ac7deafcda1a2c9b7850dc81e3dfcb64c1" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall", + "smallvec", + "windows-link", +] + +[[package]] +name = "percent-encoding" +version = "2.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" + +[[package]] +name = "phf" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1562dc717473dbaa4c1f85a36410e03c047b2e7df7f45ee938fbef64ae7fadf" +dependencies = [ + "phf_macros 0.13.1", + "phf_shared 0.13.1", + "serde", +] + +[[package]] +name = "phf" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "010378780309880b08997fae13be7834dba947d36393bd372f2b1556deb2a2f6" +dependencies = [ + "phf_macros 0.14.0", + "phf_shared 0.14.0", + "serde", +] + +[[package]] +name = "phf_codegen" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49aa7f9d80421bca176ca8dbfebe668cc7a2684708594ec9f3c0db0805d5d6e1" +dependencies = [ + "phf_generator 0.13.1", + "phf_shared 0.13.1", +] + +[[package]] +name = "phf_codegen" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41b585a510fb76fdebead6897982ef2a03a21d8e6cbcca904999742a4afc6ffe" +dependencies = [ + "phf_generator 0.14.0", + "phf_shared 0.14.0", +] + +[[package]] +name = "phf_generator" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "135ace3a761e564ec88c03a77317a7c6b80bb7f7135ef2544dbe054243b89737" +dependencies = [ + "fastrand", + "phf_shared 0.13.1", +] + +[[package]] +name = "phf_generator" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aeb62e0959d5a1bebc965f4d15d9e2b7cea002b6b0f5ba8cde6cc26738467100" +dependencies = [ + "fastrand", + "phf_shared 0.14.0", +] + +[[package]] +name = "phf_macros" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "812f032b54b1e759ccd5f8b6677695d5268c588701effba24601f6932f8269ef" +dependencies = [ + "phf_generator 0.13.1", + "phf_shared 0.13.1", + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "phf_macros" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5fa8d0ca26d424d27630da600c6624696e7dec8bf7b3b492b383c5dc49e5e085" +dependencies = [ + "phf_generator 0.14.0", + "phf_shared 0.14.0", + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "phf_shared" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e57fef6bc5981e38c2ce2d63bfa546861309f875b8a75f092d1d54ae2d64f266" +dependencies = [ + "siphasher", +] + +[[package]] +name = "phf_shared" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6fd9027e2d9319be6349febd1db4e8d02aa544921200c9b777720ac34a3aa89" +dependencies = [ + "siphasher", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c938015719552d665fd0553b90d96cd7ff58e83e4c061ca99e6bb78865a72752" + +[[package]] +name = "piper" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c835479a4443ded371d6c535cbfd8d31ad92c5d23ae9770a61bc155e4992a3c1" +dependencies = [ + "atomic-waker", + "fastrand", + "futures-io", +] + +[[package]] +name = "pkg-config" +version = "0.3.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6b464fbc74e149a392436b17d523f769e057cb6877f6a5c4618bc6f11800548" + +[[package]] +name = "plist" +version = "1.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb7a42747bbcc4374e6922a15040dccacf720e4ce48a77e668f7116b9aa19a0a" +dependencies = [ + "base64 0.23.1", + "indexmap 2.14.2", + "quick-xml", + "serde", + "time", +] + +[[package]] +name = "png" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61" +dependencies = [ + "bitflags 2.13.2", + "crc32fast", + "fdeflate", + "flate2", + "miniz_oxide 0.8.9", +] + +[[package]] +name = "polling" +version = "3.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d0e4f59085d47d8241c88ead0f274e8a0cb551f3625263c05eb8dd897c34218" +dependencies = [ + "cfg-if", + "concurrent-queue", + "hermit-abi", + "pin-project-lite", + "rustix", + "windows-sys 0.61.2", +] + +[[package]] +name = "portable-atomic" +version = "1.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05c8b63e8d9609db387f0324918f81d68fe27748f084ef092fb35954d0539a85" + +[[package]] +name = "portable-atomic-util" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "10ab3eb7f3becc3a1cbc4f2c6f20267996cfc1a6467a873763411b136a122715" +dependencies = [ + "portable-atomic", +] + +[[package]] +name = "potential_utf" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d83eb9bc6d8e5cf568e7a1101d60ee05e81ed50ea106026f3d18deeb046d7661" +dependencies = [ + "zerovec", +] + +[[package]] +name = "powerfmt" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a6394b9e965e73d0a289ee54f589087e2c676aedf60885baf52c76b771e4958" + +[[package]] +name = "precomputed-hash" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" + +[[package]] +name = "proc-macro-crate" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" +dependencies = [ + "once_cell", + "toml_edit 0.19.15", +] + +[[package]] +name = "proc-macro-crate" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b00f26d3400549137f92511a46ac1cd8ce37cb5598a96d382381458b992a5d24" +dependencies = [ + "toml_datetime 0.6.3", + "toml_edit 0.20.2", +] + +[[package]] +name = "proc-macro-crate" +version = "3.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f" +dependencies = [ + "toml_edit 0.25.21+spec-1.1.0", +] + +[[package]] +name = "proc-macro-error" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" +dependencies = [ + "proc-macro-error-attr", + "proc-macro2", + "quote", + "syn 1.0.109", + "version_check", +] + +[[package]] +name = "proc-macro-error-attr" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" +dependencies = [ + "proc-macro2", + "quote", + "version_check", +] + +[[package]] +name = "proc-macro2" +version = "1.0.107" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "985e7ec9bb745e6ce6535b544d84d6cd6f7ad8bd711c398938ae983b91a766d9" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "pxfm" +version = "0.1.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d55d956fa96f5ec02be2e13af0e20391a5aa83d6a074e3ad368959d0fab299ea" + +[[package]] +name = "quick-xml" +version = "0.42.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41b1177fdf999d2321d3fb46ff47159d9c1fb9ad66a4879f8c50a0b504615e9b" +dependencies = [ + "memchr", +] + +[[package]] +name = "quote" +version = "1.0.47" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fbf4db142a473a8d80c26bbf18454ed458bf8d26c8219c331daecfdbd079001" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "r-efi" +version = "5.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f" + +[[package]] +name = "r-efi" +version = "6.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf" + +[[package]] +name = "rand" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f6fa277c67e6ea590466f04c3fe82cb509f0864fe470643e5570de9514a9b11" +dependencies = [ + "chacha20", + "getrandom 0.4.3", + "rand_core", +] + +[[package]] +name = "rand_core" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69" + +[[package]] +name = "raw-window-handle" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539" + +[[package]] +name = "redox_syscall" +version = "0.5.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d" +dependencies = [ + "bitflags 2.13.2", +] + +[[package]] +name = "redox_users" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60dc65c0ff1a7ae1294b0c67b9f14baf70b644404010370171787bfac1038fc0" +dependencies = [ + "libredox", + "thiserror 2.0.21", +] + +[[package]] +name = "ref-cast" +version = "1.0.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e440fb4e4b4147295338efb76001ab9e4efc0e5839df2c47fc5ac2381d365c3" +dependencies = [ + "ref-cast-impl", +] + +[[package]] +name = "ref-cast-impl" +version = "1.0.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92ecd8964f8453721699a1ed72037b0db49ce2f5a5138486ee89bed6f67cdf3a" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "regex" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9807af0e638c12e753aa1b4e601791bf2a8f71274023c8bbeec12fc149950857" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41d60ef07df457506a0a1a2073112eb4aae5733dbd2813c3da77d1b0fd441158" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d902046e6a28a1e4c3cab97258a0ce11e994903f01c2d97a9447a0b3df85f4f6" + +[[package]] +name = "reqwest" +version = "0.13.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "16a1cfa75cc186dd73d5818e510e042e40927bccc9c236b061cea97e1eb08029" +dependencies = [ + "base64 0.23.1", + "bytes", + "futures-core", + "futures-util", + "http", + "http-body", + "http-body-util", + "hyper", + "hyper-util", + "js-sys", + "log", + "percent-encoding", + "pin-project-lite", + "serde", + "serde_json", + "sync_wrapper", + "tokio", + "tokio-util", + "tower", + "tower-http", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "wasm-streams", + "web-sys", +] + +[[package]] +name = "rfd" +version = "0.17.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20dafead71c16a34e1ff357ddefc8afc11e7d51d6d2b9fbd07eaa48e3e540220" +dependencies = [ + "block2", + "dispatch2", + "glib-sys", + "gobject-sys", + "gtk-sys", + "js-sys", + "libc", + "log", + "objc2", + "objc2-app-kit", + "objc2-core-foundation", + "objc2-foundation", + "percent-encoding", + "raw-window-handle", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "windows-sys 0.61.2", +] + +[[package]] +name = "ring" +version = "0.17.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7" +dependencies = [ + "cc", + "cfg-if", + "getrandom 0.2.17", + "libc", + "untrusted", + "windows-sys 0.52.0", +] + +[[package]] +name = "rustc-hash" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d" + +[[package]] +name = "rustc_version" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "1.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5e76742e5294153d4dde1207dbec5bdd81eef6fabdc0d2118babadabfd858aa" +dependencies = [ + "bitflags 2.13.2", + "errno", + "libc", + "linux-raw-sys", + "windows-sys 0.61.2", +] + +[[package]] +name = "rustls" +version = "0.23.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48e13bd8c0e9365c43cfa5c9e8f9ad49d3c8444926c9aac819e0e4dc503c8fdf" +dependencies = [ + "log", + "once_cell", + "ring", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + +[[package]] +name = "rustls-native-certs" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5bfb394eeed242e909609f56089eecfe5fda225042e8b171791b9c95f5931e5" +dependencies = [ + "openssl-probe 0.1.6", + "rustls-pemfile", + "rustls-pki-types", + "schannel", + "security-framework 2.11.1", +] + +[[package]] +name = "rustls-pemfile" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dce314e5fee3f39953d46bb63bb8a46d40c2f8fb7cc5a3b6cab2bde9721d6e50" +dependencies = [ + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "102f35f7de7b06d8c61f1cff6592f5253e0dea431c74867aad5dfd70f44663fb" +dependencies = [ + "zeroize", +] + +[[package]] +name = "rustls-webpki" +version = "0.103.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3a0760a887c14823fca5a1c970b01d47c328c696c0c64829d1df50e8f853fd5" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + +[[package]] +name = "rustversion" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "schannel" +version = "0.1.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cb23c424d8ee841bb4d813677ca237e2a610067d594fec130f87d6093495ab5" +dependencies = [ + "windows-sys 0.61.2", +] + +[[package]] +name = "schemars" +version = "0.8.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fbf2ae1b8bc8e02df939598064d22402220cd5bbcca1c76f7d6a310974d5615" +dependencies = [ + "dyn-clone", + "indexmap 1.9.3", + "schemars_derive", + "serde", + "serde_json", + "url", + "uuid", +] + +[[package]] +name = "schemars" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4cd191f9397d57d581cddd31014772520aa448f65ef991055d7f61582c65165f" +dependencies = [ + "dyn-clone", + "ref-cast", + "serde", + "serde_json", +] + +[[package]] +name = "schemars" +version = "1.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ab508826f74a77ca9d5aba6ff19b522583ee3eaf28a19384ff3d0e5835fadf6e" +dependencies = [ + "dyn-clone", + "ref-cast", + "serde", + "serde_json", +] + +[[package]] +name = "schemars_derive" +version = "0.8.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32e265784ad618884abaea0600a9adf15393368d840e0222d101a072f3f7534d" +dependencies = [ + "proc-macro2", + "quote", + "serde_derive_internals", + "syn 2.0.119", +] + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "security-framework" +version = "2.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02" +dependencies = [ + "bitflags 2.13.2", + "core-foundation 0.9.4", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework" +version = "3.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b7f4bc775c73d9a02cde8bf7b2ec4c9d12743edf609006c7facc23998404cd1d" +dependencies = [ + "bitflags 2.13.2", + "core-foundation 0.10.1", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ce2691df843ecc5d231c0b14ece2acc3efb62c0a398c7e1d875f3983ce020e3" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "selectors" +version = "0.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8adfa1c298912827b8a28b223b3b874357397ae706e6190acd9bf28cee99114d" +dependencies = [ + "bitflags 2.13.2", + "cssparser 0.37.0", + "derive_more", + "log", + "new_debug_unreachable", + "phf 0.13.1", + "phf_codegen 0.13.1", + "precomputed-hash", + "rustc-hash", + "servo_arc 0.4.3", + "smallvec", +] + +[[package]] +name = "selectors" +version = "0.41.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8322aebea94a6cc288ff884e8a49bdbceef60206c400c6c46d22e62fc4fd91a6" +dependencies = [ + "bitflags 2.13.2", + "cssparser 0.38.0", + "derive_more", + "log", + "new_debug_unreachable", + "precomputed-hash", + "rustc-hash", + "servo_arc 0.5.0", + "smallvec", +] + +[[package]] +name = "semver" +version = "1.0.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd" +dependencies = [ + "serde", + "serde_core", +] + +[[package]] +name = "serde" +version = "1.0.229" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4148590afebada386688f18773da617792bf2ef03ffc1e4cbd2b1d45b023e0ba" +dependencies = [ + "serde_core", + "serde_derive", +] + +[[package]] +name = "serde-untagged" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f9faf48a4a2d2693be24c6289dbe26552776eb7737074e6722891fadbe6c5058" +dependencies = [ + "erased-serde", + "serde", + "serde_core", + "typeid", +] + +[[package]] +name = "serde_core" +version = "1.0.229" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67dca2c9c51e58a4791a4b1ed58308b39c64224d349a935ab5039aa360942a48" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.229" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7a5d71263a5a7d47b41f6b3f06ba276f10cc18b0931f1799f710578e2309348" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "serde_derive_internals" +version = "0.29.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "18d26a20a969b9e3fdf2fc2d9f21eda6c40e2de84c9408bb5d3b05d499aae711" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "serde_json" +version = "1.0.154" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7e9cc8b1b85264074fbcc02a88680c4096b1e47df8f739dceb03bf482f04bd6" +dependencies = [ + "itoa", + "memchr", + "serde", + "serde_core", + "zmij", +] + +[[package]] +name = "serde_repr" +version = "0.1.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d3b1629de253c70a0508c3899572da79ca359fdab27c7920ff00406df418906" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "serde_spanned" +version = "0.6.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bf41e0cfaf7226dca15e8197172c295a782857fcb97fad1808a166870dee75a3" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_spanned" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c187e0a369471c550af028cba56d4f4fa2a489ad28151ae95a4d340a2a8b782" +dependencies = [ + "serde_core", +] + +[[package]] +name = "serde_with" +version = "3.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56cb1ca7c93ae63d6439b5250f6b6b040f7e121f32e5dd2f5d523dd4149b3204" +dependencies = [ + "base64 0.23.1", + "bs58", + "chrono", + "hex", + "indexmap 1.9.3", + "indexmap 2.14.2", + "jiff 0.2.46", + "jiff 1.0.3", + "schemars 0.9.0", + "schemars 1.2.3", + "serde_core", + "serde_json", + "serde_with_macros", + "time", +] + +[[package]] +name = "serde_with_macros" +version = "3.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cff15a7c864bbec77d9586ca6822bc7c369bdf19e9243134a62b0b51ce26b31f" +dependencies = [ + "darling", + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "serialize-to-javascript" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "04f3666a07a197cdb77cdf306c32be9b7f598d7060d50cfd4d5aa04bfd92f6c5" +dependencies = [ + "serde", + "serde_json", + "serialize-to-javascript-impl", +] + +[[package]] +name = "serialize-to-javascript-impl" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "772ee033c0916d670af7860b6e1ef7d658a4629a6d0b4c8c3e67f09b3765b75d" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "servo_arc" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "170fb83ab34de17dc69aa7c67482b22218ddb85da56546f9bd6b929e32a05930" +dependencies = [ + "stable_deref_trait", +] + +[[package]] +name = "servo_arc" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4eceb519ec34d8290aaf6e46f435102f2bfa63f22b05a144fb16ab266d3b198" +dependencies = [ + "stable_deref_trait", +] + +[[package]] +name = "sha2" +version = "0.10.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283" +dependencies = [ + "cfg-if", + "cpufeatures 0.2.17", + "digest 0.10.7", +] + +[[package]] +name = "sha2" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b0e5c7d67bc53f435386b2130fdc900488c5703770f6d8a4633060e34288a27" +dependencies = [ + "cfg-if", + "cpufeatures 0.3.1", + "digest 0.11.3", +] + +[[package]] +name = "shlex" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba" + +[[package]] +name = "signal-hook-registry" +version = "1.4.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4db69cba1110affc0e9f7bcd48bbf87b3f4fc7c61fc9155afd4c469eb3d6c1b" +dependencies = [ + "errno", + "libc", +] + +[[package]] +name = "simd-adler32" +version = "0.3.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a219298ac11a56ea9a6d2120044824d6f01aeb034955e7af7bc16858527deea" + +[[package]] +name = "siphasher" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "33f4fe9184a62d842c9ef383018f3306d8ba224fd9d836f56d7288308847c256" + +[[package]] +name = "slab" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5" + +[[package]] +name = "smallvec" +version = "1.16.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3244542535d5de959d90ec55d1b5ff0fd2bb7b1310223907d5f11932847f7b59" + +[[package]] +name = "smappservice-rs" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52703b97a53101cf5d4580e0737aaa634ce1fdcfc123c16b2a9658e358013488" +dependencies = [ + "objc2", + "objc2-foundation", + "objc2-service-management", + "thiserror 2.0.21", +] + +[[package]] +name = "socket2" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3d1e2c7f27f8d4cb10542a02c49005dbd6e93095799d6f3be745fae9f8fedd4" +dependencies = [ + "libc", + "windows-sys 0.61.2", +] + +[[package]] +name = "softbuffer" +version = "0.4.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aac18da81ebbf05109ab275b157c22a653bb3c12cf884450179942f81bcbf6c3" +dependencies = [ + "bytemuck", + "js-sys", + "ndk", + "objc2", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-foundation", + "objc2-quartz-core", + "raw-window-handle", + "redox_syscall", + "tracing", + "wasm-bindgen", + "web-sys", + "windows-sys 0.61.2", +] + +[[package]] +name = "soup3" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "471f924a40f31251afc77450e781cb26d55c0b650842efafc9c6cbd2f7cc4f9f" +dependencies = [ + "futures-channel", + "gio", + "glib", + "libc", + "soup3-sys", +] + +[[package]] +name = "soup3-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ebe8950a680a12f24f15ebe1bf70db7af98ad242d9db43596ad3108aab86c27" +dependencies = [ + "gio-sys", + "glib-sys", + "gobject-sys", + "libc", + "system-deps", +] + +[[package]] +name = "stable_deref_trait" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596" + +[[package]] +name = "static_vcruntime" +version = "3.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff7589a1859b09232522bb9edf076ca7fcf14ded96685d3fa629db73023ffbb7" + +[[package]] +name = "string_cache" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a18596f8c785a729f2819c0f6a7eae6ebeebdfffbfe4214ae6b087f690e31901" +dependencies = [ + "new_debug_unreachable", + "parking_lot", + "phf_shared 0.13.1", + "precomputed-hash", +] + +[[package]] +name = "string_cache" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ffa8a5dbe8b3f0bbe29d4c3225daafaeead63afdc1b65fc4c01a1384166038e6" +dependencies = [ + "new_debug_unreachable", + "parking_lot", + "phf_shared 0.14.0", + "precomputed-hash", +] + +[[package]] +name = "string_cache_codegen" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "585635e46db231059f76c5849798146164652513eb9e8ab2685939dd90f29b69" +dependencies = [ + "phf_generator 0.13.1", + "phf_shared 0.13.1", + "proc-macro2", + "quote", +] + +[[package]] +name = "string_cache_codegen" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "928dcdf75e47626b3617a976ec205d9f057584c371c1f23b782129268d0e6edc" +dependencies = [ + "phf_generator 0.14.0", + "phf_shared 0.14.0", + "proc-macro2", + "quote", +] + +[[package]] +name = "strsim" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "swift-rs" +version = "1.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cefd87076fd385308ee4aff597256c902f1fbb4d031de1558efc12f8ffefadd9" +dependencies = [ + "base64 0.21.7", + "serde", + "serde_json", +] + +[[package]] +name = "syn" +version = "1.0.109" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" +dependencies = [ + "proc-macro2", + "unicode-ident", +] + +[[package]] +name = "syn" +version = "2.0.119" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "syn" +version = "3.0.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ae9ccbea3a7b0b09443036490c8f34a8b1b760fd345e5c0dae0aac718faea79" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "sync_wrapper" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263" +dependencies = [ + "futures-core", +] + +[[package]] +name = "synstructure" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "901704edd0dfe137f1987838ee4f259e4e063c31371bdb423f7ae38ec6f77f02" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "system-deps" +version = "6.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a3e535eb8dded36d55ec13eddacd30dec501792ff23a0b1682c38601b8cf2349" +dependencies = [ + "cfg-expr", + "heck 0.5.0", + "pkg-config", + "toml 0.8.2", + "version-compare", +] + +[[package]] +name = "tao" +version = "0.37.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02ca9c0ce2a2fd70dc4ef4449ca5e8d30e6fa0db111cd8008594602a06a68371" +dependencies = [ + "bitflags 2.13.2", + "block2", + "core-foundation 0.10.1", + "core-graphics", + "crossbeam-channel", + "dbus", + "dispatch2", + "dlopen2", + "dpi", + "gdkwayland-sys", + "gdkx11-sys", + "gtk", + "jni", + "libc", + "log", + "ndk", + "ndk-context", + "ndk-sys", + "objc2", + "objc2-app-kit", + "objc2-foundation", + "objc2-ui-kit", + "parking_lot", + "percent-encoding", + "raw-window-handle", + "tao-macros", + "unicode-segmentation", + "url", + "windows", + "windows-core", + "windows-version", + "x11-dl", +] + +[[package]] +name = "tao-macros" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f7eeb6d99155545da6150a1795945f16ac9c178deb2a5f2e74d776107bd5849" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "tar" +version = "0.4.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f6221d9a6003c78398e3b239969f352578258df48c8eb051caadae0015bc840" +dependencies = [ + "filetime", + "libc", + "xattr", +] + +[[package]] +name = "target-lexicon" +version = "0.12.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1" + +[[package]] +name = "tauri" +version = "2.12.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "30fbfbb9dc9a2697b0e96d909ddc295fb18d2d82a58ed542ab8d9eba2edbe6da" +dependencies = [ + "anyhow", + "bytes", + "cookie", + "dirs 7.0.0", + "dunce", + "embed_plist", + "getrandom 0.3.4", + "glob", + "gtk", + "heck 0.5.0", + "http", + "image", + "jni", + "libc", + "log", + "mime", + "muda", + "objc2", + "objc2-app-kit", + "objc2-foundation", + "objc2-ui-kit", + "objc2-web-kit", + "percent-encoding", + "plist", + "raw-window-handle", + "reqwest", + "serde", + "serde_json", + "serde_repr", + "serialize-to-javascript", + "swift-rs", + "tauri-build", + "tauri-macros", + "tauri-runtime", + "tauri-runtime-wry", + "tauri-utils", + "thiserror 2.0.21", + "tokio", + "tray-icon", + "url", + "webkit2gtk", + "webview2-com", + "window-vibrancy", + "windows", +] + +[[package]] +name = "tauri-build" +version = "2.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73d80784e874fa117b9b00a6680cf2f9b8a51bbd14406bea980cf8f328b00646" +dependencies = [ + "anyhow", + "cargo_toml", + "dirs 7.0.0", + "glob", + "heck 0.5.0", + "json-patch", + "schemars 0.8.22", + "semver", + "serde", + "serde_json", + "static_vcruntime", + "strsim", + "tauri-utils", + "tauri-winres", + "walkdir", +] + +[[package]] +name = "tauri-codegen" +version = "2.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c5dc6caab4da5646f57648f39b794bae118f0dd4a4305eeb8c892966171f4852" +dependencies = [ + "base64 0.23.1", + "brotli", + "ico", + "json-patch", + "plist", + "png", + "proc-macro2", + "quote", + "semver", + "serde", + "serde_json", + "sha2 0.11.2", + "syn 2.0.119", + "tauri-utils", + "thiserror 2.0.21", + "time", + "url", + "uuid", + "walkdir", +] + +[[package]] +name = "tauri-macros" +version = "2.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2831c5da8603a96b1efc0b650c2cb6decc69b6cda257d815fe70c7f5be53818e" +dependencies = [ + "heck 0.5.0", + "proc-macro2", + "quote", + "syn 2.0.119", + "tauri-codegen", + "tauri-utils", +] + +[[package]] +name = "tauri-plugin" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c18076d9b04211cb4899387aab97497e8edd0d02cd21710623afcdde27145d1" +dependencies = [ + "anyhow", + "glob", + "plist", + "schemars 0.8.22", + "serde", + "serde_json", + "tauri-utils", + "walkdir", +] + +[[package]] +name = "tauri-plugin-dialog" +version = "2.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce0fb9c2b6d34a9720627ed930ebc8af26f61e648695aecaeb03d5c33c5896f5" +dependencies = [ + "log", + "raw-window-handle", + "rfd", + "serde", + "serde_json", + "tauri", + "tauri-plugin", + "tauri-plugin-fs", + "thiserror 2.0.21", + "url", +] + +[[package]] +name = "tauri-plugin-fs" +version = "2.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d58eb1d4984e535f47a642ffec09a2da6f5c18a12b5902d12126cb7626d628b" +dependencies = [ + "anyhow", + "dunce", + "glob", + "log", + "objc2-foundation", + "percent-encoding", + "schemars 0.8.22", + "serde", + "serde_json", + "serde_repr", + "tauri", + "tauri-plugin", + "tauri-utils", + "thiserror 2.0.21", + "toml 1.2.3+spec-1.1.0", + "url", +] + +[[package]] +name = "tauri-plugin-notification" +version = "2.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "14a226bfb8189ec4ab2c1936e66330ad06c44d9f6c54a674338208491dee177f" +dependencies = [ + "log", + "notify-rust", + "rand", + "serde", + "serde_json", + "serde_repr", + "tauri", + "tauri-plugin", + "thiserror 2.0.21", + "time", + "url", + "zbus 5.19.0", +] + +[[package]] +name = "tauri-plugin-opener" +version = "2.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "54592c6718b42ab198bf11bda6a428a3553ca2f2f8e506df56f6a063ec328331" +dependencies = [ + "dunce", + "glob", + "objc2-app-kit", + "objc2-foundation", + "open", + "schemars 0.8.22", + "serde", + "serde_json", + "tauri", + "tauri-plugin", + "thiserror 2.0.21", + "url", + "windows", + "zbus 5.19.0", +] + +[[package]] +name = "tauri-plugin-single-instance" +version = "2.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "726b6da0dd5bd1344f84f4108a622c07d01923baacb5c803a605189672c5352f" +dependencies = [ + "serde", + "serde_json", + "tauri", + "thiserror 2.0.21", + "tokio", + "tracing", + "windows-sys 0.61.2", + "zbus 5.19.0", +] + +[[package]] +name = "tauri-plugin-window-state" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d6815cab7b212f9cfe16a9d79d8d22f9e14159e4a9460f7dec1467167a008e3" +dependencies = [ + "bitflags 2.13.2", + "log", + "serde", + "serde_json", + "tauri", + "tauri-plugin", + "thiserror 2.0.21", +] + +[[package]] +name = "tauri-runtime" +version = "2.12.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60c2b14bd5265b63993cdc34ad526fb836e0fd0cf64a4634a895db0784844d5e" +dependencies = [ + "cookie", + "dpi", + "gtk", + "http", + "jni", + "objc2", + "objc2-ui-kit", + "objc2-web-kit", + "raw-window-handle", + "serde", + "serde_json", + "tauri-utils", + "thiserror 2.0.21", + "url", + "webkit2gtk", + "webview2-com", + "windows", +] + +[[package]] +name = "tauri-runtime-wry" +version = "2.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8c14a025255cc9816d401635035075b09b6cc9973b7b8fd7b8fcb8753f30f92" +dependencies = [ + "gtk", + "http", + "jni", + "log", + "objc2", + "objc2-app-kit", + "percent-encoding", + "raw-window-handle", + "softbuffer", + "tao", + "tauri-runtime", + "tauri-utils", + "url", + "webkit2gtk", + "webview2-com", + "windows", + "wry", +] + +[[package]] +name = "tauri-utils" +version = "2.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "28d1d33d4453c5df0bf1672dbc7ada69d8ed74f56a4316d964a4aa73d4ecd3ad" +dependencies = [ + "anyhow", + "brotli", + "cargo_metadata", + "ctor", + "dom_query 0.28.0", + "dunce", + "glob", + "http", + "infer", + "json-patch", + "log", + "memchr", + "phf 0.13.1", + "plist", + "proc-macro2", + "quote", + "regex", + "schemars 0.8.22", + "semver", + "serde", + "serde-untagged", + "serde_json", + "serde_with", + "swift-rs", + "thiserror 2.0.21", + "toml 1.2.3+spec-1.1.0", + "url", + "urlpattern", + "uuid", + "walkdir", +] + +[[package]] +name = "tauri-winres" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c52bb6904475a6ca662f15ef787f18ade61d5740a1ee12c45d3b748efdb6f796" +dependencies = [ + "dunce", + "embed-resource", + "toml 1.2.3+spec-1.1.0", +] + +[[package]] +name = "tauri-winrt-notification" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f37a6c354fd28fc9e322ed9bd47e3959576dad28c9d58ea1cf888cce1c7ccb36" +dependencies = [ + "thiserror 2.0.21", + "windows", + "windows-version", +] + +[[package]] +name = "tempfile" +version = "3.27.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd" +dependencies = [ + "fastrand", + "getrandom 0.4.3", + "once_cell", + "rustix", + "windows-sys 0.61.2", +] + +[[package]] +name = "tendril" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5fed54709c5b3a53d09bb1c113ea4f5ceafd1e772ddcb0030a82e1d56c087b08" +dependencies = [ + "new_debug_unreachable", +] + +[[package]] +name = "thiserror" +version = "1.0.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52" +dependencies = [ + "thiserror-impl 1.0.69", +] + +[[package]] +name = "thiserror" +version = "2.0.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09e52cb86a36cede5cb101bf8908837b3e4c6e5e59fe7fd85c23fb56200d189e" +dependencies = [ + "thiserror-impl 2.0.21", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "thiserror-impl" +version = "2.0.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe5197923287db20a58125f0bc85c062f7f2c892de97b18c356f9efb14b28524" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "time" +version = "0.3.55" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cdb87b95ec50ddfa440816d227a17b2ccbdda963a316a727fda0fc4334f7d134" +dependencies = [ + "deranged", + "num-conv", + "powerfmt", + "serde_core", + "time-core", + "time-macros", +] + +[[package]] +name = "time-core" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e1c906769ad99c88eaa54e728060edef082f8e358ff32030cb7c7d315e81109" + +[[package]] +name = "time-macros" +version = "0.2.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e689342a48d2ea927c87ea50cabf8594854bf940e9310208848d680d668ed85" +dependencies = [ + "num-conv", + "time-core", +] + +[[package]] +name = "tinystr" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "abc840c238154d58f9e86b2792261edfde565a17696e1cda1a449de27979801a" +dependencies = [ + "displaydoc", + "zerovec", +] + +[[package]] +name = "tinyvec" +version = "1.13.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd3ca314f692efd6c868f8408f53fe444634a845f96c028b97d35f6a1f79f0ee" + +[[package]] +name = "tokio" +version = "1.54.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b52fd3255258d26fac7264ab5a76b53c13367136dc011d3d6ad4f8ed070396a3" +dependencies = [ + "bytes", + "libc", + "mio", + "pin-project-lite", + "socket2", + "windows-sys 0.61.2", +] + +[[package]] +name = "tokio-util" +version = "0.7.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e464cf451ba96ebfc6f9b6542f17ee8b8956e33f1e40d9690624e59d7a7f8a4b" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "toml" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d" +dependencies = [ + "serde", + "serde_spanned 0.6.9", + "toml_datetime 0.6.3", + "toml_edit 0.20.2", +] + +[[package]] +name = "toml" +version = "1.2.3+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26b1f26e9485c1fa43ee89fe76e9f3fb9e2e52bb227f8594b4d687496b83d073" +dependencies = [ + "indexmap 2.14.2", + "serde_core", + "serde_spanned 1.1.3", + "toml_datetime 1.1.3+spec-1.1.0", + "toml_parser", + "toml_writer", + "winnow 1.0.5", +] + +[[package]] +name = "toml_datetime" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_datetime" +version = "1.1.3+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "173f25c883cd2176a2d8212155638c0a60d484a9d84546d270866f40f56b6e49" +dependencies = [ + "serde_core", +] + +[[package]] +name = "toml_edit" +version = "0.19.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" +dependencies = [ + "indexmap 2.14.2", + "toml_datetime 0.6.3", + "winnow 0.5.40", +] + +[[package]] +name = "toml_edit" +version = "0.20.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" +dependencies = [ + "indexmap 2.14.2", + "serde", + "serde_spanned 0.6.9", + "toml_datetime 0.6.3", + "winnow 0.5.40", +] + +[[package]] +name = "toml_edit" +version = "0.25.21+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88497dab46de5bf343ec66b05c251e48c6213f3e9170c70a70a823f7abe886a4" +dependencies = [ + "indexmap 2.14.2", + "toml_datetime 1.1.3+spec-1.1.0", + "toml_parser", + "winnow 1.0.5", +] + +[[package]] +name = "toml_parser" +version = "1.1.7+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0bb28d6e049a9766c3bd91a8326e6179f5b132dec87906bb97018ef7a2f3431a" +dependencies = [ + "winnow 1.0.5", +] + +[[package]] +name = "toml_writer" +version = "1.2.0+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "009dbb7700f11c55ef83aebbe4c0e9cf1f1ac0844bd8d6f00dc38f302026e13a" + +[[package]] +name = "tower" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4" +dependencies = [ + "futures-core", + "futures-util", + "pin-project-lite", + "sync_wrapper", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-http" +version = "0.6.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4cfcf7e2740e6fc6d4d688b4ef00650406bb94adf4731e43c096c3a19fe40840" +dependencies = [ + "bitflags 2.13.2", + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", + "tower", + "tower-layer", + "tower-service", + "url", +] + +[[package]] +name = "tower-layer" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" + +[[package]] +name = "tower-service" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" + +[[package]] +name = "tracing" +version = "0.1.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100" +dependencies = [ + "pin-project-lite", + "tracing-attributes", + "tracing-core", +] + +[[package]] +name = "tracing-attributes" +version = "0.1.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "tracing-core" +version = "0.1.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a" +dependencies = [ + "once_cell", +] + +[[package]] +name = "tray-icon" +version = "0.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2b9c52859a94554803ccd4a24b98f74148ebc73b90676d783f3490b1bff9d72" +dependencies = [ + "crossbeam-channel", + "dirs 7.0.0", + "libappindicator", + "muda", + "objc2", + "objc2-app-kit", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-foundation", + "once_cell", + "png", + "serde", + "thiserror 2.0.21", + "windows-sys 0.61.2", +] + +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "typeid" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bc7d623258602320d5c55d1bc22793b57daff0ec7efc270ea7d55ce1d5f5471c" + +[[package]] +name = "typenum" +version = "1.20.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20" + +[[package]] +name = "uds_windows" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2f6fb2847f6742cd76af783a2a2c49e9375d0a111c7bef6f71cd9e738c72d6e" +dependencies = [ + "memoffset", + "tempfile", + "windows-sys 0.61.2", +] + +[[package]] +name = "unicode-ident" +version = "1.0.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2c754d6c33795a1c324727428e5a7dedb5b06195f9890bdbcba760d3e246563" + +[[package]] +name = "unicode-segmentation" +version = "1.13.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "ureq" +version = "2.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02d1a66277ed75f640d608235660df48c8e3c19f3b4edb6a263315626cc3c01d" +dependencies = [ + "base64 0.22.1", + "log", + "native-tls", + "once_cell", + "rustls", + "rustls-native-certs", + "rustls-pki-types", + "serde", + "serde_json", + "url", + "webpki-roots 0.26.11", +] + +[[package]] +name = "url" +version = "2.5.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f00cd2407bb42c0ef17be88d4cf020f5cceffd121665bac9b8b9493a369b3b1a" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", + "serde", + "serde_derive", +] + +[[package]] +name = "urlpattern" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df16f50ef4cc145211879a3867ba757076b25dfee812040dcb0658bd9ae7904b" +dependencies = [ + "icu_properties", + "regex", + "serde", + "url", +] + +[[package]] +name = "utf8_iter" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af3bd9d3e571c26fcce9d033b87ea5ab061b8d2ffe9b7a5675d810d68f03edf0" +dependencies = [ + "utf_types", +] + +[[package]] +name = "utf_types" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a3b425286980a367278453f3b6d28cdcb134b574e5a35824a6ff5eebad50bb6" + +[[package]] +name = "uuid" +version = "1.29.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c14b15dffa2f4bd712103e857140aa04a4f2ff6e955c77d7eb8e53ee02a3b64" +dependencies = [ + "getrandom 0.4.3", + "js-sys", + "serde_core", + "wasm-bindgen", +] + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version-compare" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "03c2856837ef78f57382f06b2b8563a2f512f7185d732608fd9176cb3b8edf0e" + +[[package]] +name = "version_check" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" + +[[package]] +name = "vswhom" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "be979b7f07507105799e854203b470ff7c78a1639e330a58f183b5fea574608b" +dependencies = [ + "libc", + "vswhom-sys", +] + +[[package]] +name = "vswhom-sys" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb067e4cbd1ff067d1df46c9194b5de0e98efd2810bbc95c5d5e5f25a3231150" +dependencies = [ + "cc", + "libc", +] + +[[package]] +name = "walkdir" +version = "2.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b42e295b7452c4604982280d8586001fcad9b8b201cac67bca9771e7a7475403" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "want" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec4cdd0dd910afe868b7ef477227d8d538b46b3075031afee8a9f2acb0a2ed0b" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.11.1+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b" + +[[package]] +name = "wasip2" +version = "1.0.4+wasi-0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487" +dependencies = [ + "wit-bindgen", +] + +[[package]] +name = "wasm-bindgen" +version = "0.2.130" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0181c14ddd6c7b8b0b0132a5f1ea2f32be0d893cd3ea97b6e3b28886b8a3d1c" +dependencies = [ + "cfg-if", + "rustversion", + "wasm-bindgen-macro", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.80" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e14e0327cb5368ad60ccb22d04a9827a693c95a926d8d125e9fa39e0baec501" +dependencies = [ + "js-sys", + "tokio", + "wasm-bindgen", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.130" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e931a02a39abdbf66966fc35902b5ed58344750a70885bed4ebb3d8eaf28ed9" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.130" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ca4b54280e455bd831e33a6b8e734baf432fe63fbc35c42ac14ce67a043a53a" +dependencies = [ + "bumpalo", + "proc-macro2", + "quote", + "syn 3.0.10", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.130" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b1f9c3798725016c6ee5f2f57869ec0831e8bbc0ab0310a86e787e97f41389e" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "wasm-streams" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9d1ec4f6517c9e11ae630e200b2b65d193279042e28edd4a2cda233e46670bbb" +dependencies = [ + "futures-util", + "js-sys", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", +] + +[[package]] +name = "web-sys" +version = "0.3.107" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d7d179596ff5ec0f6de4db64d54011bde6289cc49603d3a6e4ce3f329207ab88" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "web-time" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "web_atoms" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba8b815c1b593dc0baf78dd0f4fc8fdb2de53198fb1163738093e9a311c33fb3" +dependencies = [ + "phf 0.13.1", + "phf_codegen 0.13.1", + "string_cache 0.9.0", + "string_cache_codegen 0.6.1", +] + +[[package]] +name = "web_atoms" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7572660c8890448ba236b7376f27e389c6a7e1c70195622faced601f855c0ada" +dependencies = [ + "phf 0.14.0", + "phf_codegen 0.14.0", + "string_cache 0.11.0", + "string_cache_codegen 0.11.2", +] + +[[package]] +name = "webkit2gtk" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1027150013530fb2eaf806408df88461ae4815a45c541c8975e61d6f2fc4793" +dependencies = [ + "bitflags 1.3.2", + "cairo-rs", + "gdk", + "gdk-sys", + "gio", + "gio-sys", + "glib", + "glib-sys", + "gobject-sys", + "gtk", + "gtk-sys", + "javascriptcore-rs", + "libc", + "once_cell", + "soup3", + "webkit2gtk-sys", +] + +[[package]] +name = "webkit2gtk-sys" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "916a5f65c2ef0dfe12fff695960a2ec3d4565359fdbb2e9943c974e06c734ea5" +dependencies = [ + "bitflags 1.3.2", + "cairo-sys-rs", + "gdk-sys", + "gio-sys", + "glib-sys", + "gobject-sys", + "gtk-sys", + "javascriptcore-rs-sys", + "libc", + "pkg-config", + "soup3-sys", + "system-deps", +] + +[[package]] +name = "webpki-roots" +version = "0.26.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "521bc38abb08001b01866da9f51eb7c5d647a19260e00054a8c7fd5f9e57f7a9" +dependencies = [ + "webpki-roots 1.0.12", +] + +[[package]] +name = "webpki-roots" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7265c9301c16a8711c992c2d8da90ee77ef54b1ed51482d6dfeb00dc756b1297" +dependencies = [ + "rustls-pki-types", +] + +[[package]] +name = "webview2-com" +version = "0.39.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f89fca7a704cee10dcb3654c1dbb8941d1783132f1917358af75bec37a7d7e6" +dependencies = [ + "webview2-com-macros", + "webview2-com-sys", + "windows", + "windows-core", +] + +[[package]] +name = "webview2-com-macros" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67a921c1b6914c367b2b823cd4cde6f96beec77d30a939c8199bb377cf9b9b54" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "webview2-com-sys" +version = "0.39.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3a07132775117d6065853d9d1178157b8c90e228de47129d6bce2c7edebedfb" +dependencies = [ + "thiserror 2.0.21", + "windows", + "windows-core", +] + +[[package]] +name = "winapi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" +dependencies = [ + "winapi-i686-pc-windows-gnu", + "winapi-x86_64-pc-windows-gnu", +] + +[[package]] +name = "winapi-i686-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" + +[[package]] +name = "winapi-util" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" +dependencies = [ + "windows-sys 0.61.2", +] + +[[package]] +name = "winapi-x86_64-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" + +[[package]] +name = "window-vibrancy" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "111e51caca442cafd9bab396628ac4d814880eaea4e63dfd76a12e9f342b5580" +dependencies = [ + "objc2", + "objc2-app-kit", + "objc2-core-foundation", + "objc2-foundation", + "objc2-quartz-core", + "raw-window-handle", + "windows-sys 0.61.2", + "windows-version", +] + +[[package]] +name = "windows" +version = "0.62.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "527fadee13e0c05939a6a05d5bd6eec6cd2e3dbd648b9f8e447c6518133d8580" +dependencies = [ + "windows-collections", + "windows-core", + "windows-future", + "windows-numerics", +] + +[[package]] +name = "windows-collections" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23b2d95af1a8a14a3c7367e1ed4fc9c20e0a26e79551b1454d72583c97cc6610" +dependencies = [ + "windows-core", +] + +[[package]] +name = "windows-core" +version = "0.62.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb" +dependencies = [ + "windows-implement", + "windows-interface", + "windows-link", + "windows-result", + "windows-strings", +] + +[[package]] +name = "windows-future" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e1d6f90251fe18a279739e78025bd6ddc52a7e22f921070ccdc67dde84c605cb" +dependencies = [ + "windows-core", + "windows-link", + "windows-threading", +] + +[[package]] +name = "windows-implement" +version = "0.60.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "windows-interface" +version = "0.59.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.119", +] + +[[package]] +name = "windows-link" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5" + +[[package]] +name = "windows-numerics" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e2e40844ac143cdb44aead537bbf727de9b044e107a0f1220392177d15b0f26" +dependencies = [ + "windows-core", + "windows-link", +] + +[[package]] +name = "windows-registry" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02752bf7fbdcce7f2a27a742f798510f3e5ad88dbe84871e5168e2120c3d5720" +dependencies = [ + "windows-link", + "windows-result", + "windows-strings", +] + +[[package]] +name = "windows-result" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-strings" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-sys" +version = "0.45.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" +dependencies = [ + "windows-targets 0.42.2", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-sys" +version = "0.61.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-targets" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" +dependencies = [ + "windows_aarch64_gnullvm 0.42.2", + "windows_aarch64_msvc 0.42.2", + "windows_i686_gnu 0.42.2", + "windows_i686_msvc 0.42.2", + "windows_x86_64_gnu 0.42.2", + "windows_x86_64_gnullvm 0.42.2", + "windows_x86_64_msvc 0.42.2", +] + +[[package]] +name = "windows-targets" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" +dependencies = [ + "windows_aarch64_gnullvm 0.52.6", + "windows_aarch64_msvc 0.52.6", + "windows_i686_gnu 0.52.6", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.6", + "windows_x86_64_gnu 0.52.6", + "windows_x86_64_gnullvm 0.52.6", + "windows_x86_64_msvc 0.52.6", +] + +[[package]] +name = "windows-threading" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3949bd5b99cafdf1c7ca86b43ca564028dfe27d66958f2470940f73d86d75b37" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-version" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4060a1da109b9d0326b7262c8e12c84df67cc0dbc9e33cf49e01ccc2eb63631" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" + +[[package]] +name = "windows_i686_gnu" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" + +[[package]] +name = "windows_i686_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" + +[[package]] +name = "winnow" +version = "0.5.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +dependencies = [ + "memchr", +] + +[[package]] +name = "winnow" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c3b93199df0ab874cdf0c6a94f0a0dc3423fe41f1cafb62b8bd7b1deb277aef" +dependencies = [ + "memchr", +] + +[[package]] +name = "winreg" +version = "0.56.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d6f32a0ff4a9f6f01231eb2059cc85479330739333e0e58cadf03b6af2cca10" +dependencies = [ + "cfg-if", + "windows-sys 0.61.2", +] + +[[package]] +name = "wit-bindgen" +version = "0.57.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e" + +[[package]] +name = "writeable" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ad82d2a33cdc9674dc7465672f271e096168fcdbe0f799d9e6db8c5892679dc" + +[[package]] +name = "wry" +version = "0.57.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c7bdc0b007462dd8a6cdb598e131e6899efa7eec16afdab4ee94b33f344c705" +dependencies = [ + "base64 0.23.1", + "block2", + "cookie", + "crossbeam-channel", + "dirs 7.0.0", + "dom_query 0.30.0", + "dpi", + "dunce", + "gdkx11", + "gtk", + "http", + "javascriptcore-rs", + "jni", + "libc", + "ndk", + "objc2", + "objc2-app-kit", + "objc2-core-foundation", + "objc2-foundation", + "objc2-ui-kit", + "objc2-web-kit", + "percent-encoding", + "raw-window-handle", + "sha2 0.10.9", + "soup3", + "tao-macros", + "thiserror 2.0.21", + "url", + "webkit2gtk", + "webkit2gtk-sys", + "webview2-com", + "windows", + "windows-core", + "windows-version", + "x11-dl", +] + +[[package]] +name = "x11" +version = "2.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "502da5464ccd04011667b11c435cb992822c2c0dbde1770c988480d312a0db2e" +dependencies = [ + "libc", + "pkg-config", +] + +[[package]] +name = "x11-dl" +version = "2.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38735924fedd5314a6e548792904ed8c6de6636285cb9fec04d5b1db85c1516f" +dependencies = [ + "libc", + "once_cell", + "pkg-config", +] + +[[package]] +name = "xattr" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "963d6fab92d5504b971dc8bd90ca743c2575e590bc8071ea5bc571598667ae08" +dependencies = [ + "libc", + "rustix", +] + +[[package]] +name = "yoke" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "417ef3fcf6c300b7dbd25c85531a746931c02ad536f3cf4786ed1e88223340b3" +dependencies = [ + "stable_deref_trait", + "yoke-derive", + "zerofrom", +] + +[[package]] +name = "yoke-derive" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec8ebde2db3681e8c9980cc27822030e68752690ddfa9473e739aeb4dbde6d71" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", + "synstructure", +] + +[[package]] +name = "zbus" +version = "5.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5db4be7c075cb421e4b7ee645541604239bd243ba7c357511f4ff3a74b555907" +dependencies = [ + "async-broadcast", + "async-executor", + "async-io", + "async-lock", + "async-process", + "async-recursion", + "async-task", + "async-trait", + "blocking", + "enumflags2", + "event-listener", + "futures-core", + "futures-lite", + "hex", + "libc", + "ordered-stream", + "rustix", + "serde", + "serde_repr", + "tracing", + "uds_windows", + "uuid", + "windows-sys 0.61.2", + "winnow 1.0.5", + "zbus_macros 5.19.0", + "zbus_names", + "zvariant", +] + +[[package]] +name = "zbus" +version = "6.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a7f9f5dd97fa527c1202ba1cb35d48e07f77d4de8542317c854f7aef22b0668" +dependencies = [ + "async-trait", + "bitflags 2.13.2", + "endi", + "futures-core", + "hex", + "libc", + "ordered-stream", + "rustix", + "serde", + "serde_repr", + "socket2", + "uds_windows", + "uuid", + "windows-sys 0.61.2", + "winnow 1.0.5", + "zbus_macros 6.5.0", + "zbus_utils", + "zcheapstr", + "zruntime", +] + +[[package]] +name = "zbus_macros" +version = "5.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2990635d09ade6df1868f72f8cac69a876a90981e8bd3c40b1be413f8dc88f40" +dependencies = [ + "proc-macro-crate 3.5.0", + "proc-macro2", + "quote", + "syn 3.0.10", + "zbus_names", + "zvariant", + "zvariant_utils", +] + +[[package]] +name = "zbus_macros" +version = "6.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f5aa7f2c4ea81b7ccfb26bafefdb4d1a44dd9d4f82c8426173a3727311743e4" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", + "zbus_utils", +] + +[[package]] +name = "zbus_names" +version = "4.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "812a12be4ead7a59e18ea8f047d08add0066b73bc62fc1467066a2472ae088dd" +dependencies = [ + "serde", + "winnow 1.0.5", + "zvariant", +] + +[[package]] +name = "zbus_utils" +version = "6.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af55e52da295311b368c45bcae221f020e28e97a2420360170ce389218e76ec7" +dependencies = [ + "proc-macro2", + "quote", + "serde", + "syn 3.0.10", + "winnow 1.0.5", +] + +[[package]] +name = "zcheapstr" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2da34e7164b75d803c3197b86e6cf61b874106fbd472c5082575a8bc5fbd0907" +dependencies = [ + "serde", +] + +[[package]] +name = "zerofrom" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272" +dependencies = [ + "zerofrom-derive", +] + +[[package]] +name = "zerofrom-derive" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f75b4683f6c7f45248d4d64056a24298c6281e0993356d7d1b4a1a962ef10d4a" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", + "synstructure", +] + +[[package]] +name = "zeroize" +version = "1.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85ccff8a4805aba1eaa4cd4afcd49f7557dd2cf5fd79ffc37f8959466effc5aa" + +[[package]] +name = "zerotrie" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ea269c3bd32f0a32c321907a2ae912ba6f4649bb0fc764a15627e99a7095a3f" +dependencies = [ + "displaydoc", + "yoke", + "zerofrom", +] + +[[package]] +name = "zerovec" +version = "0.11.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f58a2799cfe9a1670c7ea8edbd52ef8edb93cb37a7f83bf31ba9e35d9dae6a40" +dependencies = [ + "yoke", + "zerofrom", + "zerovec-derive", +] + +[[package]] +name = "zerovec-derive" +version = "0.11.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3743ddbf47738d929cd1ae2e199d40d0162979dfe31aef8ae646d2bf00bf97a" +dependencies = [ + "proc-macro2", + "quote", + "syn 3.0.10", +] + +[[package]] +name = "zip" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1dcb24d0152526ae49b9b96c1dcf71850ca1e0b882e4e28ed898a93c41334744" +dependencies = [ + "arbitrary", + "crc32fast", + "crossbeam-utils", + "flate2", + "indexmap 2.14.2", + "memchr", + "zopfli", +] + +[[package]] +name = "zlib-rs" +version = "0.6.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa76918995d776d9dd34d371030be228d021137449771493d56e29f77e4148ac" + +[[package]] +name = "zmij" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b" + +[[package]] +name = "zopfli" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aaf7fc5d30c28483d93805c4a5e12b05bbb52407fa67c5f8bd552374cd01fb11" +dependencies = [ + "bumpalo", + "crc32fast", + "log", + "simd-adler32", +] + +[[package]] +name = "zruntime" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac67096b97c00742108c4674db6bb6178adb78c4b66a506b0e4a7a9593aa5d9e" +dependencies = [ + "futures-core", + "futures-io", + "rustix", + "socket2", + "windows-sys 0.61.2", +] + +[[package]] +name = "zvariant" +version = "5.15.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "80bf6d6cd6a4b601acb64cfb8284cdc643fcfa75ef26ae3c46ec8aa4e8a1fbb7" +dependencies = [ + "endi", + "enumflags2", + "serde", + "winnow 1.0.5", + "zcheapstr", + "zvariant_derive", + "zvariant_utils", +] + +[[package]] +name = "zvariant_derive" +version = "5.15.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef2672456ba1cb54b5eaec136e63135b3c7495fb938e53b28a62e633496d486d" +dependencies = [ + "proc-macro-crate 3.5.0", + "proc-macro2", + "quote", + "syn 3.0.10", + "zvariant_utils", +] + +[[package]] +name = "zvariant_utils" +version = "4.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bad0294361a320b694a328460dc73add56c306150f5cb6bfafc44446120008a3" +dependencies = [ + "proc-macro2", + "quote", + "serde", + "syn 3.0.10", + "winnow 1.0.5", +] diff --git a/desktop/Cargo.toml b/desktop/Cargo.toml new file mode 100644 index 00000000..9b9fe825 --- /dev/null +++ b/desktop/Cargo.toml @@ -0,0 +1,47 @@ +[package] +name = "craftbot-desktop" +version = "0.1.0" +edition = "2021" +rust-version = "1.87" +description = "CraftBot desktop app: a native window and tray for the CraftBot agent" +license = "MIT" +publish = false + +[[bin]] +name = "craftbot-desktop" +path = "src/main.rs" + +[build-dependencies] +tauri-build = { version = "2.7", features = [] } + +[dependencies] +tauri = { version = "2.12", features = ["tray-icon", "image-png"] } +tauri-plugin-single-instance = "2.5" +tauri-plugin-notification = "2.8" +tauri-plugin-window-state = "2.5" +tauri-plugin-opener = "2.7" +tauri-plugin-dialog = "2.8" +serde = { version = "1", features = ["derive"] } +serde_json = "1" +# Install, start, stop and state: the setup window's own code. +craftbot-launcher-core = { path = "../launcher/core" } +# Open at Login (src/login.rs). Used directly, not through +# tauri-plugin-autostart, which writes the path unquoted. +auto-launch = "0.6" + +# WebKitGTK ships with getUserMedia off, and has no permission prompt of its +# own; src/permissions.rs turns the one on and supplies the other. Versions +# match what tauri itself links. +[target.'cfg(target_os = "linux")'.dependencies] +gtk = "0.18" +webkit2gtk = { version = "2.0", features = ["v2_40"] } + +[dev-dependencies] +tempfile = "3" + +[profile.release] +opt-level = "s" +lto = true +codegen-units = 1 +strip = true +panic = "abort" diff --git a/desktop/README.md b/desktop/README.md new file mode 100644 index 00000000..717e705e --- /dev/null +++ b/desktop/README.md @@ -0,0 +1,146 @@ +# CraftBot desktop app + +CraftBot in its own window, with a tray icon: Rust and +[Tauri 2](https://v2.tauri.app), using the system webview (WebView2 on +Windows, WKWebView on macOS, WebKitGTK on Linux). The binary is about 8 MB. + +## How it works + +The window shows the UI the running agent already serves (the address in +`ui.json`, normally `http://localhost:7925`). Nothing of the UI is bundled +here, so the app always shows the version the agent runs, and the backend's +origin checks (`app/ui_layer/adapters/ws_auth.py`) see the loopback origin +they already allow. Agent Apps stay cross-origin frames on their own ports, +as in a browser. + +Until CraftBot runs, the window shows the app's own page (`ui/`): + +| CraftBot is | The app | +|---|---| +| not installed | offers **Install CraftBot**: the setup window's pipeline (`launcher/core`), then `craftbot.py install` | +| stopped when the app opens | starts it (`craftbot.py start --no-open-browser`) | +| stopped when the app opens at login | waits: CraftBot's own login item starts it; if not, the app does once its window opens | +| stopped later (tray, terminal) | offers **Start CraftBot**; a stop someone asked for is not undone | +| starting | waits for `.agent-ready` | +| running | shows its UI | + +State comes from the files run.py writes (`craftbot.pid`, `.agent-ready`, +`ui.json`), polled once a second, whoever started CraftBot: this app, a +terminal or the login item. + +Closing the window hides it; the agent keeps working (schedules, proactive +tasks). The tray has Open, Open in Browser, Start, Stop, Restart, Open at +Login, Open Log and Quit. **Quit** closes the app, not CraftBot. A second +launch brings the existing window forward. + +**Open at Login** (off until turned on) starts the app at sign-in, in the +tray (`--hidden`, `src/login.rs`): a Run value `CraftBot Desktop` on Windows, +`~/.config/autostart/CraftBot Desktop.desktop` on Linux, a LaunchAgent +`dev.craftos.craftbot` on macOS. It is the app's own entry, apart from the +one CraftBot writes to start the agent at login. Tauri's Windows uninstaller +deletes the Run value named after the product, `CraftBot`, which is the +agent's; `packaging/windows/hooks.nsh` keeps that one and removes the app's. + +### Which CraftBot + +A CraftBot is its source tree (`craftbot.py`), its interpreter and its state +root. The app takes them from, in order: `--dir`, `--python` and +`--state-root` on its command line; `desktop.json` (the last ones given on a +command line); `launcher.json` (a copy this app or the setup window +installed). `craftbot.py open` passes all three, so a source checkout is +driven exactly like an installed copy. + +`craftbot.py open` (the desktop shortcut) and `craftbot.py start` open the +app instead of a browser tab once it is installed: `/Applications` or +`~/Applications` on macOS, `%LOCALAPPDATA%\CraftBot` on Windows, +`craftbot-desktop` on `PATH` on Linux. `CRAFTBOT_DESKTOP_APP` names another +executable, or `off` keeps the browser. + +### What a browser does that a bare webview does not + +- Links to the web, `window.open` and pages that would take over the window + open in the default browser; the window stays on CraftBot. +- Downloads go to the Downloads folder, numbered instead of overwriting. +- Files dropped on the window reach the page (the chat's attachments). +- Notifications: while the window is in the background, agent replies, + questions and errors become system notifications + (`store/socket/desktopNotifications.ts` in the UI; nothing changes in a + browser). +- Camera, microphone and screen: WebView2 and WKWebView ask the user + themselves. WebKitGTK has getUserMedia off and no prompt of its own; the + app turns it on and asks with a dialog on every request + (`src/permissions.rs`). + +### What the page may do + +Tauri refuses commands from remote origins unless a capability names them. +The UI's origin is granted `notification:default` and nothing else, at +runtime, once its port is known (`src/shell.rs`). It cannot call the app's +own commands, open URLs or files, or reach any other plugin. Agent Apps, on +other origins, get nothing. + +## Known limits + +- Dictation in the chat box uses the Web Speech API, which WebKitGTK and + WebView2 do not provide (Firefox does not either). The button says so. +- On Linux the app needs WebKitGTK 4.1, GTK 3 and libayatana-appindicator + (the `.deb` and `.rpm` declare them; the AppImage carries them). Servers + without a desktop keep using the setup window's `--headless` mode or + `craftbot.py`. + +## Files + +Under the user data root (`launcher/core/src/paths.rs`): `desktop.json` +(see above) and `launcher.log`, shared with the setup window. The webview's +own data (local storage, cookies) is in the platform's app data folder under +`dev.craftos.craftbot`. + +## Building + +```bash +cd desktop +cargo test +cargo build --release # target/release/craftbot-desktop +npx @tauri-apps/cli@2.12.6 build # plus installers in target/release/bundle/ +``` + +Linux needs `libwebkit2gtk-4.1-dev libayatana-appindicator3-dev librsvg2-dev` +(Debian and Ubuntu names; on Arch `webkit2gtk-4.1 libappindicator-gtk3`). +The CraftBot version the app installs is baked in as for the setup window: +`CRAFTBOT_VERSION`, else a `VERSION` file, else "latest". + +`.github/workflows/desktop.yml` tests and builds the app on every platform +for changes here and in `launcher/core`. On a `v*` tag it builds the +installers, signs them when the Release workflow's signing secrets exist, and +attaches them to the release. + +### Debug builds + +Two variables help exercise the app with nobody at the screen. Neither +exists in a release build. + +- `CRAFTBOT_DESKTOP_EVAL_FILE=` runs the script on every page the + window finishes loading. +- `CRAFTBOT_DESKTOP_SNAPSHOT_DIR=` (Linux) saves what the webview shows + every 3 seconds as `snap-NNN.ppm`. WebKit renders these itself, so they + work on a locked screen. + +## Layout + +``` +desktop/ + Cargo.toml, build.rs, tauri.conf.json + capabilities/page.json what the app's own page may call + ui/ the app's page: install, start, errors + icons/ generated from craftbot_logo_1.png (tauri icon) + packaging/macos/ Info.plist usage strings, entitlements + packaging/windows/ uninstaller hooks: login entries + src/main.rs plugins, window, tray, poll thread + src/agent.rs CraftBot's state and the jobs that change it + src/location.rs which CraftBot: --dir, desktop.json, launcher.json + src/shell.rs the window: navigation, links, downloads, capability + src/permissions.rs camera, microphone and screen requests + src/tray.rs the tray menu + src/login.rs Open at Login + src/setup.rs commands for the app's page +``` diff --git a/desktop/build.rs b/desktop/build.rs new file mode 100644 index 00000000..d860e1e6 --- /dev/null +++ b/desktop/build.rs @@ -0,0 +1,3 @@ +fn main() { + tauri_build::build() +} diff --git a/desktop/capabilities/page.json b/desktop/capabilities/page.json new file mode 100644 index 00000000..4c0be217 --- /dev/null +++ b/desktop/capabilities/page.json @@ -0,0 +1,7 @@ +{ + "$schema": "../gen/schemas/desktop-schema.json", + "identifier": "page", + "description": "The app's own page (ui/): install, start and errors. CraftBot's UI is a remote origin and gets only notifications, at runtime (src/shell.rs).", + "windows": ["main"], + "permissions": ["core:default"] +} diff --git a/desktop/icons/128x128.png b/desktop/icons/128x128.png new file mode 100644 index 00000000..d4623da6 Binary files /dev/null and b/desktop/icons/128x128.png differ diff --git a/desktop/icons/128x128@2x.png b/desktop/icons/128x128@2x.png new file mode 100644 index 00000000..87466fd7 Binary files /dev/null and b/desktop/icons/128x128@2x.png differ diff --git a/desktop/icons/32x32.png b/desktop/icons/32x32.png new file mode 100644 index 00000000..fc5e131d Binary files /dev/null and b/desktop/icons/32x32.png differ diff --git a/desktop/icons/64x64.png b/desktop/icons/64x64.png new file mode 100644 index 00000000..02fbc670 Binary files /dev/null and b/desktop/icons/64x64.png differ diff --git a/desktop/icons/Square107x107Logo.png b/desktop/icons/Square107x107Logo.png new file mode 100644 index 00000000..a0c532c5 Binary files /dev/null and b/desktop/icons/Square107x107Logo.png differ diff --git a/desktop/icons/Square142x142Logo.png b/desktop/icons/Square142x142Logo.png new file mode 100644 index 00000000..6a302902 Binary files /dev/null and b/desktop/icons/Square142x142Logo.png differ diff --git a/desktop/icons/Square150x150Logo.png b/desktop/icons/Square150x150Logo.png new file mode 100644 index 00000000..893bc6d0 Binary files /dev/null and b/desktop/icons/Square150x150Logo.png differ diff --git a/desktop/icons/Square284x284Logo.png b/desktop/icons/Square284x284Logo.png new file mode 100644 index 00000000..cb353ee5 Binary files /dev/null and b/desktop/icons/Square284x284Logo.png differ diff --git a/desktop/icons/Square30x30Logo.png b/desktop/icons/Square30x30Logo.png new file mode 100644 index 00000000..edad256d Binary files /dev/null and b/desktop/icons/Square30x30Logo.png differ diff --git a/desktop/icons/Square310x310Logo.png b/desktop/icons/Square310x310Logo.png new file mode 100644 index 00000000..ef0658bd Binary files /dev/null and b/desktop/icons/Square310x310Logo.png differ diff --git a/desktop/icons/Square44x44Logo.png b/desktop/icons/Square44x44Logo.png new file mode 100644 index 00000000..a2413421 Binary files /dev/null and b/desktop/icons/Square44x44Logo.png differ diff --git a/desktop/icons/Square71x71Logo.png b/desktop/icons/Square71x71Logo.png new file mode 100644 index 00000000..52d14300 Binary files /dev/null and b/desktop/icons/Square71x71Logo.png differ diff --git a/desktop/icons/Square89x89Logo.png b/desktop/icons/Square89x89Logo.png new file mode 100644 index 00000000..70bfd910 Binary files /dev/null and b/desktop/icons/Square89x89Logo.png differ diff --git a/desktop/icons/StoreLogo.png b/desktop/icons/StoreLogo.png new file mode 100644 index 00000000..a2c9e91a Binary files /dev/null and b/desktop/icons/StoreLogo.png differ diff --git a/desktop/icons/icon.icns b/desktop/icons/icon.icns new file mode 100644 index 00000000..536cd9ba Binary files /dev/null and b/desktop/icons/icon.icns differ diff --git a/desktop/icons/icon.ico b/desktop/icons/icon.ico new file mode 100644 index 00000000..a0c0689e Binary files /dev/null and b/desktop/icons/icon.ico differ diff --git a/desktop/icons/icon.png b/desktop/icons/icon.png new file mode 100644 index 00000000..e6430f76 Binary files /dev/null and b/desktop/icons/icon.png differ diff --git a/desktop/packaging/macos/Info.plist b/desktop/packaging/macos/Info.plist new file mode 100644 index 00000000..52a940a0 --- /dev/null +++ b/desktop/packaging/macos/Info.plist @@ -0,0 +1,10 @@ + + + + + NSMicrophoneUsageDescription + Agent Apps you run in CraftBot can ask to use the microphone. + NSCameraUsageDescription + Agent Apps you run in CraftBot can ask to use the camera. + + diff --git a/desktop/packaging/macos/entitlements.plist b/desktop/packaging/macos/entitlements.plist new file mode 100644 index 00000000..77b031c4 --- /dev/null +++ b/desktop/packaging/macos/entitlements.plist @@ -0,0 +1,12 @@ + + + + + + com.apple.security.device.audio-input + + com.apple.security.device.camera + + + diff --git a/desktop/packaging/windows/hooks.nsh b/desktop/packaging/windows/hooks.nsh new file mode 100644 index 00000000..313f6b44 --- /dev/null +++ b/desktop/packaging/windows/hooks.nsh @@ -0,0 +1,24 @@ +; Uninstall hooks (tauri.conf.json > bundle > windows > nsis > installerHooks). +; +; CraftBot's agent starts at login from the Run value "CraftBot" +; (craftbot.py's TASK_NAME). Tauri's uninstaller deletes the Run value named +; after the product, which is also "CraftBot": keep the agent's, and remove +; the app's own Open at Login value, "CraftBot Desktop" (src/login.rs). + +!define CRAFTBOT_RUN_KEY "Software\Microsoft\Windows\CurrentVersion\Run" + +!macro NSIS_HOOK_PREUNINSTALL + Var /GLOBAL CraftBotAgentRun + ClearErrors + ReadRegStr $CraftBotAgentRun HKCU "${CRAFTBOT_RUN_KEY}" "CraftBot" +!macroend + +!macro NSIS_HOOK_POSTUNINSTALL + ${If} $CraftBotAgentRun != "" + WriteRegStr HKCU "${CRAFTBOT_RUN_KEY}" "CraftBot" $CraftBotAgentRun + ${EndIf} + ${If} $UpdateMode <> 1 + DeleteRegValue HKCU "${CRAFTBOT_RUN_KEY}" "CraftBot Desktop" + DeleteRegValue HKCU "Software\Microsoft\Windows\CurrentVersion\Explorer\StartupApproved\Run" "CraftBot Desktop" + ${EndIf} +!macroend diff --git a/desktop/src/agent.rs b/desktop/src/agent.rs new file mode 100644 index 00000000..e8aad55e --- /dev/null +++ b/desktop/src/agent.rs @@ -0,0 +1,481 @@ +//! The CraftBot this app drives: what it is doing, and the jobs that change +//! that. +//! +//! A poll thread looks at the files run.py writes (craftbot.pid, +//! .agent-ready, ui.json) once a second, whoever started CraftBot: this +//! app, a terminal, or the login item. From that it decides what the window +//! shows: +//! +//! * running and ready: the UI CraftBot serves, at the URL in ui.json; +//! * stopped: the app's own page, which starts CraftBot once per launch +//! and otherwise offers Start; +//! * not installed: the app's own page, which offers Install. +//! +//! Jobs (install, start, stop, restart) run one at a time on a worker +//! thread. Install is the setup window's own pipeline (launcher-core); +//! everything else is `craftbot.py `, as for the setup window. + +use crate::location::Location; +use crate::{shell, tray}; +use launcher_core::install::{self, Event, Job}; +use launcher_core::{craftbot, download, logger, paths, payload, record::InstallRecord, state}; +use serde::Serialize; +use std::path::PathBuf; +use std::sync::mpsc; +use std::sync::Mutex; +use std::time::Duration; +use tauri::{AppHandle, Manager}; + +/// How many polls in a row CraftBot must be down before the window leaves +/// its UI. A restart from inside CraftBot passes through "stopped" briefly, +/// and the UI reconnects by itself. +const DOWN_POLLS: u32 = 3; + +#[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize)] +#[serde(rename_all = "camelCase")] +pub enum Phase { + NotInstalled, + Stopped, + Starting, + Running, +} + +#[derive(Debug, Clone, Copy, PartialEq, Eq)] +pub enum Task { + Install, + Repair, + Start, + Stop, + Restart, +} + +impl Task { + fn is_setup(self) -> bool { + matches!(self, Task::Install | Task::Repair) + } + + fn label(self) -> &'static str { + match self { + Task::Install => "install", + Task::Repair => "repair", + Task::Start => "start", + Task::Stop => "stop", + Task::Restart => "restart", + } + } +} + +/// What the app's page renders. +#[derive(Debug, Clone, Serialize)] +#[serde(rename_all = "camelCase")] +pub struct View { + pub phase: Phase, + pub busy: Option<&'static str>, + pub status: String, + /// 0..1 while a download has a known size. + pub progress: Option, + pub error: Option, + pub details: String, + pub setup_failed: bool, + pub install_dir: String, + pub can_change_dir: bool, + pub version: String, +} + +pub struct Agent { + inner: Mutex, +} + +struct Inner { + location: Option, + phase: Phase, + busy: Option, + status: String, + progress: Option, + error: Option<(String, String)>, + setup_failed: bool, + target: PathBuf, + /// The window shows CraftBot's UI (rather than the app's page). + showing_ui: bool, + down_polls: u32, + /// Start CraftBot by itself only when the app finds it stopped at launch + /// (or a second launch names another one). Any later stop was asked + /// for, so the page offers Start instead of undoing it. + auto_started: bool, + /// Opened at login, in the tray: CraftBot's own login item starts the + /// agent, and the app waits for its window to open before starting it, + /// so the two never race. + wait_for_window: bool, +} + +enum Action { + ShowUi(String), + ShowPage, + Start, + Tray(Phase, bool), +} + +impl Agent { + pub fn new(location: Option, hidden: bool) -> Self { + let target = InstallRecord::load_any() + .map(|r| r.install_dir) + .unwrap_or_else(paths::default_install_dir); + Self { + inner: Mutex::new(Inner { + location, + phase: Phase::NotInstalled, + busy: None, + status: String::new(), + progress: None, + error: None, + setup_failed: false, + target, + showing_ui: false, + down_polls: 0, + auto_started: false, + wait_for_window: hidden, + }), + } + } + + fn lock(&self) -> std::sync::MutexGuard<'_, Inner> { + self.inner.lock().unwrap_or_else(|e| e.into_inner()) + } + + /// The window opened: from here on the app starts a stopped CraftBot + /// as at any launch. + pub fn window_shown(&self) { + self.lock().wait_for_window = false; + } + + pub fn view(&self) -> View { + let inner = self.lock(); + let status = if inner.busy.is_some() || !inner.status.is_empty() { + inner.status.clone() + } else { + match inner.phase { + Phase::NotInstalled if inner.setup_failed => "Setup did not finish".into(), + Phase::NotInstalled => String::new(), + Phase::Stopped => "Not running".into(), + Phase::Starting => "Starting CraftBot…".into(), + Phase::Running => "Running".into(), + } + }; + let installed = inner.phase != Phase::NotInstalled; + View { + phase: inner.phase, + busy: inner.busy.map(Task::label), + status, + progress: inner.progress, + error: inner.error.as_ref().map(|(e, _)| e.clone()), + details: inner + .error + .as_ref() + .map(|(_, d)| d.clone()) + .unwrap_or_default(), + setup_failed: inner.setup_failed, + install_dir: inner.target.display().to_string(), + can_change_dir: !installed && !inner.setup_failed && inner.busy.is_none(), + version: payload::VERSION.to_string(), + } + } + + pub fn location(&self) -> Option { + self.lock().location.clone() + } + + pub fn phase(&self) -> Phase { + self.lock().phase + } + + /// Drive another CraftBot, named by a second launch's command line. + pub fn set_location(&self, loc: Location) { + let mut inner = self.lock(); + if inner.location.as_ref() != Some(&loc) { + logger::log(&format!("now driving {}", loc.dir.display())); + inner.location = Some(loc); + inner.error = None; + inner.auto_started = false; + } + } + + pub fn set_target(&self, dir: PathBuf) { + let mut inner = self.lock(); + if inner.busy.is_none() && inner.phase == Phase::NotInstalled { + inner.target = dir; + } + } + + /// The UI's address: ui.json under the state root, written by run.py + /// once it serves. Its ports move when another program holds 7925/7926. + pub fn ui_url(&self) -> String { + self.location() + .and_then(|loc| paths::ui_url_in(&loc.state_root)) + .unwrap_or_else(|| paths::DEFAULT_BROWSER_URL.to_string()) + } + + pub fn log_file(&self) -> PathBuf { + let inner = self.lock(); + // During and after a failed setup the launcher log has the story. + if inner.busy.is_some() || inner.setup_failed || inner.phase == Phase::NotInstalled { + return paths::launcher_log(); + } + inner + .location + .as_ref() + .map(Location::log_file) + .unwrap_or_else(paths::launcher_log) + } + + /// One poll: read the state, decide what the window and tray show. + fn tick(&self) -> Vec { + let location = self.location(); + let phase = probe(location.as_ref()); + let mut inner = self.lock(); + let mut actions = Vec::new(); + let changed = inner.phase != phase; + inner.phase = phase; + match phase { + Phase::Running => { + inner.down_polls = 0; + // Found running: a later stop is someone's choice (the tray, + // a terminal) and is not undone here. + inner.auto_started = true; + if !inner.showing_ui && inner.busy.is_none() { + inner.showing_ui = true; + inner.error = None; + inner.status.clear(); + let url = location + .as_ref() + .and_then(|l| paths::ui_url_in(&l.state_root)) + .unwrap_or_else(|| paths::DEFAULT_BROWSER_URL.to_string()); + actions.push(Action::ShowUi(url)); + } + } + Phase::Starting => { + inner.down_polls = 0; + inner.auto_started = true; + } + Phase::Stopped | Phase::NotInstalled => { + if inner.showing_ui && inner.busy.is_none() { + inner.down_polls += 1; + if inner.down_polls >= DOWN_POLLS { + inner.showing_ui = false; + inner.down_polls = 0; + actions.push(Action::ShowPage); + } + } + if phase == Phase::Stopped + && !inner.auto_started + && !inner.wait_for_window + && inner.busy.is_none() + && inner.error.is_none() + { + inner.auto_started = true; + actions.push(Action::Start); + } + } + } + if changed { + logger::log(&format!("CraftBot is {phase:?}")); + } + actions.push(Action::Tray(phase, inner.busy.is_some())); + actions + } + + fn begin(&self, task: Task) -> Result<(), String> { + let mut inner = self.lock(); + if inner.busy.is_some() { + return Err("Busy".into()); + } + inner.busy = Some(task); + inner.error = None; + inner.progress = None; + inner.status = match task { + Task::Install | Task::Repair => "Preparing…".into(), + Task::Start => "Starting CraftBot…".into(), + Task::Stop => "Stopping CraftBot…".into(), + Task::Restart => "Restarting CraftBot…".into(), + }; + if matches!(task, Task::Start | Task::Restart) { + inner.auto_started = true; + } + Ok(()) + } + + fn finish(&self, task: Task, result: Result<(), String>) { + let mut inner = self.lock(); + inner.busy = None; + inner.progress = None; + inner.status.clear(); + let setup = task.is_setup(); + match result { + Ok(()) => { + if !setup { + logger::log(&format!("job {} finished", task.label())); + } + if setup { + inner.setup_failed = false; + inner.location = Location::managed(); + // craftbot.py install has already started it. + inner.auto_started = true; + } + } + Err(e) => { + if !setup { + logger::log(&format!("job {} FAILED: {e}", task.label())); + } + let mut lines = e.lines(); + let first = lines.next().unwrap_or("Something went wrong").to_string(); + let rest = lines.collect::>().join("\n"); + inner.error = Some((first, rest)); + if setup { + inner.setup_failed = true; + } + } + } + } + + fn set_status(&self, text: String) { + let mut inner = self.lock(); + inner.status = text; + } + + fn set_progress(&self, read: u64, total: Option) { + let mut inner = self.lock(); + match total { + Some(t) if t > 0 => { + inner.progress = Some((read as f64 / t as f64).clamp(0.0, 1.0)); + inner.status = format!( + "Downloading… {} of {} MB", + download::mb(read), + download::mb(t) + ); + } + _ => { + inner.progress = None; + inner.status = format!("Downloading… {} MB", download::mb(read)); + } + } + } +} + +/// What run.py's files say about the CraftBot at `location`. +fn probe(location: Option<&Location>) -> Phase { + let Some(loc) = location.filter(|l| l.is_valid()) else { + return Phase::NotInstalled; + }; + let running = state::read_pid(&loc.pid_file()) + .map(state::pid_alive) + .unwrap_or(false); + if !running { + Phase::Stopped + } else if loc.ready_file().is_file() { + Phase::Running + } else { + Phase::Starting + } +} + +/// Start the poll thread. +pub fn spawn(app: AppHandle) { + std::thread::Builder::new() + .name("state-poll".into()) + .spawn(move || loop { + let actions = app.state::().tick(); + for action in actions { + match action { + Action::ShowUi(url) => shell::show_ui(&app, &url), + Action::ShowPage => shell::show_page(&app), + Action::Start => run(&app, Task::Start), + Action::Tray(phase, busy) => tray::update(&app, phase, busy), + } + } + std::thread::sleep(Duration::from_secs(1)); + }) + .expect("spawn poll thread"); +} + +/// Run a job on a worker thread. Does nothing while another one runs. +pub fn run(app: &AppHandle, task: Task) { + let agent = app.state::(); + if agent.begin(task).is_err() { + return; + } + // Install and repair log their own start and end (launcher-core). + if !task.is_setup() { + logger::log(&format!("job {} started", task.label())); + } + tray::update(app, agent.phase(), true); + let app = app.clone(); + std::thread::Builder::new() + .name(format!("job-{}", task.label())) + .spawn(move || { + let agent = app.state::(); + let result = match task { + Task::Install | Task::Repair => setup(&agent, task), + Task::Start => craftbot_py(&agent, &["start", "--no-open-browser"], "start"), + Task::Stop => craftbot_py(&agent, &["stop"], "stop"), + Task::Restart => craftbot_py(&agent, &["stop"], "stop") + .and_then(|()| craftbot_py(&agent, &["start", "--no-open-browser"], "start")), + }; + agent.finish(task, result); + tray::update(&app, agent.phase(), false); + }) + .expect("spawn job thread"); +} + +/// Install or repair: the setup window's own pipeline. +fn setup(agent: &Agent, task: Task) -> Result<(), String> { + let target = agent.lock().target.clone(); + let job = match task { + Task::Repair => Job::Repair { target }, + _ => Job::Install { target }, + }; + let (tx, rx) = mpsc::channel::(); + let worker = std::thread::spawn(move || install::run(job, tx)); + let mut result = Err("Setup ended unexpectedly".to_string()); + for event in rx { + match event { + // The commands setup echoes ("$ /path/to/python -m …") say + // nothing to a person; the step names around them do. + Event::Status(text) if text.starts_with("$ ") => {} + Event::Status(text) => agent.set_status(text), + Event::Progress { read, total } => agent.set_progress(read, total), + Event::Working => agent.lock().progress = None, + Event::Finished(r) => result = r, + } + } + let _ = worker.join(); + if result.is_ok() { + // A copy installed here is what to drive from now on, not a + // location an earlier `craftbot.py open` named. + crate::location::forget(); + } + result +} + +/// `craftbot.py ` for the current location, its output as status. +fn craftbot_py(agent: &Agent, args: &[&str], what: &str) -> Result<(), String> { + let loc = agent + .location() + .filter(Location::is_valid) + .ok_or("CraftBot is not installed")?; + let args = loc.args(args); + let args: Vec<&str> = args.iter().map(String::as_str).collect(); + let mut on_line = |line: &str| { + if let Some(text) = craftbot::meaningful(line).filter(|t| !t.starts_with("$ ")) { + agent.set_status(text); + } + }; + let outcome = craftbot::run(&loc.python, &loc.dir, &args, &mut on_line)?; + if outcome.code == 0 { + return Ok(()); + } + let mut text = format!("CraftBot did not {what} (exit {}).", outcome.code); + for line in outcome.tail { + text.push('\n'); + text.push_str(&line); + } + Err(text) +} diff --git a/desktop/src/location.rs b/desktop/src/location.rs new file mode 100644 index 00000000..db9cf8a9 --- /dev/null +++ b/desktop/src/location.rs @@ -0,0 +1,295 @@ +//! Which CraftBot this app drives. +//! +//! A CraftBot is three paths: the source tree holding `craftbot.py`, the +//! interpreter it runs under, and the state root where `run.py` writes +//! `craftbot.pid`, `.agent-ready` and `ui.json`. They come from, in order: +//! +//! 1. the command line: `--dir`, `--python`, `--state-root`. `craftbot.py +//! open` passes these when it hands over to the app, so a source checkout +//! is driven exactly like an installed copy; +//! 2. `desktop.json`, the last location the command line named; +//! 3. `launcher.json`, the record of a copy this app (or the setup window) +//! installed. +//! +//! None of them: CraftBot is not installed, and the window offers to +//! install it. + +use launcher_core::{logger, paths, record::InstallRecord}; +use serde::{Deserialize, Serialize}; +use std::ffi::OsString; +use std::path::{Path, PathBuf}; + +#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)] +pub struct Location { + /// Directory holding run.py and craftbot.py. + pub dir: PathBuf, + /// The interpreter every CraftBot process runs under. + pub python: PathBuf, + /// Where run.py writes craftbot.pid, .agent-ready and ui.json. + pub state_root: PathBuf, + /// The state root was named on the command line and must be passed on + /// to craftbot.py. Otherwise craftbot.py works it out itself, the same + /// way [`state_root_for`] does, and older versions are not handed an + /// argument they do not know. + #[serde(default)] + pub explicit_state_root: bool, +} + +impl Location { + /// A copy installed by this app or the setup window. + pub fn managed() -> Option { + InstallRecord::load().map(|rec| Self { + dir: rec.install_dir, + python: rec.python, + state_root: paths::user_data_root(), + explicit_state_root: false, + }) + } + + /// The source tree and the interpreter are both still there. + pub fn is_valid(&self) -> bool { + self.dir.join("craftbot.py").is_file() + && self.dir.join("run.py").is_file() + && self.python.is_file() + } + + pub fn pid_file(&self) -> PathBuf { + self.state_root.join("craftbot.pid") + } + + pub fn ready_file(&self) -> PathBuf { + self.state_root.join(".agent-ready") + } + + /// `craftbot.py ` arguments for this location. + pub fn args(&self, command: &[&str]) -> Vec { + let mut args: Vec = command.iter().map(|s| s.to_string()).collect(); + if self.explicit_state_root { + args.push(format!("--state-root={}", self.state_root.display())); + } + args + } + + /// The log craftbot.py and run.py write; what "Open log" shows once + /// CraftBot is installed. + pub fn log_file(&self) -> PathBuf { + let log = self.state_root.join("craftbot.log"); + if log.is_file() { + log + } else { + paths::launcher_log() + } + } +} + +/// What the command line says. +#[derive(Debug, Default, Clone)] +pub struct Args { + pub dir: Option, + pub python: Option, + pub state_root: Option, + /// Start with the window hidden (in the tray). + pub hidden: bool, +} + +impl Args { + pub fn parse(args: impl IntoIterator) -> Self { + let mut out = Args::default(); + let mut it = args.into_iter().map(|a| a.to_string_lossy().into_owned()); + while let Some(arg) = it.next() { + let (name, inline) = match arg.split_once('=') { + Some((n, v)) if n.starts_with("--") => (n.to_string(), Some(v.to_string())), + _ => (arg.clone(), None), + }; + let mut value = || inline.clone().or_else(|| it.next()).map(PathBuf::from); + match name.as_str() { + "--dir" => out.dir = value(), + "--python" => out.python = value(), + "--state-root" => out.state_root = value(), + "--hidden" => out.hidden = true, + _ => {} + } + } + out + } + + /// The location the command line names, if it names a real one. + pub fn location(&self) -> Option { + let dir = absolute(self.dir.as_ref()?); + if !dir.join("craftbot.py").is_file() { + logger::log(&format!("--dir {} holds no craftbot.py", dir.display())); + return None; + } + let (state_root, explicit_state_root) = match &self.state_root { + Some(root) => (absolute(root), true), + None => (state_root_for(&dir), false), + }; + let python = match &self.python { + Some(p) => absolute(p), + None => find_python(&state_root)?, + }; + let loc = Location { + dir, + python, + state_root, + explicit_state_root, + }; + if loc.is_valid() { + Some(loc) + } else { + logger::log(&format!("ignoring incomplete location {loc:?}")); + None + } + } +} + +/// The location to drive at startup; see the module documentation. +pub fn resolve(args: &Args) -> Option { + if let Some(loc) = args.location() { + remember(&loc); + return Some(loc); + } + if let Some(loc) = remembered().filter(Location::is_valid) { + return Some(loc); + } + Location::managed() +} + +/// Remember a location named on the command line, so the app started from +/// its own icon later drives the same CraftBot. +pub fn remember(loc: &Location) { + let path = remembered_file(); + if let Some(dir) = path.parent() { + let _ = std::fs::create_dir_all(dir); + } + match serde_json::to_string_pretty(loc) { + Ok(text) => { + if let Err(e) = std::fs::write(&path, text) { + logger::log(&format!("could not write {}: {e}", path.display())); + } + } + Err(e) => logger::log(&format!("could not save the location: {e}")), + } +} + +/// Forget a remembered location: a fresh install is what to drive now. +pub fn forget() { + let _ = std::fs::remove_file(remembered_file()); +} + +fn remembered() -> Option { + let text = std::fs::read_to_string(remembered_file()).ok()?; + serde_json::from_str(&text).ok() +} + +fn remembered_file() -> PathBuf { + paths::user_data_root().join("desktop.json") +} + +/// `app.paths.STATE_ROOT` for the tree at `dir`: CRAFTBOT_HOME, else the +/// user data root for an installed copy, else the checkout itself. +fn state_root_for(dir: &Path) -> PathBuf { + if let Some(home) = paths::home_override() { + return home; + } + let managed = dir.join(paths::MANAGED_MARKER).is_file(); + let checkout = dir.join("install.py").is_file() && dir.join("requirements.txt").is_file(); + if !managed && checkout { + dir.to_path_buf() + } else { + paths::user_data_root() + } +} + +/// The private interpreter install.py provisions under the state root, or +/// the one the setup window downloads. +fn find_python(state_root: &Path) -> Option { + let under_root = { + let base = state_root.join("runtime").join("python").join("python"); + if cfg!(windows) { + base.join("python.exe") + } else { + base.join("bin").join("python3") + } + }; + [under_root, paths::python_exe()] + .into_iter() + .find(|p| p.is_file()) +} + +fn absolute(p: &Path) -> PathBuf { + std::fs::canonicalize(p).unwrap_or_else(|_| { + if p.is_absolute() { + p.to_path_buf() + } else { + std::env::current_dir() + .map(|cwd| cwd.join(p)) + .unwrap_or_else(|_| p.to_path_buf()) + } + }) +} + +#[cfg(test)] +mod tests { + use super::*; + + fn quiet() { + launcher_core::logger::silence(); + } + + fn os(args: &[&str]) -> Vec { + args.iter().map(OsString::from).collect() + } + + #[test] + fn both_argument_forms_are_read() { + quiet(); + let a = Args::parse(os(&["--dir", "/a", "--python=/b/python3", "--hidden"])); + assert_eq!(a.dir, Some(PathBuf::from("/a"))); + assert_eq!(a.python, Some(PathBuf::from("/b/python3"))); + assert!(a.hidden); + assert_eq!(a.state_root, None); + let a = Args::parse(os(&["--state-root=/s", "--unknown", "x"])); + assert_eq!(a.state_root, Some(PathBuf::from("/s"))); + } + + #[test] + fn a_checkout_keeps_its_state_in_the_checkout() { + quiet(); + let tmp = tempfile::tempdir().unwrap(); + let dir = tmp.path(); + for f in ["craftbot.py", "run.py", "install.py", "requirements.txt"] { + std::fs::write(dir.join(f), "").unwrap(); + } + if paths::home_override().is_none() { + assert_eq!(state_root_for(dir), dir); + std::fs::write(dir.join(paths::MANAGED_MARKER), "").unwrap(); + assert_eq!(state_root_for(dir), paths::user_data_root()); + } + } + + #[test] + fn the_state_root_is_passed_on_only_when_named() { + quiet(); + let mut loc = Location { + dir: "/d".into(), + python: "/p".into(), + state_root: "/s".into(), + explicit_state_root: false, + }; + assert_eq!(loc.args(&["stop"]), vec!["stop"]); + loc.explicit_state_root = true; + assert_eq!(loc.args(&["stop"]), vec!["stop", "--state-root=/s"]); + } + + #[test] + fn a_location_without_craftbot_is_refused() { + quiet(); + let tmp = tempfile::tempdir().unwrap(); + let args = Args { + dir: Some(tmp.path().to_path_buf()), + ..Args::default() + }; + assert_eq!(args.location(), None); + } +} diff --git a/desktop/src/login.rs b/desktop/src/login.rs new file mode 100644 index 00000000..f28e5cfe --- /dev/null +++ b/desktop/src/login.rs @@ -0,0 +1,79 @@ +//! Open at Login: the app starts at sign-in, in the tray (`--hidden`). +//! +//! The entry is the app's own, named apart from the one CraftBot writes to +//! start the agent at login (craftbot.py: "CraftBot" in the Windows Run key, +//! com.craftbot.agent on macOS, craftbot.service on Linux), so turning one +//! off never touches the other. + +use auto_launch::{AutoLaunch, AutoLaunchBuilder}; + +/// The Windows Run value and Linux autostart file; the macOS LaunchAgent +/// label. packaging/windows/hooks.nsh removes the Windows one on uninstall. +#[cfg(not(target_os = "macos"))] +const NAME: &str = "CraftBot Desktop"; +#[cfg(target_os = "macos")] +const NAME: &str = "dev.craftos.craftbot"; + +fn entry() -> Result { + let exe = std::env::current_exe().map_err(|e| e.to_string())?; + // An AppImage runs from a temporary mount: start the file itself. + #[cfg(target_os = "linux")] + let exe = std::env::var_os("APPIMAGE") + .map(std::path::PathBuf::from) + .unwrap_or(exe); + let mut builder = AutoLaunchBuilder::new(); + builder + .set_app_name(NAME) + .set_app_path(&command_path(&exe.to_string_lossy())) + .set_args(&["--hidden"]); + // Never the machine-wide key, even when the app runs elevated. + #[cfg(windows)] + builder.set_windows_enable_mode(auto_launch::WindowsEnableMode::CurrentUser); + builder.build().map_err(|e| e.to_string()) +} + +/// The Run value and the autostart file's Exec line are split on spaces +/// ("C:\Users\Ada Lovelace\..."); a LaunchAgent takes the path as one +/// argument already. +fn command_path(path: &str) -> String { + if cfg!(target_os = "macos") { + path.to_string() + } else { + format!("\"{path}\"") + } +} + +pub fn is_on() -> bool { + entry() + .and_then(|e| e.is_enabled().map_err(|e| e.to_string())) + .unwrap_or(false) +} + +pub fn set(on: bool) -> Result<(), String> { + let entry = entry()?; + if on { entry.enable() } else { entry.disable() }.map_err(|e| e.to_string()) +} + +/// An app that moved (an update, another AppImage) points its entry at +/// where it runs now. Release builds only: a development build must not +/// take over the installed app's entry. +pub fn refresh() { + if cfg!(not(debug_assertions)) && is_on() { + let _ = set(true); + } +} + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn paths_with_spaces_stay_one_argument() { + let path = "/home/Ada Lovelace/CraftBot.AppImage"; + if cfg!(target_os = "macos") { + assert_eq!(command_path(path), path); + } else { + assert_eq!(command_path(path), format!("\"{path}\"")); + } + } +} diff --git a/desktop/src/main.rs b/desktop/src/main.rs new file mode 100644 index 00000000..a133c8a4 --- /dev/null +++ b/desktop/src/main.rs @@ -0,0 +1,114 @@ +//! CraftBot desktop app. +//! +//! A native window and tray around the CraftBot agent. The window shows the +//! UI the running agent serves; before CraftBot is installed or while it is +//! stopped, it shows the app's own page (ui/), which installs and starts it +//! with the setup window's pipeline (launcher/core). +//! +//! Threads: Tauri's event loop owns the window and tray; a poll thread +//! watches CraftBot's state files (agent.rs); one job thread at a time runs +//! install, start, stop or restart. + +#![cfg_attr(all(windows, not(debug_assertions)), windows_subsystem = "windows")] + +mod agent; +mod location; +mod login; +mod permissions; +mod setup; +mod shell; +mod tray; + +use agent::Agent; +use launcher_core::{logger, payload}; +use location::Args; +use tauri::{Manager, RunEvent, WindowEvent}; + +fn main() { + logger::log("──────────────────────────────────────────────"); + logger::log(&format!( + "desktop app {} for CraftBot {} starting ({} {})", + env!("CARGO_PKG_VERSION"), + payload::VERSION, + std::env::consts::OS, + std::env::consts::ARCH + )); + + let args = Args::parse(std::env::args_os().skip(1)); + let location = location::resolve(&args); + match &location { + Some(loc) => logger::log(&format!("driving {}", loc.dir.display())), + None => logger::log("CraftBot is not installed"), + } + let hidden = args.hidden; + + let app = tauri::Builder::default() + // First: a second launch hands its arguments over and exits. + .plugin(tauri_plugin_single_instance::init(|app, argv, _cwd| { + let args = Args::parse(argv.into_iter().skip(1).map(Into::into)); + if let Some(loc) = args.location() { + location::remember(&loc); + app.state::().set_location(loc); + } + if !args.hidden { + shell::show(app); + } + })) + .plugin( + tauri_plugin_window_state::Builder::default() + .with_state_flags( + tauri_plugin_window_state::StateFlags::all() + - tauri_plugin_window_state::StateFlags::VISIBLE, + ) + .build(), + ) + .plugin(tauri_plugin_notification::init()) + .plugin(tauri_plugin_opener::init()) + .plugin(tauri_plugin_dialog::init()) + .manage(Agent::new(location, hidden)) + .invoke_handler(tauri::generate_handler![ + setup::state, + setup::primary, + setup::choose_location, + setup::open_log, + ]) + .setup(move |app| { + shell::create(app.handle(), hidden)?; + login::refresh(); + if let Err(e) = tray::create(app.handle()) { + // No tray (a desktop without one): closing the window + // must then quit, or the app would be unreachable. + logger::log(&format!("no tray: {e}")); + app.manage(NoTray); + } + agent::spawn(app.handle().clone()); + Ok(()) + }) + .on_window_event(|window, event| { + if let WindowEvent::CloseRequested { api, .. } = event { + if window.app_handle().try_state::().is_none() { + // Hide, don't quit: the tray brings it back. + api.prevent_close(); + let _ = window.hide(); + } + } + }) + .build(tauri::generate_context!()) + .unwrap_or_else(|e| { + logger::log(&format!("could not start: {e}")); + eprintln!("CraftBot could not start: {e}"); + std::process::exit(1); + }); + + app.run(|app, event| match event { + #[cfg(target_os = "macos")] + RunEvent::Reopen { .. } => shell::show(app), + RunEvent::Exit => logger::log("desktop app closed"), + _ => { + let _ = app; + } + }); +} + +/// Marker: the tray could not be created. +struct NoTray; diff --git a/desktop/src/permissions.rs b/desktop/src/permissions.rs new file mode 100644 index 00000000..1892e354 --- /dev/null +++ b/desktop/src/permissions.rs @@ -0,0 +1,124 @@ +//! Camera, microphone and screen requests from the page, in practice from +//! Agent Apps (Audio Notes and the like). +//! +//! WebView2 (Windows) and WKWebView (macOS) ask the user themselves, as a +//! browser would. WebKitGTK (Linux) leaves the decision to the app and +//! refuses silently without one, so on Linux the app asks. + +use tauri::webview::{PermissionKind, PermissionResponse}; +use tauri::{Runtime, Webview}; + +pub fn decide(webview: Webview, kind: PermissionKind) -> PermissionResponse { + let what = match kind { + PermissionKind::Microphone => "your microphone", + PermissionKind::Camera => "your camera", + PermissionKind::DisplayCapture => "your screen", + _ => return PermissionResponse::Default, + }; + ask(&webview, what) +} + +#[cfg(not(target_os = "linux"))] +fn ask(_webview: &Webview, _what: &str) -> PermissionResponse { + PermissionResponse::Default +} + +/// A modal question on the window. The request arrives on the GTK thread, +/// which a modal dialog's own loop keeps running while it waits. +#[cfg(target_os = "linux")] +fn ask(webview: &Webview, what: &str) -> PermissionResponse { + use gtk::prelude::*; + let parent = webview.window().gtk_window().ok(); + let dialog = gtk::MessageDialog::new( + parent.as_ref(), + gtk::DialogFlags::MODAL | gtk::DialogFlags::DESTROY_WITH_PARENT, + gtk::MessageType::Question, + gtk::ButtonsType::None, + &format!("Allow access to {what}?"), + ); + dialog.set_secondary_text(Some(&format!("An Agent App is asking to use {what}."))); + dialog.add_button("Don't Allow", gtk::ResponseType::Reject); + dialog.add_button("Allow", gtk::ResponseType::Accept); + dialog.set_default_response(gtk::ResponseType::Reject); + let answer = dialog.run(); + dialog.close(); + launcher_core::logger::log(&format!("access to {what}: {answer:?}")); + if answer == gtk::ResponseType::Accept { + PermissionResponse::Allow + } else { + PermissionResponse::Deny + } +} + +/// WebKitGTK ships with getUserMedia and WebRTC turned off. +#[cfg(target_os = "linux")] +pub fn enable_media(window: &tauri::WebviewWindow) { + let _ = window.with_webview(|webview| { + use webkit2gtk::{SettingsExt, WebViewExt}; + if let Some(settings) = webview.inner().settings() { + settings.set_enable_media_stream(true); + settings.set_enable_mediasource(true); + settings.set_enable_webrtc(true); + } + }); +} + +/// Debug builds only: with CRAFTBOT_DESKTOP_SNAPSHOT_DIR set, save what the +/// webview shows every few seconds (snap-NNN.ppm). WebKit renders these +/// itself, so they work on a locked or powered-off screen, where a +/// screenshot cannot. +#[cfg(all(debug_assertions, target_os = "linux"))] +pub fn snapshots(window: tauri::WebviewWindow) { + let Some(dir) = std::env::var_os("CRAFTBOT_DESKTOP_SNAPSHOT_DIR").map(std::path::PathBuf::from) + else { + return; + }; + let _ = std::fs::create_dir_all(&dir); + std::thread::spawn(move || { + let mut n = 0u32; + loop { + n += 1; + std::thread::sleep(std::time::Duration::from_secs(3)); + let path = dir.join(format!("snap-{n:03}.ppm")); + let _ = window.with_webview(move |webview| { + use webkit2gtk::{SnapshotOptions, SnapshotRegion, WebViewExt}; + webview.inner().snapshot( + SnapshotRegion::Visible, + SnapshotOptions::NONE, + None::<&webkit2gtk::gio::Cancellable>, + move |result| { + if let Ok(surface) = result { + let _ = write_ppm(&surface, &path); + } + }, + ); + }); + } + }); +} + +#[cfg(all(debug_assertions, target_os = "linux"))] +fn write_ppm(surface: >k::cairo::Surface, path: &std::path::Path) -> Result<(), String> { + use gtk::cairo::{Context, Format, ImageSurface}; + let (x0, y0, x1, y1) = Context::new(surface) + .and_then(|cr| cr.clip_extents()) + .map_err(|e| e.to_string())?; + let (w, h) = ((x1 - x0) as i32, (y1 - y0) as i32); + let mut image = ImageSurface::create(Format::ARgb32, w, h).map_err(|e| e.to_string())?; + { + let cr = Context::new(&image).map_err(|e| e.to_string())?; + cr.set_source_surface(surface, 0.0, 0.0) + .map_err(|e| e.to_string())?; + cr.paint().map_err(|e| e.to_string())?; + } + let stride = image.stride() as usize; + let data = image.data().map_err(|e| e.to_string())?; + let mut out = format!("P6\n{w} {h}\n255\n").into_bytes(); + for row in 0..h as usize { + for col in 0..w as usize { + let px = &data[row * stride + col * 4..row * stride + col * 4 + 4]; + out.extend_from_slice(&[px[2], px[1], px[0]]); // BGRA -> RGB + } + } + std::fs::write(path, out).map_err(|e| e.to_string()) +} diff --git a/desktop/src/setup.rs b/desktop/src/setup.rs new file mode 100644 index 00000000..14535a06 --- /dev/null +++ b/desktop/src/setup.rs @@ -0,0 +1,87 @@ +//! Commands for the app's own page (ui/index.html). Only that page can call +//! them: Tauri refuses commands from a remote origin, and CraftBot's UI is +//! one, without a capability that names them. + +use crate::agent::{self, Agent, Phase, Task, View}; +use crate::shell; +use launcher_core::logger; +use std::path::PathBuf; +use tauri::{AppHandle, Manager, State}; +use tauri_plugin_dialog::DialogExt; +use tauri_plugin_opener::OpenerExt; + +#[tauri::command] +pub fn state(agent: State<'_, Agent>) -> View { + agent.view() +} + +/// The page's main button: install, finish a failed setup, or start. +#[tauri::command] +pub fn primary(app: AppHandle) { + let view = app.state::().view(); + match view.phase { + Phase::NotInstalled if view.setup_failed => agent::run(&app, Task::Repair), + Phase::NotInstalled => agent::run(&app, Task::Install), + Phase::Stopped => agent::run(&app, Task::Start), + Phase::Running => shell::show_ui(&app, &app.state::().ui_url()), + Phase::Starting => {} + } +} + +#[tauri::command] +pub fn choose_location(app: AppHandle) { + let start_in = PathBuf::from(app.state::().view().install_dir); + let start_in = start_in.parent().map(PathBuf::from).unwrap_or(start_in); + let handle = app.clone(); + app.dialog() + .file() + .set_title("Choose where to install CraftBot") + .set_directory(start_in) + .pick_folder(move |picked| { + let Some(picked) = picked.and_then(|p| p.into_path().ok()) else { + return; + }; + handle.state::().set_target(install_dir_in(picked)); + }); +} + +#[tauri::command] +pub fn open_log(app: AppHandle) { + let path = app.state::().log_file(); + if let Err(e) = app.opener().open_path(path.to_string_lossy(), None::<&str>) { + logger::log(&format!("could not open the log: {e}")); + } +} + +/// A picked parent folder gets a CraftBot folder of its own, so an install +/// never scatters itself through, say, Documents. +fn install_dir_in(picked: PathBuf) -> PathBuf { + let named = picked + .file_name() + .and_then(|n| n.to_str()) + .map(|n| n.eq_ignore_ascii_case("craftbot")) + .unwrap_or(false); + if named { + picked + } else { + picked.join("CraftBot") + } +} + +#[cfg(test)] +mod tests { + use super::install_dir_in; + use std::path::PathBuf; + + #[test] + fn a_parent_folder_gets_its_own_craftbot_folder() { + assert_eq!( + install_dir_in(PathBuf::from("/home/a/Documents")), + PathBuf::from("/home/a/Documents/CraftBot") + ); + assert_eq!( + install_dir_in(PathBuf::from("/opt/craftbot")), + PathBuf::from("/opt/craftbot") + ); + } +} diff --git a/desktop/src/shell.rs b/desktop/src/shell.rs new file mode 100644 index 00000000..8ca336ce --- /dev/null +++ b/desktop/src/shell.rs @@ -0,0 +1,262 @@ +//! The main window: the app's own page (install, start, errors) or the UI +//! the running CraftBot serves. +//! +//! The UI is loaded from CraftBot itself, not bundled here, so it is always +//! the version the agent runs, and the backend's origin checks (ws_auth.py) +//! see the loopback origin they already allow. Agent Apps stay what they are +//! in a browser: cross-origin frames on their own loopback ports. +//! +//! What a browser would do and a bare webview does not is added here: +//! links to the web open in the default browser, downloads land in the +//! Downloads folder, files dropped on the window reach the page, and an +//! Agent App asking for the microphone or camera gets a prompt. + +use crate::agent::Agent; +use launcher_core::logger; +use std::collections::HashSet; +use std::sync::Mutex; +use tauri::ipc::CapabilityBuilder; +use tauri::webview::{DownloadEvent, NewWindowResponse, PageLoadEvent}; +use tauri::{AppHandle, Manager, Url, WebviewUrl, WebviewWindow, WebviewWindowBuilder}; +use tauri_plugin_notification::NotificationExt; +use tauri_plugin_opener::OpenerExt; + +pub const MAIN: &str = "main"; + +/// The app's own page, as the webview addresses it. +fn page_url() -> Url { + let raw = if cfg!(windows) { + "http://tauri.localhost/index.html" + } else { + "tauri://localhost/index.html" + }; + Url::parse(raw).expect("valid page URL") +} + +/// Origins already granted the notification capability. +static GRANTED: Mutex>> = Mutex::new(None); + +pub fn create(app: &AppHandle, hidden: bool) -> tauri::Result { + let for_navigation = app.clone(); + let for_new_window = app.clone(); + let for_downloads = app.clone(); + let window = WebviewWindowBuilder::new(app, MAIN, WebviewUrl::App("index.html".into())) + .title("CraftBot") + .inner_size(1280.0, 820.0) + .min_inner_size(880.0, 600.0) + .center() + .visible(!hidden) + .background_color(tauri::window::Color(0x19, 0x19, 0x19, 0xff)) + // Otherwise the webview swallows dropped files, and the chat's own + // drop zone (attachments) never sees them. + .disable_drag_drop_handler() + .on_navigation(move |url| { + if url.scheme() == "mailto" { + open_outside(&for_navigation, url); + } + allow_navigation(url) + }) + .on_new_window(move |url, _features| { + open_outside(&for_new_window, &url); + NewWindowResponse::Deny + }) + .on_page_load(|window, payload| { + #[cfg(debug_assertions)] + if payload.event() == PageLoadEvent::Finished { + debug_eval(&window); + } + if payload.event() == PageLoadEvent::Started && leaves_craftbot(payload.url()) { + // A link that took the whole window to another site: show + // it in the browser and bring CraftBot back. + let app = window.app_handle(); + open_outside(app, payload.url()); + let url = app.state::().ui_url(); + if let Ok(url) = Url::parse(&url) { + let _ = window.navigate(url); + } + } + }) + .on_download(move |_webview, event| downloaded(&for_downloads, event)) + .on_permission_request(crate::permissions::decide) + .build()?; + #[cfg(target_os = "linux")] + crate::permissions::enable_media(&window); + #[cfg(all(debug_assertions, target_os = "linux"))] + crate::permissions::snapshots(window.clone()); + Ok(window) +} + +/// Bring the window to the front. +pub fn show(app: &AppHandle) { + app.state::().window_shown(); + if let Some(w) = app.get_webview_window(MAIN) { + let _ = w.unminimize(); + let _ = w.show(); + let _ = w.set_focus(); + } +} + +/// Show CraftBot's UI. +pub fn show_ui(app: &AppHandle, url: &str) { + let Ok(parsed) = Url::parse(url) else { + logger::log(&format!("ui.json holds an unusable URL: {url}")); + return; + }; + grant_notifications(app, &parsed); + if let Some(w) = app.get_webview_window(MAIN) { + logger::log(&format!("showing the UI at {url}")); + let _ = w.navigate(parsed); + } +} + +/// Show the app's own page. +pub fn show_page(app: &AppHandle) { + if let Some(w) = app.get_webview_window(MAIN) { + logger::log("showing the app page"); + let _ = w.navigate(page_url()); + } +} + +/// The UI may raise notifications (the notification plugin makes the +/// standard Notification API native) and nothing else: no other command and +/// no other origin, Agent Apps included, can reach the app. +fn grant_notifications(app: &AppHandle, url: &Url) { + let origin = url.origin().ascii_serialization(); + let mut granted = GRANTED.lock().unwrap_or_else(|e| e.into_inner()); + let set = granted.get_or_insert_with(HashSet::new); + if set.contains(&origin) { + return; + } + let id = format!("craftbot-ui-{}", set.len()); + let capability = CapabilityBuilder::new(id) + .remote(format!("{origin}/*")) + .window(MAIN) + .permission("notification:default"); + match app.add_capability(capability) { + Ok(()) => { + set.insert(origin); + } + Err(e) => logger::log(&format!("could not allow notifications for {origin}: {e}")), + } +} + +/// Every navigation, in any frame. WebKitGTK asks for frames too, so web +/// pages are allowed here (an Agent App may frame one); a page that takes +/// over the whole window is caught in `on_page_load` instead. +fn allow_navigation(url: &Url) -> bool { + matches!( + url.scheme(), + "http" | "https" | "tauri" | "about" | "blob" | "data" + ) +} + +/// Loopback addresses are CraftBot (the UI, Agent Apps) and the app's own +/// page; anything else is the web. +fn is_craftbot(url: &Url) -> bool { + match url.scheme() { + "tauri" | "about" | "blob" | "data" => true, + "http" | "https" => matches!( + url.host_str(), + Some("localhost" | "127.0.0.1" | "[::1]" | "::1" | "tauri.localhost") + ), + _ => false, + } +} + +fn leaves_craftbot(url: &Url) -> bool { + !is_craftbot(url) +} + +/// Web pages, mail links and the like go to the program the system picks. +fn open_outside(app: &AppHandle, url: &Url) { + let allowed = matches!(url.scheme(), "http" | "https" | "mailto"); + if !allowed { + logger::log(&format!("not opening {} outside the app", url.scheme())); + return; + } + logger::log(&format!("opening {} outside the app", short(url.as_str()))); + if let Err(e) = app.opener().open_url(url.as_str(), None::<&str>) { + logger::log(&format!("could not open {url}: {e}")); + } +} + +/// Debug builds only: run the script in CRAFTBOT_DESKTOP_EVAL_FILE on every +/// page the window finishes loading. How the app is exercised end to end +/// without a person at the screen. +#[cfg(debug_assertions)] +fn debug_eval(window: &WebviewWindow) { + let Some(path) = std::env::var_os("CRAFTBOT_DESKTOP_EVAL_FILE") else { + return; + }; + match std::fs::read_to_string(&path) { + Ok(js) => { + let _ = window.eval(js); + } + Err(e) => logger::log(&format!("eval file: {e}")), + } +} + +/// Downloads go to the Downloads folder under the name the page gave +/// (numbered rather than overwriting), as in a browser. +fn downloaded(app: &AppHandle, event: DownloadEvent<'_>) -> bool { + match event { + DownloadEvent::Requested { url, destination } => { + logger::log(&format!( + "download {} -> {}", + short(url.as_str()), + destination.display() + )); + true + } + DownloadEvent::Finished { path, success, .. } => { + if success { + if let Some(name) = path.as_ref().and_then(|p| p.file_name()) { + let _ = app + .notification() + .builder() + .title("Downloaded") + .body(name.to_string_lossy()) + .show(); + } + } else { + logger::log("a download failed"); + } + true + } + _ => true, + } +} + +/// A URL for the log: a blob or data URL can be long and say nothing. +fn short(url: &str) -> String { + url.chars().take(120).collect() +} + +#[cfg(test)] +mod tests { + use super::*; + + fn u(s: &str) -> Url { + Url::parse(s).unwrap() + } + + #[test] + fn loopback_is_craftbot_and_the_web_is_not() { + assert!(is_craftbot(&u("http://localhost:7925/session/1"))); + assert!(is_craftbot(&u("http://127.0.0.1:7931/"))); + assert!(is_craftbot(&u("http://[::1]:7925/"))); + assert!(is_craftbot(&u("tauri://localhost/index.html"))); + assert!(is_craftbot(&u("http://tauri.localhost/index.html"))); + assert!(is_craftbot(&u("about:blank"))); + assert!(!is_craftbot(&u("https://github.com/CraftOS-dev/CraftBot"))); + assert!(!is_craftbot(&u("http://localhost.example.com/"))); + } + + #[test] + fn local_files_and_odd_schemes_are_not_navigated_to() { + assert!(allow_navigation(&u("https://example.com/"))); + assert!(allow_navigation(&u("http://localhost:7925/"))); + assert!(!allow_navigation(&u("file:///etc/passwd"))); + assert!(!allow_navigation(&u("mailto:someone@example.com"))); + } +} diff --git a/desktop/src/tray.rs b/desktop/src/tray.rs new file mode 100644 index 00000000..150fe8c9 --- /dev/null +++ b/desktop/src/tray.rs @@ -0,0 +1,155 @@ +//! The tray (menu bar on macOS): CraftBot's state and controls while the +//! window is closed. Closing the window only hides it; the agent keeps +//! working (schedules, proactive tasks) whether or not the app is open. + +use crate::agent::{self, Agent, Phase, Task}; +use crate::{login, shell}; +use launcher_core::logger; +use std::sync::Mutex; +use tauri::menu::{CheckMenuItem, Menu, MenuItem, PredefinedMenuItem}; +use tauri::tray::{MouseButton, MouseButtonState, TrayIconBuilder, TrayIconEvent}; +use tauri::{AppHandle, Manager, Wry}; +use tauri_plugin_opener::OpenerExt; + +struct Items { + status: MenuItem, + browser: MenuItem, + start: MenuItem, + stop: MenuItem, + restart: MenuItem, + login: CheckMenuItem, + /// What the items last showed, so an unchanged state is not re-sent. + shown: Mutex>, +} + +pub fn create(app: &AppHandle) -> tauri::Result<()> { + let status = MenuItem::with_id(app, "status", "Not running", false, None::<&str>)?; + let open = MenuItem::with_id(app, "open", "Open CraftBot", true, None::<&str>)?; + let browser = MenuItem::with_id(app, "browser", "Open in Browser", false, None::<&str>)?; + let start = MenuItem::with_id(app, "start", "Start", false, None::<&str>)?; + let stop = MenuItem::with_id(app, "stop", "Stop", false, None::<&str>)?; + let restart = MenuItem::with_id(app, "restart", "Restart", false, None::<&str>)?; + let login = CheckMenuItem::with_id( + app, + "login", + "Open at Login", + true, + login::is_on(), + None::<&str>, + )?; + let log = MenuItem::with_id(app, "log", "Open Log", true, None::<&str>)?; + let quit = MenuItem::with_id(app, "quit", "Quit", true, None::<&str>)?; + let menu = Menu::with_items( + app, + &[ + &status, + &PredefinedMenuItem::separator(app)?, + &open, + &browser, + &PredefinedMenuItem::separator(app)?, + &start, + &stop, + &restart, + &PredefinedMenuItem::separator(app)?, + &login, + &log, + &quit, + ], + )?; + + let mut builder = TrayIconBuilder::with_id("craftbot") + .tooltip("CraftBot") + .menu(&menu) + // Windows: a click opens the window, the menu is on right click. + // macOS menu bar items open their menu on click, as expected there. + .show_menu_on_left_click(cfg!(target_os = "macos")) + .on_menu_event(|app, event| on_menu(app, event.id().as_ref())) + .on_tray_icon_event(|tray, event| { + if let TrayIconEvent::Click { + button: MouseButton::Left, + button_state: MouseButtonState::Up, + .. + } = event + { + shell::show(tray.app_handle()); + } + }); + if let Some(icon) = app.default_window_icon() { + builder = builder.icon(icon.clone()); + } + builder.build(app)?; + + app.manage(Items { + status, + browser, + start, + stop, + restart, + login, + shown: Mutex::new(None), + }); + Ok(()) +} + +fn on_menu(app: &AppHandle, id: &str) { + match id { + "open" => shell::show(app), + "browser" => { + let url = app.state::().ui_url(); + if let Err(e) = app.opener().open_url(&url, None::<&str>) { + logger::log(&format!("could not open the browser: {e}")); + } + } + "start" => agent::run(app, Task::Start), + "stop" => agent::run(app, Task::Stop), + "restart" => agent::run(app, Task::Restart), + "login" => { + let items = app.state::(); + // The click has already flipped the check mark. + let on = items.login.is_checked().unwrap_or(false); + match login::set(on) { + Ok(()) => logger::log(&format!("open at login: {on}")), + Err(e) => logger::log(&format!("could not change open at login: {e}")), + } + let _ = items.login.set_checked(login::is_on()); + } + "log" => { + let path = app.state::().log_file(); + if let Err(e) = app.opener().open_path(path.to_string_lossy(), None::<&str>) { + logger::log(&format!("could not open the log: {e}")); + } + } + "quit" => { + logger::log("quit from the tray; CraftBot itself keeps running"); + app.exit(0); + } + _ => {} + } +} + +/// Reflect CraftBot's state in the menu. +pub fn update(app: &AppHandle, phase: Phase, busy: bool) { + let Some(items) = app.try_state::() else { + return; + }; + { + let mut shown = items.shown.lock().unwrap_or_else(|e| e.into_inner()); + if *shown == Some((phase, busy)) { + return; + } + *shown = Some((phase, busy)); + } + let label = match phase { + Phase::NotInstalled => "Not installed", + Phase::Stopped => "Not running", + Phase::Starting => "Starting…", + Phase::Running => "Running", + }; + let running = phase == Phase::Running; + let up = matches!(phase, Phase::Running | Phase::Starting); + let _ = items.status.set_text(if busy { "Working…" } else { label }); + let _ = items.browser.set_enabled(running); + let _ = items.start.set_enabled(phase == Phase::Stopped && !busy); + let _ = items.stop.set_enabled(up && !busy); + let _ = items.restart.set_enabled(running && !busy); +} diff --git a/desktop/tauri.conf.json b/desktop/tauri.conf.json new file mode 100644 index 00000000..b159ae0f --- /dev/null +++ b/desktop/tauri.conf.json @@ -0,0 +1,44 @@ +{ + "$schema": "https://schema.tauri.app/config/2", + "productName": "CraftBot", + "mainBinaryName": "craftbot-desktop", + "identifier": "dev.craftos.craftbot", + "build": { + "frontendDist": "ui" + }, + "app": { + "withGlobalTauri": true, + "windows": [], + "security": { + "csp": "default-src 'self'; img-src 'self' data:; style-src 'self' 'unsafe-inline'; script-src 'self'" + } + }, + "bundle": { + "active": true, + "targets": "all", + "publisher": "CraftOS", + "copyright": "CraftOS", + "homepage": "https://github.com/CraftOS-dev/CraftBot", + "category": "Productivity", + "shortDescription": "AI agent that builds and runs its own tools", + "longDescription": "CraftBot is an AI agent that works alongside you: it runs tasks, remembers your preferences, connects to your apps and builds its own tools. This app runs it in its own window.", + "icon": [ + "icons/32x32.png", + "icons/128x128.png", + "icons/128x128@2x.png", + "icons/icon.icns", + "icons/icon.ico" + ], + "macOS": { + "minimumSystemVersion": "12.0", + "infoPlist": "packaging/macos/Info.plist", + "entitlements": "packaging/macos/entitlements.plist" + }, + "windows": { + "nsis": { + "installMode": "currentUser", + "installerHooks": "packaging/windows/hooks.nsh" + } + } + } +} diff --git a/desktop/ui/index.html b/desktop/ui/index.html new file mode 100644 index 00000000..0150c107 --- /dev/null +++ b/desktop/ui/index.html @@ -0,0 +1,28 @@ + + + + + + CraftBot + + + +
+ +

CraftBot

+

+ + + + +
+
+ + +
+ + + diff --git a/desktop/ui/mark.png b/desktop/ui/mark.png new file mode 100644 index 00000000..5da80dd7 Binary files /dev/null and b/desktop/ui/mark.png differ diff --git a/desktop/ui/page.css b/desktop/ui/page.css new file mode 100644 index 00000000..3d1e7a3d --- /dev/null +++ b/desktop/ui/page.css @@ -0,0 +1,140 @@ +/* Tokens from the CraftBot UI (app/ui_layer/browser/frontend/src/styles/variables.css). */ +:root { + --bg: #191919; + --surface: #202020; + --border: rgba(255, 255, 255, 0.094); + --text: #E6E6E4; + --text-dim: #9B9A97; + --text-muted: #5A5A57; + --brand: #FF4F18; + --brand-hover: #E64515; + --error: #EF4444; + color-scheme: dark; +} + +* { box-sizing: border-box; } + +html, body { + height: 100%; + margin: 0; + background: var(--bg); + color: var(--text); + font: 14px/1.5 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; + -webkit-user-select: none; + user-select: none; +} + +body { + display: flex; + flex-direction: column; +} + +main { + flex: 1; + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + gap: 14px; + padding: 32px; +} + +.mark { width: 96px; height: 96px; } + +h1 { + margin: 0; + font-size: 24px; + font-weight: 600; + letter-spacing: -0.01em; +} + +.status { + margin: 0; + min-height: 21px; + max-width: 560px; + text-align: center; + color: var(--text-dim); +} +.status.error { color: var(--error); } + +.bar { + width: 320px; + height: 4px; + border-radius: 2px; + background: rgba(255, 255, 255, 0.12); + overflow: hidden; +} +.fill { + height: 100%; + width: 0; + background: var(--brand); + transition: width 0.3s ease; +} +.bar.indeterminate .fill { + width: 30%; + animation: slide 1.2s ease-in-out infinite; +} +@keyframes slide { + from { transform: translateX(-100%); } + to { transform: translateX(340%); } +} + +.primary { + margin-top: 6px; + min-width: 200px; + padding: 10px 20px; + border: 0; + border-radius: 6px; + background: var(--brand); + color: #fff; + font: inherit; + font-weight: 600; + cursor: pointer; +} +.primary:hover { background: var(--brand-hover); } +.primary:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; } + +.where { + display: flex; + gap: 8px; + max-width: 560px; + color: var(--text-muted); + font-size: 12px; +} +.where span { white-space: nowrap; } + +.link { + padding: 0; + border: 0; + background: none; + color: var(--text-dim); + font: inherit; + cursor: pointer; +} +.link:hover { color: var(--text); text-decoration: underline; } + +.details { + width: min(640px, 100%); + max-height: 220px; + margin: 4px 0 0; + padding: 12px 14px; + overflow: auto; + border: 1px solid var(--border); + border-radius: 6px; + background: var(--surface); + color: var(--text-dim); + font: 12px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; + white-space: pre-wrap; + -webkit-user-select: text; + user-select: text; +} + +footer { + display: flex; + justify-content: space-between; + padding: 12px 20px; + color: var(--text-muted); + font-size: 12px; +} + +[hidden] { display: none !important; } diff --git a/desktop/ui/page.js b/desktop/ui/page.js new file mode 100644 index 00000000..3ec5b2f7 --- /dev/null +++ b/desktop/ui/page.js @@ -0,0 +1,69 @@ +// The app's own page: shown until CraftBot is installed and running, and +// again whenever it stops. The app (src/agent.rs) decides when to switch +// the window to CraftBot's UI; this page only renders state and forwards +// the buttons. +'use strict' + +const { invoke } = window.__TAURI__.core +const $ = (id) => document.getElementById(id) + +const LABELS = { + notInstalled: 'Install CraftBot', + stopped: 'Start CraftBot', + running: 'Open CraftBot', +} + +function render(v) { + const busy = v.busy !== null + const starting = v.phase === 'starting' + + const status = $('status') + status.textContent = v.error || v.status + status.classList.toggle('error', !!v.error) + + const bar = $('bar') + bar.hidden = !(busy || starting) + bar.classList.toggle('indeterminate', v.progress === null) + $('fill').style.width = v.progress === null ? '' : `${Math.round(v.progress * 100)}%` + + const primary = $('primary') + let label = LABELS[v.phase] + if (v.phase === 'notInstalled' && v.setupFailed) label = 'Repair' + else if (v.error && v.phase === 'stopped') label = 'Try Again' + primary.hidden = busy || starting || !label + primary.textContent = label || '' + + $('where').hidden = v.phase !== 'notInstalled' || busy + $('dir').textContent = elide(v.installDir, 64) + $('change').hidden = !v.canChangeDir + + const details = $('details') + details.hidden = !(v.error && v.details) + if (details.textContent !== v.details) details.textContent = v.details + + const known = !['', 'latest', 'dev', 'unknown'].includes(v.version) + $('version').textContent = known ? `Version ${v.version}` : '' +} + +// Shorten from the middle so both the start and the final folder stay +// readable, as the setup window does. +function elide(text, limit) { + if (text.length <= limit) return text + const keep = Math.floor((limit - 1) / 2) + return `${text.slice(0, keep)}…${text.slice(-keep)}` +} + +async function poll() { + try { + render(await invoke('state')) + } catch (e) { + console.error(e) + } +} + +$('primary').addEventListener('click', () => invoke('primary').then(poll)) +$('change').addEventListener('click', () => invoke('choose_location')) +$('log').addEventListener('click', () => invoke('open_log')) + +poll() +setInterval(poll, 400) diff --git a/launcher/Cargo.lock b/launcher/Cargo.lock index 9165faea..7b55f28c 100644 --- a/launcher/Cargo.lock +++ b/launcher/Cargo.lock @@ -1008,25 +1008,32 @@ dependencies = [ [[package]] name = "craftbot-launcher" version = "0.1.0" +dependencies = [ + "craftbot-launcher-core", + "fontique", + "open", + "rfd", + "slint", + "slint-build", + "winresource", +] + +[[package]] +name = "craftbot-launcher-core" +version = "0.1.0" dependencies = [ "dirs", "flate2", - "fontique", "fs4", "libc", "native-tls", - "open", - "rfd", "serde", "serde_json", "sha2", - "slint", - "slint-build", "tar", "tempfile", "ureq", "windows-sys 0.59.0", - "winresource", "zip", ] diff --git a/launcher/Cargo.toml b/launcher/Cargo.toml index ea122157..62d307c3 100644 --- a/launcher/Cargo.toml +++ b/launcher/Cargo.toml @@ -26,41 +26,13 @@ slint = { version = "1.17", default-features = false, features = [ "accessibility", ] } -# HTTP, blocking. All downloads run on a worker thread, so a synchronous -# client is the simplest correct choice. Unix uses rustls with the OS trust -# store; Windows selects Schannel below, including its automatic root updates. -# Both honor installed corporate CAs and require no bundled OpenSSL library. -# ureq only reads proxy variables; src/proxy.rs adds NO_PROXY and the OS -# proxy setting (Windows registry, macOS scutil, GNOME gsettings). -ureq = { version = "2.12", default-features = false, features = ["tls", "native-certs", "json"] } -serde = { version = "1", features = ["derive"] } -serde_json = "1" -# SHA-256 of CraftBot-src.zip, checked against the digest the release -# publishes beside it before anything is extracted. -sha2 = "0.10" - -# Archives. The source payload is a zip; python-build-standalone is .tar.gz. -zip = { version = "2.4", default-features = false, features = ["deflate"] } -tar = "0.4" -flate2 = "1" +# Everything without a window: install, start, stop, state. Shared with +# the desktop app (desktop/). +craftbot-launcher-core = { path = "core" } # OS integration. rfd = { version = "0.15", default-features = false, features = ["xdg-portal", "async-std"] } open = "5" -dirs = "6" -fs4 = "0.13" - -[target.'cfg(windows)'.dependencies] -native-tls = "0.2" -ureq = { version = "2.12", default-features = false, features = ["native-tls"] } -windows-sys = { version = "0.59", features = [ - "Win32_Foundation", - "Win32_System_Registry", - "Win32_System_Threading", -] } - -[target.'cfg(unix)'.dependencies] -libc = "0.2" [target.'cfg(target_os = "linux")'.dependencies] # Slint finds fonts through fontique, which links libfontconfig unless told @@ -69,15 +41,17 @@ libc = "0.2" # packaging/linux/check_binary.sh rejects the build. fontique = { version = "0.10", default-features = false, features = ["fontconfig-dlopen"] } -[dev-dependencies] -tempfile = "3" - [build-dependencies] slint-build = "1.17" [target.'cfg(windows)'.build-dependencies] winresource = "0.1" +# `cargo test` here also runs the core's tests, as CI expects. +[workspace] +members = ["core"] +default-members = [".", "core"] + [profile.release] opt-level = "s" lto = true diff --git a/launcher/README.md b/launcher/README.md index e64e5842..6f4b2b64 100644 --- a/launcher/README.md +++ b/launcher/README.md @@ -68,7 +68,7 @@ start, removed on exit; checked against a live process) for "running", and `.agent-ready` for "running and actually serving" versus "still starting". Before anything is downloaded the launcher checks the macOS version -(`MIN_MACOS` in `src/preflight.rs`, also the bundle's +(`MIN_MACOS` in `core/src/preflight.rs`, also the bundle's `LSMinimumSystemVersion`), that the install location does not hold the user's data, and that the drive holding the data root (which receives the packages and runtimes) has `MIN_FREE_GB` (3 GB) free. @@ -115,12 +115,12 @@ Windows downloads use Schannel so certificate chains resolve on a fresh machine, including roots Windows retrieves on demand. Other platforms use rustls with the OS trust store. -Every download (`src/download.rs`) is retried up to three times with +Every download (`core/src/download.rs`) is retried up to three times with backoff. `CraftBot-src.zip` is verified by SHA-256 against the `CraftBot-src.zip.sha256` asset the release publishes beside it; the Python runtime comes from the release metadata described above and is accepted only once the unpacked interpreter reports Python 3.10. The proxy is chosen -per URL (`src/proxy.rs`): +per URL (`core/src/proxy.rs`): `HTTPS_PROXY`/`HTTP_PROXY`/`ALL_PROXY` with `NO_PROXY`, otherwise the OS setting (Windows Internet Options, macOS `scutil --proxy`, GNOME gsettings). Configuration scripts (PAC) are not evaluated; set `HTTPS_PROXY` instead. @@ -233,24 +233,28 @@ selects GPU rendering; `SLINT_BACKEND=winit-software` selects software rendering ## Layout +Everything without a window is the `core` library, which the desktop app +(`desktop/`) is built on as well. `cargo test` here runs both crates. + ``` launcher/ - Cargo.toml - build.rs compiles the UI, bakes in the version, Windows icon + Cargo.toml the window; a workspace with core/ + build.rs compiles the UI, Windows icon ui/app.slint the window — layout, palette, buttons, progress assets/ logo mark (two blink frames) and the .ico src/main.rs window ↔ state wiring, headless mode - src/state.rs installed / stopped / starting / running - src/install.rs the jobs behind the buttons - src/python.rs the Python sidecar - src/payload.rs CraftBot-src.zip: locate, download, extract, mark - src/craftbot.rs running craftbot.py and streaming its output - src/paths.rs every path, mirrored from app/paths.py and craftbot.py - src/record.rs launcher.json - src/download.rs HTTP with progress, retries, checksums, mirrors - src/proxy.rs proxy choice: variables, NO_PROXY, the OS setting - src/preflight.rs checks before any download (MIN_MACOS) - src/logger.rs launcher.log + core/build.rs bakes in the version + core/src/state.rs installed / stopped / starting / running + core/src/install.rs the jobs behind the buttons + core/src/python.rs the Python sidecar + core/src/payload.rs CraftBot-src.zip: locate, download, extract, mark + core/src/craftbot.rs running craftbot.py and streaming its output + core/src/paths.rs every path, mirrored from app/paths.py and craftbot.py + core/src/record.rs launcher.json + core/src/download.rs HTTP with progress, retries, checksums, mirrors + core/src/proxy.rs proxy choice: variables, NO_PROXY, the OS setting + core/src/preflight.rs checks before any download (MIN_MACOS) + core/src/logger.rs launcher.log packaging/macos/bundle.sh the .app; Developer ID or ad-hoc signing packaging/linux/check_binary.sh glibc floor and linked-library check packaging/patch_craftbot.py the two craftbot.py edits diff --git a/launcher/build.rs b/launcher/build.rs index aed0c4cc..864b3b02 100644 --- a/launcher/build.rs +++ b/launcher/build.rs @@ -1,34 +1,9 @@ -//! Build script: compiles the Slint UI, pins the CraftBot version into the -//! binary, and (on Windows) embeds the icon. +//! Build script: compiles the Slint UI and (on Windows) embeds the icon. +//! The CraftBot version is pinned by the core's build script (core/build.rs). -use std::path::{Path, PathBuf}; +use std::path::Path; fn main() { - // ── Version ───────────────────────────────────────────────────────── - // The launcher downloads the CraftBot release that matches its own - // version, so the version has to be baked in. Resolution order: - // 1. CRAFTBOT_VERSION in the environment (what release.yml sets from - // the git tag, e.g. "1.4.0"). - // 2. A VERSION file at the repository root (a local release build). - // 3. "latest" — a dev build, which downloads the newest release. - let version = std::env::var("CRAFTBOT_VERSION") - .ok() - .map(|v| v.trim().trim_start_matches('v').to_string()) - .filter(|v| !v.is_empty()) - .or_else(|| { - std::fs::read_to_string(repo_root().join("VERSION")) - .ok() - .map(|v| v.trim().trim_start_matches('v').to_string()) - .filter(|v| !v.is_empty()) - }) - .unwrap_or_else(|| "latest".to_string()); - println!("cargo:rustc-env=CRAFTBOT_VERSION={version}"); - println!("cargo:rerun-if-env-changed=CRAFTBOT_VERSION"); - println!( - "cargo:rerun-if-changed={}", - repo_root().join("VERSION").display() - ); - // ── UI ────────────────────────────────────────────────────────────── // One style everywhere. The window is drawn from primitives (rectangles, // text, touch areas), so the style only affects the few std-widgets used @@ -53,12 +28,3 @@ fn main() { } let _ = Path::new("assets"); } - -/// The CraftBot repository root: this crate lives in `/launcher/`. -fn repo_root() -> PathBuf { - let manifest = std::env::var("CARGO_MANIFEST_DIR").expect("CARGO_MANIFEST_DIR"); - Path::new(&manifest) - .parent() - .map(Path::to_path_buf) - .unwrap_or_else(|| PathBuf::from(&manifest)) -} diff --git a/launcher/core/Cargo.toml b/launcher/core/Cargo.toml new file mode 100644 index 00000000..a514abb7 --- /dev/null +++ b/launcher/core/Cargo.toml @@ -0,0 +1,49 @@ +[package] +name = "craftbot-launcher-core" +version = "0.1.0" +edition = "2021" +rust-version = "1.87" +description = "What the CraftBot setup window and the CraftBot desktop app share: install, start, stop and state, without any UI" +license = "MIT" +publish = false + +[lib] +name = "launcher_core" +path = "src/lib.rs" + +[dependencies] +# HTTP, blocking. All downloads run on a worker thread, so a synchronous +# client is the simplest correct choice. Unix uses rustls with the OS trust +# store; Windows selects Schannel below, including its automatic root updates. +# Both honor installed corporate CAs and require no bundled OpenSSL library. +# ureq only reads proxy variables; src/proxy.rs adds NO_PROXY and the OS +# proxy setting (Windows registry, macOS scutil, GNOME gsettings). +ureq = { version = "2.12", default-features = false, features = ["tls", "native-certs", "json"] } +serde = { version = "1", features = ["derive"] } +serde_json = "1" +# SHA-256 of CraftBot-src.zip, checked against the digest the release +# publishes beside it before anything is extracted. +sha2 = "0.10" + +# Archives. The source payload is a zip; python-build-standalone is .tar.gz. +zip = { version = "2.4", default-features = false, features = ["deflate"] } +tar = "0.4" +flate2 = "1" + +dirs = "6" +fs4 = "0.13" + +[target.'cfg(windows)'.dependencies] +native-tls = "0.2" +ureq = { version = "2.12", default-features = false, features = ["native-tls"] } +windows-sys = { version = "0.59", features = [ + "Win32_Foundation", + "Win32_System_Registry", + "Win32_System_Threading", +] } + +[target.'cfg(unix)'.dependencies] +libc = "0.2" + +[dev-dependencies] +tempfile = "3" diff --git a/launcher/core/build.rs b/launcher/core/build.rs new file mode 100644 index 00000000..b93b5df1 --- /dev/null +++ b/launcher/core/build.rs @@ -0,0 +1,40 @@ +//! Build script: pins the CraftBot version into the library. Every binary +//! built on it (the setup window, the desktop app) downloads the release +//! that matches this version. + +use std::path::{Path, PathBuf}; + +fn main() { + // Resolution order: + // 1. CRAFTBOT_VERSION in the environment (what release.yml sets from + // the git tag, e.g. "1.4.0"). + // 2. A VERSION file at the repository root (a local release build). + // 3. "latest" — a dev build, which downloads the newest release. + let version = std::env::var("CRAFTBOT_VERSION") + .ok() + .map(|v| v.trim().trim_start_matches('v').to_string()) + .filter(|v| !v.is_empty()) + .or_else(|| { + std::fs::read_to_string(repo_root().join("VERSION")) + .ok() + .map(|v| v.trim().trim_start_matches('v').to_string()) + .filter(|v| !v.is_empty()) + }) + .unwrap_or_else(|| "latest".to_string()); + println!("cargo:rustc-env=CRAFTBOT_VERSION={version}"); + println!("cargo:rerun-if-env-changed=CRAFTBOT_VERSION"); + println!( + "cargo:rerun-if-changed={}", + repo_root().join("VERSION").display() + ); +} + +/// The CraftBot repository root: this crate lives in `/launcher/core/`. +fn repo_root() -> PathBuf { + let manifest = std::env::var("CARGO_MANIFEST_DIR").expect("CARGO_MANIFEST_DIR"); + Path::new(&manifest) + .ancestors() + .nth(2) + .map(Path::to_path_buf) + .unwrap_or_else(|| PathBuf::from(&manifest)) +} diff --git a/launcher/src/craftbot.rs b/launcher/core/src/craftbot.rs similarity index 100% rename from launcher/src/craftbot.rs rename to launcher/core/src/craftbot.rs diff --git a/launcher/src/download.rs b/launcher/core/src/download.rs similarity index 100% rename from launcher/src/download.rs rename to launcher/core/src/download.rs diff --git a/launcher/src/install.rs b/launcher/core/src/install.rs similarity index 100% rename from launcher/src/install.rs rename to launcher/core/src/install.rs diff --git a/launcher/core/src/lib.rs b/launcher/core/src/lib.rs new file mode 100644 index 00000000..01344bf1 --- /dev/null +++ b/launcher/core/src/lib.rs @@ -0,0 +1,83 @@ +//! The part of the CraftBot launcher that has no window: getting a source +//! tree and an interpreter onto the disk, running `craftbot.py`, and telling +//! whether CraftBot is installed, starting or running. +//! +//! Two programs are built on it: the setup window (`launcher/`, Slint) and +//! the desktop app (`desktop/`, Tauri). Neither reimplements what +//! `install.py` and `run.py` do; see `install` and `craftbot`. + +pub mod craftbot; +pub mod download; +pub mod install; +pub mod logger; +pub mod paths; +pub mod payload; +pub mod preflight; +pub mod proxy; +pub mod python; +pub mod record; +pub mod state; + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn elide_keeps_both_ends() { + let p = "C:\\Users\\someone\\AppData\\Local\\Programs\\CraftBot"; + let e = paths::elide(p, 20); + assert!(e.starts_with("C:\\Users")); + assert!(e.ends_with("CraftBot")); + assert!(e.contains("...")); + assert_eq!(paths::elide("short", 20), "short"); + } + + #[test] + fn ansi_is_stripped() { + assert_eq!( + logger::strip_ansi("\x1b[38;2;255;79;24m▸\x1b[0m hi"), + "▸ hi" + ); + } + + #[test] + fn meaningful_lines() { + assert_eq!(craftbot::meaningful("═══════════"), None); + assert_eq!(craftbot::meaningful(" "), None); + assert_eq!( + craftbot::meaningful(" ▸ STEP 1/3 Installing dependencies"), + Some("STEP 1/3 Installing dependencies".into()) + ); + } + + #[test] + fn extract_handles_wrapper_dir() { + let tmp = + std::env::temp_dir().join(format!("craftbot-launcher-test-{}", std::process::id())); + let _ = std::fs::remove_dir_all(&tmp); + std::fs::create_dir_all(&tmp).unwrap(); + let zip_path = tmp.join("src.zip"); + { + let f = std::fs::File::create(&zip_path).unwrap(); + let mut w = zip::ZipWriter::new(f); + let opts = zip::write::SimpleFileOptions::default(); + w.start_file("CraftBot-1.0/run.py", opts).unwrap(); + std::io::Write::write_all(&mut w, b"print('hi')\n").unwrap(); + w.start_file("CraftBot-1.0/app/__init__.py", opts).unwrap(); + w.finish().unwrap(); + } + let target = tmp.join("install"); + let root = payload::extract(&zip_path, &target).unwrap(); + assert!(root.join("run.py").is_file()); + assert!(root.ends_with("CraftBot-1.0")); + payload::mark_managed(&root).unwrap(); + assert!(root.join(paths::MANAGED_MARKER).is_file()); + let _ = std::fs::remove_dir_all(&tmp); + } + + #[test] + fn version_is_baked_in() { + assert!(!payload::VERSION.is_empty()); + assert!(payload::download_url().contains("CraftBot-src.zip")); + } +} diff --git a/launcher/src/logger.rs b/launcher/core/src/logger.rs similarity index 87% rename from launcher/src/logger.rs rename to launcher/core/src/logger.rs index 6bd1bb63..6389a9dd 100644 --- a/launcher/src/logger.rs +++ b/launcher/core/src/logger.rs @@ -7,15 +7,23 @@ use std::fs::{File, OpenOptions}; use std::io::Write; +use std::sync::atomic::{AtomicBool, Ordering}; use std::sync::{Mutex, OnceLock}; use std::time::{SystemTime, UNIX_EPOCH}; static LOG: OnceLock>> = OnceLock::new(); +static SILENT: AtomicBool = AtomicBool::new(false); + +/// Write nothing from now on. For the unit tests of crates built on this +/// one, which must not write into the real user profile either. +pub fn silence() { + SILENT.store(true, Ordering::SeqCst); +} fn handle() -> &'static Mutex> { LOG.get_or_init(|| { // Unit tests must not write into the real user profile. - if cfg!(test) { + if cfg!(test) || SILENT.load(Ordering::SeqCst) { return Mutex::new(None); } let path = crate::paths::launcher_log(); @@ -34,6 +42,9 @@ fn handle() -> &'static Mutex> { /// Append one line, timestamped. Never fails; a log that cannot be written /// must not stop an install. pub fn log(line: &str) { + if SILENT.load(Ordering::SeqCst) { + return; + } if let Ok(mut guard) = handle().lock() { if let Some(file) = guard.as_mut() { let _ = writeln!(file, "{} {}", stamp(), line); @@ -43,6 +54,9 @@ pub fn log(line: &str) { /// Append raw subprocess output (already a complete line). pub fn raw(line: &str) { + if SILENT.load(Ordering::SeqCst) { + return; + } if let Ok(mut guard) = handle().lock() { if let Some(file) = guard.as_mut() { let _ = writeln!(file, " {line}"); diff --git a/launcher/src/paths.rs b/launcher/core/src/paths.rs similarity index 96% rename from launcher/src/paths.rs rename to launcher/core/src/paths.rs index 2c5fb998..ba229f46 100644 --- a/launcher/src/paths.rs +++ b/launcher/core/src/paths.rs @@ -184,10 +184,15 @@ pub const DEFAULT_BROWSER_URL: &str = "http://localhost:7925"; /// The URL "Open CraftBot" should open: `ui.json`'s, else the default. pub fn browser_url() -> String { - std::fs::read_to_string(ui_file()) + ui_url_in(&user_data_root()).unwrap_or_else(|| DEFAULT_BROWSER_URL.to_string()) +} + +/// The URL in `/ui.json`, if run.py has written one. A source +/// checkout keeps its state (and so its ui.json) in the checkout itself. +pub fn ui_url_in(state_root: &Path) -> Option { + std::fs::read_to_string(state_root.join("ui.json")) .ok() .and_then(|text| parse_ui_url(&text)) - .unwrap_or_else(|| DEFAULT_BROWSER_URL.to_string()) } fn parse_ui_url(text: &str) -> Option { diff --git a/launcher/src/payload.rs b/launcher/core/src/payload.rs similarity index 100% rename from launcher/src/payload.rs rename to launcher/core/src/payload.rs diff --git a/launcher/src/preflight.rs b/launcher/core/src/preflight.rs similarity index 100% rename from launcher/src/preflight.rs rename to launcher/core/src/preflight.rs diff --git a/launcher/src/proxy.rs b/launcher/core/src/proxy.rs similarity index 100% rename from launcher/src/proxy.rs rename to launcher/core/src/proxy.rs diff --git a/launcher/src/python.rs b/launcher/core/src/python.rs similarity index 99% rename from launcher/src/python.rs rename to launcher/core/src/python.rs index 319a4973..cfcec84c 100644 --- a/launcher/src/python.rs +++ b/launcher/core/src/python.rs @@ -35,7 +35,7 @@ struct DownloadConfig { impl DownloadConfig { fn bundled() -> Result { - serde_json::from_str(include_str!("../../app/provision/python_downloads.json")) + serde_json::from_str(include_str!("../../../app/provision/python_downloads.json")) .map_err(|error| format!("invalid Python download configuration: {error}")) } diff --git a/launcher/src/record.rs b/launcher/core/src/record.rs similarity index 100% rename from launcher/src/record.rs rename to launcher/core/src/record.rs diff --git a/launcher/src/state.rs b/launcher/core/src/state.rs similarity index 98% rename from launcher/src/state.rs rename to launcher/core/src/state.rs index 47ebd45b..8c2dfafd 100644 --- a/launcher/src/state.rs +++ b/launcher/core/src/state.rs @@ -64,7 +64,7 @@ pub fn poll() -> Snapshot { } /// Either `{"pid": N, ...}` or a bare integer. -fn read_pid(path: &Path) -> Option { +pub fn read_pid(path: &Path) -> Option { parse_pid(&std::fs::read_to_string(path).ok()?) } diff --git a/launcher/packaging/macos/bundle.sh b/launcher/packaging/macos/bundle.sh index 32ce54f3..c4eeed08 100755 --- a/launcher/packaging/macos/bundle.sh +++ b/launcher/packaging/macos/bundle.sh @@ -22,7 +22,7 @@ # binary with no signature at all; an ad-hoc one runs once the user allows # it in System Settings > Privacy & Security. # -# LSMinimumSystemVersion comes from MIN_MACOS in src/preflight.rs, the same +# LSMinimumSystemVersion comes from MIN_MACOS in core/src/preflight.rs, the same # constant the launcher checks before it downloads anything. set -euo pipefail @@ -35,9 +35,9 @@ here="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" repo="$(cd "$here/../../.." && pwd)" app="$out/CraftBotInstaller.app" -min_macos="$(sed -n 's/^pub const MIN_MACOS: &str = "\(.*\)";/\1/p' "$repo/launcher/src/preflight.rs")" +min_macos="$(sed -n 's/^pub const MIN_MACOS: &str = "\(.*\)";/\1/p' "$repo/launcher/core/src/preflight.rs")" if [ -z "$min_macos" ]; then - echo "error: MIN_MACOS not found in launcher/src/preflight.rs" >&2 + echo "error: MIN_MACOS not found in launcher/core/src/preflight.rs" >&2 exit 1 fi diff --git a/launcher/src/main.rs b/launcher/src/main.rs index 54eacdda..a26ec414 100644 --- a/launcher/src/main.rs +++ b/launcher/src/main.rs @@ -20,22 +20,11 @@ #[cfg(all(windows, target_env = "msvc", not(target_feature = "crt-static")))] compile_error!("The Windows installer needs a static C runtime. Build from the repository or launcher directory so .cargo/config.toml is loaded."); -mod craftbot; -mod download; -mod install; -mod logger; -mod paths; -mod payload; -mod preflight; -mod proxy; -mod python; -mod record; -mod state; - -use install::{Event, Job}; -use record::InstallRecord; +use launcher_core::install::{self, Event, Job}; +use launcher_core::record::InstallRecord; +use launcher_core::state::{self, Phase, Snapshot}; +use launcher_core::{download, logger, paths, payload, preflight}; use slint::{ComponentHandle, SharedString}; -use state::{Phase, Snapshot}; use std::cell::{Cell, RefCell}; use std::cmp::Ordering; use std::path::PathBuf; @@ -635,59 +624,6 @@ enum Tone { mod tests { use super::*; - #[test] - fn elide_keeps_both_ends() { - let p = "C:\\Users\\someone\\AppData\\Local\\Programs\\CraftBot"; - let e = paths::elide(p, 20); - assert!(e.starts_with("C:\\Users")); - assert!(e.ends_with("CraftBot")); - assert!(e.contains("...")); - assert_eq!(paths::elide("short", 20), "short"); - } - - #[test] - fn ansi_is_stripped() { - assert_eq!( - logger::strip_ansi("\x1b[38;2;255;79;24m▸\x1b[0m hi"), - "▸ hi" - ); - } - - #[test] - fn meaningful_lines() { - assert_eq!(craftbot::meaningful("═══════════"), None); - assert_eq!(craftbot::meaningful(" "), None); - assert_eq!( - craftbot::meaningful(" ▸ STEP 1/3 Installing dependencies"), - Some("STEP 1/3 Installing dependencies".into()) - ); - } - - #[test] - fn extract_handles_wrapper_dir() { - let tmp = - std::env::temp_dir().join(format!("craftbot-launcher-test-{}", std::process::id())); - let _ = std::fs::remove_dir_all(&tmp); - std::fs::create_dir_all(&tmp).unwrap(); - let zip_path = tmp.join("src.zip"); - { - let f = std::fs::File::create(&zip_path).unwrap(); - let mut w = zip::ZipWriter::new(f); - let opts = zip::write::SimpleFileOptions::default(); - w.start_file("CraftBot-1.0/run.py", opts).unwrap(); - std::io::Write::write_all(&mut w, b"print('hi')\n").unwrap(); - w.start_file("CraftBot-1.0/app/__init__.py", opts).unwrap(); - w.finish().unwrap(); - } - let target = tmp.join("install"); - let root = payload::extract(&zip_path, &target).unwrap(); - assert!(root.join("run.py").is_file()); - assert!(root.ends_with("CraftBot-1.0")); - payload::mark_managed(&root).unwrap(); - assert!(root.join(paths::MANAGED_MARKER).is_file()); - let _ = std::fs::remove_dir_all(&tmp); - } - #[test] fn details_are_shortened_per_line() { let long = "x".repeat(200); @@ -699,10 +635,4 @@ mod tests { assert!(lines[1].ends_with('…')); assert_eq!(lines[2], "b"); } - - #[test] - fn version_is_baked_in() { - assert!(!payload::VERSION.is_empty()); - assert!(payload::download_url().contains("CraftBot-src.zip")); - } } diff --git a/scripts/package_source.py b/scripts/package_source.py index 96fa0c8c..a54d57b5 100644 --- a/scripts/package_source.py +++ b/scripts/package_source.py @@ -58,6 +58,7 @@ "tests/", "diagnostic/", "launcher/", # the native launcher is built and shipped separately + "desktop/", # so is the desktop app ) EXCLUDE_SUFFIXES = (".md",) diff --git a/tests/test_desktop_open.py b/tests/test_desktop_open.py index 32b51416..969d2291 100644 --- a/tests/test_desktop_open.py +++ b/tests/test_desktop_open.py @@ -218,3 +218,50 @@ def test_open_command_names_this_install(tmp_path, monkeypatch): ) def test_desktop_entry_arguments_are_quoted_per_spec(arg, expected): assert craftbot._desktop_entry_arg(arg) == expected + + +# ─── The desktop app ───────────────────────────────────────────────────────── + + +@pytest.fixture +def no_desktop_app(monkeypatch): + monkeypatch.setenv("CRAFTBOT_DESKTOP_APP", "off") + + +def test_desktop_app_can_be_named_or_turned_off(tmp_path, monkeypatch): + app = tmp_path / "craftbot-desktop" + app.write_text("") + monkeypatch.setenv("CRAFTBOT_DESKTOP_APP", str(app)) + assert craftbot._desktop_app() == [str(app)] + monkeypatch.setenv("CRAFTBOT_DESKTOP_APP", str(tmp_path / "missing")) + assert craftbot._desktop_app() is None + monkeypatch.setenv("CRAFTBOT_DESKTOP_APP", "off") + assert craftbot._desktop_app() is None + + +def test_the_app_is_told_which_craftbot_to_drive(tmp_path, monkeypatch): + started = [] + monkeypatch.setattr(craftbot, "IS_FROZEN", False) + monkeypatch.setattr(craftbot, "_desktop_app", lambda: ["/opt/craftbot-desktop"]) + monkeypatch.setattr(craftbot, "_installed_python", lambda: "/runtime/python3") + monkeypatch.setattr(craftbot.paths, "STATE_ROOT", tmp_path) + monkeypatch.setattr(craftbot.subprocess, "Popen", lambda cmd, **kw: started.append(cmd)) + opened = [] + monkeypatch.setattr(craftbot.webbrowser, "open", lambda url: opened.append(url)) + + craftbot._open_browser_detached("http://localhost:7925") + + assert opened == [] + assert started == [[ + "/opt/craftbot-desktop", + "--dir", craftbot.BASE_DIR, + "--python", "/runtime/python3", + f"--state-root={tmp_path.resolve()}", + ]] + + +def test_without_the_app_the_browser_opens(no_desktop_app, monkeypatch): + opened = [] + monkeypatch.setattr(craftbot.webbrowser, "open", lambda url: opened.append(url)) + craftbot._open_browser_detached("http://localhost:7925") + assert opened == ["http://localhost:7925"]