diff --git a/.cargo/audit.toml b/.cargo/audit.toml new file mode 100644 index 00000000..23c3852b --- /dev/null +++ b/.cargo/audit.toml @@ -0,0 +1,11 @@ +[advisories] +ignore = [ + # time 0.1 + "RUSTSEC-2020-0071", + # needs sqlx 0.7 (still in alpha) + "RUSTSEC-2022-0090", + # wry needs kuchiki on Android + "RUSTSEC-2023-0019", + # atty is only used when the `colored` feature is enabled on tauri-plugin-log + "RUSTSEC-2021-0145" +] \ No newline at end of file diff --git a/.changes/config.json b/.changes/config.json index 19006ae4..212c3df5 100644 --- a/.changes/config.json +++ b/.changes/config.json @@ -3,12 +3,12 @@ "pkgManagers": { "javascript": { "version": true, - "getPublishedVersion": "node ../../.scripts/covector/package-latest-version.js npm ${ pkgFile.pkg.name } ${ pkgFile.pkg.version }", + "getPublishedVersion": "node ../../.scripts/covector/package-latest-version.cjs npm ${ pkgFile.pkg.name } ${ pkgFile.pkg.version }", "publish": ["pnpm build", "pnpm publish --access public --no-git-checks"] }, "rust": { "version": true, - "getPublishedVersion": "node ../../.scripts/covector/package-latest-version.js cargo ${ pkgFile.pkg.package.name } ${ pkgFile.pkg.package.version }", + "getPublishedVersion": "node ../../.scripts/covector/package-latest-version.cjs cargo ${ pkgFile.pkg.package.name } ${ pkgFile.pkg.package.version }", "publish": [ { "command": "cargo package --no-verify", @@ -33,85 +33,130 @@ } }, "packages": { + "api-example": { + "path": "./examples/api/src-tauri", + "manager": "rust", + "publish": false, + "dependencies": [ + "app", + "log-plugin", + "cli", + "clipboard", + "dialog", + "fs", + "global-shortcut", + "http", + "notification", + "os", + "process", + "shell", + "updater", + "window" + ] + }, + "api-example-js": { + "path": "./examples/api", + "manager": "javascript", + "publish": false, + "dependencies": [ + "app-js", + "log-js", + "cli-js", + "clipboard-js", + "dialog-js", + "fs-js", + "global-shortcut-js", + "http-js", + "notification-js", + "os-js", + "process-js", + "shell-js", + "updater-js", + "window-js" + ] + }, + + "app": { + "path": "./plugins/app", + "manager": "rust" + }, + "app-js": { + "path": "./plugins/app", + "manager": "javascript" + }, + "authenticator": { "path": "./plugins/authenticator", - "manager": "rust-disabled" + "manager": "rust" }, "authenticator-js": { "path": "./plugins/authenticator", - "manager": "javascript-disabled" + "manager": "javascript" }, "autostart": { "path": "./plugins/autostart", - "manager": "rust-disabled" + "manager": "rust" }, "autostart-js": { "path": "./plugins/autostart", - "manager": "javascript-disabled" + "manager": "javascript" }, "cli": { "path": "./plugins/cli", - "manager": "rust-disabled" + "manager": "rust" }, "cli-js": { "path": "./plugins/cli", - "manager": "javascript-disabled" + "manager": "javascript" }, - "clipboard": { - "path": "./plugins/clipboard", - "manager": "rust-disabled" + "clipboard-manager": { + "path": "./plugins/clipboard-manager", + "manager": "rust" }, - "clipboard-js": { - "path": "./plugins/clipboard", - "manager": "javascript-disabled" - }, - - "dialog": { - "path": "./plugins/dialog", - "manager": "rust-disabled" - }, - "dialog-js": { - "path": "./plugins/dialog", - "manager": "javascript-disabled" + "clipboard-manager-js": { + "path": "./plugins/clipboard-manager", + "manager": "javascript" }, "fs": { "path": "./plugins/fs", - "manager": "rust-disabled" + "manager": "rust" }, "fs-js": { "path": "./plugins/fs", - "manager": "javascript-disabled" + "manager": "javascript" }, - "fs-watch": { - "path": "./plugins/fs-watch", - "manager": "rust-disabled" + "dialog": { + "path": "./plugins/dialog", + "manager": "rust", + "dependencies": ["fs"] }, - "fs-watch-js": { - "path": "./plugins/fs-watch", - "manager": "javascript-disabled" + "dialog-js": { + "path": "./plugins/dialog", + "manager": "javascript" }, "global-shortcut": { "path": "./plugins/global-shortcut", - "manager": "rust-disabled" + "manager": "rust" }, "global-shortcut-js": { "path": "./plugins/global-shortcut", - "manager": "javascript-disabled" + "manager": "javascript" }, "http": { "path": "./plugins/http", - "manager": "rust-disabled" + "manager": "rust", + "dependencies": ["fs"] }, "http-js": { "path": "./plugins/http", - "manager": "javascript-disabled" + "manager": "javascript" }, "localhost": { @@ -119,27 +164,37 @@ "manager": "rust" }, - "log": { + "log-plugin": { "path": "./plugins/log", - "manager": "rust-disabled" + "manager": "rust" }, "log-js": { "path": "./plugins/log", - "manager": "javascript-disabled" + "manager": "javascript" }, "notification": { "path": "./plugins/notification", - "manager": "rust-disabled" + "manager": "rust" }, "notification-js": { "path": "./plugins/notification", - "manager": "javascript-disabled" + "manager": "javascript" + }, + + "os": { + "path": "./plugins/os", + "manager": "rust" + }, + "os-js": { + "path": "./plugins/os", + "manager": "javascript" }, "persisted-scope": { "path": "./plugins/persisted-scope", - "manager": "rust" + "manager": "rust", + "dependencies": ["fs"] }, "positioner": { @@ -148,66 +203,114 @@ }, "positioner-js": { "path": "./plugins/positioner", - "manager": "javascript-disabled" + "manager": "javascript" + }, + + "process": { + "path": "./plugins/process", + "manager": "rust" + }, + "process-js": { + "path": "./plugins/process", + "manager": "javascript" }, "shell": { "path": "./plugins/shell", - "manager": "rust-disabled" + "manager": "rust" }, "shell-js": { "path": "./plugins/shell", - "manager": "javascript-disabled" + "manager": "javascript" }, "single-instance": { "path": "./plugins/single-instance", - "manager": "rust-disabled" + "manager": "rust" }, "sql": { "path": "./plugins/sql", - "manager": "rust-disabled" + "manager": "rust", + "publish": [ + { + "command": "cargo package --no-verify", + "dryRunCommand": true + }, + { + "command": "echo '
\n

Cargo Publish

\n\n```'", + "dryRunCommand": true, + "pipe": true + }, + { + "command": "cargo publish --features sqlite", + "dryRunCommand": "cargo publish --features sqlite --dry-run", + "pipe": true + }, + { + "command": "echo '```\n\n
\n'", + "dryRunCommand": true, + "pipe": true + } + ] }, "sql-js": { "path": "./plugins/sql", - "manager": "javascript-disabled" + "manager": "javascript" }, "store": { "path": "./plugins/store", - "manager": "rust-disabled" + "manager": "rust" }, "store-js": { "path": "./plugins/store", - "manager": "javascript-disabled" + "manager": "javascript" }, "stronghold": { "path": "./plugins/stronghold", - "manager": "rust-disabled" + "manager": "rust" }, "stronghold-js": { "path": "./plugins/stronghold", - "manager": "javascript-disabled" + "manager": "javascript" + }, + + "updater": { + "path": "./plugins/updater", + "manager": "rust" + }, + "updater-js": { + "path": "./plugins/updater", + "manager": "javascript" }, "upload": { "path": "./plugins/upload", - "manager": "rust-disabled" + "manager": "rust" }, "upload-js": { "path": "./plugins/upload", - "manager": "javascript-disabled" + "manager": "javascript" }, "websocket": { "path": "./plugins/websocket", - "manager": "rust-disabled" + "manager": "rust" }, "websocket-js": { "path": "./plugins/websocket", - "manager": "javascript-disabled" + "manager": "javascript" + }, + + "window": { + "path": "./plugins/window", + "manager": "rust" + }, + "window-js": { + "path": "./plugins/window", + "manager": "javascript" }, "window-state": { @@ -216,7 +319,7 @@ }, "window-state-js": { "path": "./plugins/window-state", - "manager": "javascript-disabled" + "manager": "javascript" } } } diff --git a/.changes/notification-init-script.md b/.changes/notification-init-script.md new file mode 100644 index 00000000..fce58ba4 --- /dev/null +++ b/.changes/notification-init-script.md @@ -0,0 +1,5 @@ +--- +"notification": patch +--- + +Use `window.__TAURI_INVOKE__` instead of `window.__TAURI__` in init.js, fixes usage in apps without `withGlobalTauri` enabled. diff --git a/.changes/notification-sound.md b/.changes/notification-sound.md new file mode 100644 index 00000000..35f75536 --- /dev/null +++ b/.changes/notification-sound.md @@ -0,0 +1,5 @@ +--- +"notification": patch +--- + +Play a default sound when showing a notification on Windows. diff --git a/.changes/os-plugin-refactor.md b/.changes/os-plugin-refactor.md new file mode 100644 index 00000000..63cd5bdd --- /dev/null +++ b/.changes/os-plugin-refactor.md @@ -0,0 +1,11 @@ +--- +"os": minor +"os-js": minor +--- + +The os plugin is recieving a few changes to improve consistency and add new features: + +- Renamed `Kind` enum to `OsType` and `kind()` function to `os_type()`. +- Added `family()`,`exe_extension()`, and `hostname()` functions and their equivalents for JS. +- Removed `tempdir()` function and its equivalent on JS, use `std::env::temp_dir` instead of `temp_dir` from `tauri::path::PathResolver::temp_dir` and `path.tempDir` on JS. +- Modified `platform()` implementation to return `windows` instead of `win32` and `macos` instead of `darwin` to align with Rust's `std::env::consts::OS` diff --git a/.changes/persisted-scope-fix-oom.md b/.changes/persisted-scope-fix-oom.md deleted file mode 100644 index 6e6520af..00000000 --- a/.changes/persisted-scope-fix-oom.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -persisted-scope: patch ---- - -Recursively unescape saved patterns before allowing/forbidding them. This effectively prevents `.persisted-scope` files from blowing up, which caused Out-Of-Memory issues, while automatically fixing existing broken files seamlessly. diff --git a/.changes/pre.json b/.changes/pre.json new file mode 100644 index 00000000..a95db7bb --- /dev/null +++ b/.changes/pre.json @@ -0,0 +1,9 @@ +{ + "tag": "alpha", + "changes": [ + ".changes/notification-init-script.md", + ".changes/notification-sound.md", + ".changes/stronghold-constructor.md", + ".changes/v2-alpha.md" + ] +} diff --git a/.changes/stronghold-constructor.md b/.changes/stronghold-constructor.md new file mode 100644 index 00000000..99966095 --- /dev/null +++ b/.changes/stronghold-constructor.md @@ -0,0 +1,5 @@ +--- +"stronghold-js": minor +--- + +Added `Stronghold.load` and removed its constructor. diff --git a/.changes/v2-alpha.md b/.changes/v2-alpha.md new file mode 100644 index 00000000..4083686d --- /dev/null +++ b/.changes/v2-alpha.md @@ -0,0 +1,53 @@ +--- +"app": major +"app-js": major +"authenticator": major +"authenticator-js": major +"autostart": major +"autostart-js": major +"cli": major +"cli-js": major +"clipboard-manager": major +"clipboard-manager-js": major +"dialog": major +"dialog-js": major +"fs": major +"fs-js": major +"global-shortcut": major +"global-shortcut-js": major +"http": major +"http-js": major +"localhost": major +"log-plugin": major +"log-js": major +"notification": major +"notification-js": major +"os": major +"os-js": major +"persisted-scope": major +"positioner": major +"positioner-js": major +"process": major +"process-js": major +"shell": major +"shell-js": major +"single-instance": major +"sql": major +"sql-js": major +"store": major +"store-js": major +"stronghold": major +"stronghold-js": major +"updater": major +"updater-js": major +"upload": major +"upload-js": major +"websocket": major +"websocket-js": major +"window": major +"window-js": major +"window-state": major +"window-state-js": major +--- + +First v2 alpha release! diff --git a/.changes/window-state-decorated.md b/.changes/window-state-decorated.md new file mode 100644 index 00000000..191ec5c2 --- /dev/null +++ b/.changes/window-state-decorated.md @@ -0,0 +1,5 @@ +--- +"window-state": "patch" +--- + +Correctly set decoration state if no saved state xists diff --git a/.changes/window-state-promise.md b/.changes/window-state-promise.md new file mode 100644 index 00000000..f97c43df --- /dev/null +++ b/.changes/window-state-promise.md @@ -0,0 +1,5 @@ +--- +"window-state-js": "patch" +--- + +Correctly propagate the promise inside `saveWindowState`, `restoreState` and `restoreStateCurrent` so callers can choose to `await` them. diff --git a/.eslintignore b/.eslintignore index 1c120ff5..efef8f77 100644 --- a/.eslintignore +++ b/.eslintignore @@ -2,3 +2,4 @@ target node_modules dist dist-js +api-iife.js \ No newline at end of file diff --git a/.github/sync-to-mirrors.sh b/.github/sync-to-mirrors.sh index 52d4c27f..4baf55d2 100755 --- a/.github/sync-to-mirrors.sh +++ b/.github/sync-to-mirrors.sh @@ -1,4 +1,7 @@ #!/bin/bash +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT ## Environment used by this script: # diff --git a/.github/workflows/audit-javascript.yml b/.github/workflows/audit-javascript.yml index 19a7f4c8..618ebf59 100644 --- a/.github/workflows/audit-javascript.yml +++ b/.github/workflows/audit-javascript.yml @@ -1,3 +1,7 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + name: Audit JavaScript on: diff --git a/.github/workflows/audit-rust.yml b/.github/workflows/audit-rust.yml index 1ec0225e..c85d3712 100644 --- a/.github/workflows/audit-rust.yml +++ b/.github/workflows/audit-rust.yml @@ -1,3 +1,7 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + name: Audit Rust on: diff --git a/.github/workflows/check-generated-files.yml b/.github/workflows/check-generated-files.yml new file mode 100644 index 00000000..a5be08c0 --- /dev/null +++ b/.github/workflows/check-generated-files.yml @@ -0,0 +1,155 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + +name: check generated files + +on: + pull_request: + paths: + - ".github/workflows/check-generated-files.yml" + - "**/guest-js/**" + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + changes: + runs-on: ubuntu-latest + outputs: + packages: ${{ steps.filter.outputs.changes }} + steps: + - uses: actions/checkout@v3 + - uses: dorny/paths-filter@v2 + id: filter + with: + filters: | + app: + - .github/workflows/check-generated-files.yml + - plugins/app/guest-js/** + - plugins/app/src/api-iife.js + authenticator: + - .github/workflows/check-generated-files.yml + - plugins/authenticator/guest-js/** + - plugins/authenticator/src/api-iife.js + autostart: + - .github/workflows/check-generated-files.yml + - plugins/autostart/guest-js/** + - plugins/autostart/src/api-iife.js + cli: + - .github/workflows/check-generated-files.yml + - plugins/cli/guest-js/** + - plugins/cli/src/api-iife.js + clipboard-manager: + - .github/workflows/check-generated-files.yml + - plugins/clipboard-manager/guest-js/** + - plugins/clipboard-manager/src/api-iife.js + dialog: + - .github/workflows/check-generated-files.yml + - plugins/dialog/guest-js/** + - plugins/dialog/src/api-iife.js + fs: + - .github/workflows/check-generated-files.yml + - plugins/fs/guest-js/** + - plugins/fs/src/api-iife.js + global-shortcut: + - .github/workflows/check-generated-files.yml + - plugins/global-shortcut/guest-js/** + - plugins/global-shortcut/src/api-iife.js + http: + - .github/workflows/check-generated-files.yml + - plugins/http/guest-js/** + - plugins/http/src/api-iife.js + log: + - .github/workflows/check-generated-files.yml + - plugins/log/guest-js/** + - plugins/log/src/api-iife.js + notification: + - .github/workflows/check-generated-files.yml + - plugins/notification/guest-js/** + - plugins/notification/src/api-iife.js + os: + - .github/workflows/check-generated-files.yml + - plugins/os/guest-js/** + - plugins/os/src/api-iife.js + positioner: + - .github/workflows/check-generated-files.yml + - plugins/positioner/guest-js/** + - plugins/positioner/src/api-iife.js + process: + - .github/workflows/check-generated-files.yml + - plugins/process/guest-js/** + - plugins/process/src/api-iife.js + shell: + - .github/workflows/check-generated-files.yml + - plugins/shell/guest-js/** + - plugins/shell/src/api-iife.js + sql: + - .github/workflows/check-generated-files.yml + - plugins/sql/guest-js/** + - plugins/sql/src/api-iife.js + store: + - .github/workflows/check-generated-files.yml + - plugins/store/guest-js/** + - plugins/store/src/api-iife.js + stronghold: + - .github/workflows/check-generated-files.yml + - plugins/stronghold/guest-js/** + - plugins/stronghold/src/api-iife.js + updater: + - .github/workflows/check-generated-files.yml + - plugins/updater/guest-js/** + - plugins/updater/src/api-iife.js + upload: + - .github/workflows/check-generated-files.yml + - plugins/upload/guest-js/** + - plugins/upload/src/api-iife.js + websocket: + - .github/workflows/check-generated-files.yml + - plugins/websocket/guest-js/** + - plugins/websocket/src/api-iife.js + window: + - .github/workflows/check-generated-files.yml + - plugins/window/guest-js/** + - plugins/window/src/api-iife.js + window-state: + - .github/workflows/check-generated-files.yml + - plugins/window-state/guest-js/** + - plugins/window-state/src/api-iife.js + + test: + needs: changes + if: ${{ needs.changes.outputs.packages != '[]' && needs.changes.outputs.packages != '' }} + strategy: + fail-fast: false + matrix: + package: ${{ fromJSON(needs.changes.outputs.packages) }} + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + + - name: Cache pnpm modules + uses: actions/cache@v3 + with: + path: ~/.pnpm-store + key: ${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}- + - uses: actions/setup-node@v3 + with: + node-version: 18 + - uses: pnpm/action-setup@v2 + with: + version: 7.x.x + run_install: true + + - name: build api + working-directory: plugins/${{ matrix.package }} + run: pnpm install && pnpm build + + - name: check diff + run: | + ./.scripts/ci/has-diff.sh diff --git a/.github/workflows/check-license-header.yml b/.github/workflows/check-license-header.yml new file mode 100644 index 00000000..011a1780 --- /dev/null +++ b/.github/workflows/check-license-header.yml @@ -0,0 +1,28 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + +name: check license header + +on: + pull_request: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: dorny/paths-filter@v2 + id: filter + with: + list-files: shell + filters: | + added: + - added: '**' + - name: check header license on new files + if: ${{ steps.filter.outputs.added == 'true' }} + run: node .scripts/ci/check-license-header.js ${{ steps.filter.outputs.added_files }} diff --git a/.github/workflows/covector-status.yml b/.github/workflows/covector-status.yml index cb5a344a..562dd70a 100644 --- a/.github/workflows/covector-status.yml +++ b/.github/workflows/covector-status.yml @@ -1,3 +1,7 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + name: covector status on: [pull_request] @@ -10,7 +14,7 @@ jobs: with: fetch-depth: 0 # required for use of git history - name: covector status - uses: jbolda/covector/packages/action@covector-v0.8 + uses: jbolda/covector/packages/action@covector-v0 id: covector with: command: "status" diff --git a/.github/workflows/covector-version-or-publish-v2.yml b/.github/workflows/covector-version-or-publish-v2.yml new file mode 100644 index 00000000..6d1ce3a7 --- /dev/null +++ b/.github/workflows/covector-version-or-publish-v2.yml @@ -0,0 +1,68 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + +name: version or publish + +on: + push: + branches: + - v2 + +jobs: + version-or-publish: + runs-on: ubuntu-latest + timeout-minutes: 65 + outputs: + change: ${{ steps.covector.outputs.change }} + commandRan: ${{ steps.covector.outputs.commandRan }} + successfulPublish: ${{ steps.covector.outputs.successfulPublish }} + + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 # required for use of git history + + - uses: actions/setup-node@v3 + with: + node-version: "lts/*" + registry-url: "https://registry.npmjs.org" + + - uses: pnpm/action-setup@v2 + with: + version: 7.x.x + run_install: true + + - name: install webkit2gtk and libudev for [authenticator] + run: | + sudo apt-get update + sudo apt-get install -y libwebkit2gtk-4.0-dev libwebkit2gtk-4.1-dev libudev-dev + + - name: cargo login + run: cargo login ${{ secrets.ORG_CRATES_IO_TOKEN }} + + - name: git config + run: | + git config --global user.name "${{ github.event.pusher.name }}" + git config --global user.email "${{ github.event.pusher.email }}" + + - name: covector version or publish (publish when no change files present) + uses: jbolda/covector/packages/action@covector-v0 + id: covector + env: + NODE_AUTH_TOKEN: ${{ secrets.ORG_NPM_TOKEN }} + with: + token: ${{ secrets.GITHUB_TOKEN }} + command: "version-or-publish" + createRelease: true + + - name: Create Pull Request With Versions Bumped + id: cpr + uses: tauri-apps/create-pull-request@v3 + if: steps.covector.outputs.commandRan == 'version' + with: + title: "Publish New Versions (v2)" + commit-message: "publish new versions" + labels: "version updates" + branch: "release-v2" + body: ${{ steps.covector.outputs.change }} diff --git a/.github/workflows/covector-version-or-publish.yml b/.github/workflows/covector-version-or-publish.yml index b5c4ab7d..c5ef8161 100644 --- a/.github/workflows/covector-version-or-publish.yml +++ b/.github/workflows/covector-version-or-publish.yml @@ -1,3 +1,7 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + name: version or publish on: @@ -29,6 +33,11 @@ jobs: version: 7.x.x run_install: true + - name: install webkit2gtk and libudev for [authenticator] + run: | + sudo apt-get update + sudo apt-get install -y libwebkit2gtk-4.0-dev libwebkit2gtk-4.1-dev libudev-dev + - name: cargo login run: cargo login ${{ secrets.ORG_CRATES_IO_TOKEN }} @@ -38,7 +47,7 @@ jobs: git config --global user.email "${{ github.event.pusher.email }}" - name: covector version or publish (publish when no change files present) - uses: jbolda/covector/packages/action@covector-v0.8 + uses: jbolda/covector/packages/action@covector-v0 id: covector env: NODE_AUTH_TOKEN: ${{ secrets.ORG_NPM_TOKEN }} diff --git a/.github/workflows/lint-javascript.yml b/.github/workflows/lint-javascript.yml index c2c0a1d3..02b96541 100644 --- a/.github/workflows/lint-javascript.yml +++ b/.github/workflows/lint-javascript.yml @@ -1,3 +1,7 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + name: Lint JavaScript on: diff --git a/.github/workflows/lint-rust.yml b/.github/workflows/lint-rust.yml index f724e838..720fb77d 100644 --- a/.github/workflows/lint-rust.yml +++ b/.github/workflows/lint-rust.yml @@ -1,3 +1,7 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + name: Lint Rust on: @@ -8,6 +12,7 @@ on: paths: - ".github/workflows/lint-rust.yml" - "plugins/*/src/**" + - "!plugins/*/src/api-iife.js" - "**/Cargo.toml" pull_request: branches: @@ -16,6 +21,7 @@ on: paths: - ".github/workflows/lint-rust.yml" - "plugins/*/src/**" + - "!plugins/*/src/api-iife.js" - "**/Cargo.toml" concurrency: @@ -23,10 +29,108 @@ concurrency: cancel-in-progress: true jobs: + changes: + runs-on: ubuntu-latest + permissions: + pull-requests: read + outputs: + packages: ${{ steps.filter.outputs.changes }} + steps: + - uses: actions/checkout@v3 + - uses: dorny/paths-filter@v2 + id: filter + with: + filters: | + tauri-plugin-app: + - .github/workflows/lint-rust.yml + - plugins/app/** + tauri-plugin-authenticator: + - .github/workflows/lint-rust.yml + - plugins/authenticator/** + tauri-plugin-autostart: + - .github/workflows/lint-rust.yml + - plugins/autostart/** + tauri-plugin-cli: + - .github/workflows/lint-rust.yml + - plugins/cli/** + tauri-plugin-clipboard-manager: + - .github/workflows/lint-rust.yml + - plugins/clipboard-manager/** + tauri-plugin-dialog: + - .github/workflows/lint-rust.yml + - plugins/dialog/** + - plugins/fs/** + tauri-plugin-fs: + - .github/workflows/lint-rust.yml + - plugins/fs/** + tauri-plugin-global-shortcut: + - .github/workflows/lint-rust.yml + - plugins/global-shortcut/** + tauri-plugin-http: + - .github/workflows/lint-rust.yml + - plugins/http/** + - plugins/fs/** + tauri-plugin-localhost: + - .github/workflows/lint-rust.yml + - plugins/localhost/** + tauri-plugin-log: + - .github/workflows/lint-rust.yml + - plugins/log/** + tauri-plugin-notification: + - .github/workflows/lint-rust.yml + - plugins/notification/** + tauri-plugin-os: + - .github/workflows/lint-rust.yml + - plugins/os/** + tauri-plugin-persisted-scope: + - .github/workflows/lint-rust.yml + - plugins/persisted-scope/** + - plugins/fs/** + tauri-plugin-positioner: + - .github/workflows/lint-rust.yml + - plugins/positioner/** + tauri-plugin-process: + - .github/workflows/lint-rust.yml + - plugins/process/** + tauri-plugin-shell: + - .github/workflows/lint-rust.yml + - plugins/shell/** + tauri-plugin-single-instance: + - .github/workflows/lint-rust.yml + - plugins/single-instance/** + tauri-plugin-sql: + - .github/workflows/lint-rust.yml + - plugins/sql/** + tauri-plugin-store: + - .github/workflows/lint-rust.yml + - plugins/store/** + tauri-plugin-stronghold: + - .github/workflows/lint-rust.yml + - plugins/stronghold/** + tauri-plugin-updater: + - .github/workflows/lint-rust.yml + - plugins/updater/** + tauri-plugin-upload: + - .github/workflows/lint-rust.yml + - plugins/upload/** + tauri-plugin-websocket: + - .github/workflows/lint-rust.yml + - plugins/websocket/** + tauri-plugin-window: + - .github/workflows/lint-rust.yml + - plugins/window/** + tauri-plugin-window-state: + - .github/workflows/lint-rust.yml + - plugins/window-state/** + clippy: + needs: changes + if: ${{ needs.changes.outputs.packages != '[]' && needs.changes.outputs.packages != '' }} runs-on: ubuntu-latest strategy: fail-fast: false + matrix: + package: ${{ fromJSON(needs.changes.outputs.packages) }} steps: - uses: actions/checkout@v3 @@ -43,17 +147,25 @@ jobs: - uses: Swatinem/rust-cache@v2 - - name: clippy - run: cargo clippy --workspace --exclude 'tauri-plugin-sql' --all-targets --all-features -- -D warnings + - name: create dummy dist + working-directory: examples/api + run: mkdir dist + + - name: clippy ${{ matrix.package }} + if: matrix.package != 'tauri-plugin-sql' + run: cargo clippy --package ${{ matrix.package }} --all-targets -- -D warnings - - name: clippy sql:sqlite - run: cargo clippy --package 'tauri-plugin-sql' --all-targets --features sqlite -- -D warnings + - name: clippy ${{ matrix.package }} --all-features + if: ${{ !contains(fromJSON('["tauri-plugin-http", "tauri-plugin-upload", "tauri-plugin-updater", "tauri-plugin-websocket", "tauri-plugin-sql"]'), matrix.package) }} + run: cargo clippy --package ${{ matrix.package }} --all-targets --all-features -- -D warnings - - name: clippy sql:mysql - run: cargo clippy --package 'tauri-plugin-sql' --all-targets --features mysql -- -D warnings + - name: clippy ${{ matrix.package }} mysql + if: matrix.package == 'tauri-plugin-sql' + run: cargo clippy --package ${{ matrix.package }} --all-targets --no-default-features --features mysql -- -D warnings - - name: clippy sql:postgres - run: cargo clippy --package 'tauri-plugin-sql' --all-targets --features postgres -- -D warnings + - name: clippy ${{ matrix.package }} postgres + if: matrix.package == 'tauri-plugin-sql' + run: cargo clippy --package ${{ matrix.package }} --all-targets --no-default-features --features postgres -- -D warnings fmt: runs-on: ubuntu-latest diff --git a/.github/workflows/msrv-check.yml b/.github/workflows/msrv-check.yml deleted file mode 100644 index 807bbcad..00000000 --- a/.github/workflows/msrv-check.yml +++ /dev/null @@ -1,55 +0,0 @@ -name: Check MSRV - -on: - push: - branches: - - v1 - - v2 - paths: - - ".github/workflows/msrv-check.yml" - - "plugins/*/src/**" - - "**/Cargo.toml" - - "**/Cargo.lock" - pull_request: - branches: - - v1 - - v2 - paths: - - ".github/workflows/msrv-check.yml" - - "plugins/*/src/**" - - "**/Cargo.toml" - - "**/Cargo.lock" - -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true - -jobs: - msrv: - runs-on: ubuntu-latest - strategy: - fail-fast: false - - steps: - - uses: actions/checkout@v3 - - - name: install webkit2gtk and libudev for [authenticator] - run: | - sudo apt-get update - sudo apt-get install -y libwebkit2gtk-4.0-dev libwebkit2gtk-4.1-dev libudev-dev - - - uses: dtolnay/rust-toolchain@1.64.0 - - - uses: Swatinem/rust-cache@v2 - - - name: build - run: cargo build --workspace --exclude 'tauri-plugin-sql' --all-targets --all-features - - - name: build sql:sqlite - run: cargo build --package 'tauri-plugin-sql' --all-targets --features sqlite - - - name: build sql:mysql - run: cargo build --package 'tauri-plugin-sql' --all-targets --features mysql - - - name: build sql:postgres - run: cargo build --package 'tauri-plugin-sql' --all-targets --features postgres diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index 82da46fc..b34ccc7c 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -1,3 +1,7 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + name: Sync on: diff --git a/.github/workflows/test-rust.yml b/.github/workflows/test-rust.yml new file mode 100644 index 00000000..cf0de8e1 --- /dev/null +++ b/.github/workflows/test-rust.yml @@ -0,0 +1,226 @@ +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT + +name: Test Rust + +on: + push: + branches: + - v1 + - v2 + paths: + - ".github/workflows/test-rust.yml" + - "plugins/*/src/**" + - "!plugins/*/src/api-iife.js" + - "**/Cargo.toml" + - "**/Cargo.lock" + pull_request: + branches: + - v1 + - v2 + paths: + - ".github/workflows/test-rust.yml" + - "plugins/*/src/**" + - "!plugins/*/src/api-iife.js" + - "**/Cargo.toml" + - "**/Cargo.lock" + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + changes: + runs-on: ubuntu-latest + permissions: + pull-requests: read + outputs: + packages: ${{ steps.filter.outputs.changes }} + steps: + - uses: actions/checkout@v3 + - uses: dorny/paths-filter@v2 + id: filter + with: + filters: | + tauri-plugin-app: + - .github/workflows/test-rust.yml + - plugins/app/** + tauri-plugin-authenticator: + - .github/workflows/test-rust.yml + - plugins/authenticator/** + tauri-plugin-autostart: + - .github/workflows/test-rust.yml + - plugins/autostart/** + tauri-plugin-cli: + - .github/workflows/test-rust.yml + - plugins/cli/** + tauri-plugin-clipboard-manager: + - .github/workflows/test-rust.yml + - plugins/clipboard-manager/** + tauri-plugin-dialog: + - .github/workflows/test-rust.yml + - plugins/dialog/** + - plugins/fs/** + tauri-plugin-fs: + - .github/workflows/test-rust.yml + - plugins/fs/** + tauri-plugin-global-shortcut: + - .github/workflows/test-rust.yml + - plugins/global-shortcut/** + tauri-plugin-http: + - .github/workflows/test-rust.yml + - plugins/http/** + - plugins/fs/** + tauri-plugin-localhost: + - .github/workflows/test-rust.yml + - plugins/localhost/** + tauri-plugin-log: + - .github/workflows/test-rust.yml + - plugins/log/** + tauri-plugin-notification: + - .github/workflows/test-rust.yml + - plugins/notification/** + tauri-plugin-os: + - .github/workflows/test-rust.yml + - plugins/os/** + tauri-plugin-persisted-scope: + - .github/workflows/test-rust.yml + - plugins/persisted-scope/** + - plugins/fs/** + tauri-plugin-positioner: + - .github/workflows/test-rust.yml + - plugins/positioner/** + tauri-plugin-process: + - .github/workflows/test-rust.yml + - plugins/process/** + tauri-plugin-shell: + - .github/workflows/test-rust.yml + - plugins/shell/** + tauri-plugin-single-instance: + - .github/workflows/test-rust.yml + - plugins/single-instance/** + tauri-plugin-sql: + - .github/workflows/test-rust.yml + - plugins/sql/** + tauri-plugin-store: + - .github/workflows/test-rust.yml + - plugins/store/** + tauri-plugin-stronghold: + - .github/workflows/test-rust.yml + - plugins/stronghold/** + tauri-plugin-updater: + - .github/workflows/test-rust.yml + - plugins/updater/** + tauri-plugin-upload: + - .github/workflows/test-rust.yml + - plugins/upload/** + tauri-plugin-websocket: + - .github/workflows/test-rust.yml + - plugins/websocket/** + tauri-plugin-window: + - .github/workflows/test-rust.yml + - plugins/window/** + tauri-plugin-window-state: + - .github/workflows/test-rust.yml + - plugins/window-state/** + + test: + needs: changes + if: ${{ needs.changes.outputs.packages != '[]' && needs.changes.outputs.packages != '' }} + strategy: + fail-fast: false + matrix: + package: ${{ fromJSON(needs.changes.outputs.packages) }} + platform: + - { + target: x86_64-pc-windows-msvc, + os: windows-latest, + cross: false, + command: "test", + } + - { + target: x86_64-unknown-linux-gnu, + os: ubuntu-latest, + cross: false, + command: "test", + } + - { + target: x86_64-apple-darwin, + os: macos-latest, + cross: false, + command: "test", + } + - { + target: aarch64-apple-ios, + os: macos-latest, + cross: false, + command: "build", + } + - { + target: aarch64-linux-android, + os: ubuntu-latest, + cross: true, + command: "build", + } + + runs-on: ${{ matrix.platform.os }} + + steps: + - uses: actions/checkout@v3 + + - name: install webkit2gtk and libudev for [authenticator] + if: contains(matrix.platform.target, 'unknown-linux') + run: | + sudo apt-get update + sudo apt-get install -y libwebkit2gtk-4.0-dev libwebkit2gtk-4.1-dev libudev-dev + + - name: install openssl + if: ${{ matrix.platform.os == 'windows-latest' && matrix.package == 'tauri-plugin-authenticator' }} + run: | + echo "VCPKG_ROOT=$env:VCPKG_INSTALLATION_ROOT" | Out-File -FilePath $env:GITHUB_ENV -Append + vcpkg install openssl:x64-windows-static-md + + - uses: dtolnay/rust-toolchain@1.65.0 + with: + targets: ${{ matrix.platform.target }} + + - uses: Swatinem/rust-cache@v2 + with: + key: ${{ matrix.package }} + + - name: create dummy dist + working-directory: examples/api + run: mkdir dist + + - name: test ${{ matrix.package }} + if: matrix.package != 'tauri-plugin-sql' + uses: actions-rs/cargo@v1 + with: + use-cross: ${{ matrix.platform.cross }} + command: ${{ matrix.platform.command }} + args: --package ${{ matrix.package }} --target ${{ matrix.platform.target }} --all-targets + + - name: test ${{ matrix.package }} --all-features + if: ${{ !contains(fromJSON('["tauri-plugin-http", "tauri-plugin-upload", "tauri-plugin-updater", "tauri-plugin-websocket", "tauri-plugin-sql"]'), matrix.package) }} + uses: actions-rs/cargo@v1 + with: + use-cross: ${{ matrix.platform.cross }} + command: ${{ matrix.platform.command }} + args: --package ${{ matrix.package }} --target ${{ matrix.platform.target }} --all-targets --all-features + + - name: test ${{ matrix.package }} mysql + if: matrix.package == 'tauri-plugin-sql' + uses: actions-rs/cargo@v1 + with: + use-cross: ${{ matrix.platform.cross }} + command: ${{ matrix.platform.command }} + args: --package ${{ matrix.package }} --target ${{ matrix.platform.target }} --all-targets --features mysql + + - name: test ${{ matrix.package }} postgres + if: matrix.package == 'tauri-plugin-sql' + uses: actions-rs/cargo@v1 + with: + use-cross: ${{ matrix.platform.cross }} + command: ${{ matrix.platform.command }} + args: --package ${{ matrix.package }} --target ${{ matrix.platform.target }} --all-targets --features postgres diff --git a/.npmrc b/.npmrc new file mode 100644 index 00000000..f87a0443 --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +auto-install-peers=true \ No newline at end of file diff --git a/.prettierignore b/.prettierignore index 13134b1f..af351877 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,5 +1,8 @@ target node_modules dist +dist-js pnpm-lock.yaml -Cargo.lock \ No newline at end of file +Cargo.lock +.build +api-iife.js \ No newline at end of file diff --git a/.scripts/ci/check-license-header.js b/.scripts/ci/check-license-header.js new file mode 100644 index 00000000..d8a64650 --- /dev/null +++ b/.scripts/ci/check-license-header.js @@ -0,0 +1,121 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +import fs from "fs"; +import path from "path"; +import readline from "readline"; + +const header = `Copyright 2019-2023 Tauri Programme within The Commons Conservancy +SPDX-License-Identifier: Apache-2.0 +SPDX-License-Identifier: MIT`; +const ignoredLicense = "// Copyright 2021 Jonas Kruckenberg"; + +const extensions = [".rs", ".js", ".ts", ".yml", ".swift", ".kt"]; +const ignore = [ + "target", + "templates", + "node_modules", + "gen", + "dist", + "dist-js", + ".svelte-kit", + "api-iife.js", +]; + +async function checkFile(file) { + if ( + extensions.some((e) => file.endsWith(e)) && + !ignore.some((i) => file.endsWith(i)) + ) { + const fileStream = fs.createReadStream(file); + const rl = readline.createInterface({ + input: fileStream, + crlfDelay: Infinity, + }); + + let contents = ``; + let i = 0; + for await (let line of rl) { + // ignore empty lines, allow shebang, swift-tools-version and bundler license + if ( + line.length === 0 || + line.startsWith("#!") || + line.startsWith("// swift-tools-version:") || + line === ignoredLicense + ) { + continue; + } + + // strip comment marker + if (line.startsWith("// ")) { + line = line.substring(3); + } else if (line.startsWith("# ")) { + line = line.substring(2); + } + + contents += line; + if (++i === 3) { + break; + } + contents += "\n"; + } + if (contents !== header) { + return true; + } + } + return false; +} + +async function check(src) { + const missingHeader = []; + + for (const entry of fs.readdirSync(src, { withFileTypes: true })) { + const p = path.join(src, entry.name); + + if (entry.isSymbolicLink() || ignore.includes(entry.name)) { + continue; + } + + if (entry.isDirectory()) { + const missing = await check(p); + missingHeader.push(...missing); + } else { + const isMissing = await checkFile(p); + if (isMissing) { + missingHeader.push(p); + } + } + } + + return missingHeader; +} + +const [_bin, _script, ...files] = process.argv; + +if (files.length > 0) { + async function run() { + const missing = []; + for (const f of files) { + const isMissing = await checkFile(f); + if (isMissing) { + missing.push(f); + } + } + if (missing.length > 0) { + console.log(missing.join("\n")); + process.exit(1); + } + } + + run(); +} else { + check(path.resolve(new URL(import.meta.url).pathname, "../../..")).then( + (missing) => { + if (missing.length > 0) { + console.log(missing.join("\n")); + process.exit(1); + } + } + ); +} diff --git a/.scripts/ci/has-diff.sh b/.scripts/ci/has-diff.sh new file mode 100755 index 00000000..dd40c06f --- /dev/null +++ b/.scripts/ci/has-diff.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +if git diff --quiet --ignore-submodules HEAD +then + echo "working directory is clean" +else + echo "found diff" + exit 1 +fi diff --git a/.scripts/covector/package-latest-version.js b/.scripts/covector/package-latest-version.cjs similarity index 82% rename from .scripts/covector/package-latest-version.js rename to .scripts/covector/package-latest-version.cjs index 9ff107c3..68203a1f 100644 --- a/.scripts/covector/package-latest-version.js +++ b/.scripts/covector/package-latest-version.cjs @@ -44,10 +44,14 @@ https.get(url, options, (response) => { response.on("end", function () { const data = JSON.parse(chunks.join("")); if (kind === "cargo") { - const versions = data.versions.filter((v) => v.num.startsWith(target)); - console.log(versions.length ? versions[0].num : "0.0.0"); + if (data.versions) { + const versions = data.versions.filter((v) => v.num.startsWith(target)); + console.log(versions.length ? versions[0].num : "0.0.0"); + } else { + console.log("0.0.0"); + } } else if (kind === "npm") { - const versions = Object.keys(data.versions).filter((v) => + const versions = Object.keys(data.versions || {}).filter((v) => v.startsWith(target) ); console.log(versions[versions.length - 1] || "0.0.0"); diff --git a/Cargo.lock b/Cargo.lock index 2814dfd6..ac3e1bd6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -17,6 +17,16 @@ dependencies = [ "generic-array", ] +[[package]] +name = "aead" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d122413f284cf2d62fb1b7db97e02edb8cda96d769b16e443a4f6195e35662b0" +dependencies = [ + "crypto-common", + "generic-array", +] + [[package]] name = "aes" version = "0.7.5" @@ -24,22 +34,47 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" dependencies = [ "cfg-if", - "cipher", + "cipher 0.3.0", "cpufeatures", "opaque-debug", ] +[[package]] +name = "aes" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "433cfd6710c9986c576a25ca913c39d66a6474107b406f34f91d4a8923395241" +dependencies = [ + "cfg-if", + "cipher 0.4.4", + "cpufeatures", +] + [[package]] name = "aes-gcm" version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df5f85a83a7d8b0442b6aa7b504b8212c1733da07b98aae43d4bc21b2cb3cdf6" dependencies = [ - "aead", - "aes", - "cipher", - "ctr", - "ghash", + "aead 0.4.3", + "aes 0.7.5", + "cipher 0.3.0", + "ctr 0.8.0", + "ghash 0.4.4", + "subtle", +] + +[[package]] +name = "aes-gcm" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "82e1366e0c69c9f927b1fa5ce2c7bf9eafc8f9268c0b9800729e8b267612447c" +dependencies = [ + "aead 0.5.2", + "aes 0.8.2", + "cipher 0.4.4", + "ctr 0.9.2", + "ghash 0.5.0", "subtle", ] @@ -169,6 +204,47 @@ version = "1.0.70" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7de8ce5e0f9f8d88245311066a578d72b7af3e7088f32783804676302df237e4" +[[package]] +name = "api" +version = "2.0.0-alpha.1" +dependencies = [ + "log", + "serde", + "serde_json", + "tauri", + "tauri-build", + "tauri-plugin-app", + "tauri-plugin-barcode-scanner", + "tauri-plugin-cli", + "tauri-plugin-clipboard-manager", + "tauri-plugin-dialog", + "tauri-plugin-fs", + "tauri-plugin-global-shortcut", + "tauri-plugin-http", + "tauri-plugin-log", + "tauri-plugin-notification", + "tauri-plugin-os", + "tauri-plugin-process", + "tauri-plugin-shell", + "tauri-plugin-updater", + "tauri-plugin-window", + "tiny_http 0.11.0", + "window-shadows", +] + +[[package]] +name = "app-updater" +version = "0.1.0" +dependencies = [ + "serde", + "serde_json", + "tauri", + "tauri-build", + "tauri-plugin-updater", + "time 0.3.20", + "tiny_http 0.11.0", +] + [[package]] name = "arboard" version = "3.2.0" @@ -207,6 +283,16 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d92bec98840b8f03a5ff5413de5293bfcd8bf96467cf5452609f939ec6f5de16" +[[package]] +name = "assert-json-diff" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47e4f2b81832e72834d7518d8487a0396a28cc408186a2e8854c0f98011faf12" +dependencies = [ + "serde", + "serde_json", +] + [[package]] name = "async-broadcast" version = "0.5.1" @@ -294,6 +380,28 @@ dependencies = [ "syn 2.0.13", ] +[[package]] +name = "async-stream" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd56dd203fef61ac097dd65721a419ddccb106b2d2b70ba60a6b529f03961a51" +dependencies = [ + "async-stream-impl", + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "async-stream-impl" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.13", +] + [[package]] name = "async-task" version = "4.4.0" @@ -604,12 +712,12 @@ dependencies = [ [[package]] name = "cargo_toml" -version = "0.14.1" +version = "0.15.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bfbc36312494041e2cdd5f06697b7e89d4b76f42773a0b5556ac290ff22acc2" +checksum = "7f83bc2e401ed041b7057345ebc488c005efa0341d5541ce7004d30458d0090b" dependencies = [ "serde", - "toml 0.5.11", + "toml 0.7.3", ] [[package]] @@ -657,7 +765,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5c80e5460aa66fe3b91d40bcbdab953a597b60053e34d684ac6903f863b680a6" dependencies = [ "cfg-if", - "cipher", + "cipher 0.3.0", "cpufeatures", "zeroize", ] @@ -668,9 +776,9 @@ version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a18446b09be63d457bbec447509e85f662f32952b035ce892290396bc0b0cff5" dependencies = [ - "aead", + "aead 0.4.3", "chacha20", - "cipher", + "cipher 0.3.0", "poly1305", "zeroize", ] @@ -685,6 +793,7 @@ dependencies = [ "js-sys", "num-integer", "num-traits", + "serde", "time 0.1.45", "wasm-bindgen", "winapi", @@ -705,6 +814,16 @@ dependencies = [ "generic-array", ] +[[package]] +name = "cipher" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "773f3b9af64447d2ce9850330c473515014aa235e6a783b02db81ff39e4a3dad" +dependencies = [ + "crypto-common", + "inout", +] + [[package]] name = "clap" version = "4.2.2" @@ -808,6 +927,17 @@ dependencies = [ "winapi", ] +[[package]] +name = "colored" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3616f750b84d8f0de8a58bda93e08e2a81ad3f523089b05f1dffecab48c6cbd" +dependencies = [ + "atty", + "lazy_static", + "winapi", +] + [[package]] name = "combine" version = "4.6.6" @@ -927,9 +1057,9 @@ dependencies = [ [[package]] name = "crossbeam-channel" -version = "0.5.7" +version = "0.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf2b3e8478797446514c91ef04bafcb59faba183e621ad488df88983cc14128c" +checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" dependencies = [ "cfg-if", "crossbeam-utils", @@ -971,6 +1101,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" dependencies = [ "generic-array", + "rand_core 0.6.4", "typenum", ] @@ -1017,7 +1148,16 @@ version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" dependencies = [ - "cipher", + "cipher 0.3.0", +] + +[[package]] +name = "ctr" +version = "0.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" +dependencies = [ + "cipher 0.4.4", ] [[package]] @@ -1079,9 +1219,9 @@ dependencies = [ [[package]] name = "darling" -version = "0.13.4" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" +checksum = "7b750cb3417fd1b327431a470f388520309479ab0bf5e323505daf0290cd3850" dependencies = [ "darling_core", "darling_macro", @@ -1089,9 +1229,9 @@ dependencies = [ [[package]] name = "darling_core" -version = "0.13.4" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" +checksum = "109c1ca6e6b7f82cc233a97004ea8ed7ca123a9af07a8230878fcfda9b158bf0" dependencies = [ "fnv", "ident_case", @@ -1103,15 +1243,21 @@ dependencies = [ [[package]] name = "darling_macro" -version = "0.13.4" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" +checksum = "a4aab4dbc9f7611d8b55048a3a16d2d010c2c8334e46304b40ac1cc14bf3b48e" dependencies = [ "darling_core", "quote", "syn 1.0.109", ] +[[package]] +name = "data-encoding" +version = "2.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23d8666cb01533c39dde32bcbab8e227b4ed6679b2c925eba05feabea39508fb" + [[package]] name = "der" version = "0.5.1" @@ -1288,9 +1434,9 @@ dependencies = [ [[package]] name = "enumflags2" -version = "0.7.6" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0044ebdf7fbb2a772e0c0233a9d3173c5cd8af8ae7078d4c5188af44ffffaa4b" +checksum = "c041f5090df68b32bcd905365fd51769c8b9d553fe87fde0b683534f10c01bd2" dependencies = [ "enumflags2_derive", "serde", @@ -1298,9 +1444,9 @@ dependencies = [ [[package]] name = "enumflags2_derive" -version = "0.7.6" +version = "0.7.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d2c772ccdbdfd1967b4f5d79d17c98ebf92009fdcc838db7aa434462f600c26" +checksum = "5e9a1f9f7d83e59740248a6e14ecf93929ade55027844dfcea78beafccc15745" dependencies = [ "proc-macro2", "quote", @@ -1369,7 +1515,7 @@ version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d9f0c14694cbd524c8720dd69b0e3179344f04ebb5f90f2e4a440c6ea3b2f1ee" dependencies = [ - "colored", + "colored 1.9.3", "log", ] @@ -1709,6 +1855,16 @@ dependencies = [ "winapi", ] +[[package]] +name = "gethostname" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0176e0459c2e4a1fe232f984bca6890e681076abb9934f6cea7c326f3fc47818" +dependencies = [ + "libc", + "windows-targets 0.48.0", +] + [[package]] name = "getrandom" version = "0.1.16" @@ -1740,7 +1896,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1583cc1656d7839fd3732b80cf4f38850336cdb9b8ded1cd399ca62958de3c99" dependencies = [ "opaque-debug", - "polyval", + "polyval 0.5.3", +] + +[[package]] +name = "ghash" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d930750de5717d2dd0b8c0d42c076c0e884c81a73e6cab859bbd2339c71e3e40" +dependencies = [ + "opaque-debug", + "polyval 0.6.0", ] [[package]] @@ -1831,9 +1997,9 @@ checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" [[package]] name = "global-hotkey" -version = "0.2.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92007db5c632751655a4c0ef122832fd283e6651621d34613b17fd1edfbfd2ed" +checksum = "273daa5db9a79be95b2b04c9955651c301a08b5dc1d7656e692e3801634aa873" dependencies = [ "crossbeam-channel", "keyboard-types", @@ -1924,9 +2090,9 @@ dependencies = [ [[package]] name = "h2" -version = "0.3.16" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5be7b54589b581f624f566bf5d8eb2bab1db736c51528720b6bd36b96b55924d" +checksum = "d357c7ae988e7d2182f7d7871d0b963962420b0678b0997ce7de72001aeab782" dependencies = [ "bytes 1.4.0", "fnv", @@ -2103,6 +2269,19 @@ dependencies = [ "want", ] +[[package]] +name = "hyper-rustls" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0646026eb1b3eea4cd9ba47912ea5ce9cc07713d105b1a14698f4e6433d348b7" +dependencies = [ + "http", + "hyper", + "rustls 0.21.1", + "tokio", + "tokio-rustls 0.24.0", +] + [[package]] name = "hyper-tls" version = "0.5.0" @@ -2140,6 +2319,16 @@ dependencies = [ "cxx-build", ] +[[package]] +name = "ico" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "031530fe562d8c8d71c0635013d6d155bbfe8ba0aa4b4d2d24ce8af6b71047bd" +dependencies = [ + "byteorder", + "png", +] + [[package]] name = "ico" version = "0.3.0" @@ -2206,6 +2395,16 @@ checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" dependencies = [ "autocfg", "hashbrown", + "serde", +] + +[[package]] +name = "infer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f178e61cdbfe084aa75a2f4f7a25a5bb09701a47ae1753608f194b15783c937a" +dependencies = [ + "cfb", ] [[package]] @@ -2237,6 +2436,15 @@ dependencies = [ "libc", ] +[[package]] +name = "inout" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0c10553d664a4d0bcff9f4215d0aac67a639cc68ef660840afe309b807bc9f5" +dependencies = [ + "generic-array", +] + [[package]] name = "instant" version = "0.1.12" @@ -2263,9 +2471,9 @@ version = "0.15.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4e04d492224bff6e97142f033d0a4383bcbc05918be1ff7b3abd2c1cc85205a2" dependencies = [ - "aead", - "aes", - "aes-gcm", + "aead 0.4.3", + "aes 0.7.5", + "aes-gcm 0.9.4", "autocfg", "blake2", "chacha20poly1305", @@ -2285,9 +2493,9 @@ dependencies = [ [[package]] name = "iota-crypto" -version = "0.17.1" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92cdfcd73d2b8a67b913789ecd7fc06c68254f68cd2b24cc3f0419c7f8fe6bbe" +checksum = "0180a2a7939b4b0ae68e651bbec130b27fd5882ef552df5bb55e0320e78bacbc" dependencies = [ "autocfg", ] @@ -2437,9 +2645,9 @@ dependencies = [ [[package]] name = "json-patch" -version = "0.3.0" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e712e62827c382a77b87f590532febb1f8b2fdbc3eefa1ee37fe7281687075ef" +checksum = "1f54898088ccb91df1b492cc80029a6fdf1c48ca0db7c6822a8babad69c94658" dependencies = [ "serde", "serde_json", @@ -2752,12 +2960,28 @@ version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" +[[package]] +name = "mime_guess" +version = "2.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4192263c238a5f0d0c6bfd21f336a313a4ce1c450542449ca191bb657b4642ef" +dependencies = [ + "mime", + "unicase", +] + [[package]] name = "minimal-lexical" version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" +[[package]] +name = "minisign-verify" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "933dca44d65cdd53b355d0b73d380a2ff5da71f87f036053188bf1eab6a19881" + [[package]] name = "miniz_oxide" version = "0.6.2" @@ -2779,6 +3003,24 @@ dependencies = [ "windows-sys 0.45.0", ] +[[package]] +name = "mockito" +version = "0.31.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "80f9fece9bd97ab74339fe19f4bcaf52b76dcc18e5364c7977c1838f76b38de9" +dependencies = [ + "assert-json-diff", + "colored 2.0.0", + "httparse", + "lazy_static", + "log", + "rand 0.8.5", + "regex", + "serde_json", + "serde_urlencoded", + "similar", +] + [[package]] name = "native-tls" version = "0.2.11" @@ -2875,9 +3117,9 @@ dependencies = [ [[package]] name = "notify" -version = "5.1.0" +version = "5.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58ea850aa68a06e48fdb069c0ec44d0d64c8dbffa49bf3b6f7f0a901fdea1ba9" +checksum = "729f63e1ca555a43fe3efa4f3efdf4801c479da85b432242a7b726f353c88486" dependencies = [ "bitflags 1.3.2", "crossbeam-channel", @@ -2889,7 +3131,7 @@ dependencies = [ "mio", "serde", "walkdir", - "windows-sys 0.42.0", + "windows-sys 0.45.0", ] [[package]] @@ -3129,6 +3371,15 @@ version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" +[[package]] +name = "openssl-src" +version = "111.25.3+1.1.1t" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "924757a6a226bf60da5f7dd0311a34d2b52283dd82ddeb103208ddc66362f80c" +dependencies = [ + "cc", +] + [[package]] name = "openssl-sys" version = "0.9.84" @@ -3137,6 +3388,7 @@ checksum = "3a20eace9dc2d82904039cb76dcf50fb1a0bba071cfd1629720b5d6f1ddba0fa" dependencies = [ "cc", "libc", + "openssl-src", "pkg-config", "vcpkg", ] @@ -3151,6 +3403,17 @@ dependencies = [ "pin-project-lite", ] +[[package]] +name = "os_info" +version = "3.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "006e42d5b888366f1880eda20371fedde764ed2213dc8496f49622fa0c99cd5e" +dependencies = [ + "log", + "serde", + "winapi", +] + [[package]] name = "os_pipe" version = "1.1.3" @@ -3491,7 +3754,7 @@ checksum = "048aeb476be11a4b6ca432ca569e375810de9294ae78f4774e78ea98a9246ede" dependencies = [ "cpufeatures", "opaque-debug", - "universal-hash", + "universal-hash 0.4.1", ] [[package]] @@ -3503,7 +3766,19 @@ dependencies = [ "cfg-if", "cpufeatures", "opaque-debug", - "universal-hash", + "universal-hash 0.4.1", +] + +[[package]] +name = "polyval" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ef234e08c11dfcb2e56f79fd70f6f2eb7f025c0ce2333e82f4f0518ecad30c6" +dependencies = [ + "cfg-if", + "cpufeatures", + "opaque-debug", + "universal-hash 0.5.0", ] [[package]] @@ -3755,9 +4030,9 @@ checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] name = "reqwest" -version = "0.11.16" +version = "0.11.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27b71749df584b7f4cac2c426c127a7c785a5106cc98f7a8feb044115f0fa254" +checksum = "cde824a14b7c14f85caff81225f411faacc04a2013f41670f41443742b1c1c55" dependencies = [ "base64 0.21.0", "bytes 1.4.0", @@ -3768,20 +4043,25 @@ dependencies = [ "http", "http-body", "hyper", + "hyper-rustls", "hyper-tls", "ipnet", "js-sys", "log", "mime", + "mime_guess", "native-tls", "once_cell", "percent-encoding", "pin-project-lite", + "rustls 0.21.1", + "rustls-pemfile", "serde", "serde_json", "serde_urlencoded", "tokio", "tokio-native-tls", + "tokio-rustls 0.24.0", "tokio-util", "tower-service", "url", @@ -3789,6 +4069,7 @@ dependencies = [ "wasm-bindgen-futures", "wasm-streams", "web-sys", + "webpki-roots 0.22.6", "winreg", ] @@ -3905,6 +4186,18 @@ dependencies = [ "webpki", ] +[[package]] +name = "rustls" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c911ba11bc8433e811ce56fde130ccf32f5127cab0e0194e9c68c5a5b671791e" +dependencies = [ + "log", + "ring", + "rustls-webpki", + "sct", +] + [[package]] name = "rustls-pemfile" version = "1.0.2" @@ -3914,6 +4207,16 @@ dependencies = [ "base64 0.21.0", ] +[[package]] +name = "rustls-webpki" +version = "0.100.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6207cd5ed3d8dca7816f8f3725513a34609c0c765bf652b8c3cb4cfd87db46b" +dependencies = [ + "ring", + "untrusted", +] + [[package]] name = "rustversion" version = "1.0.12" @@ -4107,19 +4410,25 @@ dependencies = [ [[package]] name = "serde_with" -version = "1.14.0" +version = "2.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" +checksum = "331bb8c3bf9b92457ab7abecf07078c13f7d270ba490103e84e8b014490cd0b0" dependencies = [ + "base64 0.13.1", + "chrono", + "hex", + "indexmap", "serde", + "serde_json", "serde_with_macros", + "time 0.3.20", ] [[package]] name = "serde_with_macros" -version = "1.5.2" +version = "2.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" +checksum = "859011bddcc11f289f07f467cc1fe01c7a941daa4d8f6c40d4d1c92eb6d9319c" dependencies = [ "darling", "proc-macro2", @@ -4213,6 +4522,12 @@ dependencies = [ "winapi", ] +[[package]] +name = "similar" +version = "2.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "420acb44afdae038210c99e69aae24109f32f15500aa708e81d46c9f29d55fcf" + [[package]] name = "siphasher" version = "0.3.10" @@ -4361,7 +4676,7 @@ dependencies = [ "percent-encoding", "rand 0.8.5", "rsa", - "rustls", + "rustls 0.20.8", "rustls-pemfile", "serde", "serde_json", @@ -4375,7 +4690,7 @@ dependencies = [ "time 0.3.20", "tokio-stream", "url", - "webpki-roots", + "webpki-roots 0.22.6", "whoami", ] @@ -4407,7 +4722,7 @@ checksum = "804d3f245f894e61b1e6263c84b23ca675d96753b5abfd5cc8597d86806e8024" dependencies = [ "once_cell", "tokio", - "tokio-rustls", + "tokio-rustls 0.23.4", ] [[package]] @@ -4597,6 +4912,16 @@ dependencies = [ "unicode-ident", ] +[[package]] +name = "sys-locale" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ea0b9eefabb91675082b41eb94c3ecd91af7656caee3fb4961a07c0ec8c7ca6f" +dependencies = [ + "libc", + "windows-sys 0.45.0", +] + [[package]] name = "system-deps" version = "6.0.4" @@ -4612,9 +4937,9 @@ dependencies = [ [[package]] name = "tao" -version = "0.18.3" +version = "0.19.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f2340617d383561b0ea25358b97ec2c2ba04db48c458ce71dd1b38d7fd09ac5" +checksum = "746ae5d0ca57ae275a792f109f6e992e0b41a443abdf3f5c6eff179ef5b3443a" dependencies = [ "bitflags 1.3.2", "cairo-rs", @@ -4683,30 +5008,30 @@ dependencies = [ [[package]] name = "tauri" -version = "2.0.0-alpha.8" +version = "2.0.0-alpha.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f25eefe4ca0a396a73fd0309f778eeb22a19953a3169bf316b893abadc2118fb" +checksum = "695b6c1cdf861002bc2ea17a53cf0669e62da5def6ffcbff02fa00c7515d40b4" dependencies = [ "anyhow", "bytes 1.4.0", "cocoa", "dirs-next", "embed_plist", - "encoding_rs", - "flate2", "futures-util", "glib", "glob", "gtk", "heck 0.4.1", "http", - "ignore", + "ico 0.2.0", + "infer 0.9.0", "jni", "libc", "log", "objc", "once_cell", "percent-encoding", + "png", "rand 0.8.5", "raw-window-handle", "reqwest", @@ -4717,7 +5042,6 @@ dependencies = [ "serialize-to-javascript", "state", "swift-rs", - "tar", "tauri-build", "tauri-macros", "tauri-runtime", @@ -4735,19 +5059,20 @@ dependencies = [ [[package]] name = "tauri-build" -version = "2.0.0-alpha.4" +version = "2.0.0-alpha.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c492211c72b95f8866e5c1fbc0a915080a5ebb9f03f9b250a1c936534b680a76" +checksum = "34a5b16abedfa53fdb6ad4c68c41612e097dbfac1c18390fe6e4ded18d9ec28d" dependencies = [ "anyhow", "cargo_toml", - "filetime", "heck 0.4.1", "json-patch", + "quote", "semver", "serde", "serde_json", "swift-rs", + "tauri-codegen", "tauri-utils", "tauri-winres", "walkdir", @@ -4755,13 +5080,13 @@ dependencies = [ [[package]] name = "tauri-codegen" -version = "2.0.0-alpha.4" +version = "2.0.0-alpha.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "818c570932ebc2ff6d498be89d93494b89ff142131937a7e56d7cfb9c8ef0ad0" +checksum = "62f03863ab7ecf1fea3a748c4a9ace7b0a6a2051b4ce10ae954ec546957fb529" dependencies = [ "base64 0.21.0", "brotli", - "ico", + "ico 0.3.0", "json-patch", "plist", "png", @@ -4781,9 +5106,9 @@ dependencies = [ [[package]] name = "tauri-macros" -version = "2.0.0-alpha.4" +version = "2.0.0-alpha.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3b596485d89003d2d7869469b2830e9a846de9ac2eecd69bc7c24890234aefc" +checksum = "74f9a2623fed6b5bc04f2e1344c88df6415617bd223599c60a4171630b63fb74" dependencies = [ "heck 0.4.1", "proc-macro2", @@ -4793,9 +5118,16 @@ dependencies = [ "tauri-utils", ] +[[package]] +name = "tauri-plugin-app" +version = "2.0.0-alpha.0" +dependencies = [ + "tauri", +] + [[package]] name = "tauri-plugin-authenticator" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "authenticator", "base64 0.21.0", @@ -4814,7 +5146,7 @@ dependencies = [ [[package]] name = "tauri-plugin-autostart" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "auto-launch", "log", @@ -4838,7 +5170,7 @@ dependencies = [ [[package]] name = "tauri-plugin-cli" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "clap", "log", @@ -4849,8 +5181,8 @@ dependencies = [ ] [[package]] -name = "tauri-plugin-clipboard" -version = "0.0.0" +name = "tauri-plugin-clipboard-manager" +version = "2.0.0-alpha.0" dependencies = [ "arboard", "log", @@ -4863,7 +5195,7 @@ dependencies = [ [[package]] name = "tauri-plugin-dialog" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "glib", "log", @@ -4873,25 +5205,27 @@ dependencies = [ "serde_json", "tauri", "tauri-build", + "tauri-plugin-fs", "thiserror", ] [[package]] -name = "tauri-plugin-fs-watch" -version = "0.0.0" +name = "tauri-plugin-fs" +version = "2.0.0-alpha.0" dependencies = [ - "log", + "anyhow", + "glob", "notify", "notify-debouncer-mini", "serde", - "serde_json", "tauri", "thiserror", + "uuid", ] [[package]] name = "tauri-plugin-global-shortcut" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "global-hotkey", "log", @@ -4901,9 +5235,26 @@ dependencies = [ "thiserror", ] +[[package]] +name = "tauri-plugin-http" +version = "2.0.0-alpha.0" +dependencies = [ + "bytes 1.4.0", + "glob", + "http", + "rand 0.8.5", + "reqwest", + "serde", + "serde_json", + "serde_repr", + "tauri", + "tauri-plugin-fs", + "thiserror", +] + [[package]] name = "tauri-plugin-localhost" -version = "0.1.0" +version = "2.0.0-alpha.0" dependencies = [ "http", "log", @@ -4911,12 +5262,12 @@ dependencies = [ "serde_json", "tauri", "thiserror", - "tiny_http", + "tiny_http 0.12.0", ] [[package]] name = "tauri-plugin-log" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "android_logger", "byte-unit", @@ -4935,7 +5286,7 @@ dependencies = [ [[package]] name = "tauri-plugin-notification" -version = "0.1.0" +version = "2.0.0-alpha.1" dependencies = [ "log", "notify-rust", @@ -4951,9 +5302,23 @@ dependencies = [ "win7-notifications", ] +[[package]] +name = "tauri-plugin-os" +version = "2.0.0-alpha.0" +dependencies = [ + "gethostname 0.4.3", + "log", + "os_info", + "serde", + "serde_json", + "sys-locale", + "tauri", + "thiserror", +] + [[package]] name = "tauri-plugin-persisted-scope" -version = "0.1.0" +version = "2.0.0-alpha.0" dependencies = [ "aho-corasick 1.0.1", "bincode", @@ -4961,12 +5326,13 @@ dependencies = [ "serde", "serde_json", "tauri", + "tauri-plugin-fs", "thiserror", ] [[package]] name = "tauri-plugin-positioner" -version = "1.0.4" +version = "2.0.0-alpha.0" dependencies = [ "log", "serde", @@ -4976,9 +5342,16 @@ dependencies = [ "thiserror", ] +[[package]] +name = "tauri-plugin-process" +version = "2.0.0-alpha.0" +dependencies = [ + "tauri", +] + [[package]] name = "tauri-plugin-shell" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "encoding_rs", "log", @@ -4994,7 +5367,7 @@ dependencies = [ [[package]] name = "tauri-plugin-single-instance" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "log", "serde", @@ -5007,7 +5380,7 @@ dependencies = [ [[package]] name = "tauri-plugin-sql" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "futures-core", "log", @@ -5022,7 +5395,7 @@ dependencies = [ [[package]] name = "tauri-plugin-store" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "log", "serde", @@ -5033,10 +5406,10 @@ dependencies = [ [[package]] name = "tauri-plugin-stronghold" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "hex", - "iota-crypto 0.17.1", + "iota-crypto 0.20.0", "iota_stronghold", "log", "rand 0.8.5", @@ -5048,9 +5421,37 @@ dependencies = [ "zeroize", ] +[[package]] +name = "tauri-plugin-updater" +version = "2.0.0-alpha.0" +dependencies = [ + "base64 0.21.0", + "dirs-next", + "flate2", + "futures-util", + "http", + "ignore", + "minisign-verify", + "mockito", + "percent-encoding", + "reqwest", + "semver", + "serde", + "serde_json", + "tar", + "tauri", + "tempfile", + "thiserror", + "time 0.3.20", + "tokio", + "tokio-test", + "url", + "zip", +] + [[package]] name = "tauri-plugin-upload" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "futures-util", "log", @@ -5066,7 +5467,7 @@ dependencies = [ [[package]] name = "tauri-plugin-websocket" -version = "0.0.0" +version = "2.0.0-alpha.0" dependencies = [ "futures-util", "log", @@ -5079,9 +5480,18 @@ dependencies = [ "tokio-tungstenite", ] +[[package]] +name = "tauri-plugin-window" +version = "2.0.0-alpha.0" +dependencies = [ + "serde", + "tauri", + "thiserror", +] + [[package]] name = "tauri-plugin-window-state" -version = "0.1.0" +version = "2.0.0-alpha.0" dependencies = [ "bincode", "bitflags 2.2.1", @@ -5094,9 +5504,9 @@ dependencies = [ [[package]] name = "tauri-runtime" -version = "0.13.0-alpha.4" +version = "0.13.0-alpha.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "404367cd32a5a8d33368448aab7da54bb2187b6a632526f1019de3fd13591cc2" +checksum = "de05147581dd8cfdac638455029eb06c57fa64eb17eb03d5d7f229c571941cd9" dependencies = [ "gtk", "http", @@ -5110,15 +5520,14 @@ dependencies = [ "thiserror", "url", "uuid", - "webview2-com", "windows 0.44.0", ] [[package]] name = "tauri-runtime-wry" -version = "0.13.0-alpha.4" +version = "0.13.0-alpha.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "203764d673b440877dea87b972772be4091ee0ab25141748008646ca774a20dc" +checksum = "7784048ef49a57ff32d55bf4ce89ec72fc97e3d4fdc68785d164b23965170e49" dependencies = [ "cocoa", "gtk", @@ -5137,16 +5546,18 @@ dependencies = [ [[package]] name = "tauri-utils" -version = "2.0.0-alpha.4" +version = "2.0.0-alpha.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49fa79bc56f04ece491268a64273de945f65627bcda30d9e8ecc8708b89bca26" +checksum = "58eca5e3b6714c6bd87052182ebb7d5392d551f478f994878f136f49d4e6d640" dependencies = [ + "aes-gcm 0.10.1", "brotli", "ctor", + "getrandom 0.2.9", "glob", "heck 0.4.1", "html5ever", - "infer", + "infer 0.12.0", "json-patch", "kuchiki", "memchr", @@ -5157,6 +5568,7 @@ dependencies = [ "serde", "serde_json", "serde_with", + "serialize-to-javascript", "thiserror", "url", "walkdir", @@ -5304,6 +5716,19 @@ dependencies = [ "time-core", ] +[[package]] +name = "tiny_http" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e0d6ef4e10d23c1efb862eecad25c5054429a71958b4eeef85eb5e7170b477ca" +dependencies = [ + "ascii", + "chunked_transfer", + "log", + "time 0.3.20", + "url", +] + [[package]] name = "tiny_http" version = "0.12.0" @@ -5363,11 +5788,21 @@ version = "0.23.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c43ee83903113e03984cb9e5cebe6c04a5116269e900e3ddba8f068a62adda59" dependencies = [ - "rustls", + "rustls 0.20.8", "tokio", "webpki", ] +[[package]] +name = "tokio-rustls" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e0d409377ff5b1e3ca6437aa86c1eb7d40c134bfec254e44c830defa92669db5" +dependencies = [ + "rustls 0.21.1", + "tokio", +] + [[package]] name = "tokio-stream" version = "0.1.12" @@ -5379,18 +5814,34 @@ dependencies = [ "tokio", ] +[[package]] +name = "tokio-test" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53474327ae5e166530d17f2d956afcb4f8a004de581b3cae10f12006bc8163e3" +dependencies = [ + "async-stream", + "bytes 1.4.0", + "futures-core", + "tokio", + "tokio-stream", +] + [[package]] name = "tokio-tungstenite" -version = "0.18.0" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54319c93411147bced34cb5609a80e0a8e44c5999c93903a81cd866630ec0bfd" +checksum = "ec509ac96e9a0c43427c74f003127d953a265737636129424288d27cb5c4b12c" dependencies = [ "futures-util", "log", "native-tls", + "rustls 0.21.1", "tokio", "tokio-native-tls", + "tokio-rustls 0.24.0", "tungstenite", + "webpki-roots 0.23.0", ] [[package]] @@ -5535,22 +5986,24 @@ checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" [[package]] name = "tungstenite" -version = "0.18.0" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30ee6ab729cd4cf0fd55218530c4522ed30b7b6081752839b68fcec8d0960788" +checksum = "15fba1a6d6bb030745759a9a2a588bfe8490fc8b4751a277db3a0be1c9ebbf67" dependencies = [ - "base64 0.13.1", "byteorder", "bytes 1.4.0", + "data-encoding", "http", "httparse", "log", "native-tls", "rand 0.8.5", + "rustls 0.21.1", "sha1", "thiserror", "url", "utf-8", + "webpki", ] [[package]] @@ -5586,6 +6039,15 @@ dependencies = [ "winapi", ] +[[package]] +name = "unicase" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "50f37be617794602aabbeee0be4f259dc1778fabe05e2d67ee8f79326d5cb4f6" +dependencies = [ + "version_check", +] + [[package]] name = "unicode-bidi" version = "0.3.13" @@ -5635,6 +6097,16 @@ dependencies = [ "subtle", ] +[[package]] +name = "universal-hash" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d3160b73c9a19f7e2939a2fdad446c57c1bbbbf4d919d3213ff1267a580d8b5" +dependencies = [ + "crypto-common", + "subtle", +] + [[package]] name = "untrusted" version = "0.7.1" @@ -5919,6 +6391,15 @@ dependencies = [ "webpki", ] +[[package]] +name = "webpki-roots" +version = "0.23.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa54963694b65584e170cf5dc46aeb4dcaa5584e652ff5f3952e56d66aff0125" +dependencies = [ + "rustls-webpki", +] + [[package]] name = "webview2-com" version = "0.22.1" @@ -6023,6 +6504,18 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" +[[package]] +name = "window-shadows" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29d30320647cfc3dc45554c8ad825b84831def81f967a2f7589931328ff9b16d" +dependencies = [ + "cocoa", + "objc", + "raw-window-handle", + "windows-sys 0.42.0", +] + [[package]] name = "windows" version = "0.36.1" @@ -6353,9 +6846,9 @@ dependencies = [ [[package]] name = "wry" -version = "0.27.3" +version = "0.28.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8cf0dbfa7ccbd2e3832a3098b19d4b552360ea00a40b244a99caef46bffd84f" +checksum = "7d15f9f827d537cefe6d047be3930f5d89b238dfb85e08ba6a319153217635aa" dependencies = [ "base64 0.13.1", "block", @@ -6417,7 +6910,7 @@ version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "592b4883219f345e712b3209c62654ebda0bb50887f330cbd018d0f654bfd507" dependencies = [ - "gethostname", + "gethostname 0.2.3", "nix 0.24.3", "winapi", "winapi-wsapoll", @@ -6537,6 +7030,17 @@ dependencies = [ "syn 2.0.13", ] +[[package]] +name = "zip" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e92305c174683d78035cbf1b70e18db6329cc0f1b9cae0a52ca90bf5bfe7125" +dependencies = [ + "byteorder", + "crc32fast", + "crossbeam-utils", +] + [[package]] name = "zvariant" version = "3.12.0" diff --git a/Cargo.toml b/Cargo.toml index 44306836..7d05f86c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,13 +1,12 @@ [workspace] -members = ["plugins/*", "examples/*/src-tauri"] -exclude = ["plugins/fs", "plugins/http", "examples/api/src-tauri"] +members = ["plugins/*", "plugins/*/tests/*", "examples/*/src-tauri"] resolver = "2" [workspace.dependencies] serde = { version = "1", features = ["derive"] } log = "0.4" -tauri = "2.0.0-alpha.8" -tauri-build = "2.0.0-alpha.4" +tauri = "2.0.0-alpha.9" +tauri-build = "2.0.0-alpha.5" serde_json = "1" thiserror = "1" @@ -15,4 +14,12 @@ thiserror = "1" edition = "2021" authors = [ "Tauri Programme within The Commons Conservancy" ] license = "Apache-2.0 OR MIT" -rust-version = "1.64" +rust-version = "1.65" + +# default to small, optimized release binaries +[profile.release] +panic = "abort" +codegen-units = 1 +lto = true +incremental = false +opt-level = "s" diff --git a/README.md b/README.md index cc7541ae..1fdcf447 100644 --- a/README.md +++ b/README.md @@ -1,21 +1,19 @@ ## Plugins Found Here -| | | Win | Mac | Lin | iOS | And | -| ------------------------------------------ | --------------------------------------------------------- | --- | --- | --- | --- | --- | -| [authenticator](plugins/authenticator) | Interface with hardware security keys. | ✅ | ✅ | ✅ | ? | ? | -| [autostart](plugins/autostart) | Automatically launch your app at system startup. | ✅ | ✅ | ✅ | ? | ? | -| [fs-extra](plugins/fs-extra) | File system methods that aren't included in the core API. | ✅ | ✅ | ✅ | ? | ? | -| [fs-watch](plugins/fs-watch) | Watch the filesystem for changes. | ✅ | ✅ | ✅ | ? | ? | -| [localhost](plugins/localhost) | Use a localhost server in production apps. | ✅ | ✅ | ✅ | ? | ? | -| [log](plugins/log) | Configurable logging. | ✅ | ✅ | ✅ | ✅ | ✅ | -| [persisted-scope](plugins/persisted-scope) | Persist runtime scope changes on the filesystem. | ✅ | ✅ | ✅ | ? | ? | -| [positioner](plugins/positioner) | Move windows to common locations. | ✅ | ✅ | ✅ | ? | ? | -| [single-instance](plugins/single-instance) | Ensure a single instance of your tauri app is running. | ✅ | ? | ✅ | ? | ? | -| [sql](plugins/sql) | Interface with SQL databases. | ✅ | ✅ | ✅ | ? | ? | -| [store](plugins/store) | Persistent key value storage. | ✅ | ✅ | ✅ | ? | ? | -| [stronghold](plugins/stronghold) | Encrypted, secure database. | ✅ | ✅ | ✅ | ? | ? | -| [upload](plugins/upload) | Tauri plugin for file uploads through HTTP. | ✅ | ✅ | ✅ | ? | ? | -| [websocket](plugins/websocket) | Open a WebSocket connection using a Rust client in JS. | ✅ | ✅ | ✅ | ? | ? | -| [window-state](plugins/window-state) | Persist window sizes and positions. | ✅ | ✅ | ✅ | ? | ? | +| | | Win | Mac | Lin | iOS | And | +| ------------------------------------------ | ------------------------------------------------------ | --- | --- | --- | --- | --- | +| [authenticator](plugins/authenticator) | Interface with hardware security keys. | ✅ | ✅ | ✅ | ? | ? | +| [autostart](plugins/autostart) | Automatically launch your app at system startup. | ✅ | ✅ | ✅ | ? | ? | +| [localhost](plugins/localhost) | Use a localhost server in production apps. | ✅ | ✅ | ✅ | ? | ? | +| [log](plugins/log) | Configurable logging. | ✅ | ✅ | ✅ | ✅ | ✅ | +| [persisted-scope](plugins/persisted-scope) | Persist runtime scope changes on the filesystem. | ✅ | ✅ | ✅ | ? | ? | +| [positioner](plugins/positioner) | Move windows to common locations. | ✅ | ✅ | ✅ | ? | ? | +| [single-instance](plugins/single-instance) | Ensure a single instance of your tauri app is running. | ✅ | ? | ✅ | ? | ? | +| [sql](plugins/sql) | Interface with SQL databases. | ✅ | ✅ | ✅ | ? | ? | +| [store](plugins/store) | Persistent key value storage. | ✅ | ✅ | ✅ | ? | ? | +| [stronghold](plugins/stronghold) | Encrypted, secure database. | ✅ | ✅ | ✅ | ? | ? | +| [upload](plugins/upload) | Tauri plugin for file uploads through HTTP. | ✅ | ✅ | ✅ | ? | ? | +| [websocket](plugins/websocket) | Open a WebSocket connection using a Rust client in JS. | ✅ | ✅ | ✅ | ? | ? | +| [window-state](plugins/window-state) | Persist window sizes and positions. | ✅ | ✅ | ✅ | ? | ? | -_This repo and all plugins require a Rust version of at least **1.64**_ +_This repo and all plugins require a Rust version of at least **1.65**_ diff --git a/examples/api/.setup-cross.sh b/examples/api/.setup-cross.sh index cd563694..a9e4f867 100644 --- a/examples/api/.setup-cross.sh +++ b/examples/api/.setup-cross.sh @@ -1,4 +1,7 @@ #!/usr/bin/env bash +# Copyright 2019-2023 Tauri Programme within The Commons Conservancy +# SPDX-License-Identifier: Apache-2.0 +# SPDX-License-Identifier: MIT export ICONS_VOLUME="$(realpath icons)" export DIST_VOLUME="$(realpath dist)" diff --git a/examples/api/CHANGELOG.md b/examples/api/CHANGELOG.md new file mode 100644 index 00000000..4da28c4f --- /dev/null +++ b/examples/api/CHANGELOG.md @@ -0,0 +1,7 @@ +# Changelog + +## \[2.0.0-alpha.0] + +### Dependencies + +- Plugins v2 alpha. diff --git a/examples/api/package.json b/examples/api/package.json index d26a48f1..558f573b 100644 --- a/examples/api/package.json +++ b/examples/api/package.json @@ -1,6 +1,7 @@ { "name": "svelte-app", - "version": "1.0.0", + "private": true, + "version": "2.0.0-alpha.0", "type": "module", "scripts": { "dev": "vite --clearScreen false", @@ -8,23 +9,28 @@ "serve": "vite preview" }, "dependencies": { - "@tauri-apps/api": "2.0.0-alpha.3", - "@tauri-apps/cli": "2.0.0-alpha.8", + "@tauri-apps/api": "2.0.0-alpha.4", "@zerodevx/svelte-json-view": "0.2.1", - "tauri-plugin-barcode-scanner-api": "0.0.0", - "tauri-plugin-cli-api": "0.0.0", - "tauri-plugin-clipboard-api": "0.0.0", - "tauri-plugin-dialog-api": "0.0.0", - "tauri-plugin-fs-api": "0.0.0", - "tauri-plugin-global-shortcut-api": "0.0.0", - "tauri-plugin-http-api": "0.0.0", - "tauri-plugin-notification-api": "0.0.0", - "tauri-plugin-shell-api": "0.0.0" + "@tauri-apps/plugin-app": "2.0.0-alpha.0", + "@tauri-apps/plugin-barcode-scanner": "0.0.0", + "@tauri-apps/plugin-cli": "2.0.0-alpha.0", + "@tauri-apps/plugin-clipboard-manager": "2.0.0-alpha.0", + "@tauri-apps/plugin-dialog": "2.0.0-alpha.0", + "@tauri-apps/plugin-fs": "2.0.0-alpha.0", + "@tauri-apps/plugin-global-shortcut": "2.0.0-alpha.0", + "@tauri-apps/plugin-http": "2.0.0-alpha.0", + "@tauri-apps/plugin-notification": "2.0.0-alpha.0", + "@tauri-apps/plugin-os": "2.0.0-alpha.0", + "@tauri-apps/plugin-process": "2.0.0-alpha.0", + "@tauri-apps/plugin-shell": "2.0.0-alpha.0", + "@tauri-apps/plugin-updater": "2.0.0-alpha.0", + "@tauri-apps/plugin-window": "2.0.0-alpha.0" }, "devDependencies": { "@iconify-json/codicon": "^1.1.10", "@iconify-json/ph": "^1.1.1", "@sveltejs/vite-plugin-svelte": "^1.0.1", + "@tauri-apps/cli": "2.0.0-alpha.9", "internal-ip": "^7.0.0", "svelte": "^3.49.0", "unocss": "^0.39.3", diff --git a/examples/api/src-tauri/CHANGELOG.md b/examples/api/src-tauri/CHANGELOG.md new file mode 100644 index 00000000..22d9cf7a --- /dev/null +++ b/examples/api/src-tauri/CHANGELOG.md @@ -0,0 +1,13 @@ +# Changelog + +## \[2.0.0-alpha.1] + +### Dependencies + +- Updated to latest `notification` + +## \[2.0.0-alpha.0] + +### Dependencies + +- Plugins v2 alpha. diff --git a/examples/api/src-tauri/Cargo.lock b/examples/api/src-tauri/Cargo.lock deleted file mode 100644 index 415040ad..00000000 --- a/examples/api/src-tauri/Cargo.lock +++ /dev/null @@ -1,4993 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "aead" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c192eb8f11fc081b0fe4259ba5af04217d4e0faddd02417310a927911abd7c8" -dependencies = [ - "crypto-common", - "generic-array", -] - -[[package]] -name = "aes" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "433cfd6710c9986c576a25ca913c39d66a6474107b406f34f91d4a8923395241" -dependencies = [ - "cfg-if", - "cipher", - "cpufeatures", -] - -[[package]] -name = "aes-gcm" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e1366e0c69c9f927b1fa5ce2c7bf9eafc8f9268c0b9800729e8b267612447c" -dependencies = [ - "aead", - "aes", - "cipher", - "ctr", - "ghash", - "subtle", -] - -[[package]] -name = "aho-corasick" -version = "0.7.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" -dependencies = [ - "memchr", -] - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "android_log-sys" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85965b6739a430150bdd138e2374a98af0c3ee0d030b3bb7fc3bddff58d0102e" - -[[package]] -name = "android_logger" -version = "0.11.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8619b80c242aa7bd638b5c7ddd952addeecb71f69c75e33f1d47b2804f8f883a" -dependencies = [ - "android_log-sys", - "env_logger", - "log", - "once_cell", -] - -[[package]] -name = "anstream" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e579a7752471abc2a8268df8b20005e3eadd975f585398f17efcfd8d4927371" -dependencies = [ - "anstyle", - "anstyle-parse", - "anstyle-query", - "anstyle-wincon", - "colorchoice", - "is-terminal", - "utf8parse", -] - -[[package]] -name = "anstyle" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41ed9a86bf92ae6580e0a31281f65a1b1d867c0cc68d5346e2ae128dddfa6a7d" - -[[package]] -name = "anstyle-parse" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e765fd216e48e067936442276d1d57399e37bce53c264d6fefbe298080cb57ee" -dependencies = [ - "utf8parse", -] - -[[package]] -name = "anstyle-query" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ca11d4be1bab0c8bc8734a9aa7bf4ee8316d462a08c6ac5052f888fef5b494b" -dependencies = [ - "windows-sys 0.48.0", -] - -[[package]] -name = "anstyle-wincon" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bcd8291a340dd8ac70e18878bc4501dd7b4ff970cfa21c207d36ece51ea88fd" -dependencies = [ - "anstyle", - "windows-sys 0.48.0", -] - -[[package]] -name = "anyhow" -version = "1.0.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "224afbd727c3d6e4b90103ece64b8d1b67fbb1973b1046c2281eed3f3803f800" - -[[package]] -name = "api" -version = "0.1.0" -dependencies = [ - "log", - "serde", - "serde_json", - "tauri", - "tauri-build", - "tauri-plugin-barcode-scanner", - "tauri-plugin-cli", - "tauri-plugin-clipboard", - "tauri-plugin-dialog", - "tauri-plugin-fs", - "tauri-plugin-global-shortcut", - "tauri-plugin-http", - "tauri-plugin-log", - "tauri-plugin-notification", - "tauri-plugin-shell", - "tiny_http", - "window-shadows", -] - -[[package]] -name = "arboard" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6041616acea41d67c4a984709ddab1587fd0b10efe5cc563fee954d2f011854" -dependencies = [ - "clipboard-win", - "core-graphics", - "image", - "log", - "objc", - "objc-foundation", - "objc_id", - "once_cell", - "parking_lot", - "thiserror", - "winapi", - "x11rb", -] - -[[package]] -name = "ascii" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d92bec98840b8f03a5ff5413de5293bfcd8bf96467cf5452609f939ec6f5de16" - -[[package]] -name = "async-broadcast" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c48ccdbf6ca6b121e0f586cbc0e73ae440e56c67c30fa0873b4e110d9c26d2b" -dependencies = [ - "event-listener", - "futures-core", -] - -[[package]] -name = "async-channel" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf46fee83e5ccffc220104713af3292ff9bc7c64c7de289f66dae8e38d826833" -dependencies = [ - "concurrent-queue", - "event-listener", - "futures-core", -] - -[[package]] -name = "async-executor" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17adb73da160dfb475c183343c8cccd80721ea5a605d3eb57125f0a7b7a92d0b" -dependencies = [ - "async-lock", - "async-task", - "concurrent-queue", - "fastrand", - "futures-lite", - "slab", -] - -[[package]] -name = "async-fs" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "279cf904654eeebfa37ac9bb1598880884924aab82e290aa65c9e77a0e142e06" -dependencies = [ - "async-lock", - "autocfg", - "blocking", - "futures-lite", -] - -[[package]] -name = "async-io" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fc5b45d93ef0529756f812ca52e44c221b35341892d3dcc34132ac02f3dd2af" -dependencies = [ - "async-lock", - "autocfg", - "cfg-if", - "concurrent-queue", - "futures-lite", - "log", - "parking", - "polling", - "rustix", - "slab", - "socket2", - "waker-fn", -] - -[[package]] -name = "async-lock" -version = "2.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa24f727524730b077666307f2734b4a1a1c57acb79193127dcc8914d5242dd7" -dependencies = [ - "event-listener", -] - -[[package]] -name = "async-recursion" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b015a331cc64ebd1774ba119538573603427eaace0a1950c423ab971f903796" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "async-task" -version = "4.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc7ab41815b3c653ccd2978ec3255c81349336702dfdf62ee6f7069b12a3aae" - -[[package]] -name = "async-trait" -version = "0.1.66" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b84f9ebcc6c1f5b8cb160f6990096a5c127f423fcb6e1ccc46c370cbdfb75dfc" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "atk" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39991bc421ddf72f70159011b323ff49b0f783cc676a7287c59453da2e2531cf" -dependencies = [ - "atk-sys", - "bitflags", - "glib", - "libc", -] - -[[package]] -name = "atk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11ad703eb64dc058024f0e57ccfa069e15a413b98dbd50a1a950e743b7f11148" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "atomic-waker" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "debc29dde2e69f9e47506b525f639ed42300fc014a3e007832592448fa8e4599" - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "base64" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" - -[[package]] -name = "base64" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "block" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" - -[[package]] -name = "block-buffer" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69cce20737498f97b993470a6e536b8523f0af7892a4f928cceb1ac5e52ebe7e" -dependencies = [ - "generic-array", -] - -[[package]] -name = "blocking" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c67b173a56acffd6d2326fb7ab938ba0b00a71480e14902b2591c87bc5741e8" -dependencies = [ - "async-channel", - "async-lock", - "async-task", - "atomic-waker", - "fastrand", - "futures-lite", -] - -[[package]] -name = "brotli" -version = "3.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a0b1dbcc8ae29329621f8d4f0d835787c1c38bb1401979b49d13b0b305ff68" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b6561fd3f895a11e8f72af2cb7d22e08366bebc2b6b57f7744c4bda27034744" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bstr" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d4260bcc2e8fc9df1eac4919a720effeb63a3f0952f5bf4944adfa18897f09" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" - -[[package]] -name = "byte-unit" -version = "4.0.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da78b32057b8fdfc352504708feeba7216dcd65a2c9ab02978cbd288d1279b6c" -dependencies = [ - "serde", - "utf8-width", -] - -[[package]] -name = "bytemuck" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c041d3eab048880cb0b86b256447da3f18859a163c3b8d8893f4e6368abe6393" - -[[package]] -name = "byteorder" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" - -[[package]] -name = "bytes" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" -dependencies = [ - "serde", -] - -[[package]] -name = "cairo-rs" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3125b15ec28b84c238f6f476c6034016a5f6cc0221cb514ca46c532139fc97d" -dependencies = [ - "bitflags", - "cairo-sys-rs", - "glib", - "libc", - "once_cell", - "thiserror", -] - -[[package]] -name = "cairo-sys-rs" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c48f4af05fabdcfa9658178e1326efa061853f040ce7d72e33af6885196f421" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "cargo_toml" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bfbc36312494041e2cdd5f06697b7e89d4b76f42773a0b5556ac290ff22acc2" -dependencies = [ - "serde", - "toml", -] - -[[package]] -name = "cc" -version = "1.0.79" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" - -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - -[[package]] -name = "cfb" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d38f2da7a0a2c4ccf0065be06397cc26a81f4e528be095826eee9d4adbb8c60f" -dependencies = [ - "byteorder", - "fnv", - "uuid", -] - -[[package]] -name = "cfg-expr" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0357a6402b295ca3a86bc148e84df46c02e41f41fef186bda662557ef6328aa" -dependencies = [ - "smallvec", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "chunked_transfer" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cca491388666e04d7248af3f60f0c40cfb0991c72205595d7c396e3510207d1a" - -[[package]] -name = "cipher" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1873270f8f7942c191139cb8a40fd228da6c3fd2fc376d7e92d47aa14aeb59e" -dependencies = [ - "crypto-common", - "inout", -] - -[[package]] -name = "clap" -version = "4.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b802d85aaf3a1cdb02b224ba472ebdea62014fccfcb269b95a4d76443b5ee5a" -dependencies = [ - "clap_builder", -] - -[[package]] -name = "clap_builder" -version = "4.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14a1a858f532119338887a4b8e1af9c60de8249cd7bafd68036a489e261e37b6" -dependencies = [ - "anstream", - "anstyle", - "bitflags", - "clap_lex", - "strsim", -] - -[[package]] -name = "clap_lex" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a2dd5a6fe8c6e3502f568a6353e5273bbb15193ad9a89e457b9970798efbea1" - -[[package]] -name = "clipboard-win" -version = "4.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7191c27c2357d9b7ef96baac1773290d4ca63b24205b82a3fd8a0637afcf0362" -dependencies = [ - "error-code", - "str-buf", - "winapi", -] - -[[package]] -name = "cocoa" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f425db7937052c684daec3bd6375c8abe2d146dca4b8b143d6db777c39138f3a" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation", - "core-graphics", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa-foundation" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ade49b65d560ca58c403a479bb396592b155c0185eada742ee323d1d68d6318" -dependencies = [ - "bitflags", - "block", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "color_quant" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" - -[[package]] -name = "colorchoice" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" - -[[package]] -name = "combine" -version = "4.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] - -[[package]] -name = "concurrent-queue" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c278839b831783b70278b14df4d45e1beb1aad306c07bb796637de9a0e323e8e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dc" - -[[package]] -name = "core-graphics" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" -dependencies = [ - "bitflags", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" -dependencies = [ - "bitflags", - "core-foundation", - "foreign-types", - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28d997bd5e24a5928dd43e46dc529867e207907fe0b239c3477d924f7f2ca320" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2dd04ddaf88237dc3b8d8f9a3c1004b506b54b3313403944054d23c0870c521" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb766fa798726286dbbb842f174001dab8abc7b627a1dd86e0b7222a95d929f" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "rand_core 0.6.4", - "typenum", -] - -[[package]] -name = "cssparser" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "754b69d351cdc2d8ee09ae203db831e005560fc6030da058f86ad60c92a9cb0a" -dependencies = [ - "cssparser-macros", - "dtoa-short", - "itoa 0.4.8", - "matches", - "phf 0.8.0", - "proc-macro2", - "quote", - "smallvec", - "syn", -] - -[[package]] -name = "cssparser-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfae75de57f2b2e85e8768c3ea840fd159c8f33e2b6522c7835b7abac81be16e" -dependencies = [ - "quote", - "syn", -] - -[[package]] -name = "ctor" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d2301688392eb071b0bf1a37be05c469d3cc4dbbd95df672fe28ab021e6a096" -dependencies = [ - "quote", - "syn", -] - -[[package]] -name = "ctr" -version = "0.9.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" -dependencies = [ - "cipher", -] - -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core", - "quote", - "syn", -] - -[[package]] -name = "derivative" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "derive_more" -version = "0.99.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version 0.4.0", - "syn", -] - -[[package]] -name = "digest" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dirs" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3aa72a6f96ea37bbc5aa912f6788242832f75369bdfdadcb0e38423f100059" -dependencies = [ - "dirs-sys", -] - -[[package]] -name = "dirs-next" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" -dependencies = [ - "cfg-if", - "dirs-sys-next", -] - -[[package]] -name = "dirs-sys" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dirs-sys-next" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dispatch" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" - -[[package]] -name = "dtoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" - -[[package]] -name = "dtoa-short" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde03329ae10e79ede66c9ce4dc930aa8599043b0743008548680f25b91502d6" -dependencies = [ - "dtoa", -] - -[[package]] -name = "dunce" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bd4b30a6560bbd9b4620f4de34c3f14f60848e58a9b7216801afcb4c7b31c3c" - -[[package]] -name = "embed_plist" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" - -[[package]] -name = "encoding_rs" -version = "0.8.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071a31f4ee85403370b58aca746f01041ede6f0da2730960ad001edc2b71b394" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "enumflags2" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e75d4cd21b95383444831539909fbb14b9dc3fdceb2a6f5d36577329a1f55ccb" -dependencies = [ - "enumflags2_derive", - "serde", -] - -[[package]] -name = "enumflags2_derive" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f58dc3c5e468259f19f2d46304a6b28f1c3d034442e14b322d2b850e36f6d5ae" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "env_logger" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0" -dependencies = [ - "log", - "regex", -] - -[[package]] -name = "errno" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d6a0976c999d473fe89ad888d5a284e55366d9dc9038b1ba2aa15128c4afa0" -dependencies = [ - "errno-dragonfly", - "libc", - "windows-sys 0.45.0", -] - -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] - -[[package]] -name = "error-code" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64f18991e7bf11e7ffee451b5318b5c1a73c52d0d0ada6e5a3017c8c1ced6a21" -dependencies = [ - "libc", - "str-buf", -] - -[[package]] -name = "event-listener" -version = "2.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" - -[[package]] -name = "fastrand" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a407cfaa3385c4ae6b23e84623d48c2798d06e3e6a1878f7f59f17b3f86499" -dependencies = [ - "instant", -] - -[[package]] -name = "fern" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9f0c14694cbd524c8720dd69b0e3179344f04ebb5f90f2e4a440c6ea3b2f1ee" -dependencies = [ - "log", -] - -[[package]] -name = "field-offset" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e1c54951450cbd39f3dbcf1005ac413b49487dabf18a720ad2383eccfeffb92" -dependencies = [ - "memoffset 0.6.5", - "rustc_version 0.3.3", -] - -[[package]] -name = "filetime" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e884668cd0c7480504233e951174ddc3b382f7c2666e3b7310b5c4e7b0c37f9" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "windows-sys 0.42.0", -] - -[[package]] -name = "flate2" -version = "1.0.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futf" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df420e2e84819663797d1ec6544b13c5be84629e7bb00dc960d6917db2987843" -dependencies = [ - "mac", - "new_debug_unreachable", -] - -[[package]] -name = "futures-channel" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e5317663a9089767a1ec00a487df42e0ca174b61b4483213ac24448e4664df5" -dependencies = [ - "futures-core", -] - -[[package]] -name = "futures-core" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec90ff4d0fe1f57d600049061dc6bb68ed03c7d2fbd697274c41805dcb3f8608" - -[[package]] -name = "futures-executor" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8de0a35a6ab97ec8869e32a2473f4b1324459e14c29275d14b10cb1fd19b50e" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfb8371b6fb2aeb2d280374607aeabfc99d95c72edfe51692e42d3d7f0d08531" - -[[package]] -name = "futures-lite" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7694489acd39452c77daa48516b894c153f192c3578d5a839b62c58099fcbf48" -dependencies = [ - "fastrand", - "futures-core", - "futures-io", - "memchr", - "parking", - "pin-project-lite", - "waker-fn", -] - -[[package]] -name = "futures-macro" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a73af87da33b5acf53acfebdc339fe592ecf5357ac7c0a7734ab9d8c876a70" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "futures-sink" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f310820bb3e8cfd46c80db4d7fb8353e15dfff853a127158425f31e0be6c8364" - -[[package]] -name = "futures-task" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcf79a1bf610b10f42aea489289c5a2c478a786509693b80cd39c44ccd936366" - -[[package]] -name = "futures-util" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c1d6de3acfef38d2be4b1f543f553131788603495be83da675e180c8d6b7bd1" -dependencies = [ - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "fxhash" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" -dependencies = [ - "byteorder", -] - -[[package]] -name = "gdk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa9cb33da481c6c040404a11f8212d193889e9b435db2c14fd86987f630d3ce1" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk-pixbuf", - "gdk-sys", - "gio", - "glib", - "libc", - "pango", -] - -[[package]] -name = "gdk-pixbuf" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3578c60dee9d029ad86593ed88cb40f35c1b83360e12498d055022385dd9a05" -dependencies = [ - "bitflags", - "gdk-pixbuf-sys", - "gio", - "glib", - "libc", -] - -[[package]] -name = "gdk-pixbuf-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3092cf797a5f1210479ea38070d9ae8a5b8e9f8f1be9f32f4643c529c7d70016" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gdk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d76354f97a913e55b984759a997b693aa7dc71068c9e98bcce51aa167a0a5c5a" -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.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4511710212ed3020b61a8622a37aa6f0dd2a84516575da92e9b96928dcbe83ba" -dependencies = [ - "gdk-sys", - "glib-sys", - "gobject-sys", - "libc", - "pkg-config", - "system-deps", -] - -[[package]] -name = "gdkx11-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fa2bf8b5b8c414bc5d05e48b271896d0fd3ddb57464a3108438082da61de6af" -dependencies = [ - "gdk-sys", - "glib-sys", - "libc", - "system-deps", - "x11", -] - -[[package]] -name = "generator" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d266041a359dfa931b370ef684cceb84b166beb14f7f0421f4a6a3d0c446d12e" -dependencies = [ - "cc", - "libc", - "log", - "rustversion", - "windows 0.39.0", -] - -[[package]] -name = "generic-array" -version = "0.14.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bff49e947297f3312447abdca79f45f4738097cc82b06e72054d2223f601f1b9" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "gethostname" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1ebd34e35c46e00bb73e81363248d627782724609fe1b6396f553f68fe3862e" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c05aeb6a22b8f62540c194aac980f2115af067bfe15a0734d7277a768d396b31" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "ghash" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d930750de5717d2dd0b8c0d42c076c0e884c81a73e6cab859bbd2339c71e3e40" -dependencies = [ - "opaque-debug", - "polyval", -] - -[[package]] -name = "gio" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a1c84b4534a290a29160ef5c6eff2a9c95833111472e824fc5cb78b513dd092" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-io", - "futures-util", - "gio-sys", - "glib", - "libc", - "once_cell", - "pin-project-lite", - "smallvec", - "thiserror", -] - -[[package]] -name = "gio-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9b693b8e39d042a95547fc258a7b07349b1f0b48f4b2fa3108ba3c51c0b5229" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", - "winapi", -] - -[[package]] -name = "glib" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddd4df61a866ed7259d6189b8bcb1464989a77f1d85d25d002279bbe9dd38b2f" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-executor", - "futures-task", - "futures-util", - "gio-sys", - "glib-macros", - "glib-sys", - "gobject-sys", - "libc", - "once_cell", - "smallvec", - "thiserror", -] - -[[package]] -name = "glib-macros" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e084807350b01348b6d9dbabb724d1a0bb987f47a2c85de200e98e12e30733bf" -dependencies = [ - "anyhow", - "heck 0.4.1", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "glib-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c61a4f46316d06bfa33a7ac22df6f0524c8be58e3db2d9ca99ccb1f357b62a65" -dependencies = [ - "libc", - "system-deps", -] - -[[package]] -name = "glob" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" - -[[package]] -name = "global-hotkey" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92007db5c632751655a4c0ef122832fd283e6651621d34613b17fd1edfbfd2ed" -dependencies = [ - "crossbeam-channel", - "keyboard-types", - "once_cell", - "thiserror", - "windows-sys 0.48.0", - "x11-dl", -] - -[[package]] -name = "globset" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "029d74589adefde59de1a0c4f4732695c32805624aec7b68d91503d4dba79afc" -dependencies = [ - "aho-corasick", - "bstr", - "fnv", - "log", - "regex", -] - -[[package]] -name = "gobject-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3520bb9c07ae2a12c7f2fbb24d4efc11231c8146a86956413fb1a79bb760a0f1" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gtk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4d3507d43908c866c805f74c9dd593c0ce7ba5c38e576e41846639cdcd4bee6" -dependencies = [ - "atk", - "bitflags", - "cairo-rs", - "field-offset", - "futures-channel", - "gdk", - "gdk-pixbuf", - "gio", - "glib", - "gtk-sys", - "gtk3-macros", - "libc", - "once_cell", - "pango", - "pkg-config", -] - -[[package]] -name = "gtk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b5f8946685d5fe44497007786600c2f368ff6b1e61a16251c89f72a97520a3" -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.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cfd6557b1018b773e43c8de9d0d13581d6b36190d0501916cbec4731db5ccff" -dependencies = [ - "anyhow", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "h2" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f9f29bc9dda355256b2916cf526ab02ce0aeaaaf2bad60d65ef3f12f11dd0f4" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - -[[package]] -name = "heck" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" - -[[package]] -name = "hermit-abi" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "html5ever" -version = "0.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c13fb08e5d4dfc151ee5e88bae63f7773d61852f3bdc73c9f4b9e1bde03148" -dependencies = [ - "log", - "mac", - "markup5ever", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "http" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" -dependencies = [ - "bytes", - "fnv", - "itoa 1.0.5", -] - -[[package]] -name = "http-body" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" -dependencies = [ - "bytes", - "http", - "pin-project-lite", -] - -[[package]] -name = "http-range" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21dec9db110f5f872ed9699c3ecf50cf16f423502706ba5c72462e28d3157573" - -[[package]] -name = "httparse" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" - -[[package]] -name = "httpdate" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" - -[[package]] -name = "hyper" -version = "0.14.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e011372fa0b68db8350aa7a248930ecc7839bf46d8485577d69f117a75f164c" -dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "httpdate", - "itoa 1.0.5", - "pin-project-lite", - "socket2", - "tokio", - "tower-service", - "tracing", - "want", -] - -[[package]] -name = "ico" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "031530fe562d8c8d71c0635013d6d155bbfe8ba0aa4b4d2d24ce8af6b71047bd" -dependencies = [ - "byteorder", - "png", -] - -[[package]] -name = "ico" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3804960be0bb5e4edb1e1ad67afd321a9ecfd875c3e65c099468fd2717d7cae" -dependencies = [ - "byteorder", - "png", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe7873dab538a9a44ad79ede1faf5f30d49f9a5c883ddbab48bce81b64b7492" -dependencies = [ - "globset", - "lazy_static", - "log", - "memchr", - "regex", - "same-file", - "thread_local", - "walkdir", - "winapi-util", -] - -[[package]] -name = "image" -version = "0.24.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69b7ea949b537b0fd0af141fff8c77690f2ce96f4f41f042ccb6c69c6c965945" -dependencies = [ - "bytemuck", - "byteorder", - "color_quant", - "num-rational", - "num-traits", - "png", - "tiff", -] - -[[package]] -name = "indexmap" -version = "1.9.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399" -dependencies = [ - "autocfg", - "hashbrown", -] - -[[package]] -name = "infer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f178e61cdbfe084aa75a2f4f7a25a5bb09701a47ae1753608f194b15783c937a" -dependencies = [ - "cfb", -] - -[[package]] -name = "infer" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a898e4b7951673fce96614ce5751d13c40fc5674bc2d759288e46c3ab62598b3" -dependencies = [ - "cfb", -] - -[[package]] -name = "inout" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0c10553d664a4d0bcff9f4215d0aac67a639cc68ef660840afe309b807bc9f5" -dependencies = [ - "generic-array", -] - -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "io-lifetimes" -version = "1.0.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c66c74d2ae7e79a5a8f7ac924adbe38ee42a859c6539ad869eb51f0b52dc220" -dependencies = [ - "hermit-abi 0.3.1", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "ipnet" -version = "2.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30e22bd8629359895450b59ea7a776c850561b96a3b1d31321c1949d9e6c9146" - -[[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-terminal" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adcf93614601c8129ddf72e2d5633df827ba6551541c6d8c59520a371475be1f" -dependencies = [ - "hermit-abi 0.3.1", - "io-lifetimes", - "rustix", - "windows-sys 0.48.0", -] - -[[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 = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4" - -[[package]] -name = "itoa" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fad582f4b9e86b6caa621cabeb0963332d92eea04729ab12892c2533951e6440" - -[[package]] -name = "javascriptcore-rs" -version = "0.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "110b9902c80c12bf113c432d0b71c7a94490b294a8234f326fd0abca2fac0b00" -dependencies = [ - "bitflags", - "glib", - "javascriptcore-rs-sys", -] - -[[package]] -name = "javascriptcore-rs-sys" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98a216519a52cd941a733a0ad3f1023cfdb1cd47f3955e8e863ed56f558f916c" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "jni" -version = "0.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039022cdf4d7b1cf548d31f60ae783138e5fd42013f6271049d7df7afadef96c" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - -[[package]] -name = "jni-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" - -[[package]] -name = "jpeg-decoder" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc0000e42512c92e31c2252315bda326620a4e034105e900c98ec492fa077b3e" - -[[package]] -name = "js-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "json-patch" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e712e62827c382a77b87f590532febb1f8b2fdbc3eefa1ee37fe7281687075ef" -dependencies = [ - "serde", - "serde_json", - "thiserror", - "treediff", -] - -[[package]] -name = "keyboard-types" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7668b7cff6a51fe61cdde64cd27c8a220786f399501b57ebe36f7d8112fd68" -dependencies = [ - "bitflags", - "serde", - "unicode-segmentation", -] - -[[package]] -name = "kuchiki" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ea8e9c6e031377cff82ee3001dc8026cdf431ed4e2e6b51f98ab8c73484a358" -dependencies = [ - "cssparser", - "html5ever", - "matches", - "selectors", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libappindicator" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89e1edfdc9b0853358306c6dfb4b77c79c779174256fe93d80c0b5ebca451a2f" -dependencies = [ - "glib", - "gtk", - "gtk-sys", - "libappindicator-sys", - "log", -] - -[[package]] -name = "libappindicator-sys" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08fcb2bea89cee9613982501ec83eaa2d09256b24540ae463c52a28906163918" -dependencies = [ - "gtk-sys", - "libloading", - "once_cell", -] - -[[package]] -name = "libc" -version = "0.2.139" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "201de327520df007757c1f0adce6e827fe8562fbc28bfd9c15571c66ca1f5f79" - -[[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 = "line-wrap" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30344350a2a51da54c1d53be93fade8a237e545dbcc4bdbe635413f2117cab9" -dependencies = [ - "safemem", -] - -[[package]] -name = "linux-raw-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d59d8c75012853d2e872fb56bc8a2e53718e2cafe1a4c823143141c6d90c322f" - -[[package]] -name = "lock_api" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", - "value-bag", -] - -[[package]] -name = "loom" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff50ecb28bb86013e935fb6683ab1f6d3a20016f123c76fd4c27470076ac30f5" -dependencies = [ - "cfg-if", - "generator", - "scoped-tls", - "serde", - "serde_json", - "tracing", - "tracing-subscriber", -] - -[[package]] -name = "mac" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4" - -[[package]] -name = "mac-notification-sys" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e72d50edb17756489e79d52eb146927bec8eba9dd48faadf9ef08bca3791ad5" -dependencies = [ - "cc", - "dirs-next", - "objc-foundation", - "objc_id", - "time", -] - -[[package]] -name = "malloc_buf" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb" -dependencies = [ - "libc", -] - -[[package]] -name = "markup5ever" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a24f40fb03852d1cdd84330cddcaf98e9ec08a7b7768e952fad3b4cf048ec8fd" -dependencies = [ - "log", - "phf 0.8.0", - "phf_codegen", - "string_cache", - "string_cache_codegen", - "tendril", -] - -[[package]] -name = "matchers" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" -dependencies = [ - "regex-automata", -] - -[[package]] -name = "matches" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "memoffset" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" -dependencies = [ - "autocfg", -] - -[[package]] -name = "memoffset" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5de893c32cde5f383baa4c04c5d6dbdd735cfd4a794b0debdb2bb1b421da5ff4" -dependencies = [ - "autocfg", -] - -[[package]] -name = "mime" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a60c7ce501c71e03a9c9c0d35b861413ae925bd979cc7a4e30d060069aaac8d" - -[[package]] -name = "mime_guess" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4192263c238a5f0d0c6bfd21f336a313a4ce1c450542449ca191bb657b4642ef" -dependencies = [ - "mime", - "unicase", -] - -[[package]] -name = "minisign-verify" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "933dca44d65cdd53b355d0b73d380a2ff5da71f87f036053188bf1eab6a19881" - -[[package]] -name = "miniz_oxide" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5d732bc30207a6423068df043e3d02e0735b155ad7ce1a6f76fe2baa5b158de" -dependencies = [ - "libc", - "log", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.42.0", -] - -[[package]] -name = "ndk" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2032c77e030ddee34a6787a64166008da93f6a352b629261d0fee232b8742dd4" -dependencies = [ - "bitflags", - "jni-sys", - "ndk-sys", - "num_enum", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5a6ae77c8ee183dcbbba6150e2e6b9f3f4196a7666c02a715a95692ec1fa97" -dependencies = [ - "jni-sys", -] - -[[package]] -name = "new_debug_unreachable" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" - -[[package]] -name = "nix" -version = "0.24.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa52e972a9a719cecb6864fb88568781eb706bac2cd1d4f04a648542dbf78069" -dependencies = [ - "bitflags", - "cfg-if", - "libc", - "memoffset 0.6.5", -] - -[[package]] -name = "nix" -version = "0.26.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfdda3d196821d6af13126e40375cdf7da646a96114af134d5f417a9a1dc8e1a" -dependencies = [ - "bitflags", - "cfg-if", - "libc", - "memoffset 0.7.1", - "pin-utils", - "static_assertions", -] - -[[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] -name = "nom8" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae01545c9c7fc4486ab7debaf2aad7003ac19431791868fb2e8066df97fad2f8" -dependencies = [ - "memchr", -] - -[[package]] -name = "notify-rust" -version = "4.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ce656bb6d22a93ae276a23de52d1aec5ba4db3ece3c0eb79dfd5add7384db6a" -dependencies = [ - "mac-notification-sys", - "serde", - "tauri-winrt-notification", - "zbus", -] - -[[package]] -name = "nu-ansi-term" -version = "0.46.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" -dependencies = [ - "overload", - "winapi", -] - -[[package]] -name = "num-integer" -version = "0.1.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b" -dependencies = [ - "hermit-abi 0.2.6", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d829733185c1ca374f17e52b762f24f535ec625d2cc1f070e34c8a9068f341b" -dependencies = [ - "num_enum_derive", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2be1598bf1c313dcdd12092e3f1920f463462525a21b7b4e11b4168353d0123e" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "num_threads" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2819ce041d2ee131036f4fc9d6ae7ae125a3a40e97ba64d04fe799ad9dabbb44" -dependencies = [ - "libc", -] - -[[package]] -name = "objc" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1" -dependencies = [ - "malloc_buf", - "objc_exception", -] - -[[package]] -name = "objc-foundation" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1add1b659e36c9607c7aab864a76c7a4c2760cd0cd2e120f3fb8b952c7e22bf9" -dependencies = [ - "block", - "objc", - "objc_id", -] - -[[package]] -name = "objc_exception" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad970fb455818ad6cba4c122ad012fae53ae8b4795f86378bce65e4f6bab2ca4" -dependencies = [ - "cc", -] - -[[package]] -name = "objc_id" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b" -dependencies = [ - "objc", -] - -[[package]] -name = "once_cell" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f61fba1741ea2b3d6a1e3178721804bb716a68a6aeba1149b5d52e3d464ea66" - -[[package]] -name = "opaque-debug" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" - -[[package]] -name = "open" -version = "4.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d16814a067484415fda653868c9be0ac5f2abd2ef5d951082a5f2fe1b3662944" -dependencies = [ - "is-wsl", - "pathdiff", -] - -[[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.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c424bc68d15e0778838ac013b5b3449544d8133633d8016319e7e05a820b8c0" -dependencies = [ - "log", - "serde", - "winapi", -] - -[[package]] -name = "os_pipe" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a53dbb20faf34b16087a931834cba2d7a73cc74af2b7ef345a4c8324e2409a12" -dependencies = [ - "libc", - "windows-sys 0.45.0", -] - -[[package]] -name = "overload" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" - -[[package]] -name = "pango" -version = "0.16.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdff66b271861037b89d028656184059e03b0b6ccb36003820be19f7200b1e94" -dependencies = [ - "bitflags", - "gio", - "glib", - "libc", - "once_cell", - "pango-sys", -] - -[[package]] -name = "pango-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e134909a9a293e04d2cc31928aa95679c5e4df954d0b85483159bd20d8f047f" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "parking" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "427c3892f9e783d91cc128285287e70a59e206ca452770ece88a76f7a3eddd72" - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9069cbb9f99e3a5083476ccb29ceb1de18b9118cafa53e90c9551235de2b9521" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-sys 0.45.0", -] - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "percent-encoding" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" - -[[package]] -name = "pest" -version = "2.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ab62d2fa33726dbe6321cc97ef96d8cde531e3eeaf858a058de53a8a6d40d8f" -dependencies = [ - "thiserror", - "ucd-trie", -] - -[[package]] -name = "phf" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dfb61232e34fcb633f43d12c58f83c1df82962dcdfa565a4e866ffc17dafe12" -dependencies = [ - "phf_macros 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", -] - -[[package]] -name = "phf" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259" -dependencies = [ - "phf_macros 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", -] - -[[package]] -name = "phf_codegen" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbffee61585b0411840d3ece935cce9cb6321f01c45477d30066498cd5e1a815" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", -] - -[[package]] -name = "phf_generator" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17367f0cc86f2d25802b2c26ee58a7b23faeccf78a396094c13dced0d0182526" -dependencies = [ - "phf_shared 0.8.0", - "rand 0.7.3", -] - -[[package]] -name = "phf_generator" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d5285893bb5eb82e6aaf5d59ee909a06a16737a8970984dd7746ba9283498d6" -dependencies = [ - "phf_shared 0.10.0", - "rand 0.8.5", -] - -[[package]] -name = "phf_macros" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6fde18ff429ffc8fe78e2bf7f8b7a5a5a6e2a8b58bc5a9ac69198bbda9189c" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "phf_macros" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fdf3184dd560f160dd73922bea2d5cd6e8f064bf4b13110abd81b03697b4e0" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "phf_shared" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c00cf8b9eafe68dde5e9eaa2cef8ee84a9336a47d566ec55ca16589633b65af7" -dependencies = [ - "siphasher", -] - -[[package]] -name = "phf_shared" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" - -[[package]] -name = "plist" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5329b8f106a176ab0dce4aae5da86bfcb139bb74fb00882859e03745011f3635" -dependencies = [ - "base64 0.13.1", - "indexmap", - "line-wrap", - "quick-xml 0.26.0", - "serde", - "time", -] - -[[package]] -name = "png" -version = "0.17.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d708eaf860a19b19ce538740d2b4bdeeb8337fa53f7738455e706623ad5c638" -dependencies = [ - "bitflags", - "crc32fast", - "flate2", - "miniz_oxide", -] - -[[package]] -name = "polling" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e1f879b2998099c2d69ab9605d145d5b661195627eccc680002c4918a7fb6fa" -dependencies = [ - "autocfg", - "bitflags", - "cfg-if", - "concurrent-queue", - "libc", - "log", - "pin-project-lite", - "windows-sys 0.45.0", -] - -[[package]] -name = "polyval" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ef234e08c11dfcb2e56f79fd70f6f2eb7f025c0ce2333e82f4f0518ecad30c6" -dependencies = [ - "cfg-if", - "cpufeatures", - "opaque-debug", - "universal-hash", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[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.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66618389e4ec1c7afe67d51a9bf34ff9236480f8d51e7489b7d5ab0303c13f34" -dependencies = [ - "once_cell", - "toml_edit", -] - -[[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", - "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-macro-hack" -version = "0.5.20+deprecated" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" - -[[package]] -name = "proc-macro2" -version = "1.0.51" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d727cae5b39d21da60fa540906919ad737832fe0b1c165da3a34d6548c849d6" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quick-xml" -version = "0.23.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11bafc859c6815fbaffbbbf4229ecb767ac913fecb27f9ad4343662e9ef099ea" -dependencies = [ - "memchr", -] - -[[package]] -name = "quick-xml" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f50b1c63b38611e7d4d7f68b82d3ad0cc71a2ad2e7f61fc10f1328d917c93cd" -dependencies = [ - "memchr", -] - -[[package]] -name = "quote" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8856d8364d252a14d474036ea1358d63c9e6965c8e5c1885c18f73d70bff9c7b" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", - "rand_pcg", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.8", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_pcg" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "raw-window-handle" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f851a03551ceefd30132e447f07f96cb7011d6b658374f3aed847333adb5559" - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.8", - "redox_syscall", - "thiserror", -] - -[[package]] -name = "regex" -version = "1.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48aaa5748ba571fb95cd2c85c09f629215d3a6ece942baa100950af03a34f733" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "456c603be3e8d448b072f410900c09faf164fbce2d480456f50eea6e25f9c848" - -[[package]] -name = "remove_dir_all" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7" -dependencies = [ - "winapi", -] - -[[package]] -name = "reqwest" -version = "0.11.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21eed90ec8570952d53b772ecf8f206aa1ec9a3d76b2521c56c42973f2d91ee9" -dependencies = [ - "base64 0.21.0", - "bytes", - "encoding_rs", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "hyper", - "ipnet", - "js-sys", - "log", - "mime", - "mime_guess", - "once_cell", - "percent-encoding", - "pin-project-lite", - "serde", - "serde_json", - "serde_urlencoded", - "tokio", - "tokio-util", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "wasm-streams", - "web-sys", - "winreg", -] - -[[package]] -name = "rfd" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc2583255eadc4e0d816cb7648371cc91e49cbac85b0748b6ab417093bff4040" -dependencies = [ - "block", - "dispatch", - "glib-sys", - "gobject-sys", - "gtk-sys", - "js-sys", - "log", - "objc", - "objc-foundation", - "objc_id", - "raw-window-handle", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "windows 0.44.0", -] - -[[package]] -name = "rustc_version" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" -dependencies = [ - "semver 0.11.0", -] - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver 1.0.16", -] - -[[package]] -name = "rustix" -version = "0.37.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b24138615de35e32031d041a09032ef3487a616d901ca4db224e7d557efae2" -dependencies = [ - "bitflags", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys", - "windows-sys 0.45.0", -] - -[[package]] -name = "rustversion" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5583e89e108996506031660fe09baa5011b9dd0341b89029313006d1fb508d70" - -[[package]] -name = "ryu" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b4b9743ed687d4b4bcedf9ff5eaa7398495ae14e61cba0a295704edbc7decde" - -[[package]] -name = "safemem" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef703b7cb59335eae2eb93ceb664c0eb7ea6bf567079d843e09420219668e072" - -[[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 = "scoped-tls" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" - -[[package]] -name = "scopeguard" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "selectors" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df320f1889ac4ba6bc0cdc9c9af7af4bd64bb927bccdf32d81140dc1f9be12fe" -dependencies = [ - "bitflags", - "cssparser", - "derive_more", - "fxhash", - "log", - "matches", - "phf 0.8.0", - "phf_codegen", - "precomputed-hash", - "servo_arc", - "smallvec", - "thin-slice", -] - -[[package]] -name = "semver" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" -dependencies = [ - "semver-parser", -] - -[[package]] -name = "semver" -version = "1.0.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58bc9567378fc7690d6b2addae4e60ac2eeea07becb2c64b9f218b53865cba2a" -dependencies = [ - "serde", -] - -[[package]] -name = "semver-parser" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" -dependencies = [ - "pest", -] - -[[package]] -name = "serde" -version = "1.0.152" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb7d1f0d3021d347a83e556fc4683dea2ea09d87bccdf88ff5c12545d89d5efb" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.152" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af487d118eecd09402d70a5d72551860e788df87b464af30e5ea6a38c75c541e" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7434af0dc1cbd59268aa98b4c22c131c0584d2232f6fb166efb993e2832e896a" -dependencies = [ - "itoa 1.0.5", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a5ec9fa74a20ebbe5d9ac23dac1fc96ba0ecfe9f50f2843b52e537b10fbcb4e" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa 1.0.5", - "ryu", - "serde", -] - -[[package]] -name = "serde_with" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" -dependencies = [ - "serde", - "serde_with_macros", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serialize-to-javascript" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9823f2d3b6a81d98228151fdeaf848206a7855a7a042bbf9bf870449a66cafb" -dependencies = [ - "serde", - "serde_json", - "serialize-to-javascript-impl", -] - -[[package]] -name = "serialize-to-javascript-impl" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74064874e9f6a15f04c1f3cb627902d0e6b410abbf36668afa873c61889f1763" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "servo_arc" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d98238b800e0d1576d8b6e3de32827c2d74bee68bb97748dcf5071fb53965432" -dependencies = [ - "nodrop", - "stable_deref_trait", -] - -[[package]] -name = "sha1" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f04293dc80c3993519f2d7f6f511707ee7094fe0c6d3406feb330cdb3540eba3" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sha2" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sharded-slab" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31" -dependencies = [ - "lazy_static", -] - -[[package]] -name = "shared_child" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0d94659ad3c2137fef23ae75b03d5241d633f8acded53d672decfa0e6e0caef" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "siphasher" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de" - -[[package]] -name = "slab" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4614a76b2a8be0058caa9dbbaf66d988527d86d003c11a94fbd335d7661edcef" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" - -[[package]] -name = "socket2" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02e2d2db9033d13a1567121ddd7a095ee144db4e1ca1b1bda3419bc0da294ebd" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "soup3" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82bc46048125fefd69d30b32b9d263d6556c9ffe82a7a7df181a86d912da5616" -dependencies = [ - "bitflags", - "futures-channel", - "gio", - "glib", - "libc", - "once_cell", - "soup3-sys", -] - -[[package]] -name = "soup3-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "014bbeb1c4cdb30739dc181e8d98b7908f124d9555843afa89b5570aaf4ec62b" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "stable_deref_trait" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" - -[[package]] -name = "state" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe866e1e51e8260c9eed836a042a5e7f6726bb2b411dffeaa712e19c388f23b" -dependencies = [ - "loom", -] - -[[package]] -name = "static_assertions" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" - -[[package]] -name = "str-buf" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e08d8363704e6c71fc928674353e6b7c23dcea9d82d7012c8faf2a3a025f8d0" - -[[package]] -name = "string_cache" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "213494b7a2b503146286049378ce02b482200519accc31872ee8be91fa820a08" -dependencies = [ - "new_debug_unreachable", - "once_cell", - "parking_lot", - "phf_shared 0.10.0", - "precomputed-hash", - "serde", -] - -[[package]] -name = "string_cache_codegen" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bb30289b722be4ff74a408c3cc27edeaad656e06cb1fe8fa9231fa59c728988" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro2", - "quote", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "strum" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7ac893c7d471c8a21f31cfe213ec4f6d9afeed25537c772e08ef3f005f8729e" -dependencies = [ - "strum_macros", -] - -[[package]] -name = "strum_macros" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "339f799d8b549e3744c7ac7feb216383e4005d94bdb22561b3ab8f3b808ae9fb" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "subtle" -version = "2.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" - -[[package]] -name = "swift-rs" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fa67d647176dfa7bdc5775430a1cb339e0ea48fe24707424023a4b17eb9688e" -dependencies = [ - "base64 0.21.0", - "serde", - "serde_json", -] - -[[package]] -name = "syn" -version = "1.0.107" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f4064b5b16e03ae50984a5a8ed5d4f8803e6bc1fd170a3cda91a1be4b18e3f5" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-deps" -version = "6.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2955b1fe31e1fa2fbd1976b71cc69a606d7d4da16f6de3333d0c92d51419aeff" -dependencies = [ - "cfg-expr", - "heck 0.4.1", - "pkg-config", - "toml", - "version-compare", -] - -[[package]] -name = "tao" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "389820c5cd5279ffdde7729baa9cf4db20e9936e11b1e171a20fb74babe3a6d3" -dependencies = [ - "bitflags", - "cairo-rs", - "cc", - "cocoa", - "core-foundation", - "core-graphics", - "crossbeam-channel", - "dirs-next", - "dispatch", - "gdk", - "gdk-pixbuf", - "gdk-sys", - "gdkwayland-sys", - "gdkx11-sys", - "gio", - "glib", - "glib-sys", - "gtk", - "image", - "instant", - "jni", - "lazy_static", - "libappindicator", - "libc", - "log", - "ndk", - "ndk-context", - "ndk-sys", - "objc", - "once_cell", - "parking_lot", - "png", - "raw-window-handle", - "scopeguard", - "serde", - "tao-macros", - "unicode-segmentation", - "uuid", - "windows 0.44.0", - "windows-implement", - "x11-dl", -] - -[[package]] -name = "tao-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b27a4bcc5eb524658234589bdffc7e7bfb996dbae6ce9393bfd39cb4159b445" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tar" -version = "0.4.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b55807c0344e1e6c04d7c965f5289c39a8d94ae23ed5c0b57aabac549f871c6" -dependencies = [ - "filetime", - "libc", - "xattr", -] - -[[package]] -name = "tauri" -version = "2.0.0-alpha.8" -source = "git+https://github.com/tauri-apps/tauri?branch=next#256c30c72b737e49ced0d6a6483910dc779fc185" -dependencies = [ - "anyhow", - "base64 0.21.0", - "bytes", - "cocoa", - "dirs-next", - "embed_plist", - "encoding_rs", - "flate2", - "futures-util", - "glib", - "glob", - "gtk", - "heck 0.4.1", - "http", - "ico 0.2.0", - "ignore", - "infer 0.9.0", - "jni", - "libc", - "log", - "minisign-verify", - "objc", - "once_cell", - "os_info", - "percent-encoding", - "png", - "rand 0.8.5", - "raw-window-handle", - "reqwest", - "semver 1.0.16", - "serde", - "serde_json", - "serde_repr", - "serialize-to-javascript", - "state", - "swift-rs", - "tar", - "tauri-build", - "tauri-macros", - "tauri-runtime", - "tauri-runtime-wry", - "tauri-utils", - "tempfile", - "thiserror", - "time", - "tokio", - "url", - "uuid", - "webkit2gtk", - "webview2-com", - "windows 0.44.0", - "zip", -] - -[[package]] -name = "tauri-build" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#256c30c72b737e49ced0d6a6483910dc779fc185" -dependencies = [ - "anyhow", - "cargo_toml", - "filetime", - "heck 0.4.1", - "json-patch", - "quote", - "semver 1.0.16", - "serde", - "serde_json", - "swift-rs", - "tauri-codegen", - "tauri-utils", - "tauri-winres", - "walkdir", -] - -[[package]] -name = "tauri-codegen" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#256c30c72b737e49ced0d6a6483910dc779fc185" -dependencies = [ - "base64 0.21.0", - "brotli", - "ico 0.3.0", - "json-patch", - "plist", - "png", - "proc-macro2", - "quote", - "semver 1.0.16", - "serde", - "serde_json", - "sha2", - "tauri-utils", - "thiserror", - "time", - "url", - "uuid", - "walkdir", -] - -[[package]] -name = "tauri-macros" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#256c30c72b737e49ced0d6a6483910dc779fc185" -dependencies = [ - "heck 0.4.1", - "proc-macro2", - "quote", - "syn", - "tauri-codegen", - "tauri-utils", -] - -[[package]] -name = "tauri-plugin-barcode-scanner" -version = "0.0.0" -dependencies = [ - "log", - "serde", - "serde_json", - "tauri", - "tauri-build", - "thiserror", -] - -[[package]] -name = "tauri-plugin-cli" -version = "0.0.0" -dependencies = [ - "clap", - "log", - "serde", - "serde_json", - "tauri", - "thiserror", -] - -[[package]] -name = "tauri-plugin-clipboard" -version = "0.0.0" -dependencies = [ - "arboard", - "log", - "serde", - "serde_json", - "tauri", - "tauri-build", - "thiserror", -] - -[[package]] -name = "tauri-plugin-dialog" -version = "0.0.0" -dependencies = [ - "glib", - "log", - "raw-window-handle", - "rfd", - "serde", - "serde_json", - "tauri", - "tauri-build", - "thiserror", -] - -[[package]] -name = "tauri-plugin-fs" -version = "0.0.0" -dependencies = [ - "anyhow", - "serde", - "tauri", - "thiserror", -] - -[[package]] -name = "tauri-plugin-global-shortcut" -version = "0.0.0" -dependencies = [ - "global-hotkey", - "log", - "serde", - "serde_json", - "tauri", - "thiserror", -] - -[[package]] -name = "tauri-plugin-http" -version = "0.0.0" -dependencies = [ - "bytes", - "glob", - "http", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "tauri", - "thiserror", -] - -[[package]] -name = "tauri-plugin-log" -version = "0.0.0" -dependencies = [ - "android_logger", - "byte-unit", - "cocoa", - "fern", - "log", - "objc", - "serde", - "serde_json", - "serde_repr", - "swift-rs", - "tauri", - "tauri-build", - "time", -] - -[[package]] -name = "tauri-plugin-notification" -version = "0.1.0" -dependencies = [ - "log", - "notify-rust", - "rand 0.8.5", - "serde", - "serde_json", - "serde_repr", - "tauri", - "tauri-build", - "thiserror", - "time", - "url", - "win7-notifications", -] - -[[package]] -name = "tauri-plugin-shell" -version = "0.0.0" -dependencies = [ - "encoding_rs", - "log", - "open", - "os_pipe", - "regex", - "serde", - "serde_json", - "shared_child", - "tauri", - "thiserror", -] - -[[package]] -name = "tauri-runtime" -version = "0.13.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#256c30c72b737e49ced0d6a6483910dc779fc185" -dependencies = [ - "gtk", - "http", - "http-range", - "jni", - "rand 0.8.5", - "raw-window-handle", - "serde", - "serde_json", - "tauri-utils", - "thiserror", - "url", - "uuid", - "webview2-com", - "windows 0.44.0", -] - -[[package]] -name = "tauri-runtime-wry" -version = "0.13.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#256c30c72b737e49ced0d6a6483910dc779fc185" -dependencies = [ - "cocoa", - "gtk", - "jni", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "tauri-runtime", - "tauri-utils", - "uuid", - "webkit2gtk", - "webview2-com", - "windows 0.44.0", - "wry", -] - -[[package]] -name = "tauri-utils" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#256c30c72b737e49ced0d6a6483910dc779fc185" -dependencies = [ - "aes-gcm", - "brotli", - "ctor", - "getrandom 0.2.8", - "glob", - "heck 0.4.1", - "html5ever", - "infer 0.12.0", - "json-patch", - "kuchiki", - "memchr", - "phf 0.10.1", - "proc-macro2", - "quote", - "semver 1.0.16", - "serde", - "serde_json", - "serde_with", - "serialize-to-javascript", - "thiserror", - "url", - "walkdir", - "windows 0.44.0", -] - -[[package]] -name = "tauri-winres" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b7a78dc04f75fb5ab815e66ac561c81e92a968a40f29e7c21afd152d694fad8" -dependencies = [ - "toml", - "version_check", -] - -[[package]] -name = "tauri-winrt-notification" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c58de036c4d2e20717024de2a3c4bf56c301f07b21bc8ef9b57189fce06f1f3b" -dependencies = [ - "quick-xml 0.23.1", - "strum", - "windows 0.39.0", -] - -[[package]] -name = "tempfile" -version = "3.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cdb1ef4eaeeaddc8fbd371e5017057064af0911902ef36b39801f67cc6d79e4" -dependencies = [ - "cfg-if", - "fastrand", - "libc", - "redox_syscall", - "remove_dir_all", - "winapi", -] - -[[package]] -name = "tendril" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d24a120c5fc464a3458240ee02c299ebcb9d67b5249c8848b09d639dca8d7bb0" -dependencies = [ - "futf", - "mac", - "utf-8", -] - -[[package]] -name = "thin-slice" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c" - -[[package]] -name = "thiserror" -version = "1.0.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a9cd18aa97d5c45c6603caea1da6628790b37f7a34b6ca89522331c5180fed0" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fb327af4685e4d03fa8cbcf1716380da910eeb2bb8be417e7f9fd3fb164f36f" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "thread_local" -version = "1.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5516c27b78311c50bf42c071425c560ac799b11c30b31f87e3081965fe5e0180" -dependencies = [ - "once_cell", -] - -[[package]] -name = "tiff" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7449334f9ff2baf290d55d73983a7d6fa15e01198faef72af07e2a8db851e471" -dependencies = [ - "flate2", - "jpeg-decoder", - "weezl", -] - -[[package]] -name = "time" -version = "0.3.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd0cbfecb4d19b5ea75bb31ad904eb5b9fa13f21079c3b92017ebdf4999a5890" -dependencies = [ - "itoa 1.0.5", - "libc", - "num_threads", - "serde", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd" - -[[package]] -name = "time-macros" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd80a657e71da814b8e5d60d3374fc6d35045062245d80224748ae522dd76f36" -dependencies = [ - "time-core", -] - -[[package]] -name = "tiny_http" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0d6ef4e10d23c1efb862eecad25c5054429a71958b4eeef85eb5e7170b477ca" -dependencies = [ - "ascii", - "chunked_transfer", - "log", - "time", - "url", -] - -[[package]] -name = "tinyvec" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.25.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8e00990ebabbe4c14c08aca901caed183ecd5c09562a12c824bb53d3c3fd3af" -dependencies = [ - "autocfg", - "bytes", - "libc", - "memchr", - "mio", - "num_cpus", - "pin-project-lite", - "socket2", - "windows-sys 0.42.0", -] - -[[package]] -name = "tokio-util" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bb2e075f03b3d66d8d8785356224ba688d2906a371015e225beeb65ca92c740" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", - "tracing", -] - -[[package]] -name = "toml" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_datetime" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4553f467ac8e3d374bc9a177a26801e5d0f9b211aa1673fb137a403afd1c9cf5" - -[[package]] -name = "toml_edit" -version = "0.18.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56c59d8dd7d0dcbc6428bf7aa2f0e823e26e43b3c9aca15bbc9475d23e5fa12b" -dependencies = [ - "indexmap", - "nom8", - "toml_datetime", -] - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" -dependencies = [ - "cfg-if", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tracing-core" -version = "0.1.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" -dependencies = [ - "once_cell", - "valuable", -] - -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - -[[package]] -name = "tracing-subscriber" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6176eae26dd70d0c919749377897b54a9276bd7061339665dd68777926b5a70" -dependencies = [ - "matchers", - "nu-ansi-term", - "once_cell", - "regex", - "sharded-slab", - "smallvec", - "thread_local", - "tracing", - "tracing-core", - "tracing-log", -] - -[[package]] -name = "treediff" -version = "4.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52984d277bdf2a751072b5df30ec0377febdb02f7696d64c2d7d54630bac4303" -dependencies = [ - "serde_json", -] - -[[package]] -name = "try-lock" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" - -[[package]] -name = "typenum" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" - -[[package]] -name = "ucd-trie" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e79c4d996edb816c91e4308506774452e55e95c3c9de07b6729e17e15a5ef81" - -[[package]] -name = "uds_windows" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce65604324d3cce9b966701489fbd0cf318cb1f7bd9dd07ac9a4ee6fb791930d" -dependencies = [ - "tempfile", - "winapi", -] - -[[package]] -name = "unicase" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50f37be617794602aabbeee0be4f259dc1778fabe05e2d67ee8f79326d5cb4f6" -dependencies = [ - "version_check", -] - -[[package]] -name = "unicode-bidi" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d54675592c1dbefd78cbd98db9bacd89886e1ca50692a0692baefffdeb92dd58" - -[[package]] -name = "unicode-ident" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84a22b9f218b40614adcb3f4ff08b703773ad44fa9423e4e0d346d5db86e4ebc" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - -[[package]] -name = "universal-hash" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d3160b73c9a19f7e2939a2fdad446c57c1bbbbf4d919d3213ff1267a580d8b5" -dependencies = [ - "crypto-common", - "subtle", -] - -[[package]] -name = "url" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", - "serde", -] - -[[package]] -name = "utf-8" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" - -[[package]] -name = "utf8-width" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5190c9442dcdaf0ddd50f37420417d219ae5261bbf5db120d0f9bab996c9cba1" - -[[package]] -name = "utf8parse" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" - -[[package]] -name = "uuid" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1674845326ee10d37ca60470760d4288a6f80f304007d92e5c53bab78c9cfd79" -dependencies = [ - "getrandom 0.2.8", -] - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "value-bag" -version = "1.0.0-alpha.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2209b78d1249f7e6f3293657c9779fe31ced465df091bbd433a1cf88e916ec55" -dependencies = [ - "ctor", - "version_check", -] - -[[package]] -name = "version-compare" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "579a42fc0b8e0c63b76519a339be31bed574929511fa53c1a3acae26eb258f29" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "waker-fn" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d5b2c62b4012a3e1eca5a7e077d13b3bf498c4073e33ccd58626607748ceeca" - -[[package]] -name = "walkdir" -version = "2.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "808cf2735cd4b6866113f648b791c6adc5714537bc222d9347bb203386ffda56" -dependencies = [ - "same-file", - "winapi", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" -dependencies = [ - "log", - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f219e0d211ba40266969f6dbdd90636da12f75bee4fc9d6c23d1260dadb51454" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" - -[[package]] -name = "wasm-streams" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bbae3363c08332cadccd13b67db371814cd214c2524020932f0804b8cf7c078" -dependencies = [ - "futures-util", - "js-sys", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", -] - -[[package]] -name = "web-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "webkit2gtk" -version = "0.19.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8eea819afe15eb8dcdff4f19d8bfda540bae84d874c10e6f4b8faf2d6704bd1" -dependencies = [ - "bitflags", - "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 = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0ac7a95ddd3fdfcaf83d8e513b4b1ad101b95b413b6aa6662ed95f284fc3d5b" -dependencies = [ - "bitflags", - "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 = "webview2-com" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03411e89ec447e29c08b3c086edeb88c5f8fd782cbdd4d6d316bea439be7a244" -dependencies = [ - "webview2-com-macros", - "webview2-com-sys", - "windows 0.44.0", - "windows-implement", -] - -[[package]] -name = "webview2-com-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaebe196c01691db62e9e4ca52c5ef1e4fd837dcae27dae3ada599b5a8fd05ac" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "webview2-com-sys" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c0f5ce43e9611c5b2983a33156d6abe31abf39185bad84a6766c80ba1dbf1ab" -dependencies = [ - "regex", - "serde", - "serde_json", - "thiserror", - "windows 0.44.0", - "windows-bindgen", - "windows-metadata", -] - -[[package]] -name = "weezl" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9193164d4de03a926d909d3bc7c30543cecb35400c02114792c2cae20d5e2dbb" - -[[package]] -name = "win7-notifications" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "210952d7163b9ed83a6fd9754ab2a101d14480f8491b5f1d6292771d88dbee70" -dependencies = [ - "once_cell", - "windows-sys 0.36.1", -] - -[[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.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi", -] - -[[package]] -name = "winapi-wsapoll" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44c17110f57155602a80dca10be03852116403c9ff3cd25b079d666f2aa3df6e" -dependencies = [ - "winapi", -] - -[[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-shadows" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29d30320647cfc3dc45554c8ad825b84831def81f967a2f7589931328ff9b16d" -dependencies = [ - "cocoa", - "objc", - "raw-window-handle", - "windows-sys 0.42.0", -] - -[[package]] -name = "windows" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1c4bd0a50ac6020f65184721f758dba47bb9fbc2133df715ec74a237b26794a" -dependencies = [ - "windows_aarch64_msvc 0.39.0", - "windows_i686_gnu 0.39.0", - "windows_i686_msvc 0.39.0", - "windows_x86_64_gnu 0.39.0", - "windows_x86_64_msvc 0.39.0", -] - -[[package]] -name = "windows" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e745dab35a0c4c77aa3ce42d595e13d2003d6902d6b08c9ef5fc326d08da12b" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-targets 0.42.1", -] - -[[package]] -name = "windows-bindgen" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "222204ecf46521382a4d88b4a1bbefca9f8855697b4ab7d20803901425e061a3" -dependencies = [ - "windows-metadata", - "windows-tokens", -] - -[[package]] -name = "windows-implement" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce87ca8e3417b02dc2a8a22769306658670ec92d78f1bd420d6310a67c245c6" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "windows-interface" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "853f69a591ecd4f810d29f17e902d40e349fb05b0b11fff63b08b826bfe39c7f" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "windows-metadata" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee78911e3f4ce32c1ad9d3c7b0bd95389662ad8d8f1a3155688fed70bd96e2b6" - -[[package]] -name = "windows-sys" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea04155a16a59f9eab786fe12a4a450e75cdb175f9e0d80da1e17db09f55b8d2" -dependencies = [ - "windows_aarch64_msvc 0.36.1", - "windows_i686_gnu 0.36.1", - "windows_i686_msvc 0.36.1", - "windows_x86_64_gnu 0.36.1", - "windows_x86_64_msvc 0.36.1", -] - -[[package]] -name = "windows-sys" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" -dependencies = [ - "windows_aarch64_gnullvm 0.42.1", - "windows_aarch64_msvc 0.42.1", - "windows_i686_gnu 0.42.1", - "windows_i686_msvc 0.42.1", - "windows_x86_64_gnu 0.42.1", - "windows_x86_64_gnullvm 0.42.1", - "windows_x86_64_msvc 0.42.1", -] - -[[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.1", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.0", -] - -[[package]] -name = "windows-targets" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e2522491fbfcd58cc84d47aeb2958948c4b8982e9a2d8a2a35bbaed431390e7" -dependencies = [ - "windows_aarch64_gnullvm 0.42.1", - "windows_aarch64_msvc 0.42.1", - "windows_i686_gnu 0.42.1", - "windows_i686_msvc 0.42.1", - "windows_x86_64_gnu 0.42.1", - "windows_x86_64_gnullvm 0.42.1", - "windows_x86_64_msvc 0.42.1", -] - -[[package]] -name = "windows-targets" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b1eb6f0cd7c80c79759c929114ef071b87354ce476d9d94271031c0497adfd5" -dependencies = [ - "windows_aarch64_gnullvm 0.48.0", - "windows_aarch64_msvc 0.48.0", - "windows_i686_gnu 0.48.0", - "windows_i686_msvc 0.48.0", - "windows_x86_64_gnu 0.48.0", - "windows_x86_64_gnullvm 0.48.0", - "windows_x86_64_msvc 0.48.0", -] - -[[package]] -name = "windows-tokens" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa4251900975a0d10841c5d4bde79c56681543367ef811f3fabb8d1803b0959b" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c9864e83243fdec7fc9c5444389dcbbfd258f745e7853198f365e3c4968a608" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bb8c3fd39ade2d67e9874ac4f3db21f0d710bee00fe7cab16949ec184eeaa47" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec7711666096bd4096ffa835238905bb33fb87267910e154b18b44eaabb340f2" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8b1b673ffc16c47a9ff48570a9d85e25d265735c503681332589af6253c6c7" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" - -[[package]] -name = "windows_i686_gnu" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "180e6ccf01daf4c426b846dfc66db1fc518f074baa793aa7d9b9aaeffad6a3b6" - -[[package]] -name = "windows_i686_gnu" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "763fc57100a5f7042e3057e7e8d9bdd7860d330070251a73d003563a3bb49e1b" - -[[package]] -name = "windows_i686_gnu" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3887528ad530ba7bdbb1faa8275ec7a1155a45ffa57c37993960277145d640" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" - -[[package]] -name = "windows_i686_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2e7917148b2812d1eeafaeb22a97e4813dfa60a3f8f78ebe204bcc88f12f024" - -[[package]] -name = "windows_i686_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bc7cbfe58828921e10a9f446fcaaf649204dcfe6c1ddd712c5eebae6bda1106" - -[[package]] -name = "windows_i686_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf4d1122317eddd6ff351aa852118a2418ad4214e6613a50e0191f7004372605" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dcd171b8776c41b97521e5da127a2d86ad280114807d0b2ab1e462bc764d9e1" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6868c165637d653ae1e8dc4d82c25d4f97dd6605eaa8d784b5c6e0ab2a252b65" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1040f221285e17ebccbc2591ffdc2d44ee1f9186324dd3e84e99ac68d699c45" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "628bfdf232daa22b0d64fdb62b09fcc36bb01f05a3939e20ab73aaf9470d0463" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c811ca4a8c853ef420abd8592ba53ddbbac90410fab6903b3e79972a631f7680" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e4d40883ae9cae962787ca76ba76390ffa29214667a111db9e0a1ad8377e809" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "447660ad36a13288b1db4d4248e857b510e8c3a225c822ba4fb748c0aafecffd" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" - -[[package]] -name = "winreg" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d0f4e272c85def139476380b12f9ac60926689dd2e01d4923222f40580869d" -dependencies = [ - "winapi", -] - -[[package]] -name = "wry" -version = "0.28.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d15f9f827d537cefe6d047be3930f5d89b238dfb85e08ba6a319153217635aa" -dependencies = [ - "base64 0.13.1", - "block", - "cocoa", - "core-graphics", - "crossbeam-channel", - "dunce", - "gdk", - "gio", - "glib", - "gtk", - "html5ever", - "http", - "javascriptcore-rs", - "kuchiki", - "libc", - "log", - "objc", - "objc_id", - "once_cell", - "serde", - "serde_json", - "sha2", - "soup3", - "tao", - "thiserror", - "url", - "webkit2gtk", - "webkit2gtk-sys", - "webview2-com", - "windows 0.44.0", - "windows-implement", -] - -[[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 = "x11rb" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "592b4883219f345e712b3209c62654ebda0bb50887f330cbd018d0f654bfd507" -dependencies = [ - "gethostname", - "nix 0.24.3", - "winapi", - "winapi-wsapoll", - "x11rb-protocol", -] - -[[package]] -name = "x11rb-protocol" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56b245751c0ac9db0e006dc812031482784e434630205a93c73cfefcaabeac67" -dependencies = [ - "nix 0.24.3", -] - -[[package]] -name = "xattr" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d1526bbe5aaeb5eb06885f4d987bcdfa5e23187055de9b83fe00156a821fabc" -dependencies = [ - "libc", -] - -[[package]] -name = "zbus" -version = "3.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dc29e76f558b2cb94190e8605ecfe77dd40f5df8c072951714b4b71a97f5848" -dependencies = [ - "async-broadcast", - "async-executor", - "async-fs", - "async-io", - "async-lock", - "async-recursion", - "async-task", - "async-trait", - "byteorder", - "derivative", - "dirs", - "enumflags2", - "event-listener", - "futures-core", - "futures-sink", - "futures-util", - "hex", - "nix 0.26.2", - "once_cell", - "ordered-stream", - "rand 0.8.5", - "serde", - "serde_repr", - "sha1", - "static_assertions", - "tracing", - "uds_windows", - "winapi", - "zbus_macros", - "zbus_names", - "zvariant", -] - -[[package]] -name = "zbus_macros" -version = "3.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62a80fd82c011cd08459eaaf1fd83d3090c1b61e6d5284360074a7475af3a85d" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "regex", - "syn", - "zvariant_utils", -] - -[[package]] -name = "zbus_names" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f34f314916bd89bdb9934154627fab152f4f28acdda03e7c4c68181b214fe7e3" -dependencies = [ - "serde", - "static_assertions", - "zvariant", -] - -[[package]] -name = "zip" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0445d0fbc924bb93539b4316c11afb121ea39296f99a3c4c9edad09e3658cdef" -dependencies = [ - "byteorder", - "crc32fast", - "crossbeam-utils", -] - -[[package]] -name = "zvariant" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46fe4914a985446d6fd287019b5fceccce38303d71407d9e6e711d44954a05d8" -dependencies = [ - "byteorder", - "enumflags2", - "libc", - "serde", - "static_assertions", - "zvariant_derive", -] - -[[package]] -name = "zvariant_derive" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34c20260af4b28b3275d6676c7e2a6be0d4332e8e0aba4616d34007fd84e462a" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", - "zvariant_utils", -] - -[[package]] -name = "zvariant_utils" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53b22993dbc4d128a17a3b6c92f1c63872dd67198537ee728d8b5d7c40640a8b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] diff --git a/examples/api/src-tauri/Cargo.toml b/examples/api/src-tauri/Cargo.toml index 3cfc0a77..cf30b3a8 100644 --- a/examples/api/src-tauri/Cargo.toml +++ b/examples/api/src-tauri/Cargo.toml @@ -1,49 +1,50 @@ [package] name = "api" -version = "0.1.0" +publish = false +version = "2.0.0-alpha.1" description = "An example Tauri Application showcasing the api" edition = "2021" -rust-version = "1.64" +rust-version = "1.65" license = "Apache-2.0 OR MIT" [lib] -crate-type = ["staticlib", "cdylib", "rlib"] +crate-type = [ "staticlib", "cdylib", "rlib" ] [build-dependencies] -tauri-build = { version = "2.0.0-alpha.4", features = ["codegen", "isolation"] } +tauri-build = { workspace = true, features = [ "codegen", "isolation" ] } [dependencies] -serde_json = "1.0" -serde = { version = "1.0", features = [ "derive" ] } +serde_json = { workspace = true } +serde = { workspace = true } tiny_http = "0.11" -log = "0.4" -tauri-plugin-log = { path = "../../../plugins/log" } -tauri-plugin-fs = { path = "../../../plugins/fs" } -tauri-plugin-clipboard = { path = "../../../plugins/clipboard" } -tauri-plugin-dialog = { path = "../../../plugins/dialog" } -tauri-plugin-http = { path = "../../../plugins/http", features = [ "http-multipart" ] } -tauri-plugin-notification = { path = "../../../plugins/notification", features = [ "windows7-compat" ] } -tauri-plugin-shell = { path = "../../../plugins/shell" } - -[patch.crates-io] -tauri = { git = "https://github.com/tauri-apps/tauri", branch = "next" } -tauri-build = { git = "https://github.com/tauri-apps/tauri", branch = "next" } - -[dependencies.tauri] -version = "2.0.0-alpha.8" -features = [ - "api-all", +log = { workspace = true } +tauri-plugin-app = { path = "../../../plugins/app", version = "2.0.0-alpha.0" } +tauri-plugin-log = { path = "../../../plugins/log", version = "2.0.0-alpha.0" } +tauri-plugin-fs = { path = "../../../plugins/fs", version = "2.0.0-alpha.0" } +tauri-plugin-clipboard-manager = { path = "../../../plugins/clipboard-manager", version = "2.0.0-alpha.0" } +tauri-plugin-dialog = { path = "../../../plugins/dialog", version = "2.0.0-alpha.0" } +tauri-plugin-http = { path = "../../../plugins/http", features = [ "multipart" ], version = "2.0.0-alpha.0" } +tauri-plugin-notification = { path = "../../../plugins/notification", version = "2.0.0-alpha.0", features = [ "windows7-compat" ] } +tauri-plugin-os = { path = "../../../plugins/os", version = "2.0.0-alpha.0" } +tauri-plugin-process = { path = "../../../plugins/process", version = "2.0.0-alpha.0" } +tauri-plugin-shell = { path = "../../../plugins/shell", version = "2.0.0-alpha.0" } +tauri-plugin-window = { path = "../../../plugins/window", version = "2.0.0-alpha.0", features = [ "devtools", "icon-ico", "icon-png" ] } + + [dependencies.tauri] + workspace = true + features = [ "icon-ico", "icon-png", "isolation", "macos-private-api", "system-tray", - "updater" + "protocol-asset" ] [target."cfg(any(target_os = \"macos\", windows, target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"openbsd\", target_os = \"netbsd\"))".dependencies] -tauri-plugin-cli = { path = "../../../plugins/cli" } -tauri-plugin-global-shortcut = { path = "../../../plugins/global-shortcut" } +tauri-plugin-cli = { path = "../../../plugins/cli", version = "2.0.0-alpha.0" } +tauri-plugin-global-shortcut = { path = "../../../plugins/global-shortcut", version = "2.0.0-alpha.0" } +tauri-plugin-updater = { path = "../../../plugins/updater", version = "2.0.0-alpha.0" } [target."cfg(any(target_os = \"android\", target_os = \"ios\"))".dependencies] tauri-plugin-barcode-scanner = { path = "../../../plugins/barcode-scanner" } @@ -53,11 +54,3 @@ window-shadows = "0.2" [features] custom-protocol = [ "tauri/custom-protocol" ] - -# default to small, optimized release binaries -[profile.release] -panic = "abort" -codegen-units = 1 -lto = true -incremental = false -opt-level = "s" diff --git a/examples/api/src-tauri/build.rs b/examples/api/src-tauri/build.rs index 2154ff35..e9f99b29 100644 --- a/examples/api/src-tauri/build.rs +++ b/examples/api/src-tauri/build.rs @@ -3,10 +3,10 @@ // SPDX-License-Identifier: MIT fn main() { - let mut codegen = tauri_build::CodegenContext::new(); - if !cfg!(feature = "custom-protocol") { - codegen = codegen.dev(); - } - codegen.build(); - tauri_build::build(); + let mut codegen = tauri_build::CodegenContext::new(); + if !cfg!(feature = "custom-protocol") { + codegen = codegen.dev(); + } + codegen.build(); + tauri_build::build(); } diff --git a/examples/api/src-tauri/gen/android/api/.editorconfig b/examples/api/src-tauri/gen/android/.editorconfig similarity index 100% rename from examples/api/src-tauri/gen/android/api/.editorconfig rename to examples/api/src-tauri/gen/android/.editorconfig diff --git a/examples/api/src-tauri/gen/android/api/.gitignore b/examples/api/src-tauri/gen/android/.gitignore similarity index 75% rename from examples/api/src-tauri/gen/android/api/.gitignore rename to examples/api/src-tauri/gen/android/.gitignore index 78823267..66d83e91 100644 --- a/examples/api/src-tauri/gen/android/api/.gitignore +++ b/examples/api/src-tauri/gen/android/.gitignore @@ -8,6 +8,7 @@ build .externalNativeBuild .cxx local.properties +key.properties /.tauri /tauri.settings.gradle \ No newline at end of file diff --git a/examples/api/src-tauri/gen/android/api/app/build.gradle.kts b/examples/api/src-tauri/gen/android/api/app/build.gradle.kts deleted file mode 100644 index 7a18b94b..00000000 --- a/examples/api/src-tauri/gen/android/api/app/build.gradle.kts +++ /dev/null @@ -1,113 +0,0 @@ -plugins { - id("com.android.application") - id("org.jetbrains.kotlin.android") - id("rustPlugin") -} - -android { - compileSdk = 33 - defaultConfig { - manifestPlaceholders["usesCleartextTraffic"] = "false" - applicationId = "com.tauri.api" - minSdk = 24 - targetSdk = 33 - versionCode = 1 - versionName = "1.0" - } - sourceSets.getByName("main") { - // Vulkan validation layers - val ndkHome = System.getenv("NDK_HOME") - jniLibs.srcDir("${ndkHome}/sources/third_party/vulkan/src/build-android/jniLibs") - } - buildTypes { - getByName("debug") { - manifestPlaceholders["usesCleartextTraffic"] = "true" - isDebuggable = true - isJniDebuggable = true - isMinifyEnabled = false - packagingOptions { jniLibs.keepDebugSymbols.add("*/arm64-v8a/*.so") - jniLibs.keepDebugSymbols.add("*/armeabi-v7a/*.so") - jniLibs.keepDebugSymbols.add("*/x86/*.so") - jniLibs.keepDebugSymbols.add("*/x86_64/*.so") - } - } - getByName("release") { - isMinifyEnabled = true - val proguards = fileTree(".") { - include("*.pro") - } - proguardFiles(*proguards.toList().toTypedArray()) - } - } - flavorDimensions.add("abi") - productFlavors { - create("universal") { - dimension = "abi" - ndk { - abiFilters += (findProperty("abiList") as? String)?.split(",") ?: listOf( "arm64-v8a", "armeabi-v7a", "x86", "x86_64", - ) - } - } - create("arm64") { - dimension = "abi" - ndk { - abiFilters += listOf("arm64-v8a") - } - } - - create("arm") { - dimension = "abi" - ndk { - abiFilters += listOf("armeabi-v7a") - } - } - - create("x86") { - dimension = "abi" - ndk { - abiFilters += listOf("x86") - } - } - - create("x86_64") { - dimension = "abi" - ndk { - abiFilters += listOf("x86_64") - } - } - } - - assetPacks += mutableSetOf() - namespace = "com.tauri.api" -} - -rust { - rootDirRel = "../../../../" - targets = (findProperty("targetList") as? String)?.split(",") ?: listOf("aarch64", "armv7", "i686", "x86_64") - arches = (findProperty("archList") as? String)?.split(",") ?: listOf("arm64", "arm", "x86", "x86_64") -} - -dependencies { - implementation("androidx.webkit:webkit:1.5.0") - implementation("androidx.appcompat:appcompat:1.5.1") - implementation("com.google.android.material:material:1.7.0") - testImplementation("junit:junit:4.13.2") - androidTestImplementation("androidx.test.ext:junit:1.1.4") - androidTestImplementation("androidx.test.espresso:espresso-core:3.5.0") - implementation(project(":tauri-android")) -} - -apply(from = "tauri.build.gradle.kts") - -afterEvaluate { - android.applicationVariants.all { - tasks["mergeUniversalReleaseJniLibFolders"].dependsOn(tasks["rustBuildRelease"]) - tasks["mergeUniversalDebugJniLibFolders"].dependsOn(tasks["rustBuildDebug"]) - if (findProperty("targetList") == null) { - productFlavors.filter{ it.name != "universal" }.forEach { _ -> - val archAndBuildType = name.capitalize() - tasks["merge${archAndBuildType}JniLibFolders"].dependsOn(tasks["rustBuild${archAndBuildType}"]) - } - } - } -} diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/java/com/tauri/api/MainActivity.kt b/examples/api/src-tauri/gen/android/api/app/src/main/java/com/tauri/api/MainActivity.kt deleted file mode 100644 index c8d7f82b..00000000 --- a/examples/api/src-tauri/gen/android/api/app/src/main/java/com/tauri/api/MainActivity.kt +++ /dev/null @@ -1,4 +0,0 @@ -package com.tauri.api - -class MainActivity : TauriActivity() { -} diff --git a/examples/api/src-tauri/gen/android/api/build.gradle.kts b/examples/api/src-tauri/gen/android/api/build.gradle.kts deleted file mode 100644 index 8c6fe584..00000000 --- a/examples/api/src-tauri/gen/android/api/build.gradle.kts +++ /dev/null @@ -1,25 +0,0 @@ -// Top-level build file where you can add configuration options common to all sub-projects/modules. -buildscript { - repositories { - google() - mavenCentral() - } - dependencies { - classpath("com.android.tools.build:gradle:7.3.1") - classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.10") - // NOTE: Do not place your application dependencies here; they belong - // in the individual module build.gradle files - } -} - -allprojects { - repositories { - google() - mavenCentral() - } -} - -tasks.register("clean").configure { - delete("build") -} - diff --git a/examples/api/src-tauri/gen/android/api/buildSrc/build.gradle.kts b/examples/api/src-tauri/gen/android/api/buildSrc/build.gradle.kts deleted file mode 100644 index 73058dd7..00000000 --- a/examples/api/src-tauri/gen/android/api/buildSrc/build.gradle.kts +++ /dev/null @@ -1,23 +0,0 @@ -plugins { - `kotlin-dsl` -} - -gradlePlugin { - plugins { - create("pluginsForCoolKids") { - id = "rustPlugin" - implementationClass = "com.tauri.RustPlugin" - } - } -} - -repositories { - google() - mavenCentral() -} - -dependencies { - compileOnly(gradleApi()) - implementation("com.android.tools.build:gradle:7.3.1") -} - diff --git a/examples/api/src-tauri/gen/android/api/buildSrc/src/main/java/com/tauri/api/kotlin/RustPlugin.kt b/examples/api/src-tauri/gen/android/api/buildSrc/src/main/java/com/tauri/api/kotlin/RustPlugin.kt deleted file mode 100644 index 064fc632..00000000 --- a/examples/api/src-tauri/gen/android/api/buildSrc/src/main/java/com/tauri/api/kotlin/RustPlugin.kt +++ /dev/null @@ -1,59 +0,0 @@ -package com.tauri - -import org.gradle.api.DefaultTask -import org.gradle.api.GradleException -import org.gradle.api.Plugin -import org.gradle.api.Project -import java.io.File -import java.util.* - -const val TASK_GROUP = "rust" - -open class Config { - var rootDirRel: String? = null - var targets: List? = null - var arches: List? = null -} - -open class RustPlugin : Plugin { - private lateinit var config: Config - - override fun apply(project: Project) { - config = project.extensions.create("rust", Config::class.java) - project.afterEvaluate { - if (config.targets == null) { - throw GradleException("targets cannot be null") - } - if (config.arches == null) { - throw GradleException("arches cannot be null") - } - for (profile in listOf("debug", "release")) { - val profileCapitalized = profile.capitalize(Locale.ROOT) - val buildTask = project.tasks.maybeCreate( - "rustBuild$profileCapitalized", - DefaultTask::class.java - ).apply { - group = TASK_GROUP - description = "Build dynamic library in $profile mode for all targets" - } - for (targetPair in config.targets!!.withIndex()) { - val targetName = targetPair.value - val targetArch = config.arches!![targetPair.index] - val targetArchCapitalized = targetArch.capitalize(Locale.ROOT) - val targetBuildTask = project.tasks.maybeCreate( - "rustBuild$targetArchCapitalized$profileCapitalized", - BuildTask::class.java - ).apply { - group = TASK_GROUP - description = "Build dynamic library in $profile mode for $targetArch" - rootDirRel = config.rootDirRel?.let { File(it) } - target = targetName - release = profile == "release" - } - buildTask.dependsOn(targetBuildTask) - project.tasks.findByName("preBuild")?.mustRunAfter(targetBuildTask) - } - } - } - } -} diff --git a/examples/api/src-tauri/gen/android/api/settings.gradle b/examples/api/src-tauri/gen/android/api/settings.gradle deleted file mode 100644 index b179eac8..00000000 --- a/examples/api/src-tauri/gen/android/api/settings.gradle +++ /dev/null @@ -1,6 +0,0 @@ -include ':app' - -include ':tauri-android' -project(':tauri-android').projectDir = new File('./.tauri/tauri-api') - -apply from: 'tauri.settings.gradle' diff --git a/examples/api/src-tauri/gen/android/api/app/.gitignore b/examples/api/src-tauri/gen/android/app/.gitignore similarity index 63% rename from examples/api/src-tauri/gen/android/api/app/.gitignore rename to examples/api/src-tauri/gen/android/app/.gitignore index 3b9e0a22..ff9cb538 100644 --- a/examples/api/src-tauri/gen/android/api/app/.gitignore +++ b/examples/api/src-tauri/gen/android/app/.gitignore @@ -1,4 +1,5 @@ /src/main/java/com/tauri/api/generated /src/main/jniLibs/**/*.so +/src/main/assets/tauri.conf.json /tauri.build.gradle.kts /proguard-tauri.pro \ No newline at end of file diff --git a/examples/api/src-tauri/gen/android/app/build.gradle.kts b/examples/api/src-tauri/gen/android/app/build.gradle.kts new file mode 100644 index 00000000..e3de36fd --- /dev/null +++ b/examples/api/src-tauri/gen/android/app/build.gradle.kts @@ -0,0 +1,57 @@ +plugins { + id("com.android.application") + id("org.jetbrains.kotlin.android") + id("rust") +} + +android { + compileSdk = 33 + namespace = "com.tauri.api" + defaultConfig { + manifestPlaceholders["usesCleartextTraffic"] = "false" + applicationId = "com.tauri.api" + minSdk = 24 + targetSdk = 33 + versionCode = 1 + versionName = "1.0" + } + buildTypes { + getByName("debug") { + manifestPlaceholders["usesCleartextTraffic"] = "true" + isDebuggable = true + isJniDebuggable = true + isMinifyEnabled = false + packaging { jniLibs.keepDebugSymbols.add("*/arm64-v8a/*.so") + jniLibs.keepDebugSymbols.add("*/armeabi-v7a/*.so") + jniLibs.keepDebugSymbols.add("*/x86/*.so") + jniLibs.keepDebugSymbols.add("*/x86_64/*.so") + } + } + getByName("release") { + isMinifyEnabled = true + proguardFiles( + *fileTree(".") { include("**/*.pro") } + .plus(getDefaultProguardFile("proguard-android-optimize.txt")) + .toList().toTypedArray() + ) + } + } + kotlinOptions { + jvmTarget = "1.8" + } +} + +rust { + rootDirRel = "../../../" +} + +dependencies { + implementation("androidx.webkit:webkit:1.6.1") + implementation("androidx.appcompat:appcompat:1.6.1") + implementation("com.google.android.material:material:1.8.0") + testImplementation("junit:junit:4.13.2") + androidTestImplementation("androidx.test.ext:junit:1.1.4") + androidTestImplementation("androidx.test.espresso:espresso-core:3.5.0") +} + +apply(from = "tauri.build.gradle.kts") diff --git a/examples/api/src-tauri/gen/android/api/app/proguard-rules.pro b/examples/api/src-tauri/gen/android/app/proguard-rules.pro similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/proguard-rules.pro rename to examples/api/src-tauri/gen/android/app/proguard-rules.pro diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/AndroidManifest.xml b/examples/api/src-tauri/gen/android/app/src/main/AndroidManifest.xml similarity index 99% rename from examples/api/src-tauri/gen/android/api/app/src/main/AndroidManifest.xml rename to examples/api/src-tauri/gen/android/app/src/main/AndroidManifest.xml index 13dcbd14..6ad2d210 100644 --- a/examples/api/src-tauri/gen/android/api/app/src/main/AndroidManifest.xml +++ b/examples/api/src-tauri/gen/android/app/src/main/AndroidManifest.xml @@ -14,7 +14,6 @@ android:exported="true"> - diff --git a/examples/api/src-tauri/gen/android/app/src/main/java/com/tauri/api/MainActivity.kt b/examples/api/src-tauri/gen/android/app/src/main/java/com/tauri/api/MainActivity.kt new file mode 100644 index 00000000..ad3fa238 --- /dev/null +++ b/examples/api/src-tauri/gen/android/app/src/main/java/com/tauri/api/MainActivity.kt @@ -0,0 +1,3 @@ +package com.tauri.api + +class MainActivity : TauriActivity() diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/drawable-v24/ic_launcher_foreground.xml b/examples/api/src-tauri/gen/android/app/src/main/res/drawable-v24/ic_launcher_foreground.xml similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/drawable-v24/ic_launcher_foreground.xml rename to examples/api/src-tauri/gen/android/app/src/main/res/drawable-v24/ic_launcher_foreground.xml diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/drawable/ic_launcher_background.xml b/examples/api/src-tauri/gen/android/app/src/main/res/drawable/ic_launcher_background.xml similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/drawable/ic_launcher_background.xml rename to examples/api/src-tauri/gen/android/app/src/main/res/drawable/ic_launcher_background.xml diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/layout/activity_main.xml b/examples/api/src-tauri/gen/android/app/src/main/res/layout/activity_main.xml similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/layout/activity_main.xml rename to examples/api/src-tauri/gen/android/app/src/main/res/layout/activity_main.xml diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-hdpi/ic_launcher.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-hdpi/ic_launcher.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-hdpi/ic_launcher.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-hdpi/ic_launcher.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-hdpi/ic_launcher_round.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-hdpi/ic_launcher_round.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-mdpi/ic_launcher.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-mdpi/ic_launcher.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-mdpi/ic_launcher.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-mdpi/ic_launcher.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-mdpi/ic_launcher_round.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-mdpi/ic_launcher_round.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xhdpi/ic_launcher.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxhdpi/ic_launcher.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png b/examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png rename to examples/api/src-tauri/gen/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/values-night/themes.xml b/examples/api/src-tauri/gen/android/app/src/main/res/values-night/themes.xml similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/values-night/themes.xml rename to examples/api/src-tauri/gen/android/app/src/main/res/values-night/themes.xml diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/values/colors.xml b/examples/api/src-tauri/gen/android/app/src/main/res/values/colors.xml similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/values/colors.xml rename to examples/api/src-tauri/gen/android/app/src/main/res/values/colors.xml diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/values/strings.xml b/examples/api/src-tauri/gen/android/app/src/main/res/values/strings.xml similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/values/strings.xml rename to examples/api/src-tauri/gen/android/app/src/main/res/values/strings.xml diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/values/themes.xml b/examples/api/src-tauri/gen/android/app/src/main/res/values/themes.xml similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/values/themes.xml rename to examples/api/src-tauri/gen/android/app/src/main/res/values/themes.xml diff --git a/examples/api/src-tauri/gen/android/api/app/src/main/res/xml/file_paths.xml b/examples/api/src-tauri/gen/android/app/src/main/res/xml/file_paths.xml similarity index 100% rename from examples/api/src-tauri/gen/android/api/app/src/main/res/xml/file_paths.xml rename to examples/api/src-tauri/gen/android/app/src/main/res/xml/file_paths.xml diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/build.gradle.kts b/examples/api/src-tauri/gen/android/build.gradle.kts similarity index 51% rename from plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/build.gradle.kts rename to examples/api/src-tauri/gen/android/build.gradle.kts index 8c6fe584..5ce764e3 100644 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/build.gradle.kts +++ b/examples/api/src-tauri/gen/android/build.gradle.kts @@ -1,14 +1,11 @@ -// Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { repositories { google() mavenCentral() } dependencies { - classpath("com.android.tools.build:gradle:7.3.1") - classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.10") - // NOTE: Do not place your application dependencies here; they belong - // in the individual module build.gradle files + classpath("com.android.tools.build:gradle:8.0.0") + classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.21") } } diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/build.gradle.kts b/examples/api/src-tauri/gen/android/buildSrc/build.gradle.kts similarity index 59% rename from plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/build.gradle.kts rename to examples/api/src-tauri/gen/android/buildSrc/build.gradle.kts index 2713738b..099feff7 100644 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/build.gradle.kts +++ b/examples/api/src-tauri/gen/android/buildSrc/build.gradle.kts @@ -5,8 +5,8 @@ plugins { gradlePlugin { plugins { create("pluginsForCoolKids") { - id = "rustPlugin" - implementationClass = "app.tauri.RustPlugin" + id = "rust" + implementationClass = "RustPlugin" } } } @@ -18,6 +18,6 @@ repositories { dependencies { compileOnly(gradleApi()) - implementation("com.android.tools.build:gradle:7.3.1") + implementation("com.android.tools.build:gradle:8.0.0") } diff --git a/examples/api/src-tauri/gen/android/api/buildSrc/src/main/java/com/tauri/api/kotlin/BuildTask.kt b/examples/api/src-tauri/gen/android/buildSrc/src/main/java/com/tauri/api/kotlin/BuildTask.kt similarity index 79% rename from examples/api/src-tauri/gen/android/api/buildSrc/src/main/java/com/tauri/api/kotlin/BuildTask.kt rename to examples/api/src-tauri/gen/android/buildSrc/src/main/java/com/tauri/api/kotlin/BuildTask.kt index dfc8507e..f9874825 100644 --- a/examples/api/src-tauri/gen/android/api/buildSrc/src/main/java/com/tauri/api/kotlin/BuildTask.kt +++ b/examples/api/src-tauri/gen/android/buildSrc/src/main/java/com/tauri/api/kotlin/BuildTask.kt @@ -1,28 +1,22 @@ -package com.tauri - import java.io.File import org.apache.tools.ant.taskdefs.condition.Os import org.gradle.api.DefaultTask import org.gradle.api.GradleException import org.gradle.api.logging.LogLevel import org.gradle.api.tasks.Input -import org.gradle.api.tasks.InputDirectory -import org.gradle.api.tasks.PathSensitive -import org.gradle.api.tasks.PathSensitivity import org.gradle.api.tasks.TaskAction open class BuildTask : DefaultTask() { - @InputDirectory - @PathSensitive(PathSensitivity.RELATIVE) - var rootDirRel: File? = null + @Input + var rootDirRel: String? = null @Input var target: String? = null @Input var release: Boolean? = null @TaskAction - fun build() { - val executable = """yarn"""; + fun assemble() { + val executable = """pnpm"""; try { runTauriCli(executable) } catch (e: Exception) { @@ -41,7 +35,7 @@ open class BuildTask : DefaultTask() { val args = listOf("tauri", "android", "android-studio-script"); project.exec { - workingDir(File(project.projectDir, rootDirRel.path)) + workingDir(File(project.projectDir, rootDirRel)) executable(executable) args(args) if (project.logger.isEnabled(LogLevel.DEBUG)) { diff --git a/examples/api/src-tauri/gen/android/buildSrc/src/main/java/com/tauri/api/kotlin/RustPlugin.kt b/examples/api/src-tauri/gen/android/buildSrc/src/main/java/com/tauri/api/kotlin/RustPlugin.kt new file mode 100644 index 00000000..4aa7fcaf --- /dev/null +++ b/examples/api/src-tauri/gen/android/buildSrc/src/main/java/com/tauri/api/kotlin/RustPlugin.kt @@ -0,0 +1,85 @@ +import com.android.build.api.dsl.ApplicationExtension +import org.gradle.api.DefaultTask +import org.gradle.api.Plugin +import org.gradle.api.Project +import org.gradle.kotlin.dsl.configure +import org.gradle.kotlin.dsl.get + +const val TASK_GROUP = "rust" + +open class Config { + lateinit var rootDirRel: String +} + +open class RustPlugin : Plugin { + private lateinit var config: Config + + override fun apply(project: Project) = with(project) { + config = extensions.create("rust", Config::class.java) + + val defaultAbiList = listOf("arm64-v8a", "armeabi-v7a", "x86", "x86_64"); + val abiList = (findProperty("abiList") as? String)?.split(',') ?: defaultAbiList + + val defaultArchList = listOf("arm64", "arm", "x86", "x86_64"); + val archList = (findProperty("archList") as? String)?.split(',') ?: defaultArchList + + val targetsList = (findProperty("targetList") as? String)?.split(',') ?: listOf("aarch64", "armv7", "i686", "x86_64") + + extensions.configure { + @Suppress("UnstableApiUsage") + flavorDimensions.add("abi") + productFlavors { + create("universal") { + dimension = "abi" + ndk { + abiFilters += abiList + } + } + defaultArchList.forEachIndexed { index, arch -> + create(arch) { + dimension = "abi" + ndk { + abiFilters.add(defaultAbiList[index]) + } + } + } + } + } + + afterEvaluate { + for (profile in listOf("debug", "release")) { + val profileCapitalized = profile.replaceFirstChar { it.uppercase() } + val buildTask = tasks.maybeCreate( + "rustBuildUniversal$profileCapitalized", + DefaultTask::class.java + ).apply { + group = TASK_GROUP + description = "Build dynamic library in $profile mode for all targets" + } + + tasks["mergeUniversal${profileCapitalized}JniLibFolders"].dependsOn(buildTask) + + for (targetPair in targetsList.withIndex()) { + val targetName = targetPair.value + val targetArch = archList[targetPair.index] + val targetArchCapitalized = targetArch.replaceFirstChar { it.uppercase() } + val targetBuildTask = project.tasks.maybeCreate( + "rustBuild$targetArchCapitalized$profileCapitalized", + BuildTask::class.java + ).apply { + group = TASK_GROUP + description = "Build dynamic library in $profile mode for $targetArch" + rootDirRel = config.rootDirRel + target = targetName + release = profile == "release" + } + + buildTask.dependsOn(targetBuildTask) + tasks["merge$targetArchCapitalized${profileCapitalized}JniLibFolders"].dependsOn( + targetBuildTask + ) + } + } + } + } +} \ No newline at end of file diff --git a/examples/api/src-tauri/gen/android/api/gradle.properties b/examples/api/src-tauri/gen/android/gradle.properties similarity index 92% rename from examples/api/src-tauri/gen/android/api/gradle.properties rename to examples/api/src-tauri/gen/android/gradle.properties index cd0519bb..022338b7 100644 --- a/examples/api/src-tauri/gen/android/api/gradle.properties +++ b/examples/api/src-tauri/gen/android/gradle.properties @@ -20,4 +20,6 @@ kotlin.code.style=official # Enables namespacing of each library's R class so that its R class includes only the # resources declared in the library itself and none from the library's dependencies, # thereby reducing the size of the R class for that library -android.nonTransitiveRClass=true \ No newline at end of file +android.nonTransitiveRClass=true +android.defaults.buildfeatures.buildconfig=true +android.nonFinalResIds=false \ No newline at end of file diff --git a/examples/api/src-tauri/gen/android/api/gradle/wrapper/gradle-wrapper.jar b/examples/api/src-tauri/gen/android/gradle/wrapper/gradle-wrapper.jar similarity index 100% rename from examples/api/src-tauri/gen/android/api/gradle/wrapper/gradle-wrapper.jar rename to examples/api/src-tauri/gen/android/gradle/wrapper/gradle-wrapper.jar diff --git a/examples/api/src-tauri/gen/android/api/gradle/wrapper/gradle-wrapper.properties b/examples/api/src-tauri/gen/android/gradle/wrapper/gradle-wrapper.properties similarity index 93% rename from examples/api/src-tauri/gen/android/api/gradle/wrapper/gradle-wrapper.properties rename to examples/api/src-tauri/gen/android/gradle/wrapper/gradle-wrapper.properties index de8c362b..40a43506 100644 --- a/examples/api/src-tauri/gen/android/api/gradle/wrapper/gradle-wrapper.properties +++ b/examples/api/src-tauri/gen/android/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ #Tue May 10 19:22:52 CST 2022 distributionBase=GRADLE_USER_HOME -distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-bin.zip distributionPath=wrapper/dists zipStorePath=wrapper/dists zipStoreBase=GRADLE_USER_HOME diff --git a/examples/api/src-tauri/gen/android/api/gradlew b/examples/api/src-tauri/gen/android/gradlew similarity index 100% rename from examples/api/src-tauri/gen/android/api/gradlew rename to examples/api/src-tauri/gen/android/gradlew diff --git a/examples/api/src-tauri/gen/android/api/gradlew.bat b/examples/api/src-tauri/gen/android/gradlew.bat similarity index 100% rename from examples/api/src-tauri/gen/android/api/gradlew.bat rename to examples/api/src-tauri/gen/android/gradlew.bat diff --git a/examples/api/src-tauri/gen/android/settings.gradle b/examples/api/src-tauri/gen/android/settings.gradle new file mode 100644 index 00000000..39391166 --- /dev/null +++ b/examples/api/src-tauri/gen/android/settings.gradle @@ -0,0 +1,3 @@ +include ':app' + +apply from: 'tauri.settings.gradle' diff --git a/examples/api/src-tauri/src/lib.rs b/examples/api/src-tauri/src/lib.rs index 3695d12b..378ef5dd 100644 --- a/examples/api/src-tauri/src/lib.rs +++ b/examples/api/src-tauri/src/lib.rs @@ -31,12 +31,16 @@ pub fn run() { .level(log::LevelFilter::Info) .build(), ) + .plugin(tauri_plugin_app::init()) .plugin(tauri_plugin_fs::init()) - .plugin(tauri_plugin_clipboard::init()) + .plugin(tauri_plugin_clipboard_manager::init()) .plugin(tauri_plugin_dialog::init()) .plugin(tauri_plugin_http::init()) .plugin(tauri_plugin_notification::init()) + .plugin(tauri_plugin_os::init()) + .plugin(tauri_plugin_process::init()) .plugin(tauri_plugin_shell::init()) + .plugin(tauri_plugin_window::init()) .setup(move |app| { #[cfg(desktop)] { @@ -44,6 +48,8 @@ pub fn run() { app.handle().plugin(tauri_plugin_cli::init())?; app.handle() .plugin(tauri_plugin_global_shortcut::Builder::new().build())?; + app.handle() + .plugin(tauri_plugin_updater::Builder::new().build())?; } #[cfg(mobile)] diff --git a/examples/api/src-tauri/tauri.conf.json b/examples/api/src-tauri/tauri.conf.json index 741a7e1f..6f5f422d 100644 --- a/examples/api/src-tauri/tauri.conf.json +++ b/examples/api/src-tauri/tauri.conf.json @@ -46,6 +46,45 @@ ] } } + }, + "fs": { + "scope": { + "allow": ["$APPDATA/db/**", "$DOWNLOAD/**", "$RESOURCE/**"], + "deny": ["$APPDATA/db/*.stronghold"] + } + }, + "shell": { + "open": true, + "scope": [ + { + "name": "sh", + "cmd": "sh", + "args": [ + "-c", + { + "validator": "\\S+" + } + ] + }, + { + "name": "cmd", + "cmd": "cmd", + "args": [ + "/C", + { + "validator": "\\S+" + } + ] + } + ] + }, + "http": { + "scope": ["http://localhost:3003"] + }, + "updater": { + "endpoints": [ + "https://tauri-update-server.vercel.app/update/{{target}}/{{current_version}}" + ] } }, "tauri": { @@ -75,57 +114,10 @@ } } } - } - }, - "updater": { - "active": true, - "pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDE5QzMxNjYwNTM5OEUwNTgKUldSWTRKaFRZQmJER1h4d1ZMYVA3dnluSjdpN2RmMldJR09hUFFlZDY0SlFqckkvRUJhZDJVZXAK", - "endpoints": [ - "https://tauri-update-server.vercel.app/update/{{target}}/{{current_version}}" - ] - }, - "allowlist": { - "all": true, - "fs": { - "scope": { - "allow": ["$APPDATA/db/**", "$DOWNLOAD/**", "$RESOURCE/**"], - "deny": ["$APPDATA/db/*.stronghold"] - } }, - "shell": { - "open": true, - "scope": [ - { - "name": "sh", - "cmd": "sh", - "args": [ - "-c", - { - "validator": "\\S+" - } - ] - }, - { - "name": "cmd", - "cmd": "cmd", - "args": [ - "/C", - { - "validator": "\\S+" - } - ] - } - ] - }, - "protocol": { - "asset": true, - "assetScope": { - "allow": ["$APPDATA/db/**", "$RESOURCE/**"], - "deny": ["$APPDATA/db/*.stronghold"] - } - }, - "http": { - "scope": ["http://localhost:3003"] + "updater": { + "active": true, + "pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDE5QzMxNjYwNTM5OEUwNTgKUldSWTRKaFRZQmJER1h4d1ZMYVA3dnluSjdpN2RmMldJR09hUFFlZDY0SlFqckkvRUJhZDJVZXAK" } }, "windows": [], @@ -136,7 +128,14 @@ "img-src": "'self' asset: https://asset.localhost blob: data:", "style-src": "'unsafe-inline' 'self' https://fonts.googleapis.com" }, - "freezePrototype": true + "freezePrototype": true, + "assetProtocol": { + "enable": true, + "scope": { + "allow": ["$APPDATA/db/**", "$RESOURCE/**"], + "deny": ["$APPDATA/db/*.stronghold"] + } + } }, "systemTray": { "iconPath": "icons/tray_icon_with_transparency.png", diff --git a/examples/api/src/App.svelte b/examples/api/src/App.svelte index 2d93ba97..f3c93550 100644 --- a/examples/api/src/App.svelte +++ b/examples/api/src/App.svelte @@ -1,191 +1,191 @@ @@ -316,7 +318,7 @@ children:items-center children:justify-center" > @@ -334,7 +336,7 @@
@@ -346,7 +348,7 @@
@@ -377,7 +379,7 @@ bg-darkPrimaryLighter transition-colors-250 overflow-hidden grid select-none px-2" > open('https://tauri.app/')} + on:click={() => open("https://tauri.app/")} class="self-center p-7 cursor-pointer" src="tauri_logo.png" alt="Tauri logo" @@ -433,8 +435,8 @@ href="##" class="nv {selected === view ? 'nv_selected' : ''}" on:click={() => { - select(view) - isSideBarOpen = false + select(view); + isSideBarOpen = false; }} >
diff --git a/examples/api/src/views/App.svelte b/examples/api/src/views/App.svelte index 760590f0..de56ff6e 100644 --- a/examples/api/src/views/App.svelte +++ b/examples/api/src/views/App.svelte @@ -1,24 +1,24 @@ diff --git a/examples/api/src/views/Cli.svelte b/examples/api/src/views/Cli.svelte index 828c054f..53c3ee36 100644 --- a/examples/api/src/views/Cli.svelte +++ b/examples/api/src/views/Cli.svelte @@ -1,5 +1,5 @@ diff --git a/examples/api/src/views/Communication.svelte b/examples/api/src/views/Communication.svelte index e5b47f01..770cde47 100644 --- a/examples/api/src/views/Communication.svelte +++ b/examples/api/src/views/Communication.svelte @@ -1,41 +1,41 @@ diff --git a/examples/api/src/views/Dialog.svelte b/examples/api/src/views/Dialog.svelte index f6cabc22..46f91a56 100644 --- a/examples/api/src/views/Dialog.svelte +++ b/examples/api/src/views/Dialog.svelte @@ -1,89 +1,102 @@ @@ -116,3 +129,4 @@ + diff --git a/examples/api/src/views/FileSystem.svelte b/examples/api/src/views/FileSystem.svelte index ca0e277e..c13326a0 100644 --- a/examples/api/src/views/FileSystem.svelte +++ b/examples/api/src/views/FileSystem.svelte @@ -3,79 +3,79 @@ readBinaryFile, writeTextFile, readDir, - Dir - } from 'tauri-plugin-fs-api' - import { convertFileSrc } from '@tauri-apps/api/tauri' + Dir, + } from "@tauri-apps/plugin-fs"; + import { convertFileSrc } from "@tauri-apps/api/tauri"; - export let onMessage - export let insecureRenderHtml + export let onMessage; + export let insecureRenderHtml; - let pathToRead = '' - let img + let pathToRead = ""; + let img; function getDir() { - const dirSelect = document.getElementById('dir') - return dirSelect.value ? parseInt(dir.value) : null + const dirSelect = document.getElementById("dir"); + return dirSelect.value ? parseInt(dir.value) : null; } function arrayBufferToBase64(buffer, callback) { const blob = new Blob([buffer], { - type: 'application/octet-binary' - }) - const reader = new FileReader() + type: "application/octet-binary", + }); + const reader = new FileReader(); reader.onload = function (evt) { - const dataurl = evt.target.result - callback(dataurl.substr(dataurl.indexOf(',') + 1)) - } - reader.readAsDataURL(blob) + const dataurl = evt.target.result; + callback(dataurl.substr(dataurl.indexOf(",") + 1)); + }; + reader.readAsDataURL(blob); } const DirOptions = Object.keys(Dir) .filter((key) => isNaN(parseInt(key))) - .map((dir) => [dir, Dir[dir]]) + .map((dir) => [dir, Dir[dir]]); function read() { - const isFile = pathToRead.match(/\S+\.\S+$/g) + const isFile = pathToRead.match(/\S+\.\S+$/g); const opts = { - dir: getDir() - } + dir: getDir(), + }; const promise = isFile ? readBinaryFile(pathToRead, opts) - : readDir(pathToRead, opts) + : readDir(pathToRead, opts); promise .then(function (response) { if (isFile) { - if (pathToRead.includes('.png') || pathToRead.includes('.jpg')) { + if (pathToRead.includes(".png") || pathToRead.includes(".jpg")) { arrayBufferToBase64(new Uint8Array(response), function (base64) { - const src = 'data:image/png;base64,' + base64 - insecureRenderHtml('') - }) + const src = "data:image/png;base64," + base64; + insecureRenderHtml(''); + }); } else { - const value = String.fromCharCode.apply(null, response) + const value = String.fromCharCode.apply(null, response); insecureRenderHtml( '' - ) + ); setTimeout(() => { - const fileInput = document.getElementById('file-response') - fileInput.value = value + const fileInput = document.getElementById("file-response"); + fileInput.value = value; document - .getElementById('file-save') - .addEventListener('click', function () { + .getElementById("file-save") + .addEventListener("click", function () { writeTextFile(pathToRead, fileInput.value, { - dir: getDir() - }).catch(onMessage) - }) - }) + dir: getDir(), + }).catch(onMessage); + }); + }); } } else { - onMessage(response) + onMessage(response); } }) - .catch(onMessage) + .catch(onMessage); } function setSrc() { - img.src = convertFileSrc(pathToRead) + img.src = convertFileSrc(pathToRead); } diff --git a/examples/api/src/views/Http.svelte b/examples/api/src/views/Http.svelte index 5b34126e..5a1d3032 100644 --- a/examples/api/src/views/Http.svelte +++ b/examples/api/src/views/Http.svelte @@ -1,60 +1,60 @@ diff --git a/examples/api/src/views/Scanner.svelte b/examples/api/src/views/Scanner.svelte index f515ebde..3a358ec5 100644 --- a/examples/api/src/views/Scanner.svelte +++ b/examples/api/src/views/Scanner.svelte @@ -1,5 +1,5 @@ diff --git a/examples/api/src/views/Shortcuts.svelte b/examples/api/src/views/Shortcuts.svelte index cdc2a065..cdcc9066 100644 --- a/examples/api/src/views/Shortcuts.svelte +++ b/examples/api/src/views/Shortcuts.svelte @@ -1,46 +1,46 @@ diff --git a/examples/api/src/views/Updater.svelte b/examples/api/src/views/Updater.svelte index 3b219cfe..808e5868 100644 --- a/examples/api/src/views/Updater.svelte +++ b/examples/api/src/views/Updater.svelte @@ -1,76 +1,86 @@
{#if !isChecking && !newUpdate} - + {:else if !isInstalling && newUpdate} {:else} - +
+ {progress}% +
+
{/if}
diff --git a/examples/api/src/views/Welcome.svelte b/examples/api/src/views/Welcome.svelte index 7906d298..50048295 100644 --- a/examples/api/src/views/Welcome.svelte +++ b/examples/api/src/views/Welcome.svelte @@ -1,27 +1,27 @@ diff --git a/examples/api/src/views/Window.svelte b/examples/api/src/views/Window.svelte index df77d9b0..2d4a8c61 100644 --- a/examples/api/src/views/Window.svelte +++ b/examples/api/src/views/Window.svelte @@ -5,217 +5,217 @@ LogicalSize, UserAttentionType, PhysicalSize, - PhysicalPosition - } from '@tauri-apps/api/window' - import { open as openDialog } from 'tauri-plugin-dialog-api' - import { open } from 'tauri-plugin-shell-api' + PhysicalPosition, + } from "@tauri-apps/plugin-window"; + import { open as openDialog } from "@tauri-apps/plugin-dialog"; + import { open } from "@tauri-apps/plugin-shell"; - let selectedWindow = appWindow.label + let selectedWindow = appWindow.label; const windowMap = { - [appWindow.label]: appWindow - } + [appWindow.label]: appWindow, + }; const cursorIconOptions = [ - 'default', - 'crosshair', - 'hand', - 'arrow', - 'move', - 'text', - 'wait', - 'help', - 'progress', + "default", + "crosshair", + "hand", + "arrow", + "move", + "text", + "wait", + "help", + "progress", // something cannot be done - 'notAllowed', - 'contextMenu', - 'cell', - 'verticalText', - 'alias', - 'copy', - 'noDrop', + "notAllowed", + "contextMenu", + "cell", + "verticalText", + "alias", + "copy", + "noDrop", // something can be grabbed - 'grab', + "grab", /// something is grabbed - 'grabbing', - 'allScroll', - 'zoomIn', - 'zoomOut', + "grabbing", + "allScroll", + "zoomIn", + "zoomOut", // edge is to be moved - 'eResize', - 'nResize', - 'neResize', - 'nwResize', - 'sResize', - 'seResize', - 'swResize', - 'wResize', - 'ewResize', - 'nsResize', - 'neswResize', - 'nwseResize', - 'colResize', - 'rowResize' - ] + "eResize", + "nResize", + "neResize", + "nwResize", + "sResize", + "seResize", + "swResize", + "wResize", + "ewResize", + "nsResize", + "neswResize", + "nwseResize", + "colResize", + "rowResize", + ]; - export let onMessage + export let onMessage; - let newWindowLabel + let newWindowLabel; - let urlValue = 'https://tauri.app' - let resizable = true - let maximized = false - let decorations = true - let alwaysOnTop = false - let contentProtected = true - let fullscreen = false - let width = null - let height = null - let minWidth = null - let minHeight = null - let maxWidth = null - let maxHeight = null - let x = null - let y = null - let scaleFactor = 1 - let innerPosition = new PhysicalPosition(x, y) - let outerPosition = new PhysicalPosition(x, y) - let innerSize = new PhysicalSize(width, height) - let outerSize = new PhysicalSize(width, height) - let resizeEventUnlisten - let moveEventUnlisten - let cursorGrab = false - let cursorVisible = true - let cursorX = null - let cursorY = null - let cursorIcon = 'default' - let cursorIgnoreEvents = false - let windowTitle = 'Awesome Tauri Example!' + let urlValue = "https://tauri.app"; + let resizable = true; + let maximized = false; + let decorations = true; + let alwaysOnTop = false; + let contentProtected = true; + let fullscreen = false; + let width = null; + let height = null; + let minWidth = null; + let minHeight = null; + let maxWidth = null; + let maxHeight = null; + let x = null; + let y = null; + let scaleFactor = 1; + let innerPosition = new PhysicalPosition(x, y); + let outerPosition = new PhysicalPosition(x, y); + let innerSize = new PhysicalSize(width, height); + let outerSize = new PhysicalSize(width, height); + let resizeEventUnlisten; + let moveEventUnlisten; + let cursorGrab = false; + let cursorVisible = true; + let cursorX = null; + let cursorY = null; + let cursorIcon = "default"; + let cursorIgnoreEvents = false; + let windowTitle = "Awesome Tauri Example!"; function openUrl() { - open(urlValue) + open(urlValue); } function setTitle_() { - windowMap[selectedWindow].setTitle(windowTitle) + windowMap[selectedWindow].setTitle(windowTitle); } function hide_() { - windowMap[selectedWindow].hide() - setTimeout(windowMap[selectedWindow].show, 2000) + windowMap[selectedWindow].hide(); + setTimeout(windowMap[selectedWindow].show, 2000); } function minimize_() { - windowMap[selectedWindow].minimize() - setTimeout(windowMap[selectedWindow].unminimize, 2000) + windowMap[selectedWindow].minimize(); + setTimeout(windowMap[selectedWindow].unminimize, 2000); } function getIcon() { openDialog({ - multiple: false + multiple: false, }).then((path) => { - if (typeof path === 'string') { - windowMap[selectedWindow].setIcon(path) + if (typeof path === "string") { + windowMap[selectedWindow].setIcon(path); } - }) + }); } function createWindow() { - if (!newWindowLabel) return + if (!newWindowLabel) return; - const webview = new WebviewWindow(newWindowLabel) - windowMap[newWindowLabel] = webview - webview.once('tauri://error', function () { - onMessage('Error creating new webview') - }) + const webview = new WebviewWindow(newWindowLabel); + windowMap[newWindowLabel] = webview; + webview.once("tauri://error", function () { + onMessage("Error creating new webview"); + }); } function loadWindowSize() { windowMap[selectedWindow].innerSize().then((response) => { - innerSize = response - width = innerSize.width - height = innerSize.height - }) + innerSize = response; + width = innerSize.width; + height = innerSize.height; + }); windowMap[selectedWindow].outerSize().then((response) => { - outerSize = response - }) + outerSize = response; + }); } function loadWindowPosition() { windowMap[selectedWindow].innerPosition().then((response) => { - innerPosition = response - }) + innerPosition = response; + }); windowMap[selectedWindow].outerPosition().then((response) => { - outerPosition = response - x = outerPosition.x - y = outerPosition.y - }) + outerPosition = response; + x = outerPosition.x; + y = outerPosition.y; + }); } async function addWindowEventListeners(window) { - if (!window) return + if (!window) return; if (resizeEventUnlisten) { - resizeEventUnlisten() + resizeEventUnlisten(); } if (moveEventUnlisten) { - moveEventUnlisten() + moveEventUnlisten(); } - moveEventUnlisten = await window.listen('tauri://move', loadWindowPosition) - resizeEventUnlisten = await window.listen('tauri://resize', loadWindowSize) + moveEventUnlisten = await window.listen("tauri://move", loadWindowPosition); + resizeEventUnlisten = await window.listen("tauri://resize", loadWindowSize); } async function requestUserAttention_() { - await windowMap[selectedWindow].minimize() + await windowMap[selectedWindow].minimize(); await windowMap[selectedWindow].requestUserAttention( UserAttentionType.Critical - ) - await new Promise((resolve) => setTimeout(resolve, 3000)) - await windowMap[selectedWindow].requestUserAttention(null) + ); + await new Promise((resolve) => setTimeout(resolve, 3000)); + await windowMap[selectedWindow].requestUserAttention(null); } $: { - windowMap[selectedWindow] - loadWindowPosition() - loadWindowSize() + windowMap[selectedWindow]; + loadWindowPosition(); + loadWindowSize(); } - $: windowMap[selectedWindow]?.setResizable(resizable) + $: windowMap[selectedWindow]?.setResizable(resizable); $: maximized ? windowMap[selectedWindow]?.maximize() - : windowMap[selectedWindow]?.unmaximize() - $: windowMap[selectedWindow]?.setDecorations(decorations) - $: windowMap[selectedWindow]?.setAlwaysOnTop(alwaysOnTop) - $: windowMap[selectedWindow]?.setContentProtected(contentProtected) - $: windowMap[selectedWindow]?.setFullscreen(fullscreen) + : windowMap[selectedWindow]?.unmaximize(); + $: windowMap[selectedWindow]?.setDecorations(decorations); + $: windowMap[selectedWindow]?.setAlwaysOnTop(alwaysOnTop); + $: windowMap[selectedWindow]?.setContentProtected(contentProtected); + $: windowMap[selectedWindow]?.setFullscreen(fullscreen); $: width && height && - windowMap[selectedWindow]?.setSize(new PhysicalSize(width, height)) + windowMap[selectedWindow]?.setSize(new PhysicalSize(width, height)); $: minWidth && minHeight ? windowMap[selectedWindow]?.setMinSize( new LogicalSize(minWidth, minHeight) ) - : windowMap[selectedWindow]?.setMinSize(null) + : windowMap[selectedWindow]?.setMinSize(null); $: maxWidth > 800 && maxHeight > 400 ? windowMap[selectedWindow]?.setMaxSize( new LogicalSize(maxWidth, maxHeight) ) - : windowMap[selectedWindow]?.setMaxSize(null) + : windowMap[selectedWindow]?.setMaxSize(null); $: x !== null && y !== null && - windowMap[selectedWindow]?.setPosition(new PhysicalPosition(x, y)) + windowMap[selectedWindow]?.setPosition(new PhysicalPosition(x, y)); $: windowMap[selectedWindow] ?.scaleFactor() - .then((factor) => (scaleFactor = factor)) - $: addWindowEventListeners(windowMap[selectedWindow]) + .then((factor) => (scaleFactor = factor)); + $: addWindowEventListeners(windowMap[selectedWindow]); - $: windowMap[selectedWindow]?.setCursorGrab(cursorGrab) - $: windowMap[selectedWindow]?.setCursorVisible(cursorVisible) - $: windowMap[selectedWindow]?.setCursorIcon(cursorIcon) + $: windowMap[selectedWindow]?.setCursorGrab(cursorGrab); + $: windowMap[selectedWindow]?.setCursorVisible(cursorVisible); + $: windowMap[selectedWindow]?.setCursorIcon(cursorIcon); $: cursorX !== null && cursorY !== null && windowMap[selectedWindow]?.setCursorPosition( new PhysicalPosition(cursorX, cursorY) - ) - $: windowMap[selectedWindow]?.setIgnoreCursorEvents(cursorIgnoreEvents) + ); + $: windowMap[selectedWindow]?.setIgnoreCursorEvents(cursorIgnoreEvents);
diff --git a/examples/api/yarn-error.log b/examples/api/yarn-error.log deleted file mode 100644 index 59baf8f8..00000000 --- a/examples/api/yarn-error.log +++ /dev/null @@ -1,1094 +0,0 @@ -Arguments: - /home/lucas/.nvm/versions/node/v16.14.0/bin/node /usr/bin/yarn - -PATH: - /home/lucas/.local/bin:/opt/ums:/home/lucas/NDK/x86/bin:/home/lucas/Android/Sdk/platform-tools:/home/lucas/.yarn/bin:/home/lucas/.cargo/bin:/home/lucas/.nvm/versions/node/v16.14.0/bin:/home/lucas/.config/composer/vendor/bin:/home/lucasfernog/perl5/bin:/usr/bin:/home/lucas/.local/bin:/opt/ums:/home/lucas/NDK/x86/bin:/home/lucas/Android/Sdk/platform-tools:/home/lucas/.yarn/bin:/home/lucas/.cargo/bin:/home/lucas/.nvm/versions/node/v16.14.0/bin:/home/lucas/.config/composer/vendor/bin:/home/lucasfernog/perl5/bin:/usr/condabin:/usr/local/sbin:/usr/local/bin:/usr/bin:/home/lucas/.dotnet/tools:/home/lucas/.local/share/flatpak/exports/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/home/lucas/.rvm/bin:/home/lucas/.rvm/bin - -Yarn version: - 1.22.19 - -Node version: - 16.14.0 - -Platform: - linux x64 - -Trace: - Error: https://gitpkg.now.sh/tauri-apps/plugins-workspace/plugins/fs?feat/fs-plugin&scripts.build=build: Request failed "500 Internal Server Error" - at ResponseError.ExtendableBuiltin (/usr/lib/node_modules/yarn/lib/cli.js:696:66) - at new ResponseError (/usr/lib/node_modules/yarn/lib/cli.js:802:124) - at Request. (/usr/lib/node_modules/yarn/lib/cli.js:66215:16) - at Request.emit (node:events:520:28) - at Request.module.exports.Request.onRequestResponse (/usr/lib/node_modules/yarn/lib/cli.js:141767:10) - at ClientRequest.emit (node:events:520:28) - at HTTPParser.parserOnIncomingClient (node:_http_client:618:27) - at HTTPParser.parserOnHeadersComplete (node:_http_common:128:17) - at TLSSocket.socketOnData (node:_http_client:482:22) - at TLSSocket.emit (node:events:520:28) - -npm manifest: - { - "name": "svelte-app", - "version": "1.0.0", - "type": "module", - "scripts": { - "dev": "vite --clearScreen false", - "build": "vite build", - "serve": "vite preview", - "tauri": "node ../../tooling/cli/node/tauri.js" - }, - "dependencies": { - "@tauri-apps/api": "../../tooling/api/dist", - "@zerodevx/svelte-json-view": "0.2.1", - "tauri-plugin-fs-api": "https://gitpkg.now.sh/tauri-apps/plugins-workspace/plugins/fs?feat/fs-plugin&scripts.build=build" - }, - "devDependencies": { - "@iconify-json/codicon": "^1.1.10", - "@iconify-json/ph": "^1.1.1", - "@sveltejs/vite-plugin-svelte": "^1.0.1", - "internal-ip": "^7.0.0", - "svelte": "^3.49.0", - "unocss": "^0.39.3", - "vite": "^3.0.9" - } - } - -yarn manifest: - No manifest - -Lockfile: - # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. - # yarn lockfile v1 - - - "@antfu/install-pkg@^0.1.0": - version "0.1.0" - resolved "https://registry.yarnpkg.com/@antfu/install-pkg/-/install-pkg-0.1.0.tgz#8d8c61820cbc32e5c37d82d515485ad3ee9bd052" - integrity sha512-VaIJd3d1o7irZfK1U0nvBsHMyjkuyMP3HKYVV53z8DKyulkHKmjhhtccXO51WSPeeSHIeoJEoNOKavYpS7jkZw== - dependencies: - execa "^5.1.1" - find-up "^5.0.0" - - "@antfu/utils@^0.5.0", "@antfu/utils@^0.5.1": - version "0.5.2" - resolved "https://registry.yarnpkg.com/@antfu/utils/-/utils-0.5.2.tgz#8c2d931ff927be0ebe740169874a3d4004ab414b" - integrity sha512-CQkeV+oJxUazwjlHD0/3ZD08QWKuGQkhnrKo3e6ly5pd48VUpXbb77q0xMU4+vc2CkJnDS02Eq/M9ugyX20XZA== - - "@esbuild/linux-loong64@0.14.54": - version "0.14.54" - resolved "https://registry.yarnpkg.com/@esbuild/linux-loong64/-/linux-loong64-0.14.54.tgz#de2a4be678bd4d0d1ffbb86e6de779cde5999028" - integrity sha512-bZBrLAIX1kpWelV0XemxBZllyRmM6vgFQQG2GdNb+r3Fkp0FOh1NJSvekXDs7jq70k4euu1cryLMfU+mTXlEpw== - - "@iconify-json/codicon@^1.1.10": - version "1.1.10" - resolved "https://registry.yarnpkg.com/@iconify-json/codicon/-/codicon-1.1.10.tgz#22fee909be51afebfbcc6cd57209064b5363f202" - integrity sha512-xx3nX5k4UeDQnpX9D1T6L1RCEwyLtqu3Lqk9plYK+SoBSQ/kR73bPy9WbYyDVOw2MDw50JCSpZZYlBC718k7Sg== - dependencies: - "@iconify/types" "^1.1.0" - - "@iconify-json/ph@^1.1.1": - version "1.1.1" - resolved "https://registry.yarnpkg.com/@iconify-json/ph/-/ph-1.1.1.tgz#17b3dee91a47055bac93d65c32b9ee33c654d56f" - integrity sha512-sIHTY+c1F8x29BM49IqoccJ3T8mvVXPcrE4WOpJ3GsBaip2YqFJRYU60rw64UL6GEI13vWSD7NsZKq8ytTO87g== - dependencies: - "@iconify/types" "^1.0.12" - - "@iconify/types@^1.0.12", "@iconify/types@^1.1.0": - version "1.1.0" - resolved "https://registry.yarnpkg.com/@iconify/types/-/types-1.1.0.tgz#dc15fc988b1b3fd558dd140a24ede7e0aac11280" - integrity sha512-Jh0llaK2LRXQoYsorIH8maClebsnzTcve+7U3rQUSnC11X4jtPnFuyatqFLvMxZ8MLG8dB4zfHsbPfuvxluONw== - - "@iconify/utils@^1.0.33": - version "1.0.33" - resolved "https://registry.yarnpkg.com/@iconify/utils/-/utils-1.0.33.tgz#9952ecae79e3b1685b83c58159c1d48959f6105a" - integrity sha512-vGeAqo7aGPxOQmGdVoXFUOuyN+0V7Lcrx2EvaiRjxUD1x6Om0Tvq2bdm7E24l2Pz++4S0mWMCVFXe/17EtKImQ== - dependencies: - "@antfu/install-pkg" "^0.1.0" - "@antfu/utils" "^0.5.0" - "@iconify/types" "^1.1.0" - debug "^4.3.4" - kolorist "^1.5.1" - local-pkg "^0.4.1" - - "@nodelib/fs.scandir@2.1.5": - version "2.1.5" - resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" - integrity sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g== - dependencies: - "@nodelib/fs.stat" "2.0.5" - run-parallel "^1.1.9" - - "@nodelib/fs.stat@2.0.5", "@nodelib/fs.stat@^2.0.2": - version "2.0.5" - resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz#5bd262af94e9d25bd1e71b05deed44876a222e8b" - integrity sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A== - - "@nodelib/fs.walk@^1.2.3": - version "1.2.8" - resolved "https://registry.yarnpkg.com/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz#e95737e8bb6746ddedf69c556953494f196fe69a" - integrity sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg== - dependencies: - "@nodelib/fs.scandir" "2.1.5" - fastq "^1.6.0" - - "@polka/url@^1.0.0-next.20": - version "1.0.0-next.21" - resolved "https://registry.yarnpkg.com/@polka/url/-/url-1.0.0-next.21.tgz#5de5a2385a35309427f6011992b544514d559aa1" - integrity sha512-a5Sab1C4/icpTZVzZc5Ghpz88yQtGOyNqYXcZgOssB2uuAr+wF/MvN6bgtW32q7HHrvBki+BsZ0OuNv6EV3K9g== - - "@rollup/pluginutils@^4.2.1": - version "4.2.1" - resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-4.2.1.tgz#e6c6c3aba0744edce3fb2074922d3776c0af2a6d" - integrity sha512-iKnFXr7NkdZAIHiIWE+BX5ULi/ucVFYWD6TbAV+rZctiRTY2PL6tsIKhoIOaoskiWAkgu+VsbXgUVDNLHf+InQ== - dependencies: - estree-walker "^2.0.1" - picomatch "^2.2.2" - - "@sveltejs/vite-plugin-svelte@^1.0.1": - version "1.0.1" - resolved "https://registry.yarnpkg.com/@sveltejs/vite-plugin-svelte/-/vite-plugin-svelte-1.0.1.tgz#7f468f03c933fcdfc60d4773671c73f33b9ef4d6" - integrity sha512-PorCgUounn0VXcpeJu+hOweZODKmGuLHsLomwqSj+p26IwjjGffmYQfVHtiTWq+NqaUuuHWWG7vPge6UFw4Aeg== - dependencies: - "@rollup/pluginutils" "^4.2.1" - debug "^4.3.4" - deepmerge "^4.2.2" - kleur "^4.1.5" - magic-string "^0.26.2" - svelte-hmr "^0.14.12" - - "@tauri-apps/api@../../tooling/api/dist": - version "2.0.0-alpha.3" - - "@tauri-apps/api@^1.2.0": - version "1.2.0" - resolved "https://registry.yarnpkg.com/@tauri-apps/api/-/api-1.2.0.tgz#1f196b3e012971227f41b98214c846430a4eb477" - integrity sha512-lsI54KI6HGf7VImuf/T9pnoejfgkNoXveP14pVV7XarrQ46rOejIVJLFqHI9sRReJMGdh2YuCoI3cc/yCWCsrw== - - "@unocss/cli@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/cli/-/cli-0.39.3.tgz#a7e956a4fffb9586579f09727069f83d34c5e358" - integrity sha512-h+qq76CJTkV7GYBSQ3vSJCn/jewFzBVh8owMYH3B1ROe5D1mCev2INYvHlsQsVVoyxnccBeuZ6st6OK56VyDjA== - dependencies: - "@unocss/config" "0.39.3" - "@unocss/core" "0.39.3" - "@unocss/preset-uno" "0.39.3" - cac "^6.7.12" - chokidar "^3.5.3" - colorette "^2.0.16" - consola "^2.15.3" - fast-glob "^3.2.11" - pathe "^0.3.0" - perfect-debounce "^0.1.3" - - "@unocss/config@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/config/-/config-0.39.3.tgz#0404c29dc76b87833fef331a628652be7cb1f9ee" - integrity sha512-qyxjUUdi+D/vS4Snhoj0uW8ErKlfZCKdjJ+ntwnJK3c8dxAp/IuicE+6ukcLfHxT0kAw1xaRlNwamtL3MgcX/A== - dependencies: - "@unocss/core" "0.39.3" - unconfig "^0.3.4" - - "@unocss/core@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/core/-/core-0.39.3.tgz#fec1e71b2f89e14629c47be72f6c894dd88933ac" - integrity sha512-8MnXKHNtp6xgsFIaFtWctnbsT60c8JSlxXA7XbGxEztOmSEhpZmLeLGe5AgmEGPH6MssqJtI0DCeTbzbbtOjfw== - - "@unocss/inspector@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/inspector/-/inspector-0.39.3.tgz#0e22826e1c9c017be2d5e0db00728d48f2e39a1d" - integrity sha512-j7U04I07sqK63+3cA7oju/hoGOkdN+/hAwGYkCgWGNj+HwxiU7TTEVg0qZ1FAUU/GyyI9G/c4RIpwei9dLVz9w== - dependencies: - gzip-size "^6.0.0" - sirv "^2.0.2" - - "@unocss/preset-attributify@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/preset-attributify/-/preset-attributify-0.39.3.tgz#b2bf4f645edd7f9890e85fcdfd770e19298d611d" - integrity sha512-SZWWUfTTKyHHqlF9x6aZ+BFMIiwOsUTP4NXS3/rIroqzfvVDZtGS6/a7RVBl+M74wjqSWB/DDeS9kQiH2L/CIg== - dependencies: - "@unocss/core" "0.39.3" - - "@unocss/preset-icons@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/preset-icons/-/preset-icons-0.39.3.tgz#d6dcbd09bce41c11370a1d652967584f9eb7043f" - integrity sha512-zMTfP3pVaN2WREWY36adsY62gEm51R0CZd7v0gHOlltEG6kT1UCeyIQwOtn48wHRCesy92f70R6RIR3rwSVaCQ== - dependencies: - "@iconify/utils" "^1.0.33" - "@unocss/core" "0.39.3" - ohmyfetch "^0.4.18" - - "@unocss/preset-mini@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/preset-mini/-/preset-mini-0.39.3.tgz#3996da482ddc9ba3de5e5656d1808939befd5812" - integrity sha512-XCxp3mwWsEpCo0cIJA3tLrWqdAL09gP3wv9iGh4H9o0fIPlYXjVTC1WtUHkv3C09LdZ+MH/9Ja/KqnVf3bNROA== - dependencies: - "@unocss/core" "0.39.3" - - "@unocss/preset-tagify@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/preset-tagify/-/preset-tagify-0.39.3.tgz#a0268c8aae0e0c5825079a87312c93ac8b05a43c" - integrity sha512-OXE47cS/tiL92ZThgLOpbSFy7MPZ4upE4ZX1m9pnCaWzX7LBzp8Gw0DM+dF3IYdIfJpmU4R6b53ME8SchofuHA== - dependencies: - "@unocss/core" "0.39.3" - - "@unocss/preset-typography@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/preset-typography/-/preset-typography-0.39.3.tgz#fd151885aa9d83a9ea9577aa26737f9f96dcf661" - integrity sha512-jTJOA87bEkU0RGMPSFZK3Zobr2fgkqKCYDczTjPbCiZ8UzlMJnWrpsNTN9f4UI0b6Ck8sXtMtW8sRrJsEll9jg== - dependencies: - "@unocss/core" "0.39.3" - - "@unocss/preset-uno@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/preset-uno/-/preset-uno-0.39.3.tgz#bf8d05ee9e92006a788d56c95a52f8a6676af4e1" - integrity sha512-EADVFqx5x4te/teqwjHb025FIy/T0QXafcVDRwUijS6OOqm5rZ7fXd/hu41XYYn3B802r/g4bDC2wO+7foNVwA== - dependencies: - "@unocss/core" "0.39.3" - "@unocss/preset-mini" "0.39.3" - "@unocss/preset-wind" "0.39.3" - - "@unocss/preset-web-fonts@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/preset-web-fonts/-/preset-web-fonts-0.39.3.tgz#a7af50bda616d9e980e45157a59079f90d463e01" - integrity sha512-b23nmEGHbfvC/PCv0m0BGqFt2zX8J9ekwjfmEL1Bk1C0KL2voYGSdbSm0I8iO6sKb1CLy6qy71N/CuGtIE3FJA== - dependencies: - "@unocss/core" "0.39.3" - ohmyfetch "^0.4.18" - - "@unocss/preset-wind@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/preset-wind/-/preset-wind-0.39.3.tgz#014d5da2cae63489c363ff057a500f26d15455a4" - integrity sha512-kjMgPxt4xfmiliodKTbotJDSAqAOCy25f1jdIj9CjjFjwYsUAuiYi8UgPsEi550Bj5BlBEHFn/RhcMGvinzY8A== - dependencies: - "@unocss/core" "0.39.3" - "@unocss/preset-mini" "0.39.3" - - "@unocss/reset@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/reset/-/reset-0.39.3.tgz#71fbbac03c96617e039b46f98e372271413a5d3d" - integrity sha512-hW3gZ3lsu6N58XEG7m1dprt15fN0xkYjAo7vSp8eT3/p7h5HE7wNgU2v9ttGBC3B2z4AWHGdspfmaH3sR8lCJw== - - "@unocss/scope@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/scope/-/scope-0.39.3.tgz#8f1b5fd02f6d935bb1b83f4100c06b23dbb38c2f" - integrity sha512-ex2QDRgBQ5mTwBcXtCWdTDPl6/HrBv0asDWVXXv7ezjxcByJjMrHj64gMvUbAcGAoX2ic7hIEUT3Ju5i6knKFw== - - "@unocss/transformer-compile-class@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/transformer-compile-class/-/transformer-compile-class-0.39.3.tgz#6e8b7ca6eee0a689588d19a8ba3b5953e03d086b" - integrity sha512-OmYP0uk+DGR5kc2T+teL6CLNj/sRxbY3SmlPx2kDbsRLc5gFccQryjj4bBk6QNOKxP5OGJpAqcw1y1JctvRgog== - dependencies: - "@unocss/core" "0.39.3" - - "@unocss/transformer-directives@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/transformer-directives/-/transformer-directives-0.39.3.tgz#e490a479582a94503fc02f91ce167347e822cff5" - integrity sha512-E1wzZaR6rIBQNemgDi9LoljtkYcOSiKGMUTz6kRGoxVBzaYE6Ji/YKbb22lKd6vLOFnRyCxzPHdzY9qvvl5D6w== - dependencies: - "@unocss/core" "0.39.3" - css-tree "^2.1.0" - - "@unocss/transformer-variant-group@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/transformer-variant-group/-/transformer-variant-group-0.39.3.tgz#31730bd414a06a676e753f69839652eaf6c0be9c" - integrity sha512-YoYz87qSSEvXXUkgHbO2kz/M03dbZuedjDvvWXsBAvj20MQFpkZpbNHYf2DJ+EkO/WXd+KEF2HBwlgoANcZlaw== - dependencies: - "@unocss/core" "0.39.3" - - "@unocss/vite@0.39.3": - version "0.39.3" - resolved "https://registry.yarnpkg.com/@unocss/vite/-/vite-0.39.3.tgz#a65cfa72732a6f3bc9c18640c74716d2f56c9f6b" - integrity sha512-JT21v6ZwLCHPGVfjoWsOdSkMhFNiW2robhQke33WLlRGyT5U4K1SWLxNk+XPDbFdP+WZdcVJi5W5yG8Mm27WBw== - dependencies: - "@rollup/pluginutils" "^4.2.1" - "@unocss/config" "0.39.3" - "@unocss/core" "0.39.3" - "@unocss/inspector" "0.39.3" - "@unocss/scope" "0.39.3" - "@unocss/transformer-directives" "0.39.3" - magic-string "^0.26.2" - - "@zerodevx/svelte-json-view@0.2.1": - version "0.2.1" - resolved "https://registry.yarnpkg.com/@zerodevx/svelte-json-view/-/svelte-json-view-0.2.1.tgz#12d1497f49d120bfb74e098dbe46ce5f16240d1c" - integrity sha512-yaLojLYTi08vccUKRg/XSRCCPoyzCZqrG+W8mVhJEGiOfFKAmWqNH6b+/il1gG3V1UaEe7amj2mzmo1mo4q1iA== - - anymatch@~3.1.2: - version "3.1.2" - resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.2.tgz#c0557c096af32f106198f4f4e2a383537e378716" - integrity sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg== - dependencies: - normalize-path "^3.0.0" - picomatch "^2.0.4" - - binary-extensions@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" - integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== - - braces@^3.0.2, braces@~3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" - integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== - dependencies: - fill-range "^7.0.1" - - busboy@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/busboy/-/busboy-1.6.0.tgz#966ea36a9502e43cdb9146962523b92f531f6893" - integrity sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA== - dependencies: - streamsearch "^1.1.0" - - cac@^6.7.12: - version "6.7.12" - resolved "https://registry.yarnpkg.com/cac/-/cac-6.7.12.tgz#6fb5ea2ff50bd01490dbda497f4ae75a99415193" - integrity sha512-rM7E2ygtMkJqD9c7WnFU6fruFcN3xe4FM5yUmgxhZzIKJk4uHl9U/fhwdajGFQbQuv43FAUo1Fe8gX/oIKDeSA== - - chokidar@^3.5.3: - version "3.5.3" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.5.3.tgz#1cf37c8707b932bd1af1ae22c0432e2acd1903bd" - integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw== - dependencies: - anymatch "~3.1.2" - braces "~3.0.2" - glob-parent "~5.1.2" - is-binary-path "~2.1.0" - is-glob "~4.0.1" - normalize-path "~3.0.0" - readdirp "~3.6.0" - optionalDependencies: - fsevents "~2.3.2" - - colorette@^2.0.16: - version "2.0.19" - resolved "https://registry.yarnpkg.com/colorette/-/colorette-2.0.19.tgz#cdf044f47ad41a0f4b56b3a0d5b4e6e1a2d5a798" - integrity sha512-3tlv/dIP7FWvj3BsbHrGLJ6l/oKh1O3TcgBqMn+yyCagOxc23fyzDS6HypQbgxWbkpDnf52p1LuR4eWDQ/K9WQ== - - consola@^2.15.3: - version "2.15.3" - resolved "https://registry.yarnpkg.com/consola/-/consola-2.15.3.tgz#2e11f98d6a4be71ff72e0bdf07bd23e12cb61550" - integrity sha512-9vAdYbHj6x2fLKC4+oPH0kFzY/orMZyG2Aj+kNylHxKGJ/Ed4dpNyAQYwJOdqO4zdM7XpVHmyejQDcQHrnuXbw== - - cross-spawn@^7.0.3: - version "7.0.3" - resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" - integrity sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w== - dependencies: - path-key "^3.1.0" - shebang-command "^2.0.0" - which "^2.0.1" - - css-tree@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-2.1.0.tgz#170e27ccf94e7c5facb183765c25898be843d1d2" - integrity sha512-PcysZRzToBbrpoUrZ9qfblRIRf8zbEAkU0AIpQFtgkFK0vSbzOmBCvdSAx2Zg7Xx5wiYJKUKk0NMP7kxevie/A== - dependencies: - mdn-data "2.0.27" - source-map-js "^1.0.1" - - debug@^4.3.4: - version "4.3.4" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" - integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== - dependencies: - ms "2.1.2" - - deepmerge@^4.2.2: - version "4.2.2" - resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.2.2.tgz#44d2ea3679b8f4d4ffba33f03d865fc1e7bf4955" - integrity sha512-FJ3UgI4gIl+PHZm53knsuSFpE+nESMr7M4v9QcgB7S63Kj/6WqMiFQJpBBYz1Pt+66bZpP3Q7Lye0Oo9MPKEdg== - - default-gateway@^6.0.3: - version "6.0.3" - resolved "https://registry.yarnpkg.com/default-gateway/-/default-gateway-6.0.3.tgz#819494c888053bdb743edbf343d6cdf7f2943a71" - integrity sha512-fwSOJsbbNzZ/CUFpqFBqYfYNLj1NbMPm8MMCIzHjC83iSJRBEGmDUxU+WP661BaBQImeC2yHwXtz+P/O9o+XEg== - dependencies: - execa "^5.0.0" - - defu@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/defu/-/defu-6.0.0.tgz#b397a6709a2f3202747a3d9daf9446e41ad0c5fc" - integrity sha512-t2MZGLf1V2rV4VBZbWIaXKdX/mUcYW0n2znQZoADBkGGxYL8EWqCuCZBmJPJ/Yy9fofJkyuuSuo5GSwo0XdEgw== - - destr@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/destr/-/destr-1.1.1.tgz#910457d10a2f2f247add4ca4fdb4a03adcc49079" - integrity sha512-QqkneF8LrYmwATMdnuD2MLI3GHQIcBnG6qFC2q9bSH430VTCDAVjcspPmUaKhPGtAtPAftIUFqY1obQYQuwmbg== - - duplexer@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/duplexer/-/duplexer-0.1.2.tgz#3abe43aef3835f8ae077d136ddce0f276b0400e6" - integrity sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg== - - esbuild-android-64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-android-64/-/esbuild-android-64-0.14.54.tgz#505f41832884313bbaffb27704b8bcaa2d8616be" - integrity sha512-Tz2++Aqqz0rJ7kYBfz+iqyE3QMycD4vk7LBRyWaAVFgFtQ/O8EJOnVmTOiDWYZ/uYzB4kvP+bqejYdVKzE5lAQ== - - esbuild-android-arm64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.14.54.tgz#8ce69d7caba49646e009968fe5754a21a9871771" - integrity sha512-F9E+/QDi9sSkLaClO8SOV6etqPd+5DgJje1F9lOWoNncDdOBL2YF59IhsWATSt0TLZbYCf3pNlTHvVV5VfHdvg== - - esbuild-darwin-64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.14.54.tgz#24ba67b9a8cb890a3c08d9018f887cc221cdda25" - integrity sha512-jtdKWV3nBviOd5v4hOpkVmpxsBy90CGzebpbO9beiqUYVMBtSc0AL9zGftFuBon7PNDcdvNCEuQqw2x0wP9yug== - - esbuild-darwin-arm64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.14.54.tgz#3f7cdb78888ee05e488d250a2bdaab1fa671bf73" - integrity sha512-OPafJHD2oUPyvJMrsCvDGkRrVCar5aVyHfWGQzY1dWnzErjrDuSETxwA2HSsyg2jORLY8yBfzc1MIpUkXlctmw== - - esbuild-freebsd-64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.14.54.tgz#09250f997a56ed4650f3e1979c905ffc40bbe94d" - integrity sha512-OKwd4gmwHqOTp4mOGZKe/XUlbDJ4Q9TjX0hMPIDBUWWu/kwhBAudJdBoxnjNf9ocIB6GN6CPowYpR/hRCbSYAg== - - esbuild-freebsd-arm64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.14.54.tgz#bafb46ed04fc5f97cbdb016d86947a79579f8e48" - integrity sha512-sFwueGr7OvIFiQT6WeG0jRLjkjdqWWSrfbVwZp8iMP+8UHEHRBvlaxL6IuKNDwAozNUmbb8nIMXa7oAOARGs1Q== - - esbuild-linux-32@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.14.54.tgz#e2a8c4a8efdc355405325033fcebeb941f781fe5" - integrity sha512-1ZuY+JDI//WmklKlBgJnglpUL1owm2OX+8E1syCD6UAxcMM/XoWd76OHSjl/0MR0LisSAXDqgjT3uJqT67O3qw== - - esbuild-linux-64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.14.54.tgz#de5fdba1c95666cf72369f52b40b03be71226652" - integrity sha512-EgjAgH5HwTbtNsTqQOXWApBaPVdDn7XcK+/PtJwZLT1UmpLoznPd8c5CxqsH2dQK3j05YsB3L17T8vE7cp4cCg== - - esbuild-linux-arm64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.14.54.tgz#dae4cd42ae9787468b6a5c158da4c84e83b0ce8b" - integrity sha512-WL71L+0Rwv+Gv/HTmxTEmpv0UgmxYa5ftZILVi2QmZBgX3q7+tDeOQNqGtdXSdsL8TQi1vIaVFHUPDe0O0kdig== - - esbuild-linux-arm@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.14.54.tgz#a2c1dff6d0f21dbe8fc6998a122675533ddfcd59" - integrity sha512-qqz/SjemQhVMTnvcLGoLOdFpCYbz4v4fUo+TfsWG+1aOu70/80RV6bgNpR2JCrppV2moUQkww+6bWxXRL9YMGw== - - esbuild-linux-mips64le@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.14.54.tgz#d9918e9e4cb972f8d6dae8e8655bf9ee131eda34" - integrity sha512-qTHGQB8D1etd0u1+sB6p0ikLKRVuCWhYQhAHRPkO+OF3I/iSlTKNNS0Lh2Oc0g0UFGguaFZZiPJdJey3AGpAlw== - - esbuild-linux-ppc64le@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.14.54.tgz#3f9a0f6d41073fb1a640680845c7de52995f137e" - integrity sha512-j3OMlzHiqwZBDPRCDFKcx595XVfOfOnv68Ax3U4UKZ3MTYQB5Yz3X1mn5GnodEVYzhtZgxEBidLWeIs8FDSfrQ== - - esbuild-linux-riscv64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.14.54.tgz#618853c028178a61837bc799d2013d4695e451c8" - integrity sha512-y7Vt7Wl9dkOGZjxQZnDAqqn+XOqFD7IMWiewY5SPlNlzMX39ocPQlOaoxvT4FllA5viyV26/QzHtvTjVNOxHZg== - - esbuild-linux-s390x@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-linux-s390x/-/esbuild-linux-s390x-0.14.54.tgz#d1885c4c5a76bbb5a0fe182e2c8c60eb9e29f2a6" - integrity sha512-zaHpW9dziAsi7lRcyV4r8dhfG1qBidQWUXweUjnw+lliChJqQr+6XD71K41oEIC3Mx1KStovEmlzm+MkGZHnHA== - - esbuild-netbsd-64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.14.54.tgz#69ae917a2ff241b7df1dbf22baf04bd330349e81" - integrity sha512-PR01lmIMnfJTgeU9VJTDY9ZerDWVFIUzAtJuDHwwceppW7cQWjBBqP48NdeRtoP04/AtO9a7w3viI+PIDr6d+w== - - esbuild-openbsd-64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.14.54.tgz#db4c8495287a350a6790de22edea247a57c5d47b" - integrity sha512-Qyk7ikT2o7Wu76UsvvDS5q0amJvmRzDyVlL0qf5VLsLchjCa1+IAvd8kTBgUxD7VBUUVgItLkk609ZHUc1oCaw== - - esbuild-sunos-64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.14.54.tgz#54287ee3da73d3844b721c21bc80c1dc7e1bf7da" - integrity sha512-28GZ24KmMSeKi5ueWzMcco6EBHStL3B6ubM7M51RmPwXQGLe0teBGJocmWhgwccA1GeFXqxzILIxXpHbl9Q/Kw== - - esbuild-windows-32@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.14.54.tgz#f8aaf9a5667630b40f0fb3aa37bf01bbd340ce31" - integrity sha512-T+rdZW19ql9MjS7pixmZYVObd9G7kcaZo+sETqNH4RCkuuYSuv9AGHUVnPoP9hhuE1WM1ZimHz1CIBHBboLU7w== - - esbuild-windows-64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.14.54.tgz#bf54b51bd3e9b0f1886ffdb224a4176031ea0af4" - integrity sha512-AoHTRBUuYwXtZhjXZbA1pGfTo8cJo3vZIcWGLiUcTNgHpJJMC1rVA44ZereBHMJtotyN71S8Qw0npiCIkW96cQ== - - esbuild-windows-arm64@0.14.54: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.14.54.tgz#937d15675a15e4b0e4fafdbaa3a01a776a2be982" - integrity sha512-M0kuUvXhot1zOISQGXwWn6YtS+Y/1RT9WrVIOywZnJHo3jCDyewAc79aKNQWFCQm+xNHVTq9h8dZKvygoXQQRg== - - esbuild@^0.14.47: - version "0.14.54" - resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.14.54.tgz#8b44dcf2b0f1a66fc22459943dccf477535e9aa2" - integrity sha512-Cy9llcy8DvET5uznocPyqL3BFRrFXSVqbgpMJ9Wz8oVjZlh/zUSNbPRbov0VX7VxN2JH1Oa0uNxZ7eLRb62pJA== - optionalDependencies: - "@esbuild/linux-loong64" "0.14.54" - esbuild-android-64 "0.14.54" - esbuild-android-arm64 "0.14.54" - esbuild-darwin-64 "0.14.54" - esbuild-darwin-arm64 "0.14.54" - esbuild-freebsd-64 "0.14.54" - esbuild-freebsd-arm64 "0.14.54" - esbuild-linux-32 "0.14.54" - esbuild-linux-64 "0.14.54" - esbuild-linux-arm "0.14.54" - esbuild-linux-arm64 "0.14.54" - esbuild-linux-mips64le "0.14.54" - esbuild-linux-ppc64le "0.14.54" - esbuild-linux-riscv64 "0.14.54" - esbuild-linux-s390x "0.14.54" - esbuild-netbsd-64 "0.14.54" - esbuild-openbsd-64 "0.14.54" - esbuild-sunos-64 "0.14.54" - esbuild-windows-32 "0.14.54" - esbuild-windows-64 "0.14.54" - esbuild-windows-arm64 "0.14.54" - - estree-walker@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" - integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== - - execa@^5.0.0, execa@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/execa/-/execa-5.1.1.tgz#f80ad9cbf4298f7bd1d4c9555c21e93741c411dd" - integrity sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg== - dependencies: - cross-spawn "^7.0.3" - get-stream "^6.0.0" - human-signals "^2.1.0" - is-stream "^2.0.0" - merge-stream "^2.0.0" - npm-run-path "^4.0.1" - onetime "^5.1.2" - signal-exit "^3.0.3" - strip-final-newline "^2.0.0" - - fast-glob@^3.2.11: - version "3.2.11" - resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.11.tgz#a1172ad95ceb8a16e20caa5c5e56480e5129c1d9" - integrity sha512-xrO3+1bxSo3ZVHAnqzyuewYT6aMFHRAd4Kcs92MAonjwQZLsK9d0SF1IyQ3k5PoirxTW0Oe/RqFgMQ6TcNE5Ew== - dependencies: - "@nodelib/fs.stat" "^2.0.2" - "@nodelib/fs.walk" "^1.2.3" - glob-parent "^5.1.2" - merge2 "^1.3.0" - micromatch "^4.0.4" - - fastq@^1.6.0: - version "1.13.0" - resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.13.0.tgz#616760f88a7526bdfc596b7cab8c18938c36b98c" - integrity sha512-YpkpUnK8od0o1hmeSc7UUs/eB/vIPWJYjKck2QKIzAf71Vm1AAQ3EbuZB3g2JIy+pg+ERD0vqI79KyZiB2e2Nw== - dependencies: - reusify "^1.0.4" - - fill-range@^7.0.1: - version "7.0.1" - resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40" - integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== - dependencies: - to-regex-range "^5.0.1" - - find-up@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/find-up/-/find-up-5.0.0.tgz#4c92819ecb7083561e4f4a240a86be5198f536fc" - integrity sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng== - dependencies: - locate-path "^6.0.0" - path-exists "^4.0.0" - - fsevents@~2.3.2: - version "2.3.2" - resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a" - integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== - - function-bind@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" - integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== - - get-stream@^6.0.0: - version "6.0.1" - resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" - integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== - - glob-parent@^5.1.2, glob-parent@~5.1.2: - version "5.1.2" - resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" - integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== - dependencies: - is-glob "^4.0.1" - - gzip-size@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/gzip-size/-/gzip-size-6.0.0.tgz#065367fd50c239c0671cbcbad5be3e2eeb10e462" - integrity sha512-ax7ZYomf6jqPTQ4+XCpUGyXKHk5WweS+e05MBO4/y3WJ5RkmPXNKvX+bx1behVILVwr6JSQvZAku021CHPXG3Q== - dependencies: - duplexer "^0.1.2" - - has@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" - integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== - dependencies: - function-bind "^1.1.1" - - human-signals@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" - integrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw== - - internal-ip@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/internal-ip/-/internal-ip-7.0.0.tgz#5b1c6a9d7e188aa73a1b69717daf50c8d8ed774f" - integrity sha512-qE4TeD4brqC45Vq/+VASeMiS1KRyfBkR6HT2sh9pZVVCzSjPkaCEfKFU+dL0PRv7NHJtvoKN2r82G6wTfzorkw== - dependencies: - default-gateway "^6.0.3" - ipaddr.js "^2.0.1" - is-ip "^3.1.0" - p-event "^4.2.0" - - ip-regex@^4.0.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/ip-regex/-/ip-regex-4.3.0.tgz#687275ab0f57fa76978ff8f4dddc8a23d5990db5" - integrity sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q== - - ipaddr.js@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-2.0.1.tgz#eca256a7a877e917aeb368b0a7497ddf42ef81c0" - integrity sha512-1qTgH9NG+IIJ4yfKs2e6Pp1bZg8wbDbKHT21HrLIeYBTRLgMYKnMTPAuI3Lcs61nfx5h1xlXnbJtH1kX5/d/ng== - - is-binary-path@~2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz#ea1f7f3b80f064236e83470f86c09c254fb45b09" - integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== - dependencies: - binary-extensions "^2.0.0" - - is-core-module@^2.9.0: - version "2.9.0" - resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.9.0.tgz#e1c34429cd51c6dd9e09e0799e396e27b19a9c69" - integrity sha512-+5FPy5PnwmO3lvfMb0AsoPaBG+5KHUI0wYFXOtYPnVVVspTFUuMZNfNaNVRt3FZadstu2c8x23vykRW/NBoU6A== - dependencies: - has "^1.0.3" - - is-extglob@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" - integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== - - is-glob@^4.0.1, is-glob@~4.0.1: - version "4.0.3" - resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.3.tgz#64f61e42cbbb2eec2071a9dac0b28ba1e65d5084" - integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg== - dependencies: - is-extglob "^2.1.1" - - is-ip@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/is-ip/-/is-ip-3.1.0.tgz#2ae5ddfafaf05cb8008a62093cf29734f657c5d8" - integrity sha512-35vd5necO7IitFPjd/YBeqwWnyDWbuLH9ZXQdMfDA8TEo7pv5X8yfrvVO3xbJbLUlERCMvf6X0hTUamQxCYJ9Q== - dependencies: - ip-regex "^4.0.0" - - is-number@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" - integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== - - is-stream@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" - integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== - - isexe@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" - integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== - - jiti@^1.13.0: - version "1.14.0" - resolved "https://registry.yarnpkg.com/jiti/-/jiti-1.14.0.tgz#5350fff532a4d891ca4bcd700c47c1f40e6ee326" - integrity sha512-4IwstlaKQc9vCTC+qUXLM1hajy2ImiL9KnLvVYiaHOtS/v3wRjhLlGl121AmgDgx/O43uKmxownJghS5XMya2A== - - kleur@^4.1.5: - version "4.1.5" - resolved "https://registry.yarnpkg.com/kleur/-/kleur-4.1.5.tgz#95106101795f7050c6c650f350c683febddb1780" - integrity sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ== - - kolorist@^1.5.1: - version "1.5.1" - resolved "https://registry.yarnpkg.com/kolorist/-/kolorist-1.5.1.tgz#c3d66dc4fabde4f6b7faa6efda84c00491f9e52b" - integrity sha512-lxpCM3HTvquGxKGzHeknB/sUjuVoUElLlfYnXZT73K8geR9jQbroGlSCFBax9/0mpGoD3kzcMLnOlGQPJJNyqQ== - - local-pkg@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/local-pkg/-/local-pkg-0.4.1.tgz#e7b0d7aa0b9c498a1110a5ac5b00ba66ef38cfff" - integrity sha512-lL87ytIGP2FU5PWwNDo0w3WhIo2gopIAxPg9RxDYF7m4rr5ahuZxP22xnJHIvaLTe4Z9P6uKKY2UHiwyB4pcrw== - - locate-path@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-6.0.0.tgz#55321eb309febbc59c4801d931a72452a681d286" - integrity sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw== - dependencies: - p-locate "^5.0.0" - - magic-string@^0.26.2: - version "0.26.2" - resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.26.2.tgz#5331700e4158cd6befda738bb6b0c7b93c0d4432" - integrity sha512-NzzlXpclt5zAbmo6h6jNc8zl2gNRGHvmsZW4IvZhTC4W7k4OlLP+S5YLussa/r3ixNT66KOQfNORlXHSOy/X4A== - dependencies: - sourcemap-codec "^1.4.8" - - mdn-data@2.0.27: - version "2.0.27" - resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-2.0.27.tgz#1710baa7b0db8176d3b3d565ccb7915fc69525ab" - integrity sha512-kwqO0I0jtWr25KcfLm9pia8vLZ8qoAKhWZuZMbneJq3jjBD3gl5nZs8l8Tu3ZBlBAHVQtDur9rdDGyvtfVraHQ== - - merge-stream@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" - integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w== - - merge2@^1.3.0: - version "1.4.1" - resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" - integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg== - - micromatch@^4.0.4: - version "4.0.5" - resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.5.tgz#bc8999a7cbbf77cdc89f132f6e467051b49090c6" - integrity sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA== - dependencies: - braces "^3.0.2" - picomatch "^2.3.1" - - mimic-fn@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" - integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== - - mrmime@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/mrmime/-/mrmime-1.0.1.tgz#5f90c825fad4bdd41dc914eff5d1a8cfdaf24f27" - integrity sha512-hzzEagAgDyoU1Q6yg5uI+AorQgdvMCur3FcKf7NhMKWsaYg+RnbTyHRa/9IlLF9rf455MOCtcqqrQQ83pPP7Uw== - - ms@2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" - integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== - - nanoid@^3.3.4: - version "3.3.4" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.4.tgz#730b67e3cd09e2deacf03c027c81c9d9dbc5e8ab" - integrity sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw== - - node-fetch-native@^0.1.3: - version "0.1.4" - resolved "https://registry.yarnpkg.com/node-fetch-native/-/node-fetch-native-0.1.4.tgz#09b06754f9e298bac23848050da2352125634f89" - integrity sha512-10EKpOCQPXwZVFh3U1ptOMWBgKTbsN7Vvo6WVKt5pw4hp8zbv6ZVBZPlXw+5M6Tyi1oc1iD4/sNPd71KYA16tQ== - - normalize-path@^3.0.0, normalize-path@~3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" - integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== - - npm-run-path@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-4.0.1.tgz#b7ecd1e5ed53da8e37a55e1c2269e0b97ed748ea" - integrity sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw== - dependencies: - path-key "^3.0.0" - - ohmyfetch@^0.4.18: - version "0.4.18" - resolved "https://registry.yarnpkg.com/ohmyfetch/-/ohmyfetch-0.4.18.tgz#2952e04bd52662d0618d3d2f344db0250c3eeac2" - integrity sha512-MslzNrQzBLtZHmiZBI8QMOcMpdNFlK61OJ34nFNFynZ4v+4BonfCQ7VIN4EGXvGGq5zhDzgdJoY3o9S1l2T7KQ== - dependencies: - destr "^1.1.1" - node-fetch-native "^0.1.3" - ufo "^0.8.4" - undici "^5.2.0" - - onetime@^5.1.2: - version "5.1.2" - resolved "https://registry.yarnpkg.com/onetime/-/onetime-5.1.2.tgz#d0e96ebb56b07476df1dd9c4806e5237985ca45e" - integrity sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg== - dependencies: - mimic-fn "^2.1.0" - - p-event@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/p-event/-/p-event-4.2.0.tgz#af4b049c8acd91ae81083ebd1e6f5cae2044c1b5" - integrity sha512-KXatOjCRXXkSePPb1Nbi0p0m+gQAwdlbhi4wQKJPI1HsMQS9g+Sqp2o+QHziPr7eYJyOZet836KoHEVM1mwOrQ== - dependencies: - p-timeout "^3.1.0" - - p-finally@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" - integrity sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow== - - p-limit@^3.0.2: - version "3.1.0" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-3.1.0.tgz#e1daccbe78d0d1388ca18c64fea38e3e57e3706b" - integrity sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ== - dependencies: - yocto-queue "^0.1.0" - - p-locate@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-5.0.0.tgz#83c8315c6785005e3bd021839411c9e110e6d834" - integrity sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw== - dependencies: - p-limit "^3.0.2" - - p-timeout@^3.1.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/p-timeout/-/p-timeout-3.2.0.tgz#c7e17abc971d2a7962ef83626b35d635acf23dfe" - integrity sha512-rhIwUycgwwKcP9yTOOFK/AKsAopjjCakVqLHePO3CC6Mir1Z99xT+R63jZxAT5lFZLa2inS5h+ZS2GvR99/FBg== - dependencies: - p-finally "^1.0.0" - - path-exists@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" - integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== - - path-key@^3.0.0, path-key@^3.1.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" - integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q== - - path-parse@^1.0.7: - version "1.0.7" - resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" - integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== - - pathe@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/pathe/-/pathe-0.3.0.tgz#fd95bc16208263fa6dc1c78c07b3907a528de6eb" - integrity sha512-3vUjp552BJzCw9vqKsO5sttHkbYqqsZtH0x1PNtItgqx8BXEXzoY1SYRKcL6BTyVh4lGJGLj0tM42elUDMvcYA== - - perfect-debounce@^0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/perfect-debounce/-/perfect-debounce-0.1.3.tgz#ff6798ea543a3ba1f0efeeaf97c0340f5c8871ce" - integrity sha512-NOT9AcKiDGpnV/HBhI22Str++XWcErO/bALvHCuhv33owZW/CjH8KAFLZDCmu3727sihe0wTxpDhyGc6M8qacQ== - - picocolors@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" - integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ== - - picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.3.1: - version "2.3.1" - resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" - integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== - - picomatch@^2.2.2: - version "2.2.2" - resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.2.2.tgz#21f333e9b6b8eaff02468f5146ea406d345f4dad" - integrity sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg== - - postcss@^8.4.16: - version "8.4.16" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.16.tgz#33a1d675fac39941f5f445db0de4db2b6e01d43c" - integrity sha512-ipHE1XBvKzm5xI7hiHCZJCSugxvsdq2mPnsq5+UF+VHCjiBvtDrlxJfMBToWaP9D5XlgNmcFGqoHmUn0EYEaRQ== - dependencies: - nanoid "^3.3.4" - picocolors "^1.0.0" - source-map-js "^1.0.2" - - queue-microtask@^1.2.2: - version "1.2.3" - resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" - integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== - - readdirp@~3.6.0: - version "3.6.0" - resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.6.0.tgz#74a370bd857116e245b29cc97340cd431a02a6c7" - integrity sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA== - dependencies: - picomatch "^2.2.1" - - resolve@^1.22.1: - version "1.22.1" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.1.tgz#27cb2ebb53f91abb49470a928bba7558066ac177" - integrity sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw== - dependencies: - is-core-module "^2.9.0" - path-parse "^1.0.7" - supports-preserve-symlinks-flag "^1.0.0" - - reusify@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/reusify/-/reusify-1.0.4.tgz#90da382b1e126efc02146e90845a88db12925d76" - integrity sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw== - - "rollup@>=2.75.6 <2.77.0 || ~2.77.0": - version "2.77.3" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.77.3.tgz#8f00418d3a2740036e15deb653bed1a90ee0cc12" - integrity sha512-/qxNTG7FbmefJWoeeYJFbHehJ2HNWnjkAFRKzWN/45eNBBF/r8lo992CwcJXEzyVxs5FmfId+vTSTQDb+bxA+g== - optionalDependencies: - fsevents "~2.3.2" - - run-parallel@^1.1.9: - version "1.2.0" - resolved "https://registry.yarnpkg.com/run-parallel/-/run-parallel-1.2.0.tgz#66d1368da7bdf921eb9d95bd1a9229e7f21a43ee" - integrity sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA== - dependencies: - queue-microtask "^1.2.2" - - shebang-command@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" - integrity sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA== - dependencies: - shebang-regex "^3.0.0" - - shebang-regex@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" - integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== - - signal-exit@^3.0.3: - version "3.0.7" - resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" - integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== - - sirv@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/sirv/-/sirv-2.0.2.tgz#128b9a628d77568139cff85703ad5497c46a4760" - integrity sha512-4Qog6aE29nIjAOKe/wowFTxOdmbEZKb+3tsLljaBRzJwtqto0BChD2zzH0LhgCSXiI+V7X+Y45v14wBZQ1TK3w== - dependencies: - "@polka/url" "^1.0.0-next.20" - mrmime "^1.0.0" - totalist "^3.0.0" - - source-map-js@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.0.1.tgz#a1741c131e3c77d048252adfa24e23b908670caf" - integrity sha512-4+TN2b3tqOCd/kaGRJ/sTYA0tR0mdXx26ipdolxcwtJVqEnqNYvlCAt1q3ypy4QMlYus+Zh34RNtYLoq2oQ4IA== - - source-map-js@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" - integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw== - - sourcemap-codec@^1.4.8: - version "1.4.8" - resolved "https://registry.yarnpkg.com/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz#ea804bd94857402e6992d05a38ef1ae35a9ab4c4" - integrity sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA== - - streamsearch@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/streamsearch/-/streamsearch-1.1.0.tgz#404dd1e2247ca94af554e841a8ef0eaa238da764" - integrity sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg== - - strip-final-newline@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/strip-final-newline/-/strip-final-newline-2.0.0.tgz#89b852fb2fcbe936f6f4b3187afb0a12c1ab58ad" - integrity sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA== - - supports-preserve-symlinks-flag@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" - integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== - - svelte-hmr@^0.14.12: - version "0.14.12" - resolved "https://registry.yarnpkg.com/svelte-hmr/-/svelte-hmr-0.14.12.tgz#a127aec02f1896500b10148b2d4d21ddde39973f" - integrity sha512-4QSW/VvXuqVcFZ+RhxiR8/newmwOCTlbYIezvkeN6302YFRE8cXy0naamHcjz8Y9Ce3ITTZtrHrIL0AGfyo61w== - - svelte@^3.49.0: - version "3.49.0" - resolved "https://registry.yarnpkg.com/svelte/-/svelte-3.49.0.tgz#5baee3c672306de1070c3b7888fc2204e36a4029" - integrity sha512-+lmjic1pApJWDfPCpUUTc1m8azDqYCG1JN9YEngrx/hUyIcFJo6VZhj0A1Ai0wqoHcEIuQy+e9tk+4uDgdtsFA== - - "tauri-plugin-fs-api@https://gitpkg.now.sh/tauri-apps/plugins-workspace/plugins/fs?feat/fs-plugin": - version "0.0.0" - resolved "https://gitpkg.now.sh/tauri-apps/plugins-workspace/plugins/fs?feat/fs-plugin#a4b37d92c5fd3e638ad21d4ccf0132e07acc0136" - dependencies: - "@tauri-apps/api" "^1.2.0" - - to-regex-range@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" - integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== - dependencies: - is-number "^7.0.0" - - totalist@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/totalist/-/totalist-3.0.0.tgz#4ef9c58c5f095255cdc3ff2a0a55091c57a3a1bd" - integrity sha512-eM+pCBxXO/njtF7vdFsHuqb+ElbxqtI4r5EAvk6grfAFyJ6IvWlSkfZ5T9ozC6xWw3Fj1fGoSmrl0gUs46JVIw== - - ufo@^0.8.4: - version "0.8.4" - resolved "https://registry.yarnpkg.com/ufo/-/ufo-0.8.4.tgz#23e9ed82398d2116dcb378e8fba5ced8eca2ee40" - integrity sha512-/+BmBDe8GvlB2nIflWasLLAInjYG0bC9HRnfEpNi4sw77J2AJNnEVnTDReVrehoh825+Q/evF3THXTAweyam2g== - - unconfig@^0.3.4: - version "0.3.4" - resolved "https://registry.yarnpkg.com/unconfig/-/unconfig-0.3.4.tgz#f0c85584a088a434dde2215d8a3b272427d6056c" - integrity sha512-cf39F1brwQuLSuMLTYXOdWJH0O1CJee6a4QW1nYtO7SoBUfVvQCvEel6ssTNXtPfi17kop1ADmVtmC49NlFkIQ== - dependencies: - "@antfu/utils" "^0.5.1" - defu "^6.0.0" - jiti "^1.13.0" - - undici@^5.2.0: - version "5.19.1" - resolved "https://registry.yarnpkg.com/undici/-/undici-5.19.1.tgz#92b1fd3ab2c089b5a6bd3e579dcda8f1934ebf6d" - integrity sha512-YiZ61LPIgY73E7syxCDxxa3LV2yl3sN8spnIuTct60boiiRaE1J8mNWHO8Im2Zi/sFrPusjLlmRPrsyraSqX6A== - dependencies: - busboy "^1.6.0" - - unocss@^0.39.3: - version "0.39.3" - resolved "https://registry.yarnpkg.com/unocss/-/unocss-0.39.3.tgz#3b92d689a86c97a5cb2e57ebfab04219a0de1c01" - integrity sha512-+BZazovI1A+jlW0+GuSSABHQjBLpu2sQkLXriBTdZiPYZAqJJdiWHuQ6VPzF4Al5WM4VPpOgX5mUYWusJ813qw== - dependencies: - "@unocss/cli" "0.39.3" - "@unocss/core" "0.39.3" - "@unocss/preset-attributify" "0.39.3" - "@unocss/preset-icons" "0.39.3" - "@unocss/preset-mini" "0.39.3" - "@unocss/preset-tagify" "0.39.3" - "@unocss/preset-typography" "0.39.3" - "@unocss/preset-uno" "0.39.3" - "@unocss/preset-web-fonts" "0.39.3" - "@unocss/preset-wind" "0.39.3" - "@unocss/reset" "0.39.3" - "@unocss/transformer-compile-class" "0.39.3" - "@unocss/transformer-directives" "0.39.3" - "@unocss/transformer-variant-group" "0.39.3" - "@unocss/vite" "0.39.3" - - vite@^3.0.9: - version "3.0.9" - resolved "https://registry.yarnpkg.com/vite/-/vite-3.0.9.tgz#45fac22c2a5290a970f23d66c1aef56a04be8a30" - integrity sha512-waYABTM+G6DBTCpYAxvevpG50UOlZuynR0ckTK5PawNVt7ebX6X7wNXHaGIO6wYYFXSM7/WcuFuO2QzhBB6aMw== - dependencies: - esbuild "^0.14.47" - postcss "^8.4.16" - resolve "^1.22.1" - rollup ">=2.75.6 <2.77.0 || ~2.77.0" - optionalDependencies: - fsevents "~2.3.2" - - which@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" - integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA== - dependencies: - isexe "^2.0.0" - - yocto-queue@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" - integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== diff --git a/package.json b/package.json index 5a0bfce4..ef6f1bd3 100644 --- a/package.json +++ b/package.json @@ -4,7 +4,7 @@ "license": "MIT or APACHE-2.0", "type": "module", "scripts": { - "build": "pnpm run -r --parallel --filter !plugins-workspace --filter !\"./plugins/*/examples/**\" build", + "build": "pnpm run -r --parallel --filter !plugins-workspace --filter !\"./plugins/*/examples/**\" --filter !\"./examples/*\" build", "lint": "eslint .", "format": "prettier --write .", "format-check": "prettier --check ." @@ -15,11 +15,12 @@ "@rollup/plugin-typescript": "^11.1.0", "@typescript-eslint/eslint-plugin": "^5.58.0", "@typescript-eslint/parser": "^5.58.0", + "covector": "^0.9.0", "eslint": "^8.38.0", "eslint-config-prettier": "^8.8.0", - "eslint-config-standard-with-typescript": "^34.0.1", + "eslint-config-standard-with-typescript": "^35.0.0", "eslint-plugin-import": "^2.27.5", - "eslint-plugin-n": "^15.7.0", + "eslint-plugin-n": "^16.0.0", "eslint-plugin-promise": "^6.1.1", "eslint-plugin-security": "^1.7.1", "prettier": "^2.8.7", @@ -27,6 +28,6 @@ "typescript": "^5.0.4" }, "engines": { - "pnpm": ">=7.24.2" + "pnpm": ">=7.33.0" } } diff --git a/plugins/app/CHANGELOG.md b/plugins/app/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/app/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/app/Cargo.toml b/plugins/app/Cargo.toml new file mode 100644 index 00000000..6ae1ca3f --- /dev/null +++ b/plugins/app/Cargo.toml @@ -0,0 +1,10 @@ +[package] +name = "tauri-plugin-app" +version = "2.0.0-alpha.0" +description = "APIs to read application metadata and change app visibility on macOS." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } + +[dependencies] +tauri = { workspace = true } diff --git a/plugins/clipboard/LICENSE.spdx b/plugins/app/LICENSE.spdx similarity index 100% rename from plugins/clipboard/LICENSE.spdx rename to plugins/app/LICENSE.spdx diff --git a/plugins/clipboard/LICENSE_APACHE-2.0 b/plugins/app/LICENSE_APACHE-2.0 similarity index 100% rename from plugins/clipboard/LICENSE_APACHE-2.0 rename to plugins/app/LICENSE_APACHE-2.0 diff --git a/plugins/clipboard/LICENSE_MIT b/plugins/app/LICENSE_MIT similarity index 100% rename from plugins/clipboard/LICENSE_MIT rename to plugins/app/LICENSE_MIT diff --git a/plugins/fs-watch/README.md b/plugins/app/README.md similarity index 61% rename from plugins/fs-watch/README.md rename to plugins/app/README.md index c410cf12..96625b18 100644 --- a/plugins/fs-watch/README.md +++ b/plugins/app/README.md @@ -1,10 +1,10 @@ -![plugin-fs-watch](banner.png) +# App -Watch files and directories for changes using [notify](https://github.com/notify-rs/notify). +This plugin provides APIs to read application metadata and macOS app visibility functions. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,7 +18,9 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] -tauri-plugin-fs-watch = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +tauri-plugin-app = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-app = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` You can install the JavaScript Guest bindings using your preferred JavaScript package manager: @@ -26,11 +28,18 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh -pnpm add https://github.com/tauri-apps/tauri-plugin-fs-watch#v2 +pnpm add @tauri-apps/plugin-app # or -npm add https://github.com/tauri-apps/tauri-plugin-fs-watch#v2 +npm add @tauri-apps/plugin-app # or -yarn add https://github.com/tauri-apps/tauri-plugin-fs-watch#v2 +yarn add @tauri-apps/plugin-app + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-app#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-app#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-app#v2 ``` ## Usage @@ -42,7 +51,7 @@ First you need to register the core plugin with Tauri: ```rust fn main() { tauri::Builder::default() - .plugin(tauri_plugin_fs_watch::init()) + .plugin(tauri_plugin_app::init()) .run(tauri::generate_context!()) .expect("error while running tauri application"); } @@ -51,24 +60,9 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { watch, watchImmediate } from "tauri-plugin-fs-watch-api"; - -// can also watch an array of paths -const stopWatching = await watch( - "/path/to/something", - (event) => { - const { type, payload } = event; - }, - { recursive: true } -); - -const stopRawWatcher = await watchImmediate( - ["/path/a", "/path/b"], - (event) => { - const { path, operation, cookie } = event; - }, - {} -); +import { getVersion, hide } from "@tauri-apps/plugin-app"; +const appVersion = await getVersion(); +await hide(); ``` ## Contributing diff --git a/plugins/app/guest-js/index.ts b/plugins/app/guest-js/index.ts new file mode 100644 index 00000000..b2420ad7 --- /dev/null +++ b/plugins/app/guest-js/index.ts @@ -0,0 +1,90 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +/** + * Get application metadata. + * + * @module + */ + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} + +/** + * Gets the application version. + * @example + * ```typescript + * import { getVersion } from '@tauri-apps/plugin-app'; + * const appVersion = await getVersion(); + * ``` + * + * @since 2.0.0 + */ +async function getVersion(): Promise { + return window.__TAURI_INVOKE__("plugin:app|version"); +} + +/** + * Gets the application name. + * @example + * ```typescript + * import { getName } from '@tauri-apps/plugin-app'; + * const appName = await getName(); + * ``` + * + * @since 2.0.0 + */ +async function getName(): Promise { + return window.__TAURI_INVOKE__("plugin:app|name"); +} + +/** + * Gets the Tauri version. + * + * @example + * ```typescript + * import { getTauriVersion } from '@tauri-apps/plugin-app'; + * const tauriVersion = await getTauriVersion(); + * ``` + * + * @since 2.0.0 + */ +async function getTauriVersion(): Promise { + return window.__TAURI_INVOKE__("plugin:app|tauri_version"); +} + +/** + * Shows the application on macOS. This function does not automatically focus any specific app window. + * + * @example + * ```typescript + * import { show } from '@tauri-apps/plugin-app'; + * await show(); + * ``` + * + * @since 2.0.0 + */ +async function show(): Promise { + return window.__TAURI_INVOKE__("plugin:app|show"); +} + +/** + * Hides the application on macOS. + * + * @example + * ```typescript + * import { hide } from '@tauri-apps/plugin-app'; + * await hide(); + * ``` + * + * @since 2.0.0 + */ +async function hide(): Promise { + return window.__TAURI_INVOKE__("plugin:app|hide"); +} + +export { getName, getVersion, getTauriVersion, show, hide }; diff --git a/plugins/fs-watch/package.json b/plugins/app/package.json similarity index 78% rename from plugins/fs-watch/package.json rename to plugins/app/package.json index 4ac45241..f875fdb0 100644 --- a/plugins/fs-watch/package.json +++ b/plugins/app/package.json @@ -1,7 +1,6 @@ { - "name": "tauri-plugin-fs-watch-api", - "version": "0.0.0", - "description": "Watch files and directories for changes.", + "name": "@tauri-apps/plugin-app", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -28,6 +27,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/clipboard/rollup.config.mjs b/plugins/app/rollup.config.mjs similarity index 100% rename from plugins/clipboard/rollup.config.mjs rename to plugins/app/rollup.config.mjs diff --git a/plugins/app/src/api-iife.js b/plugins/app/src/api-iife.js new file mode 100644 index 00000000..a9e45a48 --- /dev/null +++ b/plugins/app/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_APP__=function(_){"use strict";return _.getName=async function(){return window.__TAURI_INVOKE__("plugin:app|name")},_.getTauriVersion=async function(){return window.__TAURI_INVOKE__("plugin:app|tauri_version")},_.getVersion=async function(){return window.__TAURI_INVOKE__("plugin:app|version")},_.hide=async function(){return window.__TAURI_INVOKE__("plugin:app|hide")},_.show=async function(){return window.__TAURI_INVOKE__("plugin:app|show")},_}({});Object.defineProperty(window.__TAURI__,"app",{value:__TAURI_APP__})} diff --git a/plugins/app/src/commands.rs b/plugins/app/src/commands.rs new file mode 100644 index 00000000..ebe06f76 --- /dev/null +++ b/plugins/app/src/commands.rs @@ -0,0 +1,36 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use tauri::{AppHandle, Runtime}; + +#[tauri::command] +pub fn version(app: AppHandle) -> String { + app.package_info().version.to_string() +} + +#[tauri::command] +pub fn name(app: AppHandle) -> String { + app.package_info().name.clone() +} + +#[tauri::command] +pub fn tauri_version() -> &'static str { + tauri::VERSION +} + +#[tauri::command] +#[allow(unused_variables)] +pub fn show(app: AppHandle) -> tauri::Result<()> { + #[cfg(target_os = "macos")] + app.show()?; + Ok(()) +} + +#[tauri::command] +#[allow(unused_variables)] +pub fn hide(app: AppHandle) -> tauri::Result<()> { + #[cfg(target_os = "macos")] + app.hide()?; + Ok(()) +} diff --git a/plugins/app/src/lib.rs b/plugins/app/src/lib.rs new file mode 100644 index 00000000..aa6fb802 --- /dev/null +++ b/plugins/app/src/lib.rs @@ -0,0 +1,23 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use tauri::{ + plugin::{Builder, TauriPlugin}, + Runtime, +}; + +mod commands; + +pub fn init() -> TauriPlugin { + Builder::new("app") + .js_init_script(include_str!("api-iife.js").to_string()) + .invoke_handler(tauri::generate_handler![ + commands::version, + commands::name, + commands::tauri_version, + commands::show, + commands::hide + ]) + .build() +} diff --git a/plugins/clipboard/tsconfig.json b/plugins/app/tsconfig.json similarity index 100% rename from plugins/clipboard/tsconfig.json rename to plugins/app/tsconfig.json diff --git a/plugins/authenticator/CHANGELOG.md b/plugins/authenticator/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/authenticator/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/authenticator/Cargo.toml b/plugins/authenticator/Cargo.toml index 007e63f4..4ce3b98e 100644 --- a/plugins/authenticator/Cargo.toml +++ b/plugins/authenticator/Cargo.toml @@ -1,20 +1,20 @@ [package] name = "tauri-plugin-authenticator" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Use hardware security-keys in your Tauri App." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } + +[target."cfg(not(any(target_os = \"android\", target_os = \"ios\")))".dependencies] authenticator = "0.3.1" once_cell = "1" sha2 = "0.10" diff --git a/plugins/authenticator/README.md b/plugins/authenticator/README.md index c64fecdf..bcdedeab 100644 --- a/plugins/authenticator/README.md +++ b/plugins/authenticator/README.md @@ -2,9 +2,11 @@ Use hardware security-keys in your Tauri App. +- Supported platforms: Windows, Linux, FreeBSD, NetBSD, OpenBSD, and macOS. + ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -17,9 +19,10 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: `src-tauri/Cargo.toml` ```toml -[dependencies] -tauri-plugin-authenticator = "0.1" -# or through git +# you can add the dependencies on the `[dependencies]` section if you do not target mobile +[target."cfg(not(any(target_os = \"android\", target_os = \"ios\")))".dependencies] +tauri-plugin-authenticator = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-authenticator = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -27,6 +30,16 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. +```sh +pnpm add @tauri-apps/plugin-authenticator +# or +npm add @tauri-apps/plugin-authenticator +# or +yarn add @tauri-apps/plugin-authenticator +``` + +Alternatively with Git: + ```sh pnpm add https://github.com/tauri-apps/tauri-plugin-authenticator#v2 # or @@ -44,7 +57,11 @@ First you need to register the core plugin with Tauri: ```rust fn main() { tauri::Builder::default() - .plugin(tauri_plugin_authenticator::init()) + .setup(|app| { + #[cfg(desktop)] + app.handle().plugin(tauri_plugin_authenticator::init())?; + Ok(()) + }) .run(tauri::generate_context!()) .expect("error while running tauri application"); } @@ -53,7 +70,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { Authenticator } from "tauri-plugin-authenticator-api"; +import { Authenticator } from "@tauri-apps/plugin-authenticator"; const auth = new Authenticator(); auth.init(); // initialize transports diff --git a/plugins/authenticator/guest-js/index.ts b/plugins/authenticator/guest-js/index.ts index 8b4a533c..c7bb51a1 100644 --- a/plugins/authenticator/guest-js/index.ts +++ b/plugins/authenticator/guest-js/index.ts @@ -1,12 +1,20 @@ -import { invoke } from "@tauri-apps/api/tauri"; +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} export class Authenticator { async init(): Promise { - return await invoke("plugin:authenticator|init_auth"); + return await window.__TAURI_INVOKE__("plugin:authenticator|init_auth"); } async register(challenge: string, application: string): Promise { - return await invoke("plugin:authenticator|register", { + return await window.__TAURI_INVOKE__("plugin:authenticator|register", { timeout: 10000, challenge, application, @@ -19,12 +27,15 @@ export class Authenticator { registerData: string, clientData: string ): Promise { - return await invoke("plugin:authenticator|verify_registration", { - challenge, - application, - registerData, - clientData, - }); + return await window.__TAURI_INVOKE__( + "plugin:authenticator|verify_registration", + { + challenge, + application, + registerData, + clientData, + } + ); } async sign( @@ -32,7 +43,7 @@ export class Authenticator { application: string, keyHandle: string ): Promise { - return await invoke("plugin:authenticator|sign", { + return await window.__TAURI_INVOKE__("plugin:authenticator|sign", { timeout: 10000, challenge, application, @@ -48,13 +59,16 @@ export class Authenticator { keyHandle: string, pubkey: string ): Promise { - return await invoke("plugin:authenticator|verify_signature", { - challenge, - application, - signData, - clientData, - keyHandle, - pubkey, - }); + return await window.__TAURI_INVOKE__( + "plugin:authenticator|verify_signature", + { + challenge, + application, + signData, + clientData, + keyHandle, + pubkey, + } + ); } } diff --git a/plugins/authenticator/package.json b/plugins/authenticator/package.json index 7374695f..08c5a25a 100644 --- a/plugins/authenticator/package.json +++ b/plugins/authenticator/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-authenticator-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-authenticator", + "version": "2.0.0-alpha.0", "description": "Use hardware security-keys in your Tauri App.", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/authenticator/src/api-iife.js b/plugins/authenticator/src/api-iife.js new file mode 100644 index 00000000..07f75f70 --- /dev/null +++ b/plugins/authenticator/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_AUTHENTICATOR__=function(t){"use strict";return t.Authenticator=class{async init(){return await window.__TAURI_INVOKE__("plugin:authenticator|init_auth")}async register(t,i){return await window.__TAURI_INVOKE__("plugin:authenticator|register",{timeout:1e4,challenge:t,application:i})}async verifyRegistration(t,i,a,n){return await window.__TAURI_INVOKE__("plugin:authenticator|verify_registration",{challenge:t,application:i,registerData:a,clientData:n})}async sign(t,i,a){return await window.__TAURI_INVOKE__("plugin:authenticator|sign",{timeout:1e4,challenge:t,application:i,keyHandle:a})}async verifySignature(t,i,a,n,e,_){return await window.__TAURI_INVOKE__("plugin:authenticator|verify_signature",{challenge:t,application:i,signData:a,clientData:n,keyHandle:e,pubkey:_})}},t}({});Object.defineProperty(window.__TAURI__,"authenticator",{value:__TAURI_AUTHENTICATOR__})} diff --git a/plugins/authenticator/src/auth.rs b/plugins/authenticator/src/auth.rs index c334173d..34bc332b 100644 --- a/plugins/authenticator/src/auth.rs +++ b/plugins/authenticator/src/auth.rs @@ -1,4 +1,4 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT diff --git a/plugins/authenticator/src/error.rs b/plugins/authenticator/src/error.rs index 87a393d2..8cc5df00 100644 --- a/plugins/authenticator/src/error.rs +++ b/plugins/authenticator/src/error.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use serde::{Serialize, Serializer}; #[derive(Debug, thiserror::Error)] diff --git a/plugins/authenticator/src/lib.rs b/plugins/authenticator/src/lib.rs index ef889e21..9e6785d0 100644 --- a/plugins/authenticator/src/lib.rs +++ b/plugins/authenticator/src/lib.rs @@ -1,7 +1,9 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT +#![cfg(not(any(target_os = "android", target_os = "ios")))] + mod auth; mod error; mod u2f; @@ -65,6 +67,7 @@ fn verify_signature( pub fn init() -> TauriPlugin { PluginBuilder::new("authenticator") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![ init_auth, register, diff --git a/plugins/authenticator/src/u2f.rs b/plugins/authenticator/src/u2f.rs index e8bd5de9..12f1d6c3 100644 --- a/plugins/authenticator/src/u2f.rs +++ b/plugins/authenticator/src/u2f.rs @@ -1,4 +1,4 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT diff --git a/plugins/authenticator/tsconfig.json b/plugins/authenticator/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/authenticator/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/authenticator/tsconfig.json b/plugins/authenticator/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/authenticator/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/autostart/CHANGELOG.md b/plugins/autostart/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/autostart/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/autostart/Cargo.toml b/plugins/autostart/Cargo.toml index 8d0abc50..15e757bd 100644 --- a/plugins/autostart/Cargo.toml +++ b/plugins/autostart/Cargo.toml @@ -1,18 +1,16 @@ [package] name = "tauri-plugin-autostart" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Automatically launch your application at startup." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true -auto-launch = "0.4" \ No newline at end of file +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } +auto-launch = "0.4" diff --git a/plugins/autostart/README.md b/plugins/autostart/README.md index fa787275..f14fd2c2 100644 --- a/plugins/autostart/README.md +++ b/plugins/autostart/README.md @@ -4,7 +4,7 @@ Automatically launch your application at startup. Supports Windows, Mac (via App ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-autostart = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-autostart = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-autostart +# or +npm add @tauri-apps/plugin-autostart +# or +yarn add @tauri-apps/plugin-autostart + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-autostart#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-autostart#v2 @@ -53,7 +62,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { enable, isEnabled, disable } from "tauri-plugin-autostart-api"; +import { enable, isEnabled, disable } from "@tauri-apps/plugin-autostart"; await enable(); diff --git a/plugins/autostart/guest-js/index.ts b/plugins/autostart/guest-js/index.ts index 0d43fe6e..66d71a57 100644 --- a/plugins/autostart/guest-js/index.ts +++ b/plugins/autostart/guest-js/index.ts @@ -1,17 +1,21 @@ -// Copyright 2019-2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT -import { invoke } from "@tauri-apps/api/tauri"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} export async function isEnabled(): Promise { - return await invoke("plugin:autostart|is_enabled"); + return await window.__TAURI_INVOKE__("plugin:autostart|is_enabled"); } export async function enable(): Promise { - await invoke("plugin:autostart|enable"); + await window.__TAURI_INVOKE__("plugin:autostart|enable"); } export async function disable(): Promise { - await invoke("plugin:autostart|disable"); + await window.__TAURI_INVOKE__("plugin:autostart|disable"); } diff --git a/plugins/autostart/package.json b/plugins/autostart/package.json index f8cf56cb..5557933d 100644 --- a/plugins/autostart/package.json +++ b/plugins/autostart/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-autostart-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-autostart", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/autostart/src/api-iife.js b/plugins/autostart/src/api-iife.js new file mode 100644 index 00000000..468886f4 --- /dev/null +++ b/plugins/autostart/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_AUTOSTART__=function(_){"use strict";return _.disable=async function(){await window.__TAURI_INVOKE__("plugin:autostart|disable")},_.enable=async function(){await window.__TAURI_INVOKE__("plugin:autostart|enable")},_.isEnabled=async function(){return await window.__TAURI_INVOKE__("plugin:autostart|is_enabled")},_}({});Object.defineProperty(window.__TAURI__,"autostart",{value:__TAURI_AUTOSTART__})} diff --git a/plugins/autostart/src/lib.rs b/plugins/autostart/src/lib.rs index dc9f38bb..91c6e4ec 100644 --- a/plugins/autostart/src/lib.rs +++ b/plugins/autostart/src/lib.rs @@ -1,7 +1,9 @@ -// Copyright 2019-2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT +#![cfg(not(any(target_os = "android", target_os = "ios")))] + use auto_launch::{AutoLaunch, AutoLaunchBuilder}; #[cfg(target_os = "macos")] use log::info; @@ -97,6 +99,7 @@ pub fn init( args: Option>, ) -> TauriPlugin { Builder::new("autostart") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![enable, disable, is_enabled]) .setup(move |app, _api| { let mut builder = AutoLaunchBuilder::new(); @@ -120,7 +123,7 @@ pub fn init( let exe_path = current_exe.canonicalize()?.display().to_string(); let parts: Vec<&str> = exe_path.split(".app/").collect(); let app_path = if parts.len() == 2 { - format!("{}.app", parts.get(0).unwrap().to_string()) + format!("{}.app", parts.first().unwrap()) } else { exe_path }; diff --git a/plugins/autostart/tsconfig.json b/plugins/autostart/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/autostart/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/autostart/tsconfig.json b/plugins/autostart/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/autostart/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/barcode-scanner/README.md b/plugins/barcode-scanner/README.md index eb1a850d..7f590edc 100644 --- a/plugins/barcode-scanner/README.md +++ b/plugins/barcode-scanner/README.md @@ -26,11 +26,18 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh -pnpm add tauri-plugin-barcode-scanner-api +pnpm add @tauri-apps/plugin-barcode-scanner # or -npm add tauri-plugin-barcode-scanner-api +npm add @tauri-apps/plugin-barcode-scanner # or -yarn add tauri-plugin-barcode-scanner-api +yarn add @tauri-apps/plugin-barcode-scanner + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-barcode-scanner#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-barcode-scanner#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-barcode-scanner#v2 ``` ## Usage diff --git a/plugins/barcode-scanner/package.json b/plugins/barcode-scanner/package.json index 6067ad10..6df0d8d7 100644 --- a/plugins/barcode-scanner/package.json +++ b/plugins/barcode-scanner/package.json @@ -1,5 +1,5 @@ { - "name": "tauri-plugin-barcode-scanner-api", + "name": "@tauri-apps/plugin-barcode-scanner", "version": "0.0.0", "license": "MIT or APACHE-2.0", "authors": [ @@ -27,6 +27,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/barcode-scanner/src/api-iife.js b/plugins/barcode-scanner/src/api-iife.js new file mode 100644 index 00000000..3236f86e --- /dev/null +++ b/plugins/barcode-scanner/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_BARCODESCANNER__=function(e){"use strict";var n=Object.defineProperty,t=(e,n,t)=>{if(!n.has(e))throw TypeError("Cannot "+t)},r=(e,n,r)=>(t(e,n,"read from private field"),r?r.call(e):n.get(e)),a=(e,n,r,a)=>(t(e,n,"write to private field"),a?a.call(e,r):n.set(e,r),r);function i(e,n=!1){let t=window.crypto.getRandomValues(new Uint32Array(1))[0],r=`_${t}`;return Object.defineProperty(window,r,{value:t=>(n&&Reflect.deleteProperty(window,r),e?.(t)),writable:!1,configurable:!0}),t}((e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})})({},{Channel:()=>c,PluginListener:()=>o,addPluginListener:()=>l,convertFileSrc:()=>d,invoke:()=>u,transformCallback:()=>i});var s,c=class{constructor(){this.__TAURI_CHANNEL_MARKER__=!0,((e,n,t)=>{if(n.has(e))throw TypeError("Cannot add the same private member more than once");n instanceof WeakSet?n.add(e):n.set(e,t)})(this,s,(()=>{})),this.id=i((e=>{r(this,s).call(this,e)}))}set onmessage(e){a(this,s,e)}get onmessage(){return r(this,s)}toJSON(){return`__CHANNEL__:${this.id}`}};s=new WeakMap;var o=class{constructor(e,n,t){this.plugin=e,this.event=n,this.channelId=t}async unregister(){return u(`plugin:${this.plugin}|remove_listener`,{event:this.event,channelId:this.channelId})}};async function l(e,n,t){let r=new c;return r.onmessage=t,u(`plugin:${e}|register_listener`,{event:n,handler:r}).then((()=>new o(e,n,r.id)))}async function u(e,n={}){return new Promise(((t,r)=>{let a=i((e=>{t(e),Reflect.deleteProperty(window,`_${s}`)}),!0),s=i((e=>{r(e),Reflect.deleteProperty(window,`_${a}`)}),!0);window.__TAURI_IPC__({cmd:e,callback:a,error:s,...n})}))}function d(e,n="asset"){let t=encodeURIComponent(e);return navigator.userAgent.includes("Windows")?`https://${n}.localhost/${t}`:`${n}://localhost/${t}`}return e.cancel=async function(){return await u("plugin:barcodeScanner|cancel")},e.checkPermissions=async function(){return await u("plugin:barcodeScanner|check_permissions").then((e=>e.camera))},e.openAppSettings=async function(){return await u("plugin:barcodeScanner|open_app_settings")},e.prepare=async function(e){return await u("plugin:barcodeScanner|prepare",{...e})},e.requestPermissions=async function(){return await u("plugin:barcodeScanner|request_permissions").then((e=>e.camera))},e.scan=async function(e){return await u("plugin:barcodeScanner|scan",{...e})},e}({});Object.defineProperty(window.__TAURI__,"barcodeScanner",{value:__TAURI_BARCODESCANNER__})} diff --git a/plugins/cli/CHANGELOG.md b/plugins/cli/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/cli/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/cli/Cargo.toml b/plugins/cli/Cargo.toml index f6dc2cd3..b3a2ca7d 100644 --- a/plugins/cli/Cargo.toml +++ b/plugins/cli/Cargo.toml @@ -1,14 +1,15 @@ [package] name = "tauri-plugin-cli" -version = "0.0.0" -edition.workspace = true -authors.workspace = true -license.workspace = true +version = "2.0.0-alpha.0" +description = "Parse arguments from your Tauri application's command line interface." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true -clap = { version = "4", features = ["string"] } +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } +clap = { version = "4", features = [ "string" ] } diff --git a/plugins/cli/README.md b/plugins/cli/README.md index 2d567acb..5de6c9e8 100644 --- a/plugins/cli/README.md +++ b/plugins/cli/README.md @@ -1,10 +1,12 @@ -![plugin-cli](banner.jpg) +# CLI - +Parse arguments from your Command Line Interface. + +- Supported platforms: Windows, Linux and macOS. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -17,8 +19,11 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: `src-tauri/Cargo.toml` ```toml -[dependencies] -tauri-plugin-cli = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "next" } +# you can add the dependencies on the `[dependencies]` section if you do not target mobile +[target."cfg(not(any(target_os = \"android\", target_os = \"ios\")))".dependencies] +tauri-plugin-cli = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-cli = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` You can install the JavaScript Guest bindings using your preferred JavaScript package manager: @@ -26,6 +31,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-cli +# or +npm add @tauri-apps/plugin-cli +# or +yarn add @tauri-apps/plugin-cli + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-cli#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-cli#v2 @@ -42,7 +54,11 @@ First you need to register the core plugin with Tauri: ```rust fn main() { tauri::Builder::default() - .plugin(tauri_plugin_cli::init()) + .setup(|app| { + #[cfg(desktop)] + app.handle().plugin(tauri_plugin_cli::init())?; + Ok(()) + }) .run(tauri::generate_context!()) .expect("error while running tauri application"); } @@ -51,7 +67,18 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript - +import { getMatches } from "@tauri-apps/plugin-cli"; +const matches = await getMatches(); +if (matches.subcommand?.name === "run") { + // `./your-app run $ARGS` was executed + const args = matches.subcommand?.matches.args; + if ("debug" in args) { + // `./your-app run --debug` was executed + } +} else { + const args = matches.args; + // `./your-app $ARGS` was executed +} ``` ## Contributing diff --git a/plugins/cli/guest-js/index.ts b/plugins/cli/guest-js/index.ts index 81eaae86..87c1a97e 100644 --- a/plugins/cli/guest-js/index.ts +++ b/plugins/cli/guest-js/index.ts @@ -8,10 +8,14 @@ * @module */ -import { invoke } from "@tauri-apps/api/tauri"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} /** - * @since 1.0.0 + * @since 2.0.0 */ interface ArgMatch { /** @@ -27,7 +31,7 @@ interface ArgMatch { } /** - * @since 1.0.0 + * @since 2.0.0 */ interface SubcommandMatch { name: string; @@ -35,7 +39,7 @@ interface SubcommandMatch { } /** - * @since 1.0.0 + * @since 2.0.0 */ interface CliMatches { args: Record; @@ -47,7 +51,7 @@ interface CliMatches { * * @example * ```typescript - * import { getMatches } from 'tauri-plugin-cli-api'; + * import { getMatches } from '@tauri-apps/plugin-cli'; * const matches = await getMatches(); * if (matches.subcommand?.name === 'run') { * // `./your-app run $ARGS` was executed @@ -61,10 +65,10 @@ interface CliMatches { * } * ``` * - * @since 1.0.0 + * @since 2.0.0 */ async function getMatches(): Promise { - return await invoke("plugin:cli|cli_matches"); + return await window.__TAURI_INVOKE__("plugin:cli|cli_matches"); } export type { ArgMatch, SubcommandMatch, CliMatches }; diff --git a/plugins/cli/package.json b/plugins/cli/package.json index aa29aa22..c47c63e4 100644 --- a/plugins/cli/package.json +++ b/plugins/cli/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-cli-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-cli", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/cli/src/api-iife.js b/plugins/cli/src/api-iife.js new file mode 100644 index 00000000..79da44bb --- /dev/null +++ b/plugins/cli/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_CLI__=function(_){"use strict";return _.getMatches=async function(){return await window.__TAURI_INVOKE__("plugin:cli|cli_matches")},_}({});Object.defineProperty(window.__TAURI__,"cli",{value:__TAURI_CLI__})} diff --git a/plugins/cli/src/config.rs b/plugins/cli/src/config.rs index f00b8370..f7f36a0e 100644 --- a/plugins/cli/src/config.rs +++ b/plugins/cli/src/config.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::collections::HashMap; use serde::Deserialize; diff --git a/plugins/cli/src/error.rs b/plugins/cli/src/error.rs index 8dee7f66..b4bd2872 100644 --- a/plugins/cli/src/error.rs +++ b/plugins/cli/src/error.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use serde::{Serialize, Serializer}; #[derive(Debug, thiserror::Error)] diff --git a/plugins/cli/src/lib.rs b/plugins/cli/src/lib.rs index aaa13498..096b62a2 100644 --- a/plugins/cli/src/lib.rs +++ b/plugins/cli/src/lib.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use tauri::{ plugin::{Builder, PluginApi, TauriPlugin}, AppHandle, Manager, Runtime, State, @@ -11,12 +15,11 @@ use config::{Arg, Config}; pub use error::Error; type Result = std::result::Result; -// TODO: use PluginApi#app when 2.0.0-alpha.9 is released -pub struct Cli(PluginApi, AppHandle); +pub struct Cli(PluginApi); impl Cli { pub fn matches(&self) -> Result { - parser::get_matches(self.0.config(), self.1.package_info()) + parser::get_matches(self.0.config(), self.0.app().package_info()) } } @@ -37,9 +40,10 @@ fn cli_matches(_app: AppHandle, cli: State<'_, Cli>) -> Result pub fn init() -> TauriPlugin { Builder::new("cli") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![cli_matches]) .setup(|app, api| { - app.manage(Cli(api, app.clone())); + app.manage(Cli(api)); Ok(()) }) .build() diff --git a/plugins/cli/src/parser.rs b/plugins/cli/src/parser.rs index d68fd10a..69a926c1 100644 --- a/plugins/cli/src/parser.rs +++ b/plugins/cli/src/parser.rs @@ -72,10 +72,10 @@ impl Matches { /// # Examples /// /// ```rust,no_run -/// use tauri_plugin_cli::get_matches; +/// use tauri_plugin_cli::CliExt; /// tauri::Builder::default() /// .setup(|app| { -/// let matches = get_matches(app.config().tauri.cli.as_ref().unwrap(), app.package_info())?; +/// let matches = app.cli().matches()?; /// Ok(()) /// }); /// ``` diff --git a/plugins/clipboard/.gitignore b/plugins/clipboard-manager/.gitignore similarity index 100% rename from plugins/clipboard/.gitignore rename to plugins/clipboard-manager/.gitignore diff --git a/plugins/clipboard-manager/CHANGELOG.md b/plugins/clipboard-manager/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/clipboard-manager/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/clipboard-manager/Cargo.toml b/plugins/clipboard-manager/Cargo.toml new file mode 100644 index 00000000..c0881b49 --- /dev/null +++ b/plugins/clipboard-manager/Cargo.toml @@ -0,0 +1,21 @@ +[package] +name = "tauri-plugin-clipboard-manager" +version = "2.0.0-alpha.0" +description = "Read and write to the system clipboard." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } +links = "tauri-plugin-clipboard-manager" + +[build-dependencies] +tauri-build = { workspace = true } + +[dependencies] +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } + +[target."cfg(any(target_os = \"macos\", windows, target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"openbsd\", target_os = \"netbsd\"))".dependencies] +arboard = "3" diff --git a/plugins/fs-watch/LICENSE.spdx b/plugins/clipboard-manager/LICENSE.spdx similarity index 100% rename from plugins/fs-watch/LICENSE.spdx rename to plugins/clipboard-manager/LICENSE.spdx diff --git a/plugins/fs-watch/LICENSE_APACHE-2.0 b/plugins/clipboard-manager/LICENSE_APACHE-2.0 similarity index 100% rename from plugins/fs-watch/LICENSE_APACHE-2.0 rename to plugins/clipboard-manager/LICENSE_APACHE-2.0 diff --git a/plugins/fs-watch/LICENSE_MIT b/plugins/clipboard-manager/LICENSE_MIT similarity index 100% rename from plugins/fs-watch/LICENSE_MIT rename to plugins/clipboard-manager/LICENSE_MIT diff --git a/plugins/clipboard-manager/README.md b/plugins/clipboard-manager/README.md new file mode 100644 index 00000000..9767c310 --- /dev/null +++ b/plugins/clipboard-manager/README.md @@ -0,0 +1,76 @@ +# Clipboard Manager + +Read and write to the system clipboard. + +## Install + +_This plugin requires a Rust version of at least **1.65**_ + +There are three general methods of installation that we can recommend. + +1. Use crates.io and npm (easiest, and requires you to trust that our publishing pipeline worked) +2. Pull sources directly from Github using git tags / revision hashes (most secure) +3. Git submodule install this repo in your tauri project and then use file protocol to ingest the source (most secure, but inconvenient to use) + +Install the Core plugin by adding the following to your `Cargo.toml` file: + +`src-tauri/Cargo.toml` + +```toml +[dependencies] +tauri-plugin-clipboard-manager = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-clipboard-manager = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +``` + +You can install the JavaScript Guest bindings using your preferred JavaScript package manager: + +> Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. + +```sh +pnpm add @tauri-apps/plugin-clipboard-manager +# or +npm add @tauri-apps/plugin-clipboard-manager +# or +yarn add @tauri-apps/plugin-clipboard-manager + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-clipboard-manager#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-clipboard-manager#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-clipboard-manager#v2 +``` + +## Usage + +First you need to register the core plugin with Tauri: + +`src-tauri/src/main.rs` + +```rust +fn main() { + tauri::Builder::default() + .plugin(tauri_plugin_clipboard_manager::init()) + .run(tauri::generate_context!()) + .expect("error while running tauri application"); +} +``` + +Afterwards all the plugin's APIs are available through the JavaScript guest bindings: + +```javascript +import { writeText, readText } from "@tauri-apps/plugin-clipboard-manager"; +await writeText("Tauri is awesome!"); +assert(await readText(), "Tauri is awesome!"); +``` + +## Contributing + +PRs accepted. Please make sure to read the Contributing Guide before making a pull request. + +## License + +Code: (c) 2015 - Present - The Tauri Programme within The Commons Conservancy. + +MIT or MIT/Apache 2.0 where applicable. diff --git a/plugins/clipboard/android/.gitignore b/plugins/clipboard-manager/android/.gitignore similarity index 100% rename from plugins/clipboard/android/.gitignore rename to plugins/clipboard-manager/android/.gitignore diff --git a/plugins/clipboard/android/build.gradle.kts b/plugins/clipboard-manager/android/build.gradle.kts similarity index 100% rename from plugins/clipboard/android/build.gradle.kts rename to plugins/clipboard-manager/android/build.gradle.kts diff --git a/plugins/clipboard/android/proguard-rules.pro b/plugins/clipboard-manager/android/proguard-rules.pro similarity index 100% rename from plugins/clipboard/android/proguard-rules.pro rename to plugins/clipboard-manager/android/proguard-rules.pro diff --git a/plugins/clipboard/android/settings.gradle b/plugins/clipboard-manager/android/settings.gradle similarity index 100% rename from plugins/clipboard/android/settings.gradle rename to plugins/clipboard-manager/android/settings.gradle diff --git a/plugins/clipboard/android/src/androidTest/java/ExampleInstrumentedTest.kt b/plugins/clipboard-manager/android/src/androidTest/java/ExampleInstrumentedTest.kt similarity index 82% rename from plugins/clipboard/android/src/androidTest/java/ExampleInstrumentedTest.kt rename to plugins/clipboard-manager/android/src/androidTest/java/ExampleInstrumentedTest.kt index 2938f836..02e6984b 100644 --- a/plugins/clipboard/android/src/androidTest/java/ExampleInstrumentedTest.kt +++ b/plugins/clipboard-manager/android/src/androidTest/java/ExampleInstrumentedTest.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.clipboard import androidx.test.platform.app.InstrumentationRegistry diff --git a/plugins/clipboard/android/src/main/AndroidManifest.xml b/plugins/clipboard-manager/android/src/main/AndroidManifest.xml similarity index 100% rename from plugins/clipboard/android/src/main/AndroidManifest.xml rename to plugins/clipboard-manager/android/src/main/AndroidManifest.xml diff --git a/plugins/clipboard/android/src/main/java/ClipboardPlugin.kt b/plugins/clipboard-manager/android/src/main/java/ClipboardPlugin.kt similarity index 92% rename from plugins/clipboard/android/src/main/java/ClipboardPlugin.kt rename to plugins/clipboard-manager/android/src/main/java/ClipboardPlugin.kt index ece3e45e..8f622251 100644 --- a/plugins/clipboard/android/src/main/java/ClipboardPlugin.kt +++ b/plugins/clipboard-manager/android/src/main/java/ClipboardPlugin.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.clipboard import android.R.attr.value diff --git a/plugins/clipboard/android/src/test/java/ExampleUnitTest.kt b/plugins/clipboard-manager/android/src/test/java/ExampleUnitTest.kt similarity index 70% rename from plugins/clipboard/android/src/test/java/ExampleUnitTest.kt rename to plugins/clipboard-manager/android/src/test/java/ExampleUnitTest.kt index 6a889763..282700f2 100644 --- a/plugins/clipboard/android/src/test/java/ExampleUnitTest.kt +++ b/plugins/clipboard-manager/android/src/test/java/ExampleUnitTest.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.clipboard import org.junit.Test diff --git a/plugins/clipboard/build.rs b/plugins/clipboard-manager/build.rs similarity index 62% rename from plugins/clipboard/build.rs rename to plugins/clipboard-manager/build.rs index 86ac3f0a..743096a6 100644 --- a/plugins/clipboard/build.rs +++ b/plugins/clipboard-manager/build.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::process::exit; fn main() { diff --git a/plugins/clipboard/guest-js/index.ts b/plugins/clipboard-manager/guest-js/index.ts similarity index 56% rename from plugins/clipboard/guest-js/index.ts rename to plugins/clipboard-manager/guest-js/index.ts index 3dd2a67f..bd68d724 100644 --- a/plugins/clipboard/guest-js/index.ts +++ b/plugins/clipboard-manager/guest-js/index.ts @@ -5,26 +5,14 @@ /** * Read and write to the system clipboard. * - * The APIs must be added to [`tauri.allowlist.clipboard`](https://tauri.app/v1/api/config/#allowlistconfig.clipboard) in `tauri.conf.json`: - * ```json - * { - * "tauri": { - * "allowlist": { - * "clipboard": { - * "all": true, // enable all Clipboard APIs - * "writeText": true, - * "readText": true - * } - * } - * } - * } - * ``` - * It is recommended to allowlist only the APIs you use for optimal bundle size and security. - * * @module */ -import { invoke } from "@tauri-apps/api/tauri"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} interface Clip { kind: K; @@ -37,20 +25,20 @@ type ClipResponse = Clip<"PlainText", string>; * Writes plain text to the clipboard. * @example * ```typescript - * import { writeText, readText } from 'tauri-plugin-clipboard-api'; + * import { writeText, readText } from '@tauri-apps/plugin-clipboard-manager'; * await writeText('Tauri is awesome!'); * assert(await readText(), 'Tauri is awesome!'); * ``` * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0. + * @since 2.0.0 */ async function writeText( text: string, opts?: { label?: string } ): Promise { - return invoke("plugin:clipboard|write", { + return window.__TAURI_INVOKE__("plugin:clipboard|write", { data: { kind: "PlainText", options: { @@ -65,13 +53,15 @@ async function writeText( * Gets the clipboard content as plain text. * @example * ```typescript - * import { readText } from 'tauri-plugin-clipboard-api'; + * import { readText } from '@tauri-apps/plugin-clipboard-manager'; * const clipboardText = await readText(); * ``` - * @since 1.0.0. + * @since 2.0.0 */ async function readText(): Promise { - const kind: ClipResponse = await invoke("plugin:clipboard|read"); + const kind: ClipResponse = await window.__TAURI_INVOKE__( + "plugin:clipboard|read" + ); return kind.options; } diff --git a/plugins/clipboard/ios/.gitignore b/plugins/clipboard-manager/ios/.gitignore similarity index 100% rename from plugins/clipboard/ios/.gitignore rename to plugins/clipboard-manager/ios/.gitignore diff --git a/plugins/clipboard/ios/Package.swift b/plugins/clipboard-manager/ios/Package.swift similarity index 69% rename from plugins/clipboard/ios/Package.swift rename to plugins/clipboard-manager/ios/Package.swift index e38a8bb6..f6200857 100644 --- a/plugins/clipboard/ios/Package.swift +++ b/plugins/clipboard-manager/ios/Package.swift @@ -1,19 +1,21 @@ // swift-tools-version:5.3 -// The swift-tools-version declares the minimum version of Swift required to build this package. +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT import PackageDescription let package = Package( - name: "tauri-plugin-clipboard", + name: "tauri-plugin-clipboard-manager", platforms: [ .iOS(.v13), ], products: [ // Products define the executables and libraries a package produces, and make them visible to other packages. .library( - name: "tauri-plugin-clipboard", + name: "tauri-plugin-clipboard-manager", type: .static, - targets: ["tauri-plugin-clipboard"]), + targets: ["tauri-plugin-clipboard-manager"]), ], dependencies: [ .package(name: "Tauri", path: "../.tauri/tauri-api") @@ -22,7 +24,7 @@ let package = Package( // Targets are the basic building blocks of a package. A target can define a module or a test suite. // Targets can depend on other targets in this package, and on products in packages this package depends on. .target( - name: "tauri-plugin-clipboard", + name: "tauri-plugin-clipboard-manager", dependencies: [ .byName(name: "Tauri") ], diff --git a/plugins/clipboard/ios/README.md b/plugins/clipboard-manager/ios/README.md similarity index 100% rename from plugins/clipboard/ios/README.md rename to plugins/clipboard-manager/ios/README.md diff --git a/plugins/clipboard/ios/Sources/ClipboardPlugin.swift b/plugins/clipboard-manager/ios/Sources/ClipboardPlugin.swift similarity index 81% rename from plugins/clipboard/ios/Sources/ClipboardPlugin.swift rename to plugins/clipboard-manager/ios/Sources/ClipboardPlugin.swift index cde6fa52..5f84aa65 100644 --- a/plugins/clipboard/ios/Sources/ClipboardPlugin.swift +++ b/plugins/clipboard-manager/ios/Sources/ClipboardPlugin.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import UIKit import WebKit import Tauri @@ -37,6 +41,6 @@ class ClipboardPlugin: Plugin { } @_cdecl("init_plugin_clipboard") -func initPlugin(name: SRString, webview: WKWebView?) { - Tauri.registerPlugin(webview: webview, name: name.toString(), plugin: ClipboardPlugin()) +func initPlugin() -> Plugin { + return ClipboardPlugin() } diff --git a/plugins/clipboard/ios/Tests/PluginTests/PluginTests.swift b/plugins/clipboard-manager/ios/Tests/PluginTests/PluginTests.swift similarity index 55% rename from plugins/clipboard/ios/Tests/PluginTests/PluginTests.swift rename to plugins/clipboard-manager/ios/Tests/PluginTests/PluginTests.swift index f1657dea..e5d54b38 100644 --- a/plugins/clipboard/ios/Tests/PluginTests/PluginTests.swift +++ b/plugins/clipboard-manager/ios/Tests/PluginTests/PluginTests.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import XCTest @testable import ClipboardPlugin diff --git a/plugins/clipboard/package.json b/plugins/clipboard-manager/package.json similarity index 82% rename from plugins/clipboard/package.json rename to plugins/clipboard-manager/package.json index d51585f4..0121be50 100644 --- a/plugins/clipboard/package.json +++ b/plugins/clipboard-manager/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-clipboard-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-clipboard-manager", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/fs-watch/rollup.config.mjs b/plugins/clipboard-manager/rollup.config.mjs similarity index 100% rename from plugins/fs-watch/rollup.config.mjs rename to plugins/clipboard-manager/rollup.config.mjs diff --git a/plugins/clipboard-manager/src/api-iife.js b/plugins/clipboard-manager/src/api-iife.js new file mode 100644 index 00000000..b2a3574f --- /dev/null +++ b/plugins/clipboard-manager/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_CLIPBOARDMANAGER__=function(_){"use strict";return _.readText=async function(){return(await window.__TAURI_INVOKE__("plugin:clipboard|read")).options},_.writeText=async function(_,n){return window.__TAURI_INVOKE__("plugin:clipboard|write",{data:{kind:"PlainText",options:{label:null==n?void 0:n.label,text:_}}})},_}({});Object.defineProperty(window.__TAURI__,"clipboardManager",{value:__TAURI_CLIPBOARDMANAGER__})} diff --git a/plugins/clipboard/src/commands.rs b/plugins/clipboard-manager/src/commands.rs similarity index 100% rename from plugins/clipboard/src/commands.rs rename to plugins/clipboard-manager/src/commands.rs diff --git a/plugins/clipboard/src/desktop.rs b/plugins/clipboard-manager/src/desktop.rs similarity index 100% rename from plugins/clipboard/src/desktop.rs rename to plugins/clipboard-manager/src/desktop.rs diff --git a/plugins/clipboard/src/error.rs b/plugins/clipboard-manager/src/error.rs similarity index 100% rename from plugins/clipboard/src/error.rs rename to plugins/clipboard-manager/src/error.rs diff --git a/plugins/clipboard/src/lib.rs b/plugins/clipboard-manager/src/lib.rs similarity index 95% rename from plugins/clipboard/src/lib.rs rename to plugins/clipboard-manager/src/lib.rs index a655d93e..7fc05348 100644 --- a/plugins/clipboard/src/lib.rs +++ b/plugins/clipboard-manager/src/lib.rs @@ -39,6 +39,7 @@ impl> crate::ClipboardExt for T { /// Initializes the plugin. pub fn init() -> TauriPlugin { Builder::new("clipboard") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![commands::write, commands::read]) .setup(|app, api| { #[cfg(mobile)] diff --git a/plugins/clipboard/src/mobile.rs b/plugins/clipboard-manager/src/mobile.rs similarity index 100% rename from plugins/clipboard/src/mobile.rs rename to plugins/clipboard-manager/src/mobile.rs diff --git a/plugins/clipboard/src/models.rs b/plugins/clipboard-manager/src/models.rs similarity index 100% rename from plugins/clipboard/src/models.rs rename to plugins/clipboard-manager/src/models.rs diff --git a/plugins/clipboard-manager/tsconfig.json b/plugins/clipboard-manager/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/clipboard-manager/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/clipboard/Cargo.lock b/plugins/clipboard/Cargo.lock deleted file mode 100644 index f81b2058..00000000 --- a/plugins/clipboard/Cargo.lock +++ /dev/null @@ -1,3584 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "aho-corasick" -version = "0.7.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" -dependencies = [ - "memchr", -] - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "anyhow" -version = "1.0.70" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7de8ce5e0f9f8d88245311066a578d72b7af3e7088f32783804676302df237e4" - -[[package]] -name = "atk" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39991bc421ddf72f70159011b323ff49b0f783cc676a7287c59453da2e2531cf" -dependencies = [ - "atk-sys", - "bitflags", - "glib", - "libc", -] - -[[package]] -name = "atk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11ad703eb64dc058024f0e57ccfa069e15a413b98dbd50a1a950e743b7f11148" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "base64" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" - -[[package]] -name = "base64" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "block" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" - -[[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 = "brotli" -version = "3.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a0b1dbcc8ae29329621f8d4f0d835787c1c38bb1401979b49d13b0b305ff68" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b6561fd3f895a11e8f72af2cb7d22e08366bebc2b6b57f7744c4bda27034744" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bstr" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d4260bcc2e8fc9df1eac4919a720effeb63a3f0952f5bf4944adfa18897f09" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" - -[[package]] -name = "bytemuck" -version = "1.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17febce684fd15d89027105661fec94afb475cb995fbc59d2865198446ba2eea" - -[[package]] -name = "byteorder" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" - -[[package]] -name = "bytes" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" -dependencies = [ - "serde", -] - -[[package]] -name = "cairo-rs" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3125b15ec28b84c238f6f476c6034016a5f6cc0221cb514ca46c532139fc97d" -dependencies = [ - "bitflags", - "cairo-sys-rs", - "glib", - "libc", - "once_cell", - "thiserror", -] - -[[package]] -name = "cairo-sys-rs" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c48f4af05fabdcfa9658178e1326efa061853f040ce7d72e33af6885196f421" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "cargo_toml" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bfbc36312494041e2cdd5f06697b7e89d4b76f42773a0b5556ac290ff22acc2" -dependencies = [ - "serde", - "toml 0.5.11", -] - -[[package]] -name = "cc" -version = "1.0.79" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" - -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - -[[package]] -name = "cfb" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d38f2da7a0a2c4ccf0065be06397cc26a81f4e528be095826eee9d4adbb8c60f" -dependencies = [ - "byteorder", - "fnv", - "uuid", -] - -[[package]] -name = "cfg-expr" -version = "0.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a35b255461940a32985c627ce82900867c61db1659764d3675ea81963f72a4c6" -dependencies = [ - "smallvec", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "cocoa" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f425db7937052c684daec3bd6375c8abe2d146dca4b8b143d6db777c39138f3a" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation", - "core-graphics", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa-foundation" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "931d3837c286f56e3c58423ce4eba12d08db2374461a785c86f672b08b5650d6" -dependencies = [ - "bitflags", - "block", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "color_quant" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" - -[[package]] -name = "combine" -version = "4.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" - -[[package]] -name = "core-graphics" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" -dependencies = [ - "bitflags", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" -dependencies = [ - "bitflags", - "core-foundation", - "foreign-types", - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "280a9f2d8b3a38871a3c8a46fb80db65e5e5ed97da80c4d08bf27fb63e35e181" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c063cd8cc95f5c377ed0d4b49a4b21f632396ff690e8470c29b3359b346984b" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "cssparser" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "754b69d351cdc2d8ee09ae203db831e005560fc6030da058f86ad60c92a9cb0a" -dependencies = [ - "cssparser-macros", - "dtoa-short", - "itoa 0.4.8", - "matches", - "phf 0.8.0", - "proc-macro2", - "quote", - "smallvec", - "syn 1.0.109", -] - -[[package]] -name = "cssparser-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfae75de57f2b2e85e8768c3ea840fd159c8f33e2b6522c7835b7abac81be16e" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ctor" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d2301688392eb071b0bf1a37be05c469d3cc4dbbd95df672fe28ab021e6a096" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 1.0.109", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "derive_more" -version = "0.99.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version", - "syn 1.0.109", -] - -[[package]] -name = "digest" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dirs-next" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" -dependencies = [ - "cfg-if", - "dirs-sys-next", -] - -[[package]] -name = "dirs-sys-next" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dispatch" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" - -[[package]] -name = "dtoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" - -[[package]] -name = "dtoa-short" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde03329ae10e79ede66c9ce4dc930aa8599043b0743008548680f25b91502d6" -dependencies = [ - "dtoa", -] - -[[package]] -name = "dunce" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bd4b30a6560bbd9b4620f4de34c3f14f60848e58a9b7216801afcb4c7b31c3c" - -[[package]] -name = "embed_plist" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" - -[[package]] -name = "encoding_rs" -version = "0.8.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071a31f4ee85403370b58aca746f01041ede6f0da2730960ad001edc2b71b394" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "errno" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bcfec3a70f97c962c307b2d2c56e358cf1d00b558d74262b5f929ee8cc7e73a" -dependencies = [ - "errno-dragonfly", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] - -[[package]] -name = "fastrand" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" -dependencies = [ - "instant", -] - -[[package]] -name = "fdeflate" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d329bdeac514ee06249dabc27877490f17f5d371ec693360768b838e19f3ae10" -dependencies = [ - "simd-adler32", -] - -[[package]] -name = "field-offset" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3cf3a800ff6e860c863ca6d4b16fd999db8b752819c1606884047b73e468535" -dependencies = [ - "memoffset", - "rustc_version", -] - -[[package]] -name = "filetime" -version = "0.2.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cbc844cecaee9d4443931972e1289c8ff485cb4cc2767cb03ca139ed6885153" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.2.16", - "windows-sys 0.48.0", -] - -[[package]] -name = "flate2" -version = "1.0.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" -dependencies = [ - "crc32fast", - "miniz_oxide 0.6.2", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futf" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df420e2e84819663797d1ec6544b13c5be84629e7bb00dc960d6917db2987843" -dependencies = [ - "mac", - "new_debug_unreachable", -] - -[[package]] -name = "futures-channel" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" -dependencies = [ - "futures-core", -] - -[[package]] -name = "futures-core" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" - -[[package]] -name = "futures-executor" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" - -[[package]] -name = "futures-macro" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "futures-sink" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" - -[[package]] -name = "futures-task" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" - -[[package]] -name = "futures-util" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" -dependencies = [ - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "fxhash" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" -dependencies = [ - "byteorder", -] - -[[package]] -name = "gdk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa9cb33da481c6c040404a11f8212d193889e9b435db2c14fd86987f630d3ce1" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk-pixbuf", - "gdk-sys", - "gio", - "glib", - "libc", - "pango", -] - -[[package]] -name = "gdk-pixbuf" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3578c60dee9d029ad86593ed88cb40f35c1b83360e12498d055022385dd9a05" -dependencies = [ - "bitflags", - "gdk-pixbuf-sys", - "gio", - "glib", - "libc", -] - -[[package]] -name = "gdk-pixbuf-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3092cf797a5f1210479ea38070d9ae8a5b8e9f8f1be9f32f4643c529c7d70016" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gdk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d76354f97a913e55b984759a997b693aa7dc71068c9e98bcce51aa167a0a5c5a" -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.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4511710212ed3020b61a8622a37aa6f0dd2a84516575da92e9b96928dcbe83ba" -dependencies = [ - "gdk-sys", - "glib-sys", - "gobject-sys", - "libc", - "pkg-config", - "system-deps", -] - -[[package]] -name = "gdkx11-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fa2bf8b5b8c414bc5d05e48b271896d0fd3ddb57464a3108438082da61de6af" -dependencies = [ - "gdk-sys", - "glib-sys", - "libc", - "system-deps", - "x11", -] - -[[package]] -name = "generator" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33a20a288a94683f5f4da0adecdbe095c94a77c295e514cc6484e9394dd8376e" -dependencies = [ - "cc", - "libc", - "log", - "rustversion", - "windows", -] - -[[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.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c85e1d9ab2eadba7e5040d4e09cbd6d072b76a557ad64e797c2cb9d4da21d7e4" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gio" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a1c84b4534a290a29160ef5c6eff2a9c95833111472e824fc5cb78b513dd092" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-io", - "futures-util", - "gio-sys", - "glib", - "libc", - "once_cell", - "pin-project-lite", - "smallvec", - "thiserror", -] - -[[package]] -name = "gio-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9b693b8e39d042a95547fc258a7b07349b1f0b48f4b2fa3108ba3c51c0b5229" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", - "winapi", -] - -[[package]] -name = "glib" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddd4df61a866ed7259d6189b8bcb1464989a77f1d85d25d002279bbe9dd38b2f" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-executor", - "futures-task", - "futures-util", - "gio-sys", - "glib-macros", - "glib-sys", - "gobject-sys", - "libc", - "once_cell", - "smallvec", - "thiserror", -] - -[[package]] -name = "glib-macros" -version = "0.16.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb1a9325847aa46f1e96ffea37611b9d51fc4827e67f79e7de502a297560a67b" -dependencies = [ - "anyhow", - "heck", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "glib-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c61a4f46316d06bfa33a7ac22df6f0524c8be58e3db2d9ca99ccb1f357b62a65" -dependencies = [ - "libc", - "system-deps", -] - -[[package]] -name = "glob" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" - -[[package]] -name = "globset" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "029d74589adefde59de1a0c4f4732695c32805624aec7b68d91503d4dba79afc" -dependencies = [ - "aho-corasick", - "bstr", - "fnv", - "log", - "regex", -] - -[[package]] -name = "gobject-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3520bb9c07ae2a12c7f2fbb24d4efc11231c8146a86956413fb1a79bb760a0f1" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gtk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4d3507d43908c866c805f74c9dd593c0ce7ba5c38e576e41846639cdcd4bee6" -dependencies = [ - "atk", - "bitflags", - "cairo-rs", - "field-offset", - "futures-channel", - "gdk", - "gdk-pixbuf", - "gio", - "glib", - "gtk-sys", - "gtk3-macros", - "libc", - "once_cell", - "pango", - "pkg-config", -] - -[[package]] -name = "gtk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b5f8946685d5fe44497007786600c2f368ff6b1e61a16251c89f72a97520a3" -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.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "096eb63c6fedf03bafe65e5924595785eaf1bcb7200dac0f2cbe9c9738f05ad8" -dependencies = [ - "anyhow", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "h2" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66b91535aa35fea1523ad1b86cb6b53c28e0ae566ba4a460f4457e936cad7c6f" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" - -[[package]] -name = "hermit-abi" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286" - -[[package]] -name = "html5ever" -version = "0.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c13fb08e5d4dfc151ee5e88bae63f7773d61852f3bdc73c9f4b9e1bde03148" -dependencies = [ - "log", - "mac", - "markup5ever", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "http" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" -dependencies = [ - "bytes", - "fnv", - "itoa 1.0.6", -] - -[[package]] -name = "http-body" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" -dependencies = [ - "bytes", - "http", - "pin-project-lite", -] - -[[package]] -name = "http-range" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21dec9db110f5f872ed9699c3ecf50cf16f423502706ba5c72462e28d3157573" - -[[package]] -name = "httparse" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" - -[[package]] -name = "httpdate" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" - -[[package]] -name = "hyper" -version = "0.14.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab302d72a6f11a3b910431ff93aae7e773078c769f0a3ef15fb9ec692ed147d4" -dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "httpdate", - "itoa 1.0.6", - "pin-project-lite", - "socket2", - "tokio", - "tower-service", - "tracing", - "want", -] - -[[package]] -name = "ico" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3804960be0bb5e4edb1e1ad67afd321a9ecfd875c3e65c099468fd2717d7cae" -dependencies = [ - "byteorder", - "png", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe7873dab538a9a44ad79ede1faf5f30d49f9a5c883ddbab48bce81b64b7492" -dependencies = [ - "globset", - "lazy_static", - "log", - "memchr", - "regex", - "same-file", - "thread_local", - "walkdir", - "winapi-util", -] - -[[package]] -name = "image" -version = "0.24.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "527909aa81e20ac3a44803521443a765550f09b5130c2c2fa1ea59c2f8f50a3a" -dependencies = [ - "bytemuck", - "byteorder", - "color_quant", - "num-rational", - "num-traits", -] - -[[package]] -name = "indexmap" -version = "1.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown", -] - -[[package]] -name = "infer" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a898e4b7951673fce96614ce5751d13c40fc5674bc2d759288e46c3ab62598b3" -dependencies = [ - "cfb", -] - -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "io-lifetimes" -version = "1.0.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c66c74d2ae7e79a5a8f7ac924adbe38ee42a859c6539ad869eb51f0b52dc220" -dependencies = [ - "hermit-abi 0.3.1", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "ipnet" -version = "2.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12b6ee2129af8d4fb011108c73d99a1b83a85977f23b82460c0ae2e25bb4b57f" - -[[package]] -name = "itoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4" - -[[package]] -name = "itoa" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "453ad9f582a441959e5f0d088b02ce04cfe8d51a8eaf077f12ac6d3e94164ca6" - -[[package]] -name = "javascriptcore-rs" -version = "0.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "110b9902c80c12bf113c432d0b71c7a94490b294a8234f326fd0abca2fac0b00" -dependencies = [ - "bitflags", - "glib", - "javascriptcore-rs-sys", -] - -[[package]] -name = "javascriptcore-rs-sys" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98a216519a52cd941a733a0ad3f1023cfdb1cd47f3955e8e863ed56f558f916c" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "jni" -version = "0.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039022cdf4d7b1cf548d31f60ae783138e5fd42013f6271049d7df7afadef96c" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - -[[package]] -name = "jni-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" - -[[package]] -name = "js-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "json-patch" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e712e62827c382a77b87f590532febb1f8b2fdbc3eefa1ee37fe7281687075ef" -dependencies = [ - "serde", - "serde_json", - "thiserror", - "treediff", -] - -[[package]] -name = "kuchiki" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ea8e9c6e031377cff82ee3001dc8026cdf431ed4e2e6b51f98ab8c73484a358" -dependencies = [ - "cssparser", - "html5ever", - "matches", - "selectors", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.141" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3304a64d199bb964be99741b7a14d26972741915b3649639149b2479bb46f4b5" - -[[package]] -name = "line-wrap" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30344350a2a51da54c1d53be93fade8a237e545dbcc4bdbe635413f2117cab9" -dependencies = [ - "safemem", -] - -[[package]] -name = "linux-raw-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d59d8c75012853d2e872fb56bc8a2e53718e2cafe1a4c823143141c6d90c322f" - -[[package]] -name = "lock_api" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "loom" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff50ecb28bb86013e935fb6683ab1f6d3a20016f123c76fd4c27470076ac30f5" -dependencies = [ - "cfg-if", - "generator", - "scoped-tls", - "serde", - "serde_json", - "tracing", - "tracing-subscriber", -] - -[[package]] -name = "mac" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4" - -[[package]] -name = "malloc_buf" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb" -dependencies = [ - "libc", -] - -[[package]] -name = "markup5ever" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a24f40fb03852d1cdd84330cddcaf98e9ec08a7b7768e952fad3b4cf048ec8fd" -dependencies = [ - "log", - "phf 0.8.0", - "phf_codegen", - "string_cache", - "string_cache_codegen", - "tendril", -] - -[[package]] -name = "matchers" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" -dependencies = [ - "regex-automata", -] - -[[package]] -name = "matches" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "memoffset" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d61c719bcfbcf5d62b3a09efa6088de8c54bc0bfcd3ea7ae39fcc186108b8de1" -dependencies = [ - "autocfg", -] - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" -dependencies = [ - "adler", -] - -[[package]] -name = "miniz_oxide" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" -dependencies = [ - "adler", - "simd-adler32", -] - -[[package]] -name = "mio" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b9d9a46eff5b4ff64b45a9e316a6d1e0bc719ef429cbec4dc630684212bfdf9" -dependencies = [ - "libc", - "log", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.45.0", -] - -[[package]] -name = "ndk" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2032c77e030ddee34a6787a64166008da93f6a352b629261d0fee232b8742dd4" -dependencies = [ - "bitflags", - "jni-sys", - "ndk-sys", - "num_enum", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5a6ae77c8ee183dcbbba6150e2e6b9f3f4196a7666c02a715a95692ec1fa97" -dependencies = [ - "jni-sys", -] - -[[package]] -name = "new_debug_unreachable" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" - -[[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] -name = "nu-ansi-term" -version = "0.46.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" -dependencies = [ - "overload", - "winapi", -] - -[[package]] -name = "num-integer" -version = "0.1.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b" -dependencies = [ - "hermit-abi 0.2.6", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" -dependencies = [ - "num_enum_derive", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "objc" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1" -dependencies = [ - "malloc_buf", - "objc_exception", -] - -[[package]] -name = "objc_exception" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad970fb455818ad6cba4c122ad012fae53ae8b4795f86378bce65e4f6bab2ca4" -dependencies = [ - "cc", -] - -[[package]] -name = "objc_id" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b" -dependencies = [ - "objc", -] - -[[package]] -name = "once_cell" -version = "1.17.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7e5500299e16ebb147ae15a00a942af264cf3688f47923b8fc2cd5858f23ad3" - -[[package]] -name = "overload" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" - -[[package]] -name = "pango" -version = "0.16.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdff66b271861037b89d028656184059e03b0b6ccb36003820be19f7200b1e94" -dependencies = [ - "bitflags", - "gio", - "glib", - "libc", - "once_cell", - "pango-sys", -] - -[[package]] -name = "pango-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e134909a9a293e04d2cc31928aa95679c5e4df954d0b85483159bd20d8f047f" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9069cbb9f99e3a5083476ccb29ceb1de18b9118cafa53e90c9551235de2b9521" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.2.16", - "smallvec", - "windows-sys 0.45.0", -] - -[[package]] -name = "percent-encoding" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" - -[[package]] -name = "phf" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dfb61232e34fcb633f43d12c58f83c1df82962dcdfa565a4e866ffc17dafe12" -dependencies = [ - "phf_macros 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", -] - -[[package]] -name = "phf" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259" -dependencies = [ - "phf_macros 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", -] - -[[package]] -name = "phf_codegen" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbffee61585b0411840d3ece935cce9cb6321f01c45477d30066498cd5e1a815" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", -] - -[[package]] -name = "phf_generator" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17367f0cc86f2d25802b2c26ee58a7b23faeccf78a396094c13dced0d0182526" -dependencies = [ - "phf_shared 0.8.0", - "rand 0.7.3", -] - -[[package]] -name = "phf_generator" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d5285893bb5eb82e6aaf5d59ee909a06a16737a8970984dd7746ba9283498d6" -dependencies = [ - "phf_shared 0.10.0", - "rand 0.8.5", -] - -[[package]] -name = "phf_macros" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6fde18ff429ffc8fe78e2bf7f8b7a5a5a6e2a8b58bc5a9ac69198bbda9189c" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "phf_macros" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fdf3184dd560f160dd73922bea2d5cd6e8f064bf4b13110abd81b03697b4e0" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "phf_shared" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c00cf8b9eafe68dde5e9eaa2cef8ee84a9336a47d566ec55ca16589633b65af7" -dependencies = [ - "siphasher", -] - -[[package]] -name = "phf_shared" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" - -[[package]] -name = "plist" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bd9647b268a3d3e14ff09c23201133a62589c658db02bb7388c7246aafe0590" -dependencies = [ - "base64 0.21.0", - "indexmap", - "line-wrap", - "quick-xml", - "serde", - "time", -] - -[[package]] -name = "png" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aaeebc51f9e7d2c150d3f3bfeb667f2aa985db5ef1e3d212847bdedb488beeaa" -dependencies = [ - "bitflags", - "crc32fast", - "fdeflate", - "flate2", - "miniz_oxide 0.7.1", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[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", -] - -[[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-macro-hack" -version = "0.5.20+deprecated" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" - -[[package]] -name = "proc-macro2" -version = "1.0.56" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b63bdb0cd06f1f4dedf69b254734f9b45af66e4a031e42a7480257d9898b435" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quick-xml" -version = "0.28.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ce5e73202a820a31f8a0ee32ada5e21029c81fd9e3ebf668a40832e4219d9d1" -dependencies = [ - "memchr", -] - -[[package]] -name = "quote" -version = "1.0.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4424af4bf778aae2051a77b60283332f386554255d722233d09fbfc7e30da2fc" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", - "rand_pcg", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.9", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_pcg" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "raw-window-handle" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2ff9a1f06a88b01621b7ae906ef0211290d1c8a168a15542486a8f61c0833b9" - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_syscall" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.9", - "redox_syscall 0.2.16", - "thiserror", -] - -[[package]] -name = "regex" -version = "1.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b1f693b24f6ac912f4893ef08244d70b6067480d2f1a46e950c9691e6749d1d" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" - -[[package]] -name = "reqwest" -version = "0.11.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27b71749df584b7f4cac2c426c127a7c785a5106cc98f7a8feb044115f0fa254" -dependencies = [ - "base64 0.21.0", - "bytes", - "encoding_rs", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "hyper", - "ipnet", - "js-sys", - "log", - "mime", - "once_cell", - "percent-encoding", - "pin-project-lite", - "serde", - "serde_json", - "serde_urlencoded", - "tokio", - "tokio-util", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "wasm-streams", - "web-sys", - "winreg", -] - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.37.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85597d61f83914ddeba6a47b3b8ffe7365107221c2e557ed94426489fefb5f77" -dependencies = [ - "bitflags", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys", - "windows-sys 0.48.0", -] - -[[package]] -name = "rustversion" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f3208ce4d8448b3f3e7d168a73f5e0c43a61e32930de3bceeccedb388b6bf06" - -[[package]] -name = "ryu" -version = "1.0.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91339c0467de62360649f8d3e185ca8de4224ff281f66000de5eb2a77a79041" - -[[package]] -name = "safemem" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef703b7cb59335eae2eb93ceb664c0eb7ea6bf567079d843e09420219668e072" - -[[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 = "scoped-tls" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" - -[[package]] -name = "scopeguard" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "selectors" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df320f1889ac4ba6bc0cdc9c9af7af4bd64bb927bccdf32d81140dc1f9be12fe" -dependencies = [ - "bitflags", - "cssparser", - "derive_more", - "fxhash", - "log", - "matches", - "phf 0.8.0", - "phf_codegen", - "precomputed-hash", - "servo_arc", - "smallvec", - "thin-slice", -] - -[[package]] -name = "semver" -version = "1.0.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bebd363326d05ec3e2f532ab7660680f3b02130d780c299bca73469d521bc0ed" -dependencies = [ - "serde", -] - -[[package]] -name = "serde" -version = "1.0.160" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb2f3770c8bce3bcda7e149193a069a0f4365bda1fa5cd88e03bca26afc1216c" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.160" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291a097c63d8497e00160b166a967a4a79c64f3facdd01cbd7502231688d77df" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "serde_json" -version = "1.0.96" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "057d394a50403bcac12672b2b18fb387ab6d289d957dab67dd201875391e52f1" -dependencies = [ - "itoa 1.0.6", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcec881020c684085e55a25f7fd888954d56609ef363479dc5a1305eb0d40cab" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "serde_spanned" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0efd8caf556a6cebd3b285caf480045fcc1ac04f6bd786b09a6f11af30c4fcf4" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa 1.0.6", - "ryu", - "serde", -] - -[[package]] -name = "serde_with" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" -dependencies = [ - "serde", - "serde_with_macros", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "serialize-to-javascript" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9823f2d3b6a81d98228151fdeaf848206a7855a7a042bbf9bf870449a66cafb" -dependencies = [ - "serde", - "serde_json", - "serialize-to-javascript-impl", -] - -[[package]] -name = "serialize-to-javascript-impl" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74064874e9f6a15f04c1f3cb627902d0e6b410abbf36668afa873c61889f1763" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "servo_arc" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d98238b800e0d1576d8b6e3de32827c2d74bee68bb97748dcf5071fb53965432" -dependencies = [ - "nodrop", - "stable_deref_trait", -] - -[[package]] -name = "sha2" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sharded-slab" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31" -dependencies = [ - "lazy_static", -] - -[[package]] -name = "simd-adler32" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "238abfbb77c1915110ad968465608b68e869e0772622c9656714e73e5a1a522f" - -[[package]] -name = "siphasher" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de" - -[[package]] -name = "slab" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6528351c9bc8ab22353f9d776db39a20288e8d6c37ef8cfe3317cf875eecfc2d" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" - -[[package]] -name = "socket2" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "soup3" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82bc46048125fefd69d30b32b9d263d6556c9ffe82a7a7df181a86d912da5616" -dependencies = [ - "bitflags", - "futures-channel", - "gio", - "glib", - "libc", - "once_cell", - "soup3-sys", -] - -[[package]] -name = "soup3-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "014bbeb1c4cdb30739dc181e8d98b7908f124d9555843afa89b5570aaf4ec62b" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "stable_deref_trait" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" - -[[package]] -name = "state" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe866e1e51e8260c9eed836a042a5e7f6726bb2b411dffeaa712e19c388f23b" -dependencies = [ - "loom", -] - -[[package]] -name = "string_cache" -version = "0.8.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91138e76242f575eb1d3b38b4f1362f10d3a43f47d182a5b359af488a02293b" -dependencies = [ - "new_debug_unreachable", - "once_cell", - "parking_lot", - "phf_shared 0.10.0", - "precomputed-hash", - "serde", -] - -[[package]] -name = "string_cache_codegen" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bb30289b722be4ff74a408c3cc27edeaad656e06cb1fe8fa9231fa59c728988" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro2", - "quote", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "swift-rs" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05e51d6f2b5fff4808614f429f8a7655ac8bcfe218185413f3a60c508482c2d6" -dependencies = [ - "base64 0.21.0", - "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", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a34fcf3e8b60f57e6a14301a2e916d323af98b0ea63c599441eec8558660c822" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-deps" -version = "6.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "555fc8147af6256f3931a36bb83ad0023240ce9cf2b319dec8236fd1f220b05f" -dependencies = [ - "cfg-expr", - "heck", - "pkg-config", - "toml 0.7.3", - "version-compare", -] - -[[package]] -name = "tao" -version = "0.18.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f2340617d383561b0ea25358b97ec2c2ba04db48c458ce71dd1b38d7fd09ac5" -dependencies = [ - "bitflags", - "cairo-rs", - "cc", - "cocoa", - "core-foundation", - "core-graphics", - "crossbeam-channel", - "dispatch", - "gdk", - "gdk-pixbuf", - "gdk-sys", - "gdkwayland-sys", - "gdkx11-sys", - "gio", - "glib", - "glib-sys", - "gtk", - "image", - "instant", - "jni", - "lazy_static", - "libc", - "log", - "ndk", - "ndk-context", - "ndk-sys", - "objc", - "once_cell", - "parking_lot", - "png", - "raw-window-handle", - "scopeguard", - "serde", - "tao-macros", - "unicode-segmentation", - "uuid", - "windows", - "windows-implement", - "x11-dl", -] - -[[package]] -name = "tao-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b27a4bcc5eb524658234589bdffc7e7bfb996dbae6ce9393bfd39cb4159b445" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "tar" -version = "0.4.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b55807c0344e1e6c04d7c965f5289c39a8d94ae23ed5c0b57aabac549f871c6" -dependencies = [ - "filetime", - "libc", - "xattr", -] - -[[package]] -name = "tauri" -version = "2.0.0-alpha.8" -dependencies = [ - "anyhow", - "bytes", - "cocoa", - "dirs-next", - "embed_plist", - "encoding_rs", - "flate2", - "futures-util", - "glib", - "glob", - "gtk", - "heck", - "http", - "ignore", - "jni", - "libc", - "log", - "objc", - "once_cell", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "reqwest", - "semver", - "serde", - "serde_json", - "serde_repr", - "serialize-to-javascript", - "state", - "swift-rs", - "tar", - "tauri-build", - "tauri-macros", - "tauri-runtime", - "tauri-runtime-wry", - "tauri-utils", - "tempfile", - "thiserror", - "tokio", - "url", - "uuid", - "webkit2gtk", - "webview2-com", - "windows", -] - -[[package]] -name = "tauri-build" -version = "2.0.0-alpha.4" -dependencies = [ - "anyhow", - "cargo_toml", - "filetime", - "heck", - "json-patch", - "semver", - "serde", - "serde_json", - "swift-rs", - "tauri-utils", - "tauri-winres", - "walkdir", -] - -[[package]] -name = "tauri-codegen" -version = "2.0.0-alpha.4" -dependencies = [ - "base64 0.21.0", - "brotli", - "ico", - "json-patch", - "plist", - "png", - "proc-macro2", - "quote", - "semver", - "serde", - "serde_json", - "sha2", - "tauri-utils", - "thiserror", - "time", - "url", - "uuid", - "walkdir", -] - -[[package]] -name = "tauri-macros" -version = "2.0.0-alpha.4" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn 1.0.109", - "tauri-codegen", - "tauri-utils", -] - -[[package]] -name = "tauri-plugin-clipboard" -version = "0.1.0" -dependencies = [ - "serde", - "tauri", - "tauri-build", - "thiserror", -] - -[[package]] -name = "tauri-runtime" -version = "0.13.0-alpha.4" -dependencies = [ - "gtk", - "http", - "http-range", - "jni", - "rand 0.8.5", - "raw-window-handle", - "serde", - "serde_json", - "tauri-utils", - "thiserror", - "url", - "uuid", - "webview2-com", - "windows", -] - -[[package]] -name = "tauri-runtime-wry" -version = "0.13.0-alpha.4" -dependencies = [ - "cocoa", - "gtk", - "jni", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "tauri-runtime", - "tauri-utils", - "uuid", - "webkit2gtk", - "webview2-com", - "windows", - "wry", -] - -[[package]] -name = "tauri-utils" -version = "2.0.0-alpha.4" -dependencies = [ - "brotli", - "ctor", - "glob", - "heck", - "html5ever", - "infer", - "json-patch", - "kuchiki", - "memchr", - "phf 0.10.1", - "proc-macro2", - "quote", - "semver", - "serde", - "serde_json", - "serde_with", - "thiserror", - "url", - "walkdir", - "windows", -] - -[[package]] -name = "tauri-winres" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b7a78dc04f75fb5ab815e66ac561c81e92a968a40f29e7c21afd152d694fad8" -dependencies = [ - "toml 0.5.11", - "version_check", -] - -[[package]] -name = "tempfile" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9fbec84f381d5795b08656e4912bec604d162bff9291d6189a78f4c8ab87998" -dependencies = [ - "cfg-if", - "fastrand", - "redox_syscall 0.3.5", - "rustix", - "windows-sys 0.45.0", -] - -[[package]] -name = "tendril" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d24a120c5fc464a3458240ee02c299ebcb9d67b5249c8848b09d639dca8d7bb0" -dependencies = [ - "futf", - "mac", - "utf-8", -] - -[[package]] -name = "thin-slice" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c" - -[[package]] -name = "thiserror" -version = "1.0.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "978c9a314bd8dc99be594bc3c175faaa9794be04a5a5e153caba6915336cebac" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9456a42c5b0d803c8cd86e73dd7cc9edd429499f37a3550d286d5e86720569f" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "thread_local" -version = "1.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdd6f064ccff2d6567adcb3873ca630700f00b5ad3f060c25b5dcfd9a4ce152" -dependencies = [ - "cfg-if", - "once_cell", -] - -[[package]] -name = "time" -version = "0.3.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd0cbfecb4d19b5ea75bb31ad904eb5b9fa13f21079c3b92017ebdf4999a5890" -dependencies = [ - "itoa 1.0.6", - "serde", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd" - -[[package]] -name = "time-macros" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd80a657e71da814b8e5d60d3374fc6d35045062245d80224748ae522dd76f36" -dependencies = [ - "time-core", -] - -[[package]] -name = "tinyvec" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.27.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0de47a4eecbe11f498978a9b29d792f0d2692d1dd003650c24c76510e3bc001" -dependencies = [ - "autocfg", - "bytes", - "libc", - "mio", - "num_cpus", - "pin-project-lite", - "socket2", - "windows-sys 0.45.0", -] - -[[package]] -name = "tokio-util" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5427d89453009325de0d8f342c9490009f76e999cb7672d77e46267448f7e6b2" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", - "tracing", -] - -[[package]] -name = "toml" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" -dependencies = [ - "serde", -] - -[[package]] -name = "toml" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b403acf6f2bb0859c93c7f0d967cb4a75a7ac552100f9322faf64dc047669b21" -dependencies = [ - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab8ed2edee10b50132aed5f331333428b011c99402b5a534154ed15746f9622" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.19.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "239410c8609e8125456927e6707163a3b1fdb40561e4b803bc041f466ccfdc13" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" -dependencies = [ - "cfg-if", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "tracing-core" -version = "0.1.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" -dependencies = [ - "once_cell", - "valuable", -] - -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - -[[package]] -name = "tracing-subscriber" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6176eae26dd70d0c919749377897b54a9276bd7061339665dd68777926b5a70" -dependencies = [ - "matchers", - "nu-ansi-term", - "once_cell", - "regex", - "sharded-slab", - "smallvec", - "thread_local", - "tracing", - "tracing-core", - "tracing-log", -] - -[[package]] -name = "treediff" -version = "4.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52984d277bdf2a751072b5df30ec0377febdb02f7696d64c2d7d54630bac4303" -dependencies = [ - "serde_json", -] - -[[package]] -name = "try-lock" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" - -[[package]] -name = "typenum" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" - -[[package]] -name = "unicode-bidi" -version = "0.3.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" - -[[package]] -name = "unicode-ident" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5464a87b239f13a63a501f2701565754bae92d243d4bb7eb12f6d57d2269bf4" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - -[[package]] -name = "url" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", - "serde", -] - -[[package]] -name = "utf-8" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" - -[[package]] -name = "uuid" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b55a3fef2a1e3b3a00ce878640918820d3c51081576ac657d23af9fc7928fdb" -dependencies = [ - "getrandom 0.2.9", -] - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "version-compare" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "579a42fc0b8e0c63b76519a339be31bed574929511fa53c1a3acae26eb258f29" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36df944cda56c7d8d8b7496af378e6b16de9284591917d307c9b4d313c44e698" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" -dependencies = [ - "log", - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn 1.0.109", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f219e0d211ba40266969f6dbdd90636da12f75bee4fc9d6c23d1260dadb51454" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" - -[[package]] -name = "wasm-streams" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bbae3363c08332cadccd13b67db371814cd214c2524020932f0804b8cf7c078" -dependencies = [ - "futures-util", - "js-sys", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", -] - -[[package]] -name = "web-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "webkit2gtk" -version = "0.19.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8eea819afe15eb8dcdff4f19d8bfda540bae84d874c10e6f4b8faf2d6704bd1" -dependencies = [ - "bitflags", - "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 = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0ac7a95ddd3fdfcaf83d8e513b4b1ad101b95b413b6aa6662ed95f284fc3d5b" -dependencies = [ - "bitflags", - "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 = "webview2-com" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11296e5daf3a653b79bf47d66c380e4143d5b9c975818871179a3bda79499562" -dependencies = [ - "webview2-com-macros", - "webview2-com-sys", - "windows", - "windows-implement", -] - -[[package]] -name = "webview2-com-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaebe196c01691db62e9e4ca52c5ef1e4fd837dcae27dae3ada599b5a8fd05ac" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "webview2-com-sys" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cde542bed28058a5b028d459689ee57f1d06685bb6c266da3b91b1be6703952f" -dependencies = [ - "regex", - "serde", - "serde_json", - "thiserror", - "windows", - "windows-bindgen", - "windows-metadata", -] - -[[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.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi", -] - -[[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 = "windows" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e745dab35a0c4c77aa3ce42d595e13d2003d6902d6b08c9ef5fc326d08da12b" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-targets 0.42.2", -] - -[[package]] -name = "windows-bindgen" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "222204ecf46521382a4d88b4a1bbefca9f8855697b4ab7d20803901425e061a3" -dependencies = [ - "windows-metadata", - "windows-tokens", -] - -[[package]] -name = "windows-implement" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce87ca8e3417b02dc2a8a22769306658670ec92d78f1bd420d6310a67c245c6" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "windows-interface" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "853f69a591ecd4f810d29f17e902d40e349fb05b0b11fff63b08b826bfe39c7f" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "windows-metadata" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee78911e3f4ce32c1ad9d3c7b0bd95389662ad8d8f1a3155688fed70bd96e2b6" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.0", -] - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b1eb6f0cd7c80c79759c929114ef071b87354ce476d9d94271031c0497adfd5" -dependencies = [ - "windows_aarch64_gnullvm 0.48.0", - "windows_aarch64_msvc 0.48.0", - "windows_i686_gnu 0.48.0", - "windows_i686_msvc 0.48.0", - "windows_x86_64_gnu 0.48.0", - "windows_x86_64_gnullvm 0.48.0", - "windows_x86_64_msvc 0.48.0", -] - -[[package]] -name = "windows-tokens" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa4251900975a0d10841c5d4bde79c56681543367ef811f3fabb8d1803b0959b" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" - -[[package]] -name = "winnow" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae8970b36c66498d8ff1d66685dc86b91b29db0c7739899012f63a63814b4b28" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d0f4e272c85def139476380b12f9ac60926689dd2e01d4923222f40580869d" -dependencies = [ - "winapi", -] - -[[package]] -name = "wry" -version = "0.27.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8cf0dbfa7ccbd2e3832a3098b19d4b552360ea00a40b244a99caef46bffd84f" -dependencies = [ - "base64 0.13.1", - "block", - "cocoa", - "core-graphics", - "crossbeam-channel", - "dunce", - "gdk", - "gio", - "glib", - "gtk", - "html5ever", - "http", - "javascriptcore-rs", - "kuchiki", - "libc", - "log", - "objc", - "objc_id", - "once_cell", - "serde", - "serde_json", - "sha2", - "soup3", - "tao", - "thiserror", - "url", - "webkit2gtk", - "webkit2gtk-sys", - "webview2-com", - "windows", - "windows-implement", -] - -[[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 = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d1526bbe5aaeb5eb06885f4d987bcdfa5e23187055de9b83fe00156a821fabc" -dependencies = [ - "libc", -] diff --git a/plugins/clipboard/Cargo.toml b/plugins/clipboard/Cargo.toml deleted file mode 100644 index 00864ff4..00000000 --- a/plugins/clipboard/Cargo.toml +++ /dev/null @@ -1,19 +0,0 @@ -[package] -name = "tauri-plugin-clipboard" -version = "0.0.0" -edition.workspace = true -authors.workspace = true -license.workspace = true - -[build-dependencies] -tauri-build.workspace = true - -[dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true - -[target."cfg(any(target_os = \"macos\", windows, target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"openbsd\", target_os = \"netbsd\"))".dependencies] -arboard = "3" diff --git a/plugins/dialog/CHANGELOG.md b/plugins/dialog/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/dialog/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/dialog/Cargo.toml b/plugins/dialog/Cargo.toml index 905de823..7ca49870 100644 --- a/plugins/dialog/Cargo.toml +++ b/plugins/dialog/Cargo.toml @@ -1,18 +1,19 @@ [package] name = "tauri-plugin-dialog" -version = "0.0.0" -edition.workspace = true -authors.workspace = true -license.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +version = "2.0.0-alpha.0" +description = "Native system dialogs for opening and saving files along with message dialogs on your Tauri application." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } +links = "tauri-plugin-dialog" [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } +tauri-plugin-fs = { path = "../fs", version = "2.0.0-alpha.0" } [target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"openbsd\", target_os = \"netbsd\"))".dependencies] glib = "0.16" @@ -22,4 +23,4 @@ rfd = { version = "0.11", features = [ "gtk3", "common-controls-v6" ] } raw-window-handle = "0.5" [build-dependencies] -tauri-build.workspace = true +tauri-build = { workspace = true } diff --git a/plugins/dialog/README.md b/plugins/dialog/README.md index 24a5b214..8e06ed2b 100644 --- a/plugins/dialog/README.md +++ b/plugins/dialog/README.md @@ -1,10 +1,10 @@ -![Dialog](banner.jpg) +# Dialog - +Native system dialogs for opening and saving files along with message dialogs. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,7 +18,9 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] -tauri-plugin-dialog-api = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +tauri-plugin-dialog = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-dialog = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` You can install the JavaScript Guest bindings using your preferred JavaScript package manager: @@ -26,11 +28,18 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh -pnpm add tauri-plugin-dialog-api +pnpm add @tauri-apps/plugin-dialog # or -npm add tauri-plugin-dialog-api +npm add @tauri-apps/plugin-dialog # or -yarn add tauri-plugin-dialog-api +yarn add @tauri-apps/plugin-dialog + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-dialog#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-dialog#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-dialog#v2 ``` ## Usage diff --git a/plugins/dialog/android/src/androidTest/java/ExampleInstrumentedTest.kt b/plugins/dialog/android/src/androidTest/java/ExampleInstrumentedTest.kt index cebbd46c..6c9d837e 100644 --- a/plugins/dialog/android/src/androidTest/java/ExampleInstrumentedTest.kt +++ b/plugins/dialog/android/src/androidTest/java/ExampleInstrumentedTest.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.dialog import androidx.test.platform.app.InstrumentationRegistry diff --git a/plugins/dialog/android/src/test/java/ExampleUnitTest.kt b/plugins/dialog/android/src/test/java/ExampleUnitTest.kt index b7d61c6a..00369a3f 100644 --- a/plugins/dialog/android/src/test/java/ExampleUnitTest.kt +++ b/plugins/dialog/android/src/test/java/ExampleUnitTest.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.dialog import org.junit.Test diff --git a/plugins/dialog/build.rs b/plugins/dialog/build.rs index 86ac3f0a..743096a6 100644 --- a/plugins/dialog/build.rs +++ b/plugins/dialog/build.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::process::exit; fn main() { diff --git a/plugins/dialog/examples/tauri-app/.gitignore b/plugins/dialog/examples/tauri-app/.gitignore deleted file mode 100644 index a547bf36..00000000 --- a/plugins/dialog/examples/tauri-app/.gitignore +++ /dev/null @@ -1,24 +0,0 @@ -# Logs -logs -*.log -npm-debug.log* -yarn-debug.log* -yarn-error.log* -pnpm-debug.log* -lerna-debug.log* - -node_modules -dist -dist-ssr -*.local - -# Editor directories and files -.vscode/* -!.vscode/extensions.json -.idea -.DS_Store -*.suo -*.ntvs* -*.njsproj -*.sln -*.sw? diff --git a/plugins/dialog/examples/tauri-app/README.md b/plugins/dialog/examples/tauri-app/README.md deleted file mode 100644 index 220a1834..00000000 --- a/plugins/dialog/examples/tauri-app/README.md +++ /dev/null @@ -1 +0,0 @@ -# Dialog Example diff --git a/plugins/dialog/examples/tauri-app/index.html b/plugins/dialog/examples/tauri-app/index.html deleted file mode 100644 index fad1c5d9..00000000 --- a/plugins/dialog/examples/tauri-app/index.html +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - Tauri + Svelte - - - -
- - - diff --git a/plugins/dialog/examples/tauri-app/jsconfig.json b/plugins/dialog/examples/tauri-app/jsconfig.json deleted file mode 100644 index ee5e92f2..00000000 --- a/plugins/dialog/examples/tauri-app/jsconfig.json +++ /dev/null @@ -1,34 +0,0 @@ -{ - "compilerOptions": { - "moduleResolution": "Node", - "target": "ESNext", - "module": "ESNext", - /** - * svelte-preprocess cannot figure out whether you have - * a value or a type, so tell TypeScript to enforce using - * `import type` instead of `import` for Types. - */ - "importsNotUsedAsValues": "error", - "isolatedModules": true, - "resolveJsonModule": true, - /** - * To have warnings / errors of the Svelte compiler at the - * correct position, enable source maps by default. - */ - "sourceMap": true, - "esModuleInterop": true, - "skipLibCheck": true, - "forceConsistentCasingInFileNames": true, - "baseUrl": ".", - /** - * Typecheck JS in `.svelte` and `.js` files by default. - * Disable this if you'd like to use dynamic types. - */ - "checkJs": true - }, - /** - * Use global.d.ts instead of compilerOptions.types - * to avoid limiting type declarations. - */ - "include": ["src/**/*.d.ts", "src/**/*.js", "src/**/*.svelte"] -} diff --git a/plugins/dialog/examples/tauri-app/package.json b/plugins/dialog/examples/tauri-app/package.json deleted file mode 100644 index 39488aee..00000000 --- a/plugins/dialog/examples/tauri-app/package.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "name": "tauri-app", - "private": true, - "version": "0.0.0", - "type": "module", - "scripts": { - "dev": "vite", - "build": "vite build", - "preview": "vite preview", - "tauri": "tauri" - }, - "dependencies": { - "tauri-plugin-dialog-api": "link:../../" - }, - "devDependencies": { - "@sveltejs/vite-plugin-svelte": "^1.0.1", - "@tauri-apps/cli": "^2.0.0-alpha.7", - "internal-ip": "^7.0.0", - "svelte": "^3.49.0", - "vite": "^3.0.2" - } -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/.gitignore b/plugins/dialog/examples/tauri-app/src-tauri/.gitignore deleted file mode 100644 index c055de2d..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -# Generated by Cargo -# will have compiled files and executables -/target/ - -.cargo diff --git a/plugins/dialog/examples/tauri-app/src-tauri/Cargo.lock b/plugins/dialog/examples/tauri-app/src-tauri/Cargo.lock deleted file mode 100644 index 0e4a9644..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/Cargo.lock +++ /dev/null @@ -1,4243 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "aho-corasick" -version = "0.7.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" -dependencies = [ - "memchr", -] - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "android_log-sys" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85965b6739a430150bdd138e2374a98af0c3ee0d030b3bb7fc3bddff58d0102e" - -[[package]] -name = "android_logger" -version = "0.11.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8619b80c242aa7bd638b5c7ddd952addeecb71f69c75e33f1d47b2804f8f883a" -dependencies = [ - "android_log-sys", - "env_logger", - "log", - "once_cell", -] - -[[package]] -name = "anyhow" -version = "1.0.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "224afbd727c3d6e4b90103ece64b8d1b67fbb1973b1046c2281eed3f3803f800" - -[[package]] -name = "app" -version = "0.0.0" -dependencies = [ - "log", - "serde", - "serde_json", - "tauri", - "tauri-build", - "tauri-plugin-dialog", - "tauri-plugin-log", -] - -[[package]] -name = "async-broadcast" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c48ccdbf6ca6b121e0f586cbc0e73ae440e56c67c30fa0873b4e110d9c26d2b" -dependencies = [ - "event-listener", - "futures-core", -] - -[[package]] -name = "async-channel" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf46fee83e5ccffc220104713af3292ff9bc7c64c7de289f66dae8e38d826833" -dependencies = [ - "concurrent-queue", - "event-listener", - "futures-core", -] - -[[package]] -name = "async-executor" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17adb73da160dfb475c183343c8cccd80721ea5a605d3eb57125f0a7b7a92d0b" -dependencies = [ - "async-lock", - "async-task", - "concurrent-queue", - "fastrand", - "futures-lite", - "slab", -] - -[[package]] -name = "async-fs" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "279cf904654eeebfa37ac9bb1598880884924aab82e290aa65c9e77a0e142e06" -dependencies = [ - "async-lock", - "autocfg", - "blocking", - "futures-lite", -] - -[[package]] -name = "async-io" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fc5b45d93ef0529756f812ca52e44c221b35341892d3dcc34132ac02f3dd2af" -dependencies = [ - "async-lock", - "autocfg", - "cfg-if", - "concurrent-queue", - "futures-lite", - "log", - "parking", - "polling", - "rustix", - "slab", - "socket2", - "waker-fn", -] - -[[package]] -name = "async-lock" -version = "2.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa24f727524730b077666307f2734b4a1a1c57acb79193127dcc8914d5242dd7" -dependencies = [ - "event-listener", -] - -[[package]] -name = "async-recursion" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b015a331cc64ebd1774ba119538573603427eaace0a1950c423ab971f903796" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "async-task" -version = "4.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc7ab41815b3c653ccd2978ec3255c81349336702dfdf62ee6f7069b12a3aae" - -[[package]] -name = "async-trait" -version = "0.1.66" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b84f9ebcc6c1f5b8cb160f6990096a5c127f423fcb6e1ccc46c370cbdfb75dfc" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "atk" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39991bc421ddf72f70159011b323ff49b0f783cc676a7287c59453da2e2531cf" -dependencies = [ - "atk-sys", - "bitflags", - "glib", - "libc", -] - -[[package]] -name = "atk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11ad703eb64dc058024f0e57ccfa069e15a413b98dbd50a1a950e743b7f11148" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "atomic-waker" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "debc29dde2e69f9e47506b525f639ed42300fc014a3e007832592448fa8e4599" - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "base64" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" - -[[package]] -name = "base64" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "block" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" - -[[package]] -name = "block-buffer" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69cce20737498f97b993470a6e536b8523f0af7892a4f928cceb1ac5e52ebe7e" -dependencies = [ - "generic-array", -] - -[[package]] -name = "blocking" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c67b173a56acffd6d2326fb7ab938ba0b00a71480e14902b2591c87bc5741e8" -dependencies = [ - "async-channel", - "async-lock", - "async-task", - "atomic-waker", - "fastrand", - "futures-lite", -] - -[[package]] -name = "brotli" -version = "3.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a0b1dbcc8ae29329621f8d4f0d835787c1c38bb1401979b49d13b0b305ff68" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b6561fd3f895a11e8f72af2cb7d22e08366bebc2b6b57f7744c4bda27034744" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bstr" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7f0778972c64420fdedc63f09919c8a88bda7b25135357fd25a5d9f3257e832" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" - -[[package]] -name = "byte-unit" -version = "4.0.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da78b32057b8fdfc352504708feeba7216dcd65a2c9ab02978cbd288d1279b6c" -dependencies = [ - "serde", - "utf8-width", -] - -[[package]] -name = "bytemuck" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c041d3eab048880cb0b86b256447da3f18859a163c3b8d8893f4e6368abe6393" - -[[package]] -name = "byteorder" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" - -[[package]] -name = "bytes" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" -dependencies = [ - "serde", -] - -[[package]] -name = "cairo-rs" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3125b15ec28b84c238f6f476c6034016a5f6cc0221cb514ca46c532139fc97d" -dependencies = [ - "bitflags", - "cairo-sys-rs", - "glib", - "libc", - "once_cell", - "thiserror", -] - -[[package]] -name = "cairo-sys-rs" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c48f4af05fabdcfa9658178e1326efa061853f040ce7d72e33af6885196f421" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "cargo_toml" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bfbc36312494041e2cdd5f06697b7e89d4b76f42773a0b5556ac290ff22acc2" -dependencies = [ - "serde", - "toml", -] - -[[package]] -name = "cc" -version = "1.0.79" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" - -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - -[[package]] -name = "cfb" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d38f2da7a0a2c4ccf0065be06397cc26a81f4e528be095826eee9d4adbb8c60f" -dependencies = [ - "byteorder", - "fnv", - "uuid", -] - -[[package]] -name = "cfg-expr" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0357a6402b295ca3a86bc148e84df46c02e41f41fef186bda662557ef6328aa" -dependencies = [ - "smallvec", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "cocoa" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f425db7937052c684daec3bd6375c8abe2d146dca4b8b143d6db777c39138f3a" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation", - "core-graphics", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa-foundation" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ade49b65d560ca58c403a479bb396592b155c0185eada742ee323d1d68d6318" -dependencies = [ - "bitflags", - "block", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "color_quant" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" - -[[package]] -name = "combine" -version = "4.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] - -[[package]] -name = "concurrent-queue" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c278839b831783b70278b14df4d45e1beb1aad306c07bb796637de9a0e323e8e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dc" - -[[package]] -name = "core-graphics" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" -dependencies = [ - "bitflags", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" -dependencies = [ - "bitflags", - "core-foundation", - "foreign-types", - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28d997bd5e24a5928dd43e46dc529867e207907fe0b239c3477d924f7f2ca320" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2dd04ddaf88237dc3b8d8f9a3c1004b506b54b3313403944054d23c0870c521" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb766fa798726286dbbb842f174001dab8abc7b627a1dd86e0b7222a95d929f" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "cssparser" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "754b69d351cdc2d8ee09ae203db831e005560fc6030da058f86ad60c92a9cb0a" -dependencies = [ - "cssparser-macros", - "dtoa-short", - "itoa 0.4.8", - "matches", - "phf 0.8.0", - "proc-macro2", - "quote", - "smallvec", - "syn", -] - -[[package]] -name = "cssparser-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfae75de57f2b2e85e8768c3ea840fd159c8f33e2b6522c7835b7abac81be16e" -dependencies = [ - "quote", - "syn", -] - -[[package]] -name = "ctor" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d2301688392eb071b0bf1a37be05c469d3cc4dbbd95df672fe28ab021e6a096" -dependencies = [ - "quote", - "syn", -] - -[[package]] -name = "cty" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b365fabc795046672053e29c954733ec3b05e4be654ab130fe8f1f94d7051f35" - -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core", - "quote", - "syn", -] - -[[package]] -name = "derivative" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "derive_more" -version = "0.99.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version 0.4.0", - "syn", -] - -[[package]] -name = "digest" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dirs" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3aa72a6f96ea37bbc5aa912f6788242832f75369bdfdadcb0e38423f100059" -dependencies = [ - "dirs-sys", -] - -[[package]] -name = "dirs-next" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" -dependencies = [ - "cfg-if", - "dirs-sys-next", -] - -[[package]] -name = "dirs-sys" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dirs-sys-next" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dispatch" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" - -[[package]] -name = "dtoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" - -[[package]] -name = "dtoa-short" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde03329ae10e79ede66c9ce4dc930aa8599043b0743008548680f25b91502d6" -dependencies = [ - "dtoa", -] - -[[package]] -name = "dunce" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bd4b30a6560bbd9b4620f4de34c3f14f60848e58a9b7216801afcb4c7b31c3c" - -[[package]] -name = "embed_plist" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" - -[[package]] -name = "encoding_rs" -version = "0.8.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071a31f4ee85403370b58aca746f01041ede6f0da2730960ad001edc2b71b394" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "enumflags2" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e75d4cd21b95383444831539909fbb14b9dc3fdceb2a6f5d36577329a1f55ccb" -dependencies = [ - "enumflags2_derive", - "serde", -] - -[[package]] -name = "enumflags2_derive" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f58dc3c5e468259f19f2d46304a6b28f1c3d034442e14b322d2b850e36f6d5ae" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "env_logger" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0" -dependencies = [ - "log", - "regex", -] - -[[package]] -name = "errno" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d6a0976c999d473fe89ad888d5a284e55366d9dc9038b1ba2aa15128c4afa0" -dependencies = [ - "errno-dragonfly", - "libc", - "windows-sys 0.45.0", -] - -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] - -[[package]] -name = "event-listener" -version = "2.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" - -[[package]] -name = "fastrand" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" -dependencies = [ - "instant", -] - -[[package]] -name = "fern" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9f0c14694cbd524c8720dd69b0e3179344f04ebb5f90f2e4a440c6ea3b2f1ee" -dependencies = [ - "log", -] - -[[package]] -name = "field-offset" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e1c54951450cbd39f3dbcf1005ac413b49487dabf18a720ad2383eccfeffb92" -dependencies = [ - "memoffset 0.6.5", - "rustc_version 0.3.3", -] - -[[package]] -name = "filetime" -version = "0.2.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a3de6e8d11b22ff9edc6d916f890800597d60f8b2da1caf2955c274638d6412" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "windows-sys 0.45.0", -] - -[[package]] -name = "flate2" -version = "1.0.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futf" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df420e2e84819663797d1ec6544b13c5be84629e7bb00dc960d6917db2987843" -dependencies = [ - "mac", - "new_debug_unreachable", -] - -[[package]] -name = "futures-channel" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e5317663a9089767a1ec00a487df42e0ca174b61b4483213ac24448e4664df5" -dependencies = [ - "futures-core", -] - -[[package]] -name = "futures-core" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec90ff4d0fe1f57d600049061dc6bb68ed03c7d2fbd697274c41805dcb3f8608" - -[[package]] -name = "futures-executor" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8de0a35a6ab97ec8869e32a2473f4b1324459e14c29275d14b10cb1fd19b50e" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfb8371b6fb2aeb2d280374607aeabfc99d95c72edfe51692e42d3d7f0d08531" - -[[package]] -name = "futures-lite" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7694489acd39452c77daa48516b894c153f192c3578d5a839b62c58099fcbf48" -dependencies = [ - "fastrand", - "futures-core", - "futures-io", - "memchr", - "parking", - "pin-project-lite", - "waker-fn", -] - -[[package]] -name = "futures-macro" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a73af87da33b5acf53acfebdc339fe592ecf5357ac7c0a7734ab9d8c876a70" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "futures-sink" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" - -[[package]] -name = "futures-task" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcf79a1bf610b10f42aea489289c5a2c478a786509693b80cd39c44ccd936366" - -[[package]] -name = "futures-util" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c1d6de3acfef38d2be4b1f543f553131788603495be83da675e180c8d6b7bd1" -dependencies = [ - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "fxhash" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" -dependencies = [ - "byteorder", -] - -[[package]] -name = "gdk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa9cb33da481c6c040404a11f8212d193889e9b435db2c14fd86987f630d3ce1" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk-pixbuf", - "gdk-sys", - "gio", - "glib", - "libc", - "pango", -] - -[[package]] -name = "gdk-pixbuf" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3578c60dee9d029ad86593ed88cb40f35c1b83360e12498d055022385dd9a05" -dependencies = [ - "bitflags", - "gdk-pixbuf-sys", - "gio", - "glib", - "libc", -] - -[[package]] -name = "gdk-pixbuf-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3092cf797a5f1210479ea38070d9ae8a5b8e9f8f1be9f32f4643c529c7d70016" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gdk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d76354f97a913e55b984759a997b693aa7dc71068c9e98bcce51aa167a0a5c5a" -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.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4511710212ed3020b61a8622a37aa6f0dd2a84516575da92e9b96928dcbe83ba" -dependencies = [ - "gdk-sys", - "glib-sys", - "gobject-sys", - "libc", - "pkg-config", - "system-deps", -] - -[[package]] -name = "gdkx11-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fa2bf8b5b8c414bc5d05e48b271896d0fd3ddb57464a3108438082da61de6af" -dependencies = [ - "gdk-sys", - "glib-sys", - "libc", - "system-deps", - "x11", -] - -[[package]] -name = "generator" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d266041a359dfa931b370ef684cceb84b166beb14f7f0421f4a6a3d0c446d12e" -dependencies = [ - "cc", - "libc", - "log", - "rustversion", - "windows 0.39.0", -] - -[[package]] -name = "generic-array" -version = "0.14.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bff49e947297f3312447abdca79f45f4738097cc82b06e72054d2223f601f1b9" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c05aeb6a22b8f62540c194aac980f2115af067bfe15a0734d7277a768d396b31" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gio" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a1c84b4534a290a29160ef5c6eff2a9c95833111472e824fc5cb78b513dd092" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-io", - "futures-util", - "gio-sys", - "glib", - "libc", - "once_cell", - "pin-project-lite", - "smallvec", - "thiserror", -] - -[[package]] -name = "gio-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9b693b8e39d042a95547fc258a7b07349b1f0b48f4b2fa3108ba3c51c0b5229" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", - "winapi", -] - -[[package]] -name = "glib" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddd4df61a866ed7259d6189b8bcb1464989a77f1d85d25d002279bbe9dd38b2f" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-executor", - "futures-task", - "futures-util", - "gio-sys", - "glib-macros", - "glib-sys", - "gobject-sys", - "libc", - "once_cell", - "smallvec", - "thiserror", -] - -[[package]] -name = "glib-macros" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e084807350b01348b6d9dbabb724d1a0bb987f47a2c85de200e98e12e30733bf" -dependencies = [ - "anyhow", - "heck 0.4.1", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "glib-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c61a4f46316d06bfa33a7ac22df6f0524c8be58e3db2d9ca99ccb1f357b62a65" -dependencies = [ - "libc", - "system-deps", -] - -[[package]] -name = "glob" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" - -[[package]] -name = "globset" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "029d74589adefde59de1a0c4f4732695c32805624aec7b68d91503d4dba79afc" -dependencies = [ - "aho-corasick", - "bstr", - "fnv", - "log", - "regex", -] - -[[package]] -name = "gobject-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3520bb9c07ae2a12c7f2fbb24d4efc11231c8146a86956413fb1a79bb760a0f1" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gtk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4d3507d43908c866c805f74c9dd593c0ce7ba5c38e576e41846639cdcd4bee6" -dependencies = [ - "atk", - "bitflags", - "cairo-rs", - "field-offset", - "futures-channel", - "gdk", - "gdk-pixbuf", - "gio", - "glib", - "gtk-sys", - "gtk3-macros", - "libc", - "once_cell", - "pango", - "pkg-config", -] - -[[package]] -name = "gtk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b5f8946685d5fe44497007786600c2f368ff6b1e61a16251c89f72a97520a3" -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.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cfd6557b1018b773e43c8de9d0d13581d6b36190d0501916cbec4731db5ccff" -dependencies = [ - "anyhow", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "h2" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5be7b54589b581f624f566bf5d8eb2bab1db736c51528720b6bd36b96b55924d" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - -[[package]] -name = "heck" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" - -[[package]] -name = "hermit-abi" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "html5ever" -version = "0.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c13fb08e5d4dfc151ee5e88bae63f7773d61852f3bdc73c9f4b9e1bde03148" -dependencies = [ - "log", - "mac", - "markup5ever", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "http" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" -dependencies = [ - "bytes", - "fnv", - "itoa 1.0.5", -] - -[[package]] -name = "http-body" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" -dependencies = [ - "bytes", - "http", - "pin-project-lite", -] - -[[package]] -name = "http-range" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21dec9db110f5f872ed9699c3ecf50cf16f423502706ba5c72462e28d3157573" - -[[package]] -name = "httparse" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" - -[[package]] -name = "httpdate" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" - -[[package]] -name = "hyper" -version = "0.14.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc5e554ff619822309ffd57d8734d77cd5ce6238bc956f037ea06c58238c9899" -dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "httpdate", - "itoa 1.0.5", - "pin-project-lite", - "socket2", - "tokio", - "tower-service", - "tracing", - "want", -] - -[[package]] -name = "ico" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3804960be0bb5e4edb1e1ad67afd321a9ecfd875c3e65c099468fd2717d7cae" -dependencies = [ - "byteorder", - "png", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "713f1b139373f96a2e0ce3ac931cd01ee973c3c5dd7c40c0c2efe96ad2b6751d" -dependencies = [ - "crossbeam-utils", - "globset", - "lazy_static", - "log", - "memchr", - "regex", - "same-file", - "thread_local", - "walkdir", - "winapi-util", -] - -[[package]] -name = "image" -version = "0.24.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69b7ea949b537b0fd0af141fff8c77690f2ce96f4f41f042ccb6c69c6c965945" -dependencies = [ - "bytemuck", - "byteorder", - "color_quant", - "num-rational", - "num-traits", -] - -[[package]] -name = "indexmap" -version = "1.9.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399" -dependencies = [ - "autocfg", - "hashbrown", -] - -[[package]] -name = "infer" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a898e4b7951673fce96614ce5751d13c40fc5674bc2d759288e46c3ab62598b3" -dependencies = [ - "cfb", -] - -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "io-lifetimes" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09270fd4fa1111bc614ed2246c7ef56239a3063d5be0d1ec3b589c505d400aeb" -dependencies = [ - "hermit-abi 0.3.1", - "libc", - "windows-sys 0.45.0", -] - -[[package]] -name = "ipnet" -version = "2.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12b6ee2129af8d4fb011108c73d99a1b83a85977f23b82460c0ae2e25bb4b57f" - -[[package]] -name = "itoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4" - -[[package]] -name = "itoa" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fad582f4b9e86b6caa621cabeb0963332d92eea04729ab12892c2533951e6440" - -[[package]] -name = "javascriptcore-rs" -version = "0.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "110b9902c80c12bf113c432d0b71c7a94490b294a8234f326fd0abca2fac0b00" -dependencies = [ - "bitflags", - "glib", - "javascriptcore-rs-sys", -] - -[[package]] -name = "javascriptcore-rs-sys" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98a216519a52cd941a733a0ad3f1023cfdb1cd47f3955e8e863ed56f558f916c" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "jni" -version = "0.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039022cdf4d7b1cf548d31f60ae783138e5fd42013f6271049d7df7afadef96c" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - -[[package]] -name = "jni-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" - -[[package]] -name = "js-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "json-patch" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e712e62827c382a77b87f590532febb1f8b2fdbc3eefa1ee37fe7281687075ef" -dependencies = [ - "serde", - "serde_json", - "thiserror", - "treediff", -] - -[[package]] -name = "kuchiki" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ea8e9c6e031377cff82ee3001dc8026cdf431ed4e2e6b51f98ab8c73484a358" -dependencies = [ - "cssparser", - "html5ever", - "matches", - "selectors", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.139" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "201de327520df007757c1f0adce6e827fe8562fbc28bfd9c15571c66ca1f5f79" - -[[package]] -name = "line-wrap" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30344350a2a51da54c1d53be93fade8a237e545dbcc4bdbe635413f2117cab9" -dependencies = [ - "safemem", -] - -[[package]] -name = "linux-raw-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d59d8c75012853d2e872fb56bc8a2e53718e2cafe1a4c823143141c6d90c322f" - -[[package]] -name = "lock_api" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", - "value-bag", -] - -[[package]] -name = "loom" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff50ecb28bb86013e935fb6683ab1f6d3a20016f123c76fd4c27470076ac30f5" -dependencies = [ - "cfg-if", - "generator", - "scoped-tls", - "serde", - "serde_json", - "tracing", - "tracing-subscriber", -] - -[[package]] -name = "mac" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4" - -[[package]] -name = "mac-notification-sys" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e72d50edb17756489e79d52eb146927bec8eba9dd48faadf9ef08bca3791ad5" -dependencies = [ - "cc", - "dirs-next", - "objc-foundation", - "objc_id", - "time", -] - -[[package]] -name = "malloc_buf" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb" -dependencies = [ - "libc", -] - -[[package]] -name = "markup5ever" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a24f40fb03852d1cdd84330cddcaf98e9ec08a7b7768e952fad3b4cf048ec8fd" -dependencies = [ - "log", - "phf 0.8.0", - "phf_codegen", - "string_cache", - "string_cache_codegen", - "tendril", -] - -[[package]] -name = "matchers" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" -dependencies = [ - "regex-automata", -] - -[[package]] -name = "matches" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "memoffset" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" -dependencies = [ - "autocfg", -] - -[[package]] -name = "memoffset" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5de893c32cde5f383baa4c04c5d6dbdd735cfd4a794b0debdb2bb1b421da5ff4" -dependencies = [ - "autocfg", -] - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b9d9a46eff5b4ff64b45a9e316a6d1e0bc719ef429cbec4dc630684212bfdf9" -dependencies = [ - "libc", - "log", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.45.0", -] - -[[package]] -name = "ndk" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2032c77e030ddee34a6787a64166008da93f6a352b629261d0fee232b8742dd4" -dependencies = [ - "bitflags", - "jni-sys", - "ndk-sys", - "num_enum", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5a6ae77c8ee183dcbbba6150e2e6b9f3f4196a7666c02a715a95692ec1fa97" -dependencies = [ - "jni-sys", -] - -[[package]] -name = "new_debug_unreachable" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" - -[[package]] -name = "nix" -version = "0.26.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfdda3d196821d6af13126e40375cdf7da646a96114af134d5f417a9a1dc8e1a" -dependencies = [ - "bitflags", - "cfg-if", - "libc", - "memoffset 0.7.1", - "pin-utils", - "static_assertions", -] - -[[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] -name = "nom8" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae01545c9c7fc4486ab7debaf2aad7003ac19431791868fb2e8066df97fad2f8" -dependencies = [ - "memchr", -] - -[[package]] -name = "notify-rust" -version = "4.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "260208751689b605138bb55ab6af43ad75f628619a7e0b818d63bf6629e59467" -dependencies = [ - "mac-notification-sys", - "serde", - "tauri-winrt-notification", - "zbus", -] - -[[package]] -name = "nu-ansi-term" -version = "0.46.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" -dependencies = [ - "overload", - "winapi", -] - -[[package]] -name = "num-integer" -version = "0.1.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b" -dependencies = [ - "hermit-abi 0.2.6", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e0072973714303aa6e3631c7e8e777970cf4bdd25dc4932e41031027b8bcc4e" -dependencies = [ - "num_enum_derive", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0629cbd6b897944899b1f10496d9c4a7ac5878d45fd61bc22e9e79bfbbc29597" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "num_threads" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2819ce041d2ee131036f4fc9d6ae7ae125a3a40e97ba64d04fe799ad9dabbb44" -dependencies = [ - "libc", -] - -[[package]] -name = "objc" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1" -dependencies = [ - "malloc_buf", - "objc_exception", -] - -[[package]] -name = "objc-foundation" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1add1b659e36c9607c7aab864a76c7a4c2760cd0cd2e120f3fb8b952c7e22bf9" -dependencies = [ - "block", - "objc", - "objc_id", -] - -[[package]] -name = "objc_exception" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad970fb455818ad6cba4c122ad012fae53ae8b4795f86378bce65e4f6bab2ca4" -dependencies = [ - "cc", -] - -[[package]] -name = "objc_id" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b" -dependencies = [ - "objc", -] - -[[package]] -name = "once_cell" -version = "1.17.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7e5500299e16ebb147ae15a00a942af264cf3688f47923b8fc2cd5858f23ad3" - -[[package]] -name = "open" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2078c0039e6a54a0c42c28faa984e115fb4c2d5bf2208f77d1961002df8576f8" -dependencies = [ - "pathdiff", - "windows-sys 0.42.0", -] - -[[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.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5209b2162b2c140df493a93689e04f8deab3a67634f5bc7a553c0a98e5b8d399" -dependencies = [ - "log", - "serde", - "winapi", -] - -[[package]] -name = "os_pipe" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a53dbb20faf34b16087a931834cba2d7a73cc74af2b7ef345a4c8324e2409a12" -dependencies = [ - "libc", - "windows-sys 0.45.0", -] - -[[package]] -name = "overload" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" - -[[package]] -name = "pango" -version = "0.16.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdff66b271861037b89d028656184059e03b0b6ccb36003820be19f7200b1e94" -dependencies = [ - "bitflags", - "gio", - "glib", - "libc", - "once_cell", - "pango-sys", -] - -[[package]] -name = "pango-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e134909a9a293e04d2cc31928aa95679c5e4df954d0b85483159bd20d8f047f" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "parking" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "427c3892f9e783d91cc128285287e70a59e206ca452770ece88a76f7a3eddd72" - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9069cbb9f99e3a5083476ccb29ceb1de18b9118cafa53e90c9551235de2b9521" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-sys 0.45.0", -] - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "percent-encoding" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" - -[[package]] -name = "pest" -version = "2.5.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "028accff104c4e513bad663bbcd2ad7cfd5304144404c31ed0a77ac103d00660" -dependencies = [ - "thiserror", - "ucd-trie", -] - -[[package]] -name = "phf" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dfb61232e34fcb633f43d12c58f83c1df82962dcdfa565a4e866ffc17dafe12" -dependencies = [ - "phf_macros 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", -] - -[[package]] -name = "phf" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259" -dependencies = [ - "phf_macros 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", -] - -[[package]] -name = "phf_codegen" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbffee61585b0411840d3ece935cce9cb6321f01c45477d30066498cd5e1a815" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", -] - -[[package]] -name = "phf_generator" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17367f0cc86f2d25802b2c26ee58a7b23faeccf78a396094c13dced0d0182526" -dependencies = [ - "phf_shared 0.8.0", - "rand 0.7.3", -] - -[[package]] -name = "phf_generator" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d5285893bb5eb82e6aaf5d59ee909a06a16737a8970984dd7746ba9283498d6" -dependencies = [ - "phf_shared 0.10.0", - "rand 0.8.5", -] - -[[package]] -name = "phf_macros" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6fde18ff429ffc8fe78e2bf7f8b7a5a5a6e2a8b58bc5a9ac69198bbda9189c" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "phf_macros" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fdf3184dd560f160dd73922bea2d5cd6e8f064bf4b13110abd81b03697b4e0" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "phf_shared" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c00cf8b9eafe68dde5e9eaa2cef8ee84a9336a47d566ec55ca16589633b65af7" -dependencies = [ - "siphasher", -] - -[[package]] -name = "phf_shared" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" - -[[package]] -name = "plist" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5329b8f106a176ab0dce4aae5da86bfcb139bb74fb00882859e03745011f3635" -dependencies = [ - "base64 0.13.1", - "indexmap", - "line-wrap", - "quick-xml 0.26.0", - "serde", - "time", -] - -[[package]] -name = "png" -version = "0.17.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d708eaf860a19b19ce538740d2b4bdeeb8337fa53f7738455e706623ad5c638" -dependencies = [ - "bitflags", - "crc32fast", - "flate2", - "miniz_oxide", -] - -[[package]] -name = "polling" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e1f879b2998099c2d69ab9605d145d5b661195627eccc680002c4918a7fb6fa" -dependencies = [ - "autocfg", - "bitflags", - "cfg-if", - "concurrent-queue", - "libc", - "log", - "pin-project-lite", - "windows-sys 0.45.0", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[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.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66618389e4ec1c7afe67d51a9bf34ff9236480f8d51e7489b7d5ab0303c13f34" -dependencies = [ - "once_cell", - "toml_edit", -] - -[[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", - "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-macro-hack" -version = "0.5.20+deprecated" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" - -[[package]] -name = "proc-macro2" -version = "1.0.51" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d727cae5b39d21da60fa540906919ad737832fe0b1c165da3a34d6548c849d6" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quick-xml" -version = "0.23.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11bafc859c6815fbaffbbbf4229ecb767ac913fecb27f9ad4343662e9ef099ea" -dependencies = [ - "memchr", -] - -[[package]] -name = "quick-xml" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f50b1c63b38611e7d4d7f68b82d3ad0cc71a2ad2e7f61fc10f1328d917c93cd" -dependencies = [ - "memchr", -] - -[[package]] -name = "quote" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8856d8364d252a14d474036ea1358d63c9e6965c8e5c1885c18f73d70bff9c7b" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", - "rand_pcg", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.8", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_pcg" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "raw-window-handle" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed7e3d950b66e19e0c372f3fa3fbbcf85b1746b571f74e0c2af6042a5c93420a" -dependencies = [ - "cty", -] - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.8", - "redox_syscall", - "thiserror", -] - -[[package]] -name = "regex" -version = "1.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48aaa5748ba571fb95cd2c85c09f629215d3a6ece942baa100950af03a34f733" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "456c603be3e8d448b072f410900c09faf164fbce2d480456f50eea6e25f9c848" - -[[package]] -name = "remove_dir_all" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7" -dependencies = [ - "winapi", -] - -[[package]] -name = "reqwest" -version = "0.11.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27b71749df584b7f4cac2c426c127a7c785a5106cc98f7a8feb044115f0fa254" -dependencies = [ - "base64 0.21.0", - "bytes", - "encoding_rs", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "hyper", - "ipnet", - "js-sys", - "log", - "mime", - "once_cell", - "percent-encoding", - "pin-project-lite", - "serde", - "serde_json", - "serde_urlencoded", - "tokio", - "tokio-util", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "wasm-streams", - "web-sys", - "winreg", -] - -[[package]] -name = "rfd" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fe3bae427b011620cf4436d5dd7405c1a86dce3dfcdc0cda12b41fd31569ac3" -dependencies = [ - "block", - "dispatch", - "glib-sys", - "gobject-sys", - "gtk-sys", - "js-sys", - "log", - "objc", - "objc-foundation", - "objc_id", - "raw-window-handle", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "windows 0.44.0", -] - -[[package]] -name = "rustc_version" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" -dependencies = [ - "semver 0.11.0", -] - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver 1.0.16", -] - -[[package]] -name = "rustix" -version = "0.37.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b24138615de35e32031d041a09032ef3487a616d901ca4db224e7d557efae2" -dependencies = [ - "bitflags", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys", - "windows-sys 0.45.0", -] - -[[package]] -name = "rustversion" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5583e89e108996506031660fe09baa5011b9dd0341b89029313006d1fb508d70" - -[[package]] -name = "ryu" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b4b9743ed687d4b4bcedf9ff5eaa7398495ae14e61cba0a295704edbc7decde" - -[[package]] -name = "safemem" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef703b7cb59335eae2eb93ceb664c0eb7ea6bf567079d843e09420219668e072" - -[[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 = "scoped-tls" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" - -[[package]] -name = "scopeguard" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "selectors" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df320f1889ac4ba6bc0cdc9c9af7af4bd64bb927bccdf32d81140dc1f9be12fe" -dependencies = [ - "bitflags", - "cssparser", - "derive_more", - "fxhash", - "log", - "matches", - "phf 0.8.0", - "phf_codegen", - "precomputed-hash", - "servo_arc", - "smallvec", - "thin-slice", -] - -[[package]] -name = "semver" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" -dependencies = [ - "semver-parser", -] - -[[package]] -name = "semver" -version = "1.0.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58bc9567378fc7690d6b2addae4e60ac2eeea07becb2c64b9f218b53865cba2a" -dependencies = [ - "serde", -] - -[[package]] -name = "semver-parser" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" -dependencies = [ - "pest", -] - -[[package]] -name = "serde" -version = "1.0.152" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb7d1f0d3021d347a83e556fc4683dea2ea09d87bccdf88ff5c12545d89d5efb" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.152" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af487d118eecd09402d70a5d72551860e788df87b464af30e5ea6a38c75c541e" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cad406b69c91885b5107daf2c29572f6c8cdb3c66826821e286c533490c0bc76" -dependencies = [ - "itoa 1.0.5", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a5ec9fa74a20ebbe5d9ac23dac1fc96ba0ecfe9f50f2843b52e537b10fbcb4e" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa 1.0.5", - "ryu", - "serde", -] - -[[package]] -name = "serde_with" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" -dependencies = [ - "serde", - "serde_with_macros", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serialize-to-javascript" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9823f2d3b6a81d98228151fdeaf848206a7855a7a042bbf9bf870449a66cafb" -dependencies = [ - "serde", - "serde_json", - "serialize-to-javascript-impl", -] - -[[package]] -name = "serialize-to-javascript-impl" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74064874e9f6a15f04c1f3cb627902d0e6b410abbf36668afa873c61889f1763" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "servo_arc" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d98238b800e0d1576d8b6e3de32827c2d74bee68bb97748dcf5071fb53965432" -dependencies = [ - "nodrop", - "stable_deref_trait", -] - -[[package]] -name = "sha1" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f04293dc80c3993519f2d7f6f511707ee7094fe0c6d3406feb330cdb3540eba3" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sha2" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sharded-slab" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31" -dependencies = [ - "lazy_static", -] - -[[package]] -name = "shared_child" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0d94659ad3c2137fef23ae75b03d5241d633f8acded53d672decfa0e6e0caef" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "siphasher" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de" - -[[package]] -name = "slab" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4614a76b2a8be0058caa9dbbaf66d988527d86d003c11a94fbd335d7661edcef" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" - -[[package]] -name = "socket2" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "soup3" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82bc46048125fefd69d30b32b9d263d6556c9ffe82a7a7df181a86d912da5616" -dependencies = [ - "bitflags", - "futures-channel", - "gio", - "glib", - "libc", - "once_cell", - "soup3-sys", -] - -[[package]] -name = "soup3-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "014bbeb1c4cdb30739dc181e8d98b7908f124d9555843afa89b5570aaf4ec62b" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "stable_deref_trait" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" - -[[package]] -name = "state" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe866e1e51e8260c9eed836a042a5e7f6726bb2b411dffeaa712e19c388f23b" -dependencies = [ - "loom", -] - -[[package]] -name = "static_assertions" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" - -[[package]] -name = "string_cache" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "213494b7a2b503146286049378ce02b482200519accc31872ee8be91fa820a08" -dependencies = [ - "new_debug_unreachable", - "once_cell", - "parking_lot", - "phf_shared 0.10.0", - "precomputed-hash", - "serde", -] - -[[package]] -name = "string_cache_codegen" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bb30289b722be4ff74a408c3cc27edeaad656e06cb1fe8fa9231fa59c728988" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro2", - "quote", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "strum" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7ac893c7d471c8a21f31cfe213ec4f6d9afeed25537c772e08ef3f005f8729e" -dependencies = [ - "strum_macros", -] - -[[package]] -name = "strum_macros" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "339f799d8b549e3744c7ac7feb216383e4005d94bdb22561b3ab8f3b808ae9fb" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "swift-rs" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fa67d647176dfa7bdc5775430a1cb339e0ea48fe24707424023a4b17eb9688e" -dependencies = [ - "base64 0.21.0", - "serde", - "serde_json", -] - -[[package]] -name = "syn" -version = "1.0.107" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f4064b5b16e03ae50984a5a8ed5d4f8803e6bc1fd170a3cda91a1be4b18e3f5" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-deps" -version = "6.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2955b1fe31e1fa2fbd1976b71cc69a606d7d4da16f6de3333d0c92d51419aeff" -dependencies = [ - "cfg-expr", - "heck 0.4.1", - "pkg-config", - "toml", - "version-compare", -] - -[[package]] -name = "tao" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1d16138f5d521fcde40580e1a34df784b063dd9ac05c7cbe344bf01f02a23be" -dependencies = [ - "bitflags", - "cairo-rs", - "cc", - "cocoa", - "core-foundation", - "core-graphics", - "crossbeam-channel", - "dispatch", - "gdk", - "gdk-pixbuf", - "gdk-sys", - "gdkwayland-sys", - "gdkx11-sys", - "gio", - "glib", - "glib-sys", - "gtk", - "image", - "instant", - "jni", - "lazy_static", - "libc", - "log", - "ndk", - "ndk-context", - "ndk-sys", - "objc", - "once_cell", - "parking_lot", - "png", - "raw-window-handle", - "scopeguard", - "serde", - "tao-macros", - "unicode-segmentation", - "uuid", - "windows 0.44.0", - "windows-implement", - "x11-dl", -] - -[[package]] -name = "tao-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b27a4bcc5eb524658234589bdffc7e7bfb996dbae6ce9393bfd39cb4159b445" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tar" -version = "0.4.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b55807c0344e1e6c04d7c965f5289c39a8d94ae23ed5c0b57aabac549f871c6" -dependencies = [ - "filetime", - "libc", - "xattr", -] - -[[package]] -name = "tauri" -version = "2.0.0-alpha.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f25eefe4ca0a396a73fd0309f778eeb22a19953a3169bf316b893abadc2118fb" -dependencies = [ - "anyhow", - "bytes", - "cocoa", - "dirs-next", - "embed_plist", - "encoding_rs", - "flate2", - "futures-util", - "glib", - "glob", - "gtk", - "heck 0.4.1", - "http", - "ignore", - "jni", - "libc", - "log", - "notify-rust", - "objc", - "once_cell", - "open", - "os_info", - "os_pipe", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "regex", - "reqwest", - "rfd", - "semver 1.0.16", - "serde", - "serde_json", - "serde_repr", - "serialize-to-javascript", - "shared_child", - "state", - "swift-rs", - "tar", - "tauri-build", - "tauri-macros", - "tauri-runtime", - "tauri-runtime-wry", - "tauri-utils", - "tempfile", - "thiserror", - "tokio", - "url", - "uuid", - "webkit2gtk", - "webview2-com", - "windows 0.44.0", -] - -[[package]] -name = "tauri-build" -version = "2.0.0-alpha.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c492211c72b95f8866e5c1fbc0a915080a5ebb9f03f9b250a1c936534b680a76" -dependencies = [ - "anyhow", - "cargo_toml", - "filetime", - "heck 0.4.1", - "json-patch", - "semver 1.0.16", - "serde", - "serde_json", - "swift-rs", - "tauri-utils", - "tauri-winres", - "walkdir", -] - -[[package]] -name = "tauri-codegen" -version = "2.0.0-alpha.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "818c570932ebc2ff6d498be89d93494b89ff142131937a7e56d7cfb9c8ef0ad0" -dependencies = [ - "base64 0.21.0", - "brotli", - "ico", - "json-patch", - "plist", - "png", - "proc-macro2", - "quote", - "regex", - "semver 1.0.16", - "serde", - "serde_json", - "sha2", - "tauri-utils", - "thiserror", - "time", - "url", - "uuid", - "walkdir", -] - -[[package]] -name = "tauri-macros" -version = "2.0.0-alpha.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3b596485d89003d2d7869469b2830e9a846de9ac2eecd69bc7c24890234aefc" -dependencies = [ - "heck 0.4.1", - "proc-macro2", - "quote", - "syn", - "tauri-codegen", - "tauri-utils", -] - -[[package]] -name = "tauri-plugin-dialog" -version = "0.1.0" -dependencies = [ - "glib", - "log", - "raw-window-handle", - "rfd", - "serde", - "serde_json", - "tauri", - "tauri-build", - "thiserror", -] - -[[package]] -name = "tauri-plugin-log" -version = "0.1.0" -dependencies = [ - "android_logger", - "byte-unit", - "cocoa", - "fern", - "log", - "objc", - "serde", - "serde_json", - "serde_repr", - "swift-rs", - "tauri", - "tauri-build", - "time", -] - -[[package]] -name = "tauri-runtime" -version = "0.13.0-alpha.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "404367cd32a5a8d33368448aab7da54bb2187b6a632526f1019de3fd13591cc2" -dependencies = [ - "gtk", - "http", - "http-range", - "jni", - "rand 0.8.5", - "raw-window-handle", - "serde", - "serde_json", - "tauri-utils", - "thiserror", - "url", - "uuid", - "webview2-com", - "windows 0.44.0", -] - -[[package]] -name = "tauri-runtime-wry" -version = "0.13.0-alpha.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "203764d673b440877dea87b972772be4091ee0ab25141748008646ca774a20dc" -dependencies = [ - "cocoa", - "gtk", - "jni", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "tauri-runtime", - "tauri-utils", - "uuid", - "webkit2gtk", - "webview2-com", - "windows 0.44.0", - "wry", -] - -[[package]] -name = "tauri-utils" -version = "2.0.0-alpha.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49fa79bc56f04ece491268a64273de945f65627bcda30d9e8ecc8708b89bca26" -dependencies = [ - "brotli", - "ctor", - "glob", - "heck 0.4.1", - "html5ever", - "infer", - "json-patch", - "kuchiki", - "memchr", - "phf 0.10.1", - "proc-macro2", - "quote", - "semver 1.0.16", - "serde", - "serde_json", - "serde_with", - "thiserror", - "url", - "walkdir", - "windows 0.44.0", -] - -[[package]] -name = "tauri-winres" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b7a78dc04f75fb5ab815e66ac561c81e92a968a40f29e7c21afd152d694fad8" -dependencies = [ - "toml", - "version_check", -] - -[[package]] -name = "tauri-winrt-notification" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c58de036c4d2e20717024de2a3c4bf56c301f07b21bc8ef9b57189fce06f1f3b" -dependencies = [ - "quick-xml 0.23.1", - "strum", - "windows 0.39.0", -] - -[[package]] -name = "tempfile" -version = "3.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cdb1ef4eaeeaddc8fbd371e5017057064af0911902ef36b39801f67cc6d79e4" -dependencies = [ - "cfg-if", - "fastrand", - "libc", - "redox_syscall", - "remove_dir_all", - "winapi", -] - -[[package]] -name = "tendril" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d24a120c5fc464a3458240ee02c299ebcb9d67b5249c8848b09d639dca8d7bb0" -dependencies = [ - "futf", - "mac", - "utf-8", -] - -[[package]] -name = "thin-slice" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c" - -[[package]] -name = "thiserror" -version = "1.0.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a9cd18aa97d5c45c6603caea1da6628790b37f7a34b6ca89522331c5180fed0" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fb327af4685e4d03fa8cbcf1716380da910eeb2bb8be417e7f9fd3fb164f36f" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "thread_local" -version = "1.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdd6f064ccff2d6567adcb3873ca630700f00b5ad3f060c25b5dcfd9a4ce152" -dependencies = [ - "cfg-if", - "once_cell", -] - -[[package]] -name = "time" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d634a985c4d4238ec39cacaed2e7ae552fbd3c476b552c1deac3021b7d7eaf0c" -dependencies = [ - "itoa 1.0.5", - "libc", - "num_threads", -] - -[[package]] -name = "tinyvec" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.25.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8e00990ebabbe4c14c08aca901caed183ecd5c09562a12c824bb53d3c3fd3af" -dependencies = [ - "autocfg", - "bytes", - "libc", - "memchr", - "mio", - "num_cpus", - "pin-project-lite", - "socket2", - "windows-sys 0.42.0", -] - -[[package]] -name = "tokio-util" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5427d89453009325de0d8f342c9490009f76e999cb7672d77e46267448f7e6b2" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", - "tracing", -] - -[[package]] -name = "toml" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_datetime" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4553f467ac8e3d374bc9a177a26801e5d0f9b211aa1673fb137a403afd1c9cf5" - -[[package]] -name = "toml_edit" -version = "0.18.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56c59d8dd7d0dcbc6428bf7aa2f0e823e26e43b3c9aca15bbc9475d23e5fa12b" -dependencies = [ - "indexmap", - "nom8", - "toml_datetime", -] - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" -dependencies = [ - "cfg-if", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tracing-core" -version = "0.1.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" -dependencies = [ - "once_cell", - "valuable", -] - -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - -[[package]] -name = "tracing-subscriber" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6176eae26dd70d0c919749377897b54a9276bd7061339665dd68777926b5a70" -dependencies = [ - "matchers", - "nu-ansi-term", - "once_cell", - "regex", - "sharded-slab", - "smallvec", - "thread_local", - "tracing", - "tracing-core", - "tracing-log", -] - -[[package]] -name = "treediff" -version = "4.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52984d277bdf2a751072b5df30ec0377febdb02f7696d64c2d7d54630bac4303" -dependencies = [ - "serde_json", -] - -[[package]] -name = "try-lock" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" - -[[package]] -name = "typenum" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" - -[[package]] -name = "ucd-trie" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e79c4d996edb816c91e4308506774452e55e95c3c9de07b6729e17e15a5ef81" - -[[package]] -name = "uds_windows" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce65604324d3cce9b966701489fbd0cf318cb1f7bd9dd07ac9a4ee6fb791930d" -dependencies = [ - "tempfile", - "winapi", -] - -[[package]] -name = "unicode-bidi" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d54675592c1dbefd78cbd98db9bacd89886e1ca50692a0692baefffdeb92dd58" - -[[package]] -name = "unicode-ident" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84a22b9f218b40614adcb3f4ff08b703773ad44fa9423e4e0d346d5db86e4ebc" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - -[[package]] -name = "url" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", - "serde", -] - -[[package]] -name = "utf-8" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" - -[[package]] -name = "utf8-width" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5190c9442dcdaf0ddd50f37420417d219ae5261bbf5db120d0f9bab996c9cba1" - -[[package]] -name = "uuid" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1674845326ee10d37ca60470760d4288a6f80f304007d92e5c53bab78c9cfd79" -dependencies = [ - "getrandom 0.2.8", -] - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "value-bag" -version = "1.0.0-alpha.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2209b78d1249f7e6f3293657c9779fe31ced465df091bbd433a1cf88e916ec55" -dependencies = [ - "ctor", - "version_check", -] - -[[package]] -name = "version-compare" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "579a42fc0b8e0c63b76519a339be31bed574929511fa53c1a3acae26eb258f29" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "waker-fn" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d5b2c62b4012a3e1eca5a7e077d13b3bf498c4073e33ccd58626607748ceeca" - -[[package]] -name = "walkdir" -version = "2.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "808cf2735cd4b6866113f648b791c6adc5714537bc222d9347bb203386ffda56" -dependencies = [ - "same-file", - "winapi", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" -dependencies = [ - "log", - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f219e0d211ba40266969f6dbdd90636da12f75bee4fc9d6c23d1260dadb51454" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" - -[[package]] -name = "wasm-streams" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bbae3363c08332cadccd13b67db371814cd214c2524020932f0804b8cf7c078" -dependencies = [ - "futures-util", - "js-sys", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", -] - -[[package]] -name = "web-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "webkit2gtk" -version = "0.19.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8eea819afe15eb8dcdff4f19d8bfda540bae84d874c10e6f4b8faf2d6704bd1" -dependencies = [ - "bitflags", - "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 = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0ac7a95ddd3fdfcaf83d8e513b4b1ad101b95b413b6aa6662ed95f284fc3d5b" -dependencies = [ - "bitflags", - "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 = "webview2-com" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11296e5daf3a653b79bf47d66c380e4143d5b9c975818871179a3bda79499562" -dependencies = [ - "webview2-com-macros", - "webview2-com-sys", - "windows 0.44.0", - "windows-implement", -] - -[[package]] -name = "webview2-com-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaebe196c01691db62e9e4ca52c5ef1e4fd837dcae27dae3ada599b5a8fd05ac" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "webview2-com-sys" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cde542bed28058a5b028d459689ee57f1d06685bb6c266da3b91b1be6703952f" -dependencies = [ - "regex", - "serde", - "serde_json", - "thiserror", - "windows 0.44.0", - "windows-bindgen", - "windows-metadata", -] - -[[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.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi", -] - -[[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 = "windows" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1c4bd0a50ac6020f65184721f758dba47bb9fbc2133df715ec74a237b26794a" -dependencies = [ - "windows_aarch64_msvc 0.39.0", - "windows_i686_gnu 0.39.0", - "windows_i686_msvc 0.39.0", - "windows_x86_64_gnu 0.39.0", - "windows_x86_64_msvc 0.39.0", -] - -[[package]] -name = "windows" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e745dab35a0c4c77aa3ce42d595e13d2003d6902d6b08c9ef5fc326d08da12b" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-targets", -] - -[[package]] -name = "windows-bindgen" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "222204ecf46521382a4d88b4a1bbefca9f8855697b4ab7d20803901425e061a3" -dependencies = [ - "windows-metadata", - "windows-tokens", -] - -[[package]] -name = "windows-implement" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce87ca8e3417b02dc2a8a22769306658670ec92d78f1bd420d6310a67c245c6" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "windows-interface" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "853f69a591ecd4f810d29f17e902d40e349fb05b0b11fff63b08b826bfe39c7f" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "windows-metadata" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee78911e3f4ce32c1ad9d3c7b0bd95389662ad8d8f1a3155688fed70bd96e2b6" - -[[package]] -name = "windows-sys" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" -dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc 0.42.1", - "windows_i686_gnu 0.42.1", - "windows_i686_msvc 0.42.1", - "windows_x86_64_gnu 0.42.1", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc 0.42.1", -] - -[[package]] -name = "windows-sys" -version = "0.45.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" -dependencies = [ - "windows-targets", -] - -[[package]] -name = "windows-targets" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e2522491fbfcd58cc84d47aeb2958948c4b8982e9a2d8a2a35bbaed431390e7" -dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc 0.42.1", - "windows_i686_gnu 0.42.1", - "windows_i686_msvc 0.42.1", - "windows_x86_64_gnu 0.42.1", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc 0.42.1", -] - -[[package]] -name = "windows-tokens" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa4251900975a0d10841c5d4bde79c56681543367ef811f3fabb8d1803b0959b" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c9864e83243fdec7fc9c5444389dcbbfd258f745e7853198f365e3c4968a608" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec7711666096bd4096ffa835238905bb33fb87267910e154b18b44eaabb340f2" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8b1b673ffc16c47a9ff48570a9d85e25d265735c503681332589af6253c6c7" - -[[package]] -name = "windows_i686_gnu" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "763fc57100a5f7042e3057e7e8d9bdd7860d330070251a73d003563a3bb49e1b" - -[[package]] -name = "windows_i686_gnu" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3887528ad530ba7bdbb1faa8275ec7a1155a45ffa57c37993960277145d640" - -[[package]] -name = "windows_i686_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bc7cbfe58828921e10a9f446fcaaf649204dcfe6c1ddd712c5eebae6bda1106" - -[[package]] -name = "windows_i686_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf4d1122317eddd6ff351aa852118a2418ad4214e6613a50e0191f7004372605" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6868c165637d653ae1e8dc4d82c25d4f97dd6605eaa8d784b5c6e0ab2a252b65" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1040f221285e17ebccbc2591ffdc2d44ee1f9186324dd3e84e99ac68d699c45" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "628bfdf232daa22b0d64fdb62b09fcc36bb01f05a3939e20ab73aaf9470d0463" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e4d40883ae9cae962787ca76ba76390ffa29214667a111db9e0a1ad8377e809" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.42.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "447660ad36a13288b1db4d4248e857b510e8c3a225c822ba4fb748c0aafecffd" - -[[package]] -name = "winreg" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d0f4e272c85def139476380b12f9ac60926689dd2e01d4923222f40580869d" -dependencies = [ - "winapi", -] - -[[package]] -name = "wry" -version = "0.27.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8cf0dbfa7ccbd2e3832a3098b19d4b552360ea00a40b244a99caef46bffd84f" -dependencies = [ - "base64 0.13.1", - "block", - "cocoa", - "core-graphics", - "crossbeam-channel", - "dunce", - "gdk", - "gio", - "glib", - "gtk", - "html5ever", - "http", - "javascriptcore-rs", - "kuchiki", - "libc", - "log", - "objc", - "objc_id", - "once_cell", - "serde", - "serde_json", - "sha2", - "soup3", - "tao", - "thiserror", - "url", - "webkit2gtk", - "webkit2gtk-sys", - "webview2-com", - "windows 0.44.0", - "windows-implement", -] - -[[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 = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d1526bbe5aaeb5eb06885f4d987bcdfa5e23187055de9b83fe00156a821fabc" -dependencies = [ - "libc", -] - -[[package]] -name = "zbus" -version = "3.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dc29e76f558b2cb94190e8605ecfe77dd40f5df8c072951714b4b71a97f5848" -dependencies = [ - "async-broadcast", - "async-executor", - "async-fs", - "async-io", - "async-lock", - "async-recursion", - "async-task", - "async-trait", - "byteorder", - "derivative", - "dirs", - "enumflags2", - "event-listener", - "futures-core", - "futures-sink", - "futures-util", - "hex", - "nix", - "once_cell", - "ordered-stream", - "rand 0.8.5", - "serde", - "serde_repr", - "sha1", - "static_assertions", - "tracing", - "uds_windows", - "winapi", - "zbus_macros", - "zbus_names", - "zvariant", -] - -[[package]] -name = "zbus_macros" -version = "3.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62a80fd82c011cd08459eaaf1fd83d3090c1b61e6d5284360074a7475af3a85d" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "regex", - "syn", - "zvariant_utils", -] - -[[package]] -name = "zbus_names" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f34f314916bd89bdb9934154627fab152f4f28acdda03e7c4c68181b214fe7e3" -dependencies = [ - "serde", - "static_assertions", - "zvariant", -] - -[[package]] -name = "zvariant" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46fe4914a985446d6fd287019b5fceccce38303d71407d9e6e711d44954a05d8" -dependencies = [ - "byteorder", - "enumflags2", - "libc", - "serde", - "static_assertions", - "zvariant_derive", -] - -[[package]] -name = "zvariant_derive" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34c20260af4b28b3275d6676c7e2a6be0d4332e8e0aba4616d34007fd84e462a" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", - "zvariant_utils", -] - -[[package]] -name = "zvariant_utils" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53b22993dbc4d128a17a3b6c92f1c63872dd67198537ee728d8b5d7c40640a8b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] diff --git a/plugins/dialog/examples/tauri-app/src-tauri/Cargo.toml b/plugins/dialog/examples/tauri-app/src-tauri/Cargo.toml deleted file mode 100644 index 1abf91c9..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/Cargo.toml +++ /dev/null @@ -1,29 +0,0 @@ -workspace = {} - -[package] -name = "app" -version = "0.0.0" -description = "A Tauri App" -authors = ["you"] -license = "" -repository = "" -edition = "2021" -rust-version = "1.64" - -[lib] -crate-type = ["staticlib", "cdylib", "rlib"] - -[build-dependencies] -tauri-build = { version = "2.0.0-alpha.4", features = [] } - -[dependencies] -serde_json = "1.0" -serde = { version = "1.0", features = ["derive"] } -tauri = { version = "2.0.0-alpha.8", features = ["api-all"] } -tauri-plugin-dialog = { path = "../../../" } -tauri-plugin-log = { path = "../../../../log" } -log = "0.4" - -[features] -# DO NOT remove this -custom-protocol = [ "tauri/custom-protocol" ] diff --git a/plugins/dialog/examples/tauri-app/src-tauri/build.rs b/plugins/dialog/examples/tauri-app/src-tauri/build.rs deleted file mode 100644 index 795b9b7c..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/build.rs +++ /dev/null @@ -1,3 +0,0 @@ -fn main() { - tauri_build::build() -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/.editorconfig b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/.editorconfig deleted file mode 100644 index ebe51d3b..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/.editorconfig +++ /dev/null @@ -1,12 +0,0 @@ -# EditorConfig is awesome: https://EditorConfig.org - -# top-most EditorConfig file -root = true - -[*] -indent_style = space -indent_size = 2 -end_of_line = lf -charset = utf-8 -trim_trailing_whitespace = false -insert_final_newline = false \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/.gitignore b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/.gitignore deleted file mode 100644 index 6bb2f5ee..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/.gitignore +++ /dev/null @@ -1,18 +0,0 @@ -*.iml -.gradle -/local.properties -/.idea/caches -/.idea/libraries -/.idea/modules.xml -/.idea/workspace.xml -/.idea/navEditor.xml -/.idea/assetWizardSettings.xml -.DS_Store -build -/captures -.externalNativeBuild -.cxx -local.properties - -/.tauri -/tauri.settings.gradle \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/.gitignore b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/.gitignore deleted file mode 100644 index 810469e2..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -/src/main/java/app/tauri/app/generated -/src/main/jniLibs/**/*.so -/tauri.build.gradle.kts -/proguard-tauri.pro \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/build.gradle.kts b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/build.gradle.kts deleted file mode 100644 index 6ada65f2..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/build.gradle.kts +++ /dev/null @@ -1,113 +0,0 @@ -plugins { - id("com.android.application") - id("org.jetbrains.kotlin.android") - id("rustPlugin") -} - -android { - compileSdk = 33 - defaultConfig { - manifestPlaceholders["usesCleartextTraffic"] = "false" - applicationId = "app.tauri.app" - minSdk = 24 - targetSdk = 33 - versionCode = 1 - versionName = "1.0" - } - sourceSets.getByName("main") { - // Vulkan validation layers - val ndkHome = System.getenv("NDK_HOME") - jniLibs.srcDir("${ndkHome}/sources/third_party/vulkan/src/build-android/jniLibs") - } - buildTypes { - getByName("debug") { - manifestPlaceholders["usesCleartextTraffic"] = "true" - isDebuggable = true - isJniDebuggable = true - isMinifyEnabled = false - packagingOptions { jniLibs.keepDebugSymbols.add("*/arm64-v8a/*.so") - jniLibs.keepDebugSymbols.add("*/armeabi-v7a/*.so") - jniLibs.keepDebugSymbols.add("*/x86/*.so") - jniLibs.keepDebugSymbols.add("*/x86_64/*.so") - } - } - getByName("release") { - isMinifyEnabled = true - val proguards = fileTree(".") { - include("*.pro") - } - proguardFiles(*proguards.toList().toTypedArray()) - } - } - flavorDimensions.add("abi") - productFlavors { - create("universal") { - dimension = "abi" - ndk { - abiFilters += (findProperty("abiList") as? String)?.split(",") ?: listOf( "arm64-v8a", "armeabi-v7a", "x86", "x86_64", - ) - } - } - create("arm64") { - dimension = "abi" - ndk { - abiFilters += listOf("arm64-v8a") - } - } - - create("arm") { - dimension = "abi" - ndk { - abiFilters += listOf("armeabi-v7a") - } - } - - create("x86") { - dimension = "abi" - ndk { - abiFilters += listOf("x86") - } - } - - create("x86_64") { - dimension = "abi" - ndk { - abiFilters += listOf("x86_64") - } - } - } - - assetPacks += mutableSetOf() - namespace = "app.tauri.app" -} - -rust { - rootDirRel = "../../../../" - targets = (findProperty("targetList") as? String)?.split(",") ?: listOf("aarch64", "armv7", "i686", "x86_64") - arches = (findProperty("archList") as? String)?.split(",") ?: listOf("arm64", "arm", "x86", "x86_64") -} - -dependencies { - implementation("androidx.webkit:webkit:1.5.0") - implementation("androidx.appcompat:appcompat:1.5.1") - implementation("com.google.android.material:material:1.7.0") - testImplementation("junit:junit:4.13.2") - androidTestImplementation("androidx.test.ext:junit:1.1.4") - androidTestImplementation("androidx.test.espresso:espresso-core:3.5.0") - implementation(project(":tauri-android")) -} - -apply(from = "tauri.build.gradle.kts") - -afterEvaluate { - android.applicationVariants.all { - tasks["mergeUniversalReleaseJniLibFolders"].dependsOn(tasks["rustBuildRelease"]) - tasks["mergeUniversalDebugJniLibFolders"].dependsOn(tasks["rustBuildDebug"]) - if (findProperty("targetList") == null) { - productFlavors.filter{ it.name != "universal" }.forEach { _ -> - val archAndBuildType = name.capitalize() - tasks["merge${archAndBuildType}JniLibFolders"].dependsOn(tasks["rustBuild${archAndBuildType}"]) - } - } - } -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/proguard-rules.pro b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/proguard-rules.pro deleted file mode 100644 index 481bb434..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/proguard-rules.pro +++ /dev/null @@ -1,21 +0,0 @@ -# Add project specific ProGuard rules here. -# You can control the set of applied configuration files using the -# proguardFiles setting in build.gradle. -# -# For more details, see -# http://developer.android.com/guide/developing/tools/proguard.html - -# If your project uses WebView with JS, uncomment the following -# and specify the fully qualified class name to the JavaScript interface -# class: -#-keepclassmembers class fqcn.of.javascript.interface.for.webview { -# public *; -#} - -# Uncomment this to preserve the line number information for -# debugging stack traces. -#-keepattributes SourceFile,LineNumberTable - -# If you keep the line number information, uncomment this to -# hide the original source file name. -#-renamesourcefileattribute SourceFile \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/AndroidManifest.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/AndroidManifest.xml deleted file mode 100644 index dadb02a0..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/AndroidManifest.xml +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/java/app/tauri/app/MainActivity.kt b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/java/app/tauri/app/MainActivity.kt deleted file mode 100644 index 3dff0081..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/java/app/tauri/app/MainActivity.kt +++ /dev/null @@ -1,7 +0,0 @@ -package app.tauri.app - -import app.tauri.plugin.PluginManager - -class MainActivity : TauriActivity() { - var pluginManager: PluginManager = PluginManager(this) -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/drawable-v24/ic_launcher_foreground.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/drawable-v24/ic_launcher_foreground.xml deleted file mode 100644 index 2b068d11..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/drawable-v24/ic_launcher_foreground.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/drawable/ic_launcher_background.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/drawable/ic_launcher_background.xml deleted file mode 100644 index 07d5da9c..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/drawable/ic_launcher_background.xml +++ /dev/null @@ -1,170 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/layout/activity_main.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/layout/activity_main.xml deleted file mode 100644 index 4fc24441..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/layout/activity_main.xml +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher.png deleted file mode 100644 index 28f1aa11..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png deleted file mode 100644 index 85d0c88a..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher_round.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher_round.png deleted file mode 100644 index 28f1aa11..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-hdpi/ic_launcher_round.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher.png deleted file mode 100644 index 73e48dbf..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png deleted file mode 100644 index 13dd2147..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher_round.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher_round.png deleted file mode 100644 index 73e48dbf..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-mdpi/ic_launcher_round.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher.png deleted file mode 100644 index 1d98044f..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png deleted file mode 100644 index a888b336..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png deleted file mode 100644 index 1d98044f..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher.png deleted file mode 100644 index 08183246..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png deleted file mode 100644 index a2a838e7..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png deleted file mode 100644 index 08183246..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png deleted file mode 100644 index b18bceb6..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png deleted file mode 100644 index 3f8a57f3..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png deleted file mode 100644 index b18bceb6..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values-night/themes.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values-night/themes.xml deleted file mode 100644 index 7cd5d350..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values-night/themes.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/colors.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/colors.xml deleted file mode 100644 index f8c6127d..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/colors.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - #FFBB86FC - #FF6200EE - #FF3700B3 - #FF03DAC5 - #FF018786 - #FF000000 - #FFFFFFFF - \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/strings.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/strings.xml deleted file mode 100644 index b2556e82..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/strings.xml +++ /dev/null @@ -1,4 +0,0 @@ - - app - app - \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/themes.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/themes.xml deleted file mode 100644 index 04239cf4..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/values/themes.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/xml/file_paths.xml b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/xml/file_paths.xml deleted file mode 100644 index 782d63b9..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/app/src/main/res/xml/file_paths.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/src/main/java/app/tauri/app/kotlin/BuildTask.kt b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/src/main/java/app/tauri/app/kotlin/BuildTask.kt deleted file mode 100644 index 2e777156..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/src/main/java/app/tauri/app/kotlin/BuildTask.kt +++ /dev/null @@ -1,58 +0,0 @@ -package app.tauri - -import java.io.File -import org.apache.tools.ant.taskdefs.condition.Os -import org.gradle.api.DefaultTask -import org.gradle.api.GradleException -import org.gradle.api.logging.LogLevel -import org.gradle.api.tasks.Input -import org.gradle.api.tasks.InputDirectory -import org.gradle.api.tasks.PathSensitive -import org.gradle.api.tasks.PathSensitivity -import org.gradle.api.tasks.TaskAction - -open class BuildTask : DefaultTask() { - @InputDirectory - @PathSensitive(PathSensitivity.RELATIVE) - var rootDirRel: File? = null - @Input - var target: String? = null - @Input - var release: Boolean? = null - - @TaskAction - fun build() { - val executable = """yarn"""; - try { - runTauriCli(executable) - } catch (e: Exception){ - if (Os.isFamily(Os.FAMILY_WINDOWS)) { - runTauriCli("$executable.cmd") - } else { - throw e; - } - } - } - - fun runTauriCli(executable: String) { - val rootDirRel = rootDirRel ?: throw GradleException("rootDirRel cannot be null") - val target = target ?: throw GradleException("target cannot be null") - val release = release ?: throw GradleException("release cannot be null") - val args = listOf("tauri", "android", "android-studio-script"); - - project.exec { - workingDir(File(project.projectDir, rootDirRel.path)) - executable(executable) - args(args) - if (project.logger.isEnabled(LogLevel.DEBUG)) { - args("-vv") - } else if (project.logger.isEnabled(LogLevel.INFO)) { - args("-v") - } - if (release) { - args("--release") - } - args(listOf("--target", target)) - }.assertNormalExitValue() - } -} \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/src/main/java/app/tauri/app/kotlin/RustPlugin.kt b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/src/main/java/app/tauri/app/kotlin/RustPlugin.kt deleted file mode 100644 index f40ad054..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/buildSrc/src/main/java/app/tauri/app/kotlin/RustPlugin.kt +++ /dev/null @@ -1,59 +0,0 @@ -package app.tauri - -import org.gradle.api.DefaultTask -import org.gradle.api.GradleException -import org.gradle.api.Plugin -import org.gradle.api.Project -import java.io.File -import java.util.* - -const val TASK_GROUP = "rust" - -open class Config { - var rootDirRel: String? = null - var targets: List? = null - var arches: List? = null -} - -open class RustPlugin : Plugin { - private lateinit var config: Config - - override fun apply(project: Project) { - config = project.extensions.create("rust", Config::class.java) - project.afterEvaluate { - if (config.targets == null) { - throw GradleException("targets cannot be null") - } - if (config.arches == null) { - throw GradleException("arches cannot be null") - } - for (profile in listOf("debug", "release")) { - val profileCapitalized = profile.capitalize(Locale.ROOT) - val buildTask = project.tasks.maybeCreate( - "rustBuild$profileCapitalized", - DefaultTask::class.java - ).apply { - group = TASK_GROUP - description = "Build dynamic library in $profile mode for all targets" - } - for (targetPair in config.targets!!.withIndex()) { - val targetName = targetPair.value - val targetArch = config.arches!![targetPair.index] - val targetArchCapitalized = targetArch.capitalize(Locale.ROOT) - val targetBuildTask = project.tasks.maybeCreate( - "rustBuild$targetArchCapitalized$profileCapitalized", - BuildTask::class.java - ).apply { - group = TASK_GROUP - description = "Build dynamic library in $profile mode for $targetArch" - rootDirRel = config.rootDirRel?.let { File(it) } - target = targetName - release = profile == "release" - } - buildTask.dependsOn(targetBuildTask) - project.tasks.findByName("preBuild")?.mustRunAfter(targetBuildTask) - } - } - } - } -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle.properties b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle.properties deleted file mode 100644 index cd0519bb..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle.properties +++ /dev/null @@ -1,23 +0,0 @@ -# Project-wide Gradle settings. -# IDE (e.g. Android Studio) users: -# Gradle settings configured through the IDE *will override* -# any settings specified in this file. -# For more details on how to configure your build environment visit -# http://www.gradle.org/docs/current/userguide/build_environment.html -# Specifies the JVM arguments used for the daemon process. -# The setting is particularly useful for tweaking memory settings. -org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8 -# When configured, Gradle will run in incubating parallel mode. -# This option should only be used with decoupled projects. More details, visit -# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects -# org.gradle.parallel=true -# AndroidX package structure to make it clearer which packages are bundled with the -# Android operating system, and which are packaged with your app"s APK -# https://developer.android.com/topic/libraries/support-library/androidx-rn -android.useAndroidX=true -# Kotlin code style for this project: "official" or "obsolete": -kotlin.code.style=official -# Enables namespacing of each library's R class so that its R class includes only the -# resources declared in the library itself and none from the library's dependencies, -# thereby reducing the size of the R class for that library -android.nonTransitiveRClass=true \ No newline at end of file diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle/wrapper/gradle-wrapper.jar b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle/wrapper/gradle-wrapper.jar deleted file mode 100644 index e708b1c0..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle/wrapper/gradle-wrapper.jar and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle/wrapper/gradle-wrapper.properties b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle/wrapper/gradle-wrapper.properties deleted file mode 100644 index de8c362b..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradle/wrapper/gradle-wrapper.properties +++ /dev/null @@ -1,6 +0,0 @@ -#Tue May 10 19:22:52 CST 2022 -distributionBase=GRADLE_USER_HOME -distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip -distributionPath=wrapper/dists -zipStorePath=wrapper/dists -zipStoreBase=GRADLE_USER_HOME diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradlew b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradlew deleted file mode 100755 index 4f906e0c..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradlew +++ /dev/null @@ -1,185 +0,0 @@ -#!/usr/bin/env sh - -# -# Copyright 2015 the original author or authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -############################################################################## -## -## Gradle start up script for UN*X -## -############################################################################## - -# Attempt to set APP_HOME -# Resolve links: $0 may be a link -PRG="$0" -# Need this for relative symlinks. -while [ -h "$PRG" ] ; do - ls=`ls -ld "$PRG"` - link=`expr "$ls" : '.*-> \(.*\)$'` - if expr "$link" : '/.*' > /dev/null; then - PRG="$link" - else - PRG=`dirname "$PRG"`"/$link" - fi -done -SAVED="`pwd`" -cd "`dirname \"$PRG\"`/" >/dev/null -APP_HOME="`pwd -P`" -cd "$SAVED" >/dev/null - -APP_NAME="Gradle" -APP_BASE_NAME=`basename "$0"` - -# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' - -# Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD="maximum" - -warn () { - echo "$*" -} - -die () { - echo - echo "$*" - echo - exit 1 -} - -# OS specific support (must be 'true' or 'false'). -cygwin=false -msys=false -darwin=false -nonstop=false -case "`uname`" in - CYGWIN* ) - cygwin=true - ;; - Darwin* ) - darwin=true - ;; - MINGW* ) - msys=true - ;; - NONSTOP* ) - nonstop=true - ;; -esac - -CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar - - -# Determine the Java command to use to start the JVM. -if [ -n "$JAVA_HOME" ] ; then - if [ -x "$JAVA_HOME/jre/sh/java" ] ; then - # IBM's JDK on AIX uses strange locations for the executables - JAVACMD="$JAVA_HOME/jre/sh/java" - else - JAVACMD="$JAVA_HOME/bin/java" - fi - if [ ! -x "$JAVACMD" ] ; then - die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." - fi -else - JAVACMD="java" - which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." -fi - -# Increase the maximum file descriptors if we can. -if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then - MAX_FD_LIMIT=`ulimit -H -n` - if [ $? -eq 0 ] ; then - if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then - MAX_FD="$MAX_FD_LIMIT" - fi - ulimit -n $MAX_FD - if [ $? -ne 0 ] ; then - warn "Could not set maximum file descriptor limit: $MAX_FD" - fi - else - warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" - fi -fi - -# For Darwin, add options to specify how the application appears in the dock -if $darwin; then - GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" -fi - -# For Cygwin or MSYS, switch paths to Windows format before running java -if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then - APP_HOME=`cygpath --path --mixed "$APP_HOME"` - CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` - - JAVACMD=`cygpath --unix "$JAVACMD"` - - # We build the pattern for arguments to be converted via cygpath - ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` - SEP="" - for dir in $ROOTDIRSRAW ; do - ROOTDIRS="$ROOTDIRS$SEP$dir" - SEP="|" - done - OURCYGPATTERN="(^($ROOTDIRS))" - # Add a user-defined pattern to the cygpath arguments - if [ "$GRADLE_CYGPATTERN" != "" ] ; then - OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" - fi - # Now convert the arguments - kludge to limit ourselves to /bin/sh - i=0 - for arg in "$@" ; do - CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` - CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option - - if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition - eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` - else - eval `echo args$i`="\"$arg\"" - fi - i=`expr $i + 1` - done - case $i in - 0) set -- ;; - 1) set -- "$args0" ;; - 2) set -- "$args0" "$args1" ;; - 3) set -- "$args0" "$args1" "$args2" ;; - 4) set -- "$args0" "$args1" "$args2" "$args3" ;; - 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; - 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; - 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; - 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; - 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; - esac -fi - -# Escape application args -save () { - for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done - echo " " -} -APP_ARGS=`save "$@"` - -# Collect all arguments for the java command, following the shell quoting and substitution rules -eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" - -exec "$JAVACMD" "$@" diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradlew.bat b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradlew.bat deleted file mode 100644 index ac1b06f9..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/gradlew.bat +++ /dev/null @@ -1,89 +0,0 @@ -@rem -@rem Copyright 2015 the original author or authors. -@rem -@rem Licensed under the Apache License, Version 2.0 (the "License"); -@rem you may not use this file except in compliance with the License. -@rem You may obtain a copy of the License at -@rem -@rem https://www.apache.org/licenses/LICENSE-2.0 -@rem -@rem Unless required by applicable law or agreed to in writing, software -@rem distributed under the License is distributed on an "AS IS" BASIS, -@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -@rem See the License for the specific language governing permissions and -@rem limitations under the License. -@rem - -@if "%DEBUG%" == "" @echo off -@rem ########################################################################## -@rem -@rem Gradle startup script for Windows -@rem -@rem ########################################################################## - -@rem Set local scope for the variables with windows NT shell -if "%OS%"=="Windows_NT" setlocal - -set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. -set APP_BASE_NAME=%~n0 -set APP_HOME=%DIRNAME% - -@rem Resolve any "." and ".." in APP_HOME to make it shorter. -for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi - -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" - -@rem Find java.exe -if defined JAVA_HOME goto findJavaFromJavaHome - -set JAVA_EXE=java.exe -%JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto execute - -echo. -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:findJavaFromJavaHome -set JAVA_HOME=%JAVA_HOME:"=% -set JAVA_EXE=%JAVA_HOME%/bin/java.exe - -if exist "%JAVA_EXE%" goto execute - -echo. -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:execute -@rem Setup the command line - -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar - - -@rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* - -:end -@rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd - -:fail -rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of -rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 - -:mainEnd -if "%OS%"=="Windows_NT" endlocal - -:omega diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/settings.gradle b/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/settings.gradle deleted file mode 100644 index b179eac8..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/android/app/settings.gradle +++ /dev/null @@ -1,6 +0,0 @@ -include ':app' - -include ':tauri-android' -project(':tauri-android').projectDir = new File('./.tauri/tauri-api') - -apply from: 'tauri.settings.gradle' diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/.gitignore b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/.gitignore deleted file mode 100644 index 6726e2f8..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -xcuserdata/ -build/ -Externals/ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@1x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@1x.png deleted file mode 100644 index f8b128e3..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@1x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@2x-1.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@2x-1.png deleted file mode 100644 index 6bbd9e3c..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@2x-1.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@2x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@2x.png deleted file mode 100644 index 6bbd9e3c..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@2x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@3x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@3x.png deleted file mode 100644 index f702cc04..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-20x20@3x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@1x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@1x.png deleted file mode 100644 index c5e92f78..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@1x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@2x-1.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@2x-1.png deleted file mode 100644 index 1c607d5c..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@2x-1.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@2x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@2x.png deleted file mode 100644 index 1c607d5c..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@2x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@3x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@3x.png deleted file mode 100644 index 60e93a6a..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-29x29@3x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@1x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@1x.png deleted file mode 100644 index 6bbd9e3c..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@1x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@2x-1.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@2x-1.png deleted file mode 100644 index 819410f9..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@2x-1.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@2x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@2x.png deleted file mode 100644 index 819410f9..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@2x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@3x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@3x.png deleted file mode 100644 index e00ae5a6..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-40x40@3x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-512@2x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-512@2x.png deleted file mode 100644 index f5301f37..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-512@2x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-512x512@2x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-512x512@2x.png deleted file mode 100644 index 5e9add73..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-512x512@2x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-60x60@2x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-60x60@2x.png deleted file mode 100644 index e00ae5a6..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-60x60@2x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-60x60@3x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-60x60@3x.png deleted file mode 100644 index 3546ca10..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-60x60@3x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-76x76@1x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-76x76@1x.png deleted file mode 100644 index d8367101..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-76x76@1x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-76x76@2x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-76x76@2x.png deleted file mode 100644 index 29925f2a..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-76x76@2x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-83.5x83.5@2x.png b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-83.5x83.5@2x.png deleted file mode 100644 index dfd22619..00000000 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/AppIcon-83.5x83.5@2x.png and /dev/null differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/Contents.json b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/Contents.json deleted file mode 100644 index dd3b8bcc..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/AppIcon.appiconset/Contents.json +++ /dev/null @@ -1,116 +0,0 @@ -{ - "images": [ - { - "size": "20x20", - "idiom": "iphone", - "filename": "AppIcon-20x20@2x.png", - "scale": "2x" - }, - { - "size": "20x20", - "idiom": "iphone", - "filename": "AppIcon-20x20@3x.png", - "scale": "3x" - }, - { - "size": "29x29", - "idiom": "iphone", - "filename": "AppIcon-29x29@2x-1.png", - "scale": "2x" - }, - { - "size": "29x29", - "idiom": "iphone", - "filename": "AppIcon-29x29@3x.png", - "scale": "3x" - }, - { - "size": "40x40", - "idiom": "iphone", - "filename": "AppIcon-40x40@2x.png", - "scale": "2x" - }, - { - "size": "40x40", - "idiom": "iphone", - "filename": "AppIcon-40x40@3x.png", - "scale": "3x" - }, - { - "size": "60x60", - "idiom": "iphone", - "filename": "AppIcon-60x60@2x.png", - "scale": "2x" - }, - { - "size": "60x60", - "idiom": "iphone", - "filename": "AppIcon-60x60@3x.png", - "scale": "3x" - }, - { - "size": "20x20", - "idiom": "ipad", - "filename": "AppIcon-20x20@1x.png", - "scale": "1x" - }, - { - "size": "20x20", - "idiom": "ipad", - "filename": "AppIcon-20x20@2x-1.png", - "scale": "2x" - }, - { - "size": "29x29", - "idiom": "ipad", - "filename": "AppIcon-29x29@1x.png", - "scale": "1x" - }, - { - "size": "29x29", - "idiom": "ipad", - "filename": "AppIcon-29x29@2x.png", - "scale": "2x" - }, - { - "size": "40x40", - "idiom": "ipad", - "filename": "AppIcon-40x40@1x.png", - "scale": "1x" - }, - { - "size": "40x40", - "idiom": "ipad", - "filename": "AppIcon-40x40@2x-1.png", - "scale": "2x" - }, - { - "size": "76x76", - "idiom": "ipad", - "filename": "AppIcon-76x76@1x.png", - "scale": "1x" - }, - { - "size": "76x76", - "idiom": "ipad", - "filename": "AppIcon-76x76@2x.png", - "scale": "2x" - }, - { - "size": "83.5x83.5", - "idiom": "ipad", - "filename": "AppIcon-83.5x83.5@2x.png", - "scale": "2x" - }, - { - "size": "1024x1024", - "idiom": "ios-marketing", - "filename": "AppIcon-512@2x.png", - "scale": "1x" - } - ], - "info": { - "version": 1, - "author": "xcode" - } -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/Contents.json b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/Contents.json deleted file mode 100644 index 97a8662e..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Assets.xcassets/Contents.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "info": { - "version": 1, - "author": "xcode" - } -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/ExportOptions.plist b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/ExportOptions.plist deleted file mode 100644 index b69cf1de..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/ExportOptions.plist +++ /dev/null @@ -1,8 +0,0 @@ - - - - - method - development - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Podfile b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Podfile deleted file mode 100644 index c34954cd..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Podfile +++ /dev/null @@ -1,21 +0,0 @@ -# Uncomment the next line to define a global platform for your project - -target 'app_iOS' do -platform :ios, '13.0' - # Pods for app_iOS -end - -target 'app_macOS' do -platform :osx, '11.0' - # Pods for app_macOS -end - -# Delete the deployment target for iOS and macOS, causing it to be inherited from the Podfile -post_install do |installer| - installer.pods_project.targets.each do |target| - target.build_configurations.each do |config| - config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET' - config.build_settings.delete 'MACOSX_DEPLOYMENT_TARGET' - end - end -end diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Sources/app/bindings/bindings.h b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Sources/app/bindings/bindings.h deleted file mode 100644 index 51522007..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Sources/app/bindings/bindings.h +++ /dev/null @@ -1,8 +0,0 @@ -#pragma once - -namespace ffi { - extern "C" { - void start_app(); - } -} - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Sources/app/main.mm b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Sources/app/main.mm deleted file mode 100644 index 7793a9d5..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/Sources/app/main.mm +++ /dev/null @@ -1,6 +0,0 @@ -#include "bindings/bindings.h" - -int main(int argc, char * argv[]) { - ffi::start_app(); - return 0; -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.pbxproj b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.pbxproj deleted file mode 100644 index 02e855a0..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.pbxproj +++ /dev/null @@ -1,442 +0,0 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 51; - objects = { - -/* Begin PBXBuildFile section */ - 299814393FFBF154FAD94CA8 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F3673D372C5ABDD1AD6E7067 /* QuartzCore.framework */; }; - 31585529C029A01BE249A285 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1E81BD6B453D87B7F7B1597B /* CoreGraphics.framework */; }; - 324A1E9A4258E7911D4DAC39 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9FACFFCB6E3743955F72464C /* Security.framework */; }; - 53CDD0ACFBE8BDF1550B2E53 /* main.mm in Sources */ = {isa = PBXBuildFile; fileRef = 682535EEFE1DA20BE07B123C /* main.mm */; }; - 5C516481BCA83A182C2BCC94 /* assets in Resources */ = {isa = PBXBuildFile; fileRef = 3842AE2A64FB9933D0400EA4 /* assets */; }; - 618672DC8A5E0605441C9935 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 0E2B15F176E4B041AE33EEEA /* UIKit.framework */; }; - 836D84C5F07860664DAF79C8 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D8F57162F5CC7AEDD55F173D /* WebKit.framework */; }; - 9D59FB167BB4E699DA17D1E9 /* MetalKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 04B56F58E2E44DDE1D67E7B7 /* MetalKit.framework */; }; - C6BD59C055C986EA4A77FDA2 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AF1DE57E7D9CF13BB2E0E038 /* Assets.xcassets */; }; - C869023DDFE275D42F3FBF29 /* libapp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 39EEC6A55698228E08917A52 /* libapp.a */; }; - E68F6CFDAED6503ABB4044A5 /* Metal.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CE1209BFDECB28E00189B168 /* Metal.framework */; }; -/* End PBXBuildFile section */ - -/* Begin PBXFileReference section */ - 04B56F58E2E44DDE1D67E7B7 /* MetalKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MetalKit.framework; path = System/Library/Frameworks/MetalKit.framework; sourceTree = SDKROOT; }; - 0E2B15F176E4B041AE33EEEA /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; - 17B52554D60D361AFE791C3E /* lib.rs */ = {isa = PBXFileReference; path = lib.rs; sourceTree = ""; }; - 1E81BD6B453D87B7F7B1597B /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; - 306B9C1792E7B1C53FA262A6 /* bindings.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = bindings.h; sourceTree = ""; }; - 3842AE2A64FB9933D0400EA4 /* assets */ = {isa = PBXFileReference; lastKnownFileType = folder; path = assets; sourceTree = SOURCE_ROOT; }; - 39EEC6A55698228E08917A52 /* libapp.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; path = libapp.a; sourceTree = ""; }; - 682535EEFE1DA20BE07B123C /* main.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; path = main.mm; sourceTree = ""; }; - 9FACFFCB6E3743955F72464C /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; }; - AF1DE57E7D9CF13BB2E0E038 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; - CE1209BFDECB28E00189B168 /* Metal.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Metal.framework; path = System/Library/Frameworks/Metal.framework; sourceTree = SDKROOT; }; - D8F57162F5CC7AEDD55F173D /* WebKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WebKit.framework; path = System/Library/Frameworks/WebKit.framework; sourceTree = SDKROOT; }; - F3673D372C5ABDD1AD6E7067 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; - FBC720DFA1D01F55B0A32344 /* app_iOS.app */ = {isa = PBXFileReference; includeInIndex = 0; lastKnownFileType = wrapper.application; path = app_iOS.app; sourceTree = BUILT_PRODUCTS_DIR; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - 4825CF6C55516D374210C8E1 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - C869023DDFE275D42F3FBF29 /* libapp.a in Frameworks */, - 31585529C029A01BE249A285 /* CoreGraphics.framework in Frameworks */, - E68F6CFDAED6503ABB4044A5 /* Metal.framework in Frameworks */, - 9D59FB167BB4E699DA17D1E9 /* MetalKit.framework in Frameworks */, - 299814393FFBF154FAD94CA8 /* QuartzCore.framework in Frameworks */, - 324A1E9A4258E7911D4DAC39 /* Security.framework in Frameworks */, - 618672DC8A5E0605441C9935 /* UIKit.framework in Frameworks */, - 836D84C5F07860664DAF79C8 /* WebKit.framework in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - 1BBF8C620E54F8C028CA130C /* Frameworks */ = { - isa = PBXGroup; - children = ( - 1E81BD6B453D87B7F7B1597B /* CoreGraphics.framework */, - 39EEC6A55698228E08917A52 /* libapp.a */, - CE1209BFDECB28E00189B168 /* Metal.framework */, - 04B56F58E2E44DDE1D67E7B7 /* MetalKit.framework */, - F3673D372C5ABDD1AD6E7067 /* QuartzCore.framework */, - 9FACFFCB6E3743955F72464C /* Security.framework */, - 0E2B15F176E4B041AE33EEEA /* UIKit.framework */, - D8F57162F5CC7AEDD55F173D /* WebKit.framework */, - ); - name = Frameworks; - sourceTree = ""; - }; - 329C38BE5E8B40354375D0D0 /* bindings */ = { - isa = PBXGroup; - children = ( - 306B9C1792E7B1C53FA262A6 /* bindings.h */, - ); - path = bindings; - sourceTree = ""; - }; - 78CBE3E5873199C0066F12DF /* Sources */ = { - isa = PBXGroup; - children = ( - FB1C68C0357A1866B3D27465 /* app */, - ); - path = Sources; - sourceTree = ""; - }; - 855775165ACE55D883F89EB3 /* src */ = { - isa = PBXGroup; - children = ( - 17B52554D60D361AFE791C3E /* lib.rs */, - ); - name = src; - path = ../../src; - sourceTree = ""; - }; - 87648061424F20D5D4871E9E = { - isa = PBXGroup; - children = ( - 3842AE2A64FB9933D0400EA4 /* assets */, - AF1DE57E7D9CF13BB2E0E038 /* Assets.xcassets */, - BAFB695BB8415511FEC74542 /* Externals */, - 78CBE3E5873199C0066F12DF /* Sources */, - 855775165ACE55D883F89EB3 /* src */, - 1BBF8C620E54F8C028CA130C /* Frameworks */, - EE72B6AC647386A11F795E44 /* Products */, - ); - sourceTree = ""; - }; - BAFB695BB8415511FEC74542 /* Externals */ = { - isa = PBXGroup; - children = ( - ); - path = Externals; - sourceTree = ""; - }; - EE72B6AC647386A11F795E44 /* Products */ = { - isa = PBXGroup; - children = ( - FBC720DFA1D01F55B0A32344 /* app_iOS.app */, - ); - name = Products; - sourceTree = ""; - }; - FB1C68C0357A1866B3D27465 /* app */ = { - isa = PBXGroup; - children = ( - 682535EEFE1DA20BE07B123C /* main.mm */, - 329C38BE5E8B40354375D0D0 /* bindings */, - ); - path = app; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXNativeTarget section */ - E86255CB8A1836C0BF0C0E14 /* app_iOS */ = { - isa = PBXNativeTarget; - buildConfigurationList = CDCB6DFA1AEBFEE3F608BA27 /* Build configuration list for PBXNativeTarget "app_iOS" */; - buildPhases = ( - E028F843270D8815FCE2B491 /* Build Rust Code */, - 81BE6BC5B603407AF570E994 /* Sources */, - 2FBCB8C3ED193E9C4A9FDB59 /* Resources */, - 4825CF6C55516D374210C8E1 /* Frameworks */, - ); - buildRules = ( - ); - dependencies = ( - ); - name = app_iOS; - productName = app_iOS; - productReference = FBC720DFA1D01F55B0A32344 /* app_iOS.app */; - productType = "com.apple.product-type.application"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - A9B1B09F1872768368ACECE2 /* Project object */ = { - isa = PBXProject; - attributes = { - LastUpgradeCheck = 1200; - TargetAttributes = { - E86255CB8A1836C0BF0C0E14 = { - DevelopmentTeam = Q93MBH6S2F; - }; - }; - }; - buildConfigurationList = B302E784349268C93E6F0A36 /* Build configuration list for PBXProject "app" */; - compatibilityVersion = "Xcode 11.0"; - developmentRegion = en; - hasScannedForEncodings = 0; - knownRegions = ( - Base, - en, - ); - mainGroup = 87648061424F20D5D4871E9E; - projectDirPath = ""; - projectRoot = ""; - targets = ( - E86255CB8A1836C0BF0C0E14 /* app_iOS */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXResourcesBuildPhase section */ - 2FBCB8C3ED193E9C4A9FDB59 /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - C6BD59C055C986EA4A77FDA2 /* Assets.xcassets in Resources */, - 5C516481BCA83A182C2BCC94 /* assets in Resources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXResourcesBuildPhase section */ - -/* Begin PBXShellScriptBuildPhase section */ - E028F843270D8815FCE2B491 /* Build Rust Code */ = { - isa = PBXShellScriptBuildPhase; - alwaysOutOfDate = 1; - buildActionMask = 2147483647; - files = ( - ); - inputFileListPaths = ( - ); - inputPaths = ( - ); - name = "Build Rust Code"; - outputFileListPaths = ( - ); - outputPaths = ( - "$(SRCROOT)/target/aarch64-apple-ios/${CONFIGURATION}/deps/libapp.a", - "$(SRCROOT)/target/x86_64-apple-ios/${CONFIGURATION}/deps/libapp.a", - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "yarn tauri ios xcode-script -v --platform ${PLATFORM_DISPLAY_NAME:?} --sdk-root ${SDKROOT:?} --framework-search-paths \"${FRAMEWORK_SEARCH_PATHS:?}\" --header-search-paths \"${HEADER_SEARCH_PATHS:?}\" --gcc-preprocessor-definitions \"${GCC_PREPROCESSOR_DEFINITIONS:-}\" --configuration ${CONFIGURATION:?} ${FORCE_COLOR} ${ARCHS:?}"; - }; -/* End PBXShellScriptBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - 81BE6BC5B603407AF570E994 /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 53CDD0ACFBE8BDF1550B2E53 /* main.mm in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin XCBuildConfiguration section */ - 1B9D5B8D34E6E0C88D0207F2 /* release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; - ARCHS = ( - arm64, - "arm64-sim", - ); - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CODE_SIGN_IDENTITY = "iPhone Developer"; - DEVELOPMENT_TEAM = Q93MBH6S2F; - ENABLE_BITCODE = NO; - FRAMEWORK_SEARCH_PATHS = ( - "$(inherited)", - "\".\"", - ); - INFOPLIST_FILE = app_iOS/Info.plist; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - ); - "LIBRARY_SEARCH_PATHS[arch=arm64-sim]" = "$(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)"; - "LIBRARY_SEARCH_PATHS[arch=arm64]" = "$(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)"; - "LIBRARY_SEARCH_PATHS[arch=x86_64]" = "$(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)"; - PRODUCT_BUNDLE_IDENTIFIER = app.tauri.app; - PRODUCT_NAME = app; - SDKROOT = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; - VALID_ARCHS = "arm64 arm64-sim"; - }; - name = release; - }; - 3C6497CF9EADFA373F12EF5C /* release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 13.0; - MTL_ENABLE_DEBUG_INFO = NO; - MTL_FAST_MATH = YES; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = iphoneos; - SWIFT_COMPILATION_MODE = wholemodule; - SWIFT_OPTIMIZATION_LEVEL = "-O"; - SWIFT_VERSION = 5.0; - }; - name = release; - }; - 4AC19FD47C6011940ACEB467 /* debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; - ARCHS = ( - arm64, - "arm64-sim", - ); - ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CODE_SIGN_IDENTITY = "iPhone Developer"; - DEVELOPMENT_TEAM = Q93MBH6S2F; - ENABLE_BITCODE = NO; - FRAMEWORK_SEARCH_PATHS = ( - "$(inherited)", - "\".\"", - ); - INFOPLIST_FILE = app_iOS/Info.plist; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - ); - "LIBRARY_SEARCH_PATHS[arch=arm64-sim]" = "$(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)"; - "LIBRARY_SEARCH_PATHS[arch=arm64]" = "$(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)"; - "LIBRARY_SEARCH_PATHS[arch=x86_64]" = "$(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)"; - PRODUCT_BUNDLE_IDENTIFIER = app.tauri.app; - PRODUCT_NAME = app; - SDKROOT = iphoneos; - TARGETED_DEVICE_FAMILY = "1,2"; - VALID_ARCHS = "arm64 arm64-sim"; - }; - name = debug; - }; - CAA806262C53A2E15E5DB0CA /* debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_CXX_LIBRARY = "libc++"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - ENABLE_TESTABILITY = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_DYNAMIC_NO_PIC = NO; - GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "$(inherited)", - "DEBUG=1", - ); - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 13.0; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; - MTL_FAST_MATH = YES; - ONLY_ACTIVE_ARCH = YES; - PRODUCT_NAME = "$(TARGET_NAME)"; - SDKROOT = iphoneos; - SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; - SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - SWIFT_VERSION = 5.0; - }; - name = debug; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - B302E784349268C93E6F0A36 /* Build configuration list for PBXProject "app" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - CAA806262C53A2E15E5DB0CA /* debug */, - 3C6497CF9EADFA373F12EF5C /* release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = debug; - }; - CDCB6DFA1AEBFEE3F608BA27 /* Build configuration list for PBXNativeTarget "app_iOS" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 4AC19FD47C6011940ACEB467 /* debug */, - 1B9D5B8D34E6E0C88D0207F2 /* release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = debug; - }; -/* End XCConfigurationList section */ - }; - rootObject = A9B1B09F1872768368ACECE2 /* Project object */; -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.xcworkspace/contents.xcworkspacedata deleted file mode 100644 index 919434a6..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.xcworkspace/contents.xcworkspacedata +++ /dev/null @@ -1,7 +0,0 @@ - - - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings deleted file mode 100644 index ac90d5ac..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +++ /dev/null @@ -1,10 +0,0 @@ - - - - - BuildSystemType - Original - DisableBuildSystemDeprecationDiagnostic - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/xcshareddata/xcschemes/app_iOS.xcscheme b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/xcshareddata/xcschemes/app_iOS.xcscheme deleted file mode 100644 index bd870366..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app.xcodeproj/xcshareddata/xcschemes/app_iOS.xcscheme +++ /dev/null @@ -1,131 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app_iOS/Info.plist b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app_iOS/Info.plist deleted file mode 100644 index 9cbeec65..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/app_iOS/Info.plist +++ /dev/null @@ -1,44 +0,0 @@ - - - - - CFBundleDevelopmentRegion - $(DEVELOPMENT_LANGUAGE) - CFBundleExecutable - $(EXECUTABLE_NAME) - CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) - CFBundleInfoDictionaryVersion - 6.0 - CFBundleName - $(PRODUCT_NAME) - CFBundlePackageType - APPL - CFBundleShortVersionString - 0.0.0 - CFBundleVersion - 0.0.0 - LSRequiresIPhoneOS - - UILaunchStoryboardName - LaunchScreen - UIRequiredDeviceCapabilities - - arm64 - metal - - UISupportedInterfaceOrientations - - UIInterfaceOrientationPortrait - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - UISupportedInterfaceOrientations~ipad - - UIInterfaceOrientationPortrait - UIInterfaceOrientationPortraitUpsideDown - UIInterfaceOrientationLandscapeLeft - UIInterfaceOrientationLandscapeRight - - - diff --git a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/project.yml b/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/project.yml deleted file mode 100644 index 838c4894..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/gen/apple/project.yml +++ /dev/null @@ -1,85 +0,0 @@ -name: app -options: - bundleIdPrefix: app.tauri - deploymentTarget: - iOS: 13.0 -fileGroups: [../../src] -configs: - debug: debug - release: release -settingGroups: - app: - base: - PRODUCT_NAME: app - PRODUCT_BUNDLE_IDENTIFIER: app.tauri.app - DEVELOPMENT_TEAM: Q93MBH6S2F -targetTemplates: - app: - type: application - sources: - - path: Sources - scheme: - environmentVariables: - RUST_BACKTRACE: full - RUST_LOG: info - settings: - groups: [app] -targets: - app_iOS: - type: application - platform: iOS - sources: - - path: Sources - - path: Assets.xcassets - - path: Externals - - path: assets - buildPhase: resources - type: folder - info: - path: app_iOS/Info.plist - properties: - LSRequiresIPhoneOS: true - UILaunchStoryboardName: LaunchScreen - UIRequiredDeviceCapabilities: [arm64, metal] - UISupportedInterfaceOrientations: - - UIInterfaceOrientationPortrait - - UIInterfaceOrientationLandscapeLeft - - UIInterfaceOrientationLandscapeRight - UISupportedInterfaceOrientations~ipad: - - UIInterfaceOrientationPortrait - - UIInterfaceOrientationPortraitUpsideDown - - UIInterfaceOrientationLandscapeLeft - - UIInterfaceOrientationLandscapeRight - CFBundleShortVersionString: 0.0.0 - CFBundleVersion: 0.0.0 - scheme: - environmentVariables: - RUST_BACKTRACE: full - RUST_LOG: info - settings: - base: - ENABLE_BITCODE: false - ARCHS: [arm64, arm64-sim] - VALID_ARCHS: arm64 arm64-sim - LIBRARY_SEARCH_PATHS[arch=x86_64]: $(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME) - LIBRARY_SEARCH_PATHS[arch=arm64]: $(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME) - LIBRARY_SEARCH_PATHS[arch=arm64-sim]: $(inherited) $(PROJECT_DIR)/Externals/$(CONFIGURATION) $(SDKROOT)/usr/lib/swift $(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME) $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME) - ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES: true - groups: [app] - dependencies: - - framework: libapp.a - embed: false - - sdk: CoreGraphics.framework - - sdk: Metal.framework - - sdk: MetalKit.framework - - sdk: QuartzCore.framework - - sdk: Security.framework - - sdk: UIKit.framework - - sdk: WebKit.framework - preBuildScripts: - - script: yarn tauri ios xcode-script -v --platform ${PLATFORM_DISPLAY_NAME:?} --sdk-root ${SDKROOT:?} --framework-search-paths "${FRAMEWORK_SEARCH_PATHS:?}" --header-search-paths "${HEADER_SEARCH_PATHS:?}" --gcc-preprocessor-definitions "${GCC_PREPROCESSOR_DEFINITIONS:-}" --configuration ${CONFIGURATION:?} ${FORCE_COLOR} ${ARCHS:?} - name: Build Rust Code - basedOnDependencyAnalysis: false - outputFiles: - - $(SRCROOT)/target/aarch64-apple-ios/${CONFIGURATION}/deps/libapp.a - - $(SRCROOT)/target/x86_64-apple-ios/${CONFIGURATION}/deps/libapp.a diff --git a/plugins/dialog/examples/tauri-app/src-tauri/src/lib.rs b/plugins/dialog/examples/tauri-app/src-tauri/src/lib.rs deleted file mode 100644 index 58ccbba8..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/src/lib.rs +++ /dev/null @@ -1,16 +0,0 @@ -// Copyright 2019-2022 Tauri Programme within The Commons Conservancy -// SPDX-License-Identifier: Apache-2.0 -// SPDX-License-Identifier: MIT - -#[cfg_attr(mobile, tauri::mobile_entry_point)] -pub fn run() { - tauri::Builder::default() - .plugin( - tauri_plugin_log::Builder::default() - .level(log::LevelFilter::Info) - .build(), - ) - .plugin(tauri_plugin_dialog::init()) - .run(tauri::generate_context!()) - .expect("error while running tauri application"); -} diff --git a/plugins/dialog/examples/tauri-app/src-tauri/tauri.conf.json b/plugins/dialog/examples/tauri-app/src-tauri/tauri.conf.json deleted file mode 100644 index b6fb480a..00000000 --- a/plugins/dialog/examples/tauri-app/src-tauri/tauri.conf.json +++ /dev/null @@ -1,66 +0,0 @@ -{ - "build": { - "beforeDevCommand": "pnpm dev", - "beforeBuildCommand": "pnpm build", - "devPath": "http://localhost:5173", - "distDir": "../dist", - "withGlobalTauri": false - }, - "package": { - "productName": "app", - "version": "0.0.0" - }, - "tauri": { - "allowlist": { - "all": true - }, - "bundle": { - "active": true, - "category": "DeveloperTool", - "copyright": "", - "deb": { - "depends": [] - }, - "externalBin": [], - "icon": [ - "icons/32x32.png", - "icons/128x128.png", - "icons/128x128@2x.png", - "icons/icon.icns", - "icons/icon.ico" - ], - "identifier": "app.tauri.dialog-example", - "longDescription": "", - "macOS": { - "entitlements": null, - "exceptionDomain": "", - "frameworks": [], - "providerShortName": null, - "signingIdentity": null - }, - "resources": [], - "shortDescription": "", - "targets": "all", - "windows": { - "certificateThumbprint": null, - "digestAlgorithm": "sha256", - "timestampUrl": "" - } - }, - "security": { - "csp": null - }, - "updater": { - "active": false - }, - "windows": [ - { - "fullscreen": false, - "height": 600, - "resizable": true, - "title": "tauri-app", - "width": 800 - } - ] - } -} diff --git a/plugins/dialog/examples/tauri-app/src/App.svelte b/plugins/dialog/examples/tauri-app/src/App.svelte deleted file mode 100644 index 8faf9813..00000000 --- a/plugins/dialog/examples/tauri-app/src/App.svelte +++ /dev/null @@ -1,19 +0,0 @@ - - -
-
- -
-
- -
-
- - diff --git a/plugins/dialog/examples/tauri-app/src/lib/FileDialogs.svelte b/plugins/dialog/examples/tauri-app/src/lib/FileDialogs.svelte deleted file mode 100644 index 7473a646..00000000 --- a/plugins/dialog/examples/tauri-app/src/lib/FileDialogs.svelte +++ /dev/null @@ -1,27 +0,0 @@ - - -
-
{response}
- -
diff --git a/plugins/dialog/examples/tauri-app/src/lib/MessageDialogs.svelte b/plugins/dialog/examples/tauri-app/src/lib/MessageDialogs.svelte deleted file mode 100644 index 4189199d..00000000 --- a/plugins/dialog/examples/tauri-app/src/lib/MessageDialogs.svelte +++ /dev/null @@ -1,24 +0,0 @@ - - -
-
{response}
- -
diff --git a/plugins/dialog/examples/tauri-app/src/main.js b/plugins/dialog/examples/tauri-app/src/main.js deleted file mode 100644 index 6b4e1a96..00000000 --- a/plugins/dialog/examples/tauri-app/src/main.js +++ /dev/null @@ -1,8 +0,0 @@ -import "./style.css"; -import App from "./App.svelte"; - -const app = new App({ - target: document.getElementById("app"), -}); - -export default app; diff --git a/plugins/dialog/examples/tauri-app/src/style.css b/plugins/dialog/examples/tauri-app/src/style.css deleted file mode 100644 index c0f9e3bc..00000000 --- a/plugins/dialog/examples/tauri-app/src/style.css +++ /dev/null @@ -1,102 +0,0 @@ -:root { - font-family: Inter, Avenir, Helvetica, Arial, sans-serif; - font-size: 16px; - line-height: 24px; - font-weight: 400; - - color: #0f0f0f; - background-color: #f6f6f6; - - font-synthesis: none; - text-rendering: optimizeLegibility; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; - -webkit-text-size-adjust: 100%; -} - -.container { - margin: 0; - padding-top: 10vh; - display: flex; - flex-direction: column; - justify-content: center; - text-align: center; -} - -.logo { - height: 6em; - padding: 1.5em; - will-change: filter; - transition: 0.75s; -} - -.logo.tauri:hover { - filter: drop-shadow(0 0 2em #24c8db); -} - -.row { - display: flex; - justify-content: center; -} - -a { - font-weight: 500; - color: #646cff; - text-decoration: inherit; -} - -a:hover { - color: #535bf2; -} - -h1 { - text-align: center; -} - -input, -button { - border-radius: 8px; - border: 1px solid transparent; - padding: 0.6em 1.2em; - font-size: 1em; - font-weight: 500; - font-family: inherit; - color: #0f0f0f; - background-color: #ffffff; - transition: border-color 0.25s; - box-shadow: 0 2px 2px rgba(0, 0, 0, 0.2); -} - -button { - cursor: pointer; -} - -button:hover { - border-color: #396cd8; -} - -input, -button { - outline: none; -} - -#greet-input { - margin-right: 5px; -} - -@media (prefers-color-scheme: dark) { - :root { - color: #f6f6f6; - background-color: #2f2f2f; - } - - a:hover { - color: #24c8db; - } - - input, - button { - color: #ffffff; - background-color: #0f0f0f98; - } -} diff --git a/plugins/dialog/examples/tauri-app/src/vite-env.d.ts b/plugins/dialog/examples/tauri-app/src/vite-env.d.ts deleted file mode 100644 index 4078e747..00000000 --- a/plugins/dialog/examples/tauri-app/src/vite-env.d.ts +++ /dev/null @@ -1,2 +0,0 @@ -/// -/// diff --git a/plugins/dialog/examples/tauri-app/vite.config.ts b/plugins/dialog/examples/tauri-app/vite.config.ts deleted file mode 100644 index 8d30f660..00000000 --- a/plugins/dialog/examples/tauri-app/vite.config.ts +++ /dev/null @@ -1,44 +0,0 @@ -import { defineConfig } from "vite"; -import { svelte } from "@sveltejs/vite-plugin-svelte"; -import { internalIpV4 } from "internal-ip"; - -// https://vitejs.dev/config/ -export default defineConfig(async () => { - const host = - process.env.TAURI_PLATFORM === "android" || - process.env.TAURI_PLATFORM === "ios" - ? await internalIpV4() - : "localhost"; - return { - plugins: [svelte()], - - // Vite optons tailored for Tauri development and only applied in `tauri dev` or `tauri build` - // prevent vite from obscuring rust errors - clearScreen: false, - // tauri expects a fixed port, fail if that port is not available - server: { - host: "0.0.0.0", - port: 5173, - strictPort: true, - hmr: { - protocol: "ws", - host, - port: 5183, - }, - fs: { - allow: [".", "../../tooling/api/dist"], - }, - }, - // to make use of `TAURI_DEBUG` and other env variables - // https://tauri.studio/v1/api/config#buildconfig.beforedevcommand - envPrefix: ["VITE_", "TAURI_"], - build: { - // Tauri supports es2021 - target: ["es2021", "chrome100", "safari13"], - // don't minify for debug builds - minify: !process.env.TAURI_DEBUG ? "esbuild" : false, - // produce sourcemaps for debug builds - sourcemap: !!process.env.TAURI_DEBUG, - }, - }; -}); diff --git a/plugins/dialog/guest-js/index.ts b/plugins/dialog/guest-js/index.ts index 50c6e64c..de74217f 100644 --- a/plugins/dialog/guest-js/index.ts +++ b/plugins/dialog/guest-js/index.ts @@ -2,7 +2,11 @@ // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT -import { invoke } from "@tauri-apps/api/tauri"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} interface FileResponse { base64Data?: string; @@ -19,7 +23,7 @@ interface FileResponse { /** * Extension filters for the file dialog. * - * @since 1.0.0 + * @since 2.0.0 */ interface DialogFilter { /** Filter name. */ @@ -37,7 +41,7 @@ interface DialogFilter { /** * Options for the open dialog. * - * @since 1.0.0 + * @since 2.0.0 */ interface OpenDialogOptions { /** The title of the dialog window. */ @@ -60,7 +64,7 @@ interface OpenDialogOptions { /** * Options for the save dialog. * - * @since 1.0.0 + * @since 2.0.0 */ interface SaveDialogOptions { /** The title of the dialog window. */ @@ -76,7 +80,7 @@ interface SaveDialogOptions { } /** - * @since 1.0.0 + * @since 2.0.0 */ interface MessageDialogOptions { /** The title of the dialog. Defaults to the app name. */ @@ -113,11 +117,11 @@ async function open( /** * Open a file/directory selection dialog. * - * The selected paths are added to the filesystem and asset protocol allowlist scopes. + * The selected paths are added to the filesystem and asset protocol scopes. * When security is more important than the easy of use of this API, * prefer writing a dedicated command instead. * - * Note that the allowlist scope change is not persisted, so the values are cleared when the application is restarted. + * Note that the scope change is not persisted, so the values are cleared when the application is restarted. * You can save it to the filesystem using [tauri-plugin-persisted-scope](https://github.com/tauri-apps/tauri-plugin-persisted-scope). * @example * ```typescript @@ -160,7 +164,7 @@ async function open( * * @returns A promise resolving to the selected path(s) * - * @since 1.0.0 + * @since 2.0.0 */ async function open( options: OpenDialogOptions = {} @@ -169,17 +173,17 @@ async function open( Object.freeze(options); } - return invoke("plugin:dialog|open", { options }); + return window.__TAURI_INVOKE__("plugin:dialog|open", { options }); } /** * Open a file/directory save dialog. * - * The selected path is added to the filesystem and asset protocol allowlist scopes. + * The selected path is added to the filesystem and asset protocol scopes. * When security is more important than the easy of use of this API, * prefer writing a dedicated command instead. * - * Note that the allowlist scope change is not persisted, so the values are cleared when the application is restarted. + * Note that the scope change is not persisted, so the values are cleared when the application is restarted. * You can save it to the filesystem using [tauri-plugin-persisted-scope](https://github.com/tauri-apps/tauri-plugin-persisted-scope). * @example * ```typescript @@ -194,14 +198,14 @@ async function open( * * @returns A promise resolving to the selected path. * - * @since 1.0.0 + * @since 2.0.0 */ async function save(options: SaveDialogOptions = {}): Promise { if (typeof options === "object") { Object.freeze(options); } - return invoke("plugin:dialog|save", { options }); + return window.__TAURI_INVOKE__("plugin:dialog|save", { options }); } /** @@ -218,7 +222,7 @@ async function save(options: SaveDialogOptions = {}): Promise { * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 * */ async function message( @@ -226,7 +230,7 @@ async function message( options?: string | MessageDialogOptions ): Promise { const opts = typeof options === "string" ? { title: options } : options; - return invoke("plugin:dialog|message", { + return window.__TAURI_INVOKE__("plugin:dialog|message", { message: message.toString(), title: opts?.title?.toString(), type_: opts?.type, @@ -248,14 +252,14 @@ async function message( * * @returns A promise resolving to a boolean indicating whether `Yes` was clicked or not. * - * @since 1.0.0 + * @since 2.0.0 */ async function ask( message: string, options?: string | ConfirmDialogOptions ): Promise { const opts = typeof options === "string" ? { title: options } : options; - return invoke("plugin:dialog|ask", { + return window.__TAURI_INVOKE__("plugin:dialog|ask", { message: message.toString(), title: opts?.title?.toString(), type_: opts?.type, @@ -278,14 +282,14 @@ async function ask( * * @returns A promise resolving to a boolean indicating whether `Ok` was clicked or not. * - * @since 1.0.0 + * @since 2.0.0 */ async function confirm( message: string, options?: string | ConfirmDialogOptions ): Promise { const opts = typeof options === "string" ? { title: options } : options; - return invoke("plugin:dialog|confirm", { + return window.__TAURI_INVOKE__("plugin:dialog|confirm", { message: message.toString(), title: opts?.title?.toString(), type_: opts?.type, diff --git a/plugins/dialog/ios/Package.swift b/plugins/dialog/ios/Package.swift index 6bc96852..45a58a43 100644 --- a/plugins/dialog/ios/Package.swift +++ b/plugins/dialog/ios/Package.swift @@ -1,5 +1,7 @@ // swift-tools-version:5.3 -// The swift-tools-version declares the minimum version of Swift required to build this package. +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT import PackageDescription diff --git a/plugins/dialog/ios/Sources/DialogPlugin.swift b/plugins/dialog/ios/Sources/DialogPlugin.swift index dd0756b3..ef1dff71 100644 --- a/plugins/dialog/ios/Sources/DialogPlugin.swift +++ b/plugins/dialog/ios/Sources/DialogPlugin.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import UIKit import MobileCoreServices import PhotosUI @@ -202,6 +206,6 @@ class DialogPlugin: Plugin { } @_cdecl("init_plugin_dialog") -func initPlugin(name: SRString, webview: WKWebView?) { - Tauri.registerPlugin(webview: webview, name: name.toString(), plugin: DialogPlugin()) -} \ No newline at end of file +func initPlugin() -> Plugin { + return DialogPlugin() +} diff --git a/plugins/dialog/ios/Sources/FilePickerController.swift b/plugins/dialog/ios/Sources/FilePickerController.swift index fc636473..b2752f0b 100644 --- a/plugins/dialog/ios/Sources/FilePickerController.swift +++ b/plugins/dialog/ios/Sources/FilePickerController.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import UIKit import MobileCoreServices import PhotosUI diff --git a/plugins/dialog/ios/Tests/PluginTests/PluginTests.swift b/plugins/dialog/ios/Tests/PluginTests/PluginTests.swift index 4f8e9ace..99992ce4 100644 --- a/plugins/dialog/ios/Tests/PluginTests/PluginTests.swift +++ b/plugins/dialog/ios/Tests/PluginTests/PluginTests.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import XCTest @testable import ExamplePlugin diff --git a/plugins/dialog/package.json b/plugins/dialog/package.json index 6c5d4aed..5d83f64d 100644 --- a/plugins/dialog/package.json +++ b/plugins/dialog/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-dialog-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-dialog", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/dialog/src/api-iife.js b/plugins/dialog/src/api-iife.js new file mode 100644 index 00000000..b5a74860 --- /dev/null +++ b/plugins/dialog/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_DIALOG__=function(n){"use strict";return n.ask=async function(n,o){var t,i,l,e,u;const _="string"==typeof o?{title:o}:o;return window.__TAURI_INVOKE__("plugin:dialog|ask",{message:n.toString(),title:null===(t=null==_?void 0:_.title)||void 0===t?void 0:t.toString(),type_:null==_?void 0:_.type,okButtonLabel:null!==(l=null===(i=null==_?void 0:_.okLabel)||void 0===i?void 0:i.toString())&&void 0!==l?l:"Yes",cancelButtonLabel:null!==(u=null===(e=null==_?void 0:_.cancelLabel)||void 0===e?void 0:e.toString())&&void 0!==u?u:"No"})},n.confirm=async function(n,o){var t,i,l,e,u;const _="string"==typeof o?{title:o}:o;return window.__TAURI_INVOKE__("plugin:dialog|confirm",{message:n.toString(),title:null===(t=null==_?void 0:_.title)||void 0===t?void 0:t.toString(),type_:null==_?void 0:_.type,okButtonLabel:null!==(l=null===(i=null==_?void 0:_.okLabel)||void 0===i?void 0:i.toString())&&void 0!==l?l:"Ok",cancelButtonLabel:null!==(u=null===(e=null==_?void 0:_.cancelLabel)||void 0===e?void 0:e.toString())&&void 0!==u?u:"Cancel"})},n.message=async function(n,o){var t,i;const l="string"==typeof o?{title:o}:o;return window.__TAURI_INVOKE__("plugin:dialog|message",{message:n.toString(),title:null===(t=null==l?void 0:l.title)||void 0===t?void 0:t.toString(),type_:null==l?void 0:l.type,okButtonLabel:null===(i=null==l?void 0:l.okLabel)||void 0===i?void 0:i.toString()})},n.open=async function(n={}){return"object"==typeof n&&Object.freeze(n),window.__TAURI_INVOKE__("plugin:dialog|open",{options:n})},n.save=async function(n={}){return"object"==typeof n&&Object.freeze(n),window.__TAURI_INVOKE__("plugin:dialog|save",{options:n})},n}({});Object.defineProperty(window.__TAURI__,"dialog",{value:__TAURI_DIALOG__})} diff --git a/plugins/dialog/src/commands.rs b/plugins/dialog/src/commands.rs index bc68f39e..8232eedf 100644 --- a/plugins/dialog/src/commands.rs +++ b/plugins/dialog/src/commands.rs @@ -6,6 +6,7 @@ use std::path::PathBuf; use serde::{Deserialize, Serialize}; use tauri::{command, Manager, Runtime, State, Window}; +use tauri_plugin_fs::FsExt; use crate::{Dialog, FileDialogBuilder, FileResponse, MessageDialogKind, Result}; @@ -114,16 +115,18 @@ pub(crate) async fn open( let folders = dialog_builder.blocking_pick_folders(); if let Some(folders) = &folders { for folder in folders { - window - .fs_scope() - .allow_directory(folder, options.recursive)?; + if let Some(s) = window.try_fs_scope() { + s.allow_directory(folder, options.recursive)?; + } } } OpenResponse::Folders(folders) } else { let folder = dialog_builder.blocking_pick_folder(); if let Some(path) = &folder { - window.fs_scope().allow_directory(path, options.recursive)?; + if let Some(s) = window.try_fs_scope() { + s.allow_directory(path, options.recursive)?; + } } OpenResponse::Folder(folder) } @@ -134,14 +137,24 @@ pub(crate) async fn open( let files = dialog_builder.blocking_pick_files(); if let Some(files) = &files { for file in files { - window.fs_scope().allow_file(&file.path)?; + if let Some(s) = window.try_fs_scope() { + s.allow_file(&file.path)?; + } + window + .state::() + .allow_file(&file.path)?; } } OpenResponse::Files(files) } else { let file = dialog_builder.blocking_pick_file(); if let Some(file) = &file { - window.fs_scope().allow_file(&file.path)?; + if let Some(s) = window.try_fs_scope() { + s.allow_file(&file.path)?; + } + window + .state::() + .allow_file(&file.path)?; } OpenResponse::File(file) }; @@ -177,7 +190,10 @@ pub(crate) async fn save( let path = dialog_builder.blocking_save_file(); if let Some(p) = &path { - window.fs_scope().allow_file(p)?; + if let Some(s) = window.try_fs_scope() { + s.allow_file(p)?; + } + window.state::().allow_file(p)?; } Ok(path) @@ -255,8 +271,8 @@ pub(crate) async fn ask( title, message, type_, - ok_button_label, - cancel_button_label, + Some(ok_button_label.unwrap_or_else(|| "Yes".into())), + Some(cancel_button_label.unwrap_or_else(|| "No".into())), )) } @@ -276,7 +292,7 @@ pub(crate) async fn confirm( title, message, type_, - ok_button_label, - cancel_button_label, + Some(ok_button_label.unwrap_or_else(|| "Ok".into())), + Some(cancel_button_label.unwrap_or_else(|| "Cancel".into())), )) } diff --git a/plugins/dialog/src/desktop.rs b/plugins/dialog/src/desktop.rs index caba5892..25222f91 100644 --- a/plugins/dialog/src/desktop.rs +++ b/plugins/dialog/src/desktop.rs @@ -10,6 +10,7 @@ use std::path::PathBuf; +use raw_window_handle::{HasRawWindowHandle, RawWindowHandle}; use serde::de::DeserializeOwned; use tauri::{plugin::PluginApi, AppHandle, Runtime}; @@ -101,6 +102,14 @@ impl From for rfd::MessageLevel { } } +struct WindowHandle(RawWindowHandle); + +unsafe impl HasRawWindowHandle for WindowHandle { + fn raw_window_handle(&self) -> RawWindowHandle { + self.0 + } +} + impl From> for FileDialog { fn from(d: FileDialogBuilder) -> Self { let mut builder = FileDialog::new(); @@ -119,8 +128,8 @@ impl From> for FileDialog { builder = builder.add_filter(&filter.name, &v); } #[cfg(desktop)] - if let Some(_parent) = d.parent { - // TODO builder = builder.set_parent(&parent); + if let Some(parent) = d.parent { + builder = builder.set_parent(&WindowHandle(parent)); } builder @@ -144,8 +153,8 @@ impl From> for rfd::MessageDialog { dialog = dialog.set_buttons(buttons); } - if let Some(_parent) = d.parent { - // TODO dialog.set_parent(parent); + if let Some(parent) = d.parent { + dialog = dialog.set_parent(&WindowHandle(parent)); } dialog diff --git a/plugins/dialog/src/error.rs b/plugins/dialog/src/error.rs index 7aa9804b..069cd55c 100644 --- a/plugins/dialog/src/error.rs +++ b/plugins/dialog/src/error.rs @@ -21,6 +21,8 @@ pub enum Error { #[cfg(mobile)] #[error("File save dialog is not implemented on mobile")] FileSaveDialogNotImplemented, + #[error(transparent)] + Fs(#[from] tauri_plugin_fs::Error), } impl Serialize for Error { diff --git a/plugins/dialog/src/init.js b/plugins/dialog/src/init.js new file mode 100644 index 00000000..62d0b82c --- /dev/null +++ b/plugins/dialog/src/init.js @@ -0,0 +1,15 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +window.alert = function (message) { + window.__TAURI_INVOKE__("plugin:dialog|message", { + message: message.toString(), + }); +}; + +window.confirm = function (message) { + return window.__TAURI_INVOKE__("plugin:dialog|confirm", { + message: message.toString(), + }); +}; diff --git a/plugins/dialog/src/lib.rs b/plugins/dialog/src/lib.rs index 93969d71..8353b71c 100644 --- a/plugins/dialog/src/lib.rs +++ b/plugins/dialog/src/lib.rs @@ -69,7 +69,22 @@ impl Dialog { /// Initializes the plugin. pub fn init() -> TauriPlugin { - Builder::new("dialog") + #[allow(unused_mut)] + let mut builder = Builder::new("dialog"); + + // Dialogs are implemented natively on Android + #[cfg(not(target_os = "android"))] + { + let mut init_script = include_str!("init.js").to_string(); + init_script.push_str(include_str!("api-iife.js")); + builder = builder.js_init_script(init_script); + } + #[cfg(target_os = "android")] + { + builder = builder.js_init_script(include_str!("api-iife.js").to_string()); + } + + builder .invoke_handler(tauri::generate_handler![ commands::open, commands::save, @@ -324,12 +339,12 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// tauri::Builder::default() - /// .build(tauri::generate_context!("test/fixture/src-tauri/tauri.conf.json")) + /// .build(tauri::generate_context!("test/tauri.conf.json")) /// .expect("failed to build tauri app") - /// .run(|_app, _event| { - /// FileDialogBuilder::new().pick_file(|file_path| { + /// .run(|app, _event| { + /// app.dialog().file().pick_file(|file_path| { /// // do something with the optional file path here /// // the file path is `None` if the user closed the dialog /// }) @@ -348,12 +363,12 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// tauri::Builder::default() - /// .build(tauri::generate_context!("test/fixture/src-tauri/tauri.conf.json")) + /// .build(tauri::generate_context!("test/tauri.conf.json")) /// .expect("failed to build tauri app") - /// .run(|_app, _event| { - /// FileDialogBuilder::new().pick_files(|file_paths| { + /// .run(|app, _event| { + /// app.dialog().file().pick_files(|file_paths| { /// // do something with the optional file paths here /// // the file paths value is `None` if the user closed the dialog /// }) @@ -378,12 +393,12 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// tauri::Builder::default() - /// .build(tauri::generate_context!("test/fixture/src-tauri/tauri.conf.json")) + /// .build(tauri::generate_context!("test/tauri.conf.json")) /// .expect("failed to build tauri app") - /// .run(|_app, _event| { - /// FileDialogBuilder::new().pick_folder(|folder_path| { + /// .run(|app, _event| { + /// app.dialog().file().pick_folder(|folder_path| { /// // do something with the optional folder path here /// // the folder path is `None` if the user closed the dialog /// }) @@ -401,12 +416,12 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// tauri::Builder::default() - /// .build(tauri::generate_context!("test/fixture/src-tauri/tauri.conf.json")) + /// .build(tauri::generate_context!("test/tauri.conf.json")) /// .expect("failed to build tauri app") - /// .run(|_app, _event| { - /// FileDialogBuilder::new().pick_folders(|file_paths| { + /// .run(|app, _event| { + /// app.dialog().file().pick_folders(|file_paths| { /// // do something with the optional folder paths here /// // the folder paths value is `None` if the user closed the dialog /// }) @@ -425,12 +440,12 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// tauri::Builder::default() - /// .build(tauri::generate_context!("test/fixture/src-tauri/tauri.conf.json")) + /// .build(tauri::generate_context!("test/tauri.conf.json")) /// .expect("failed to build tauri app") - /// .run(|_app, _event| { - /// FileDialogBuilder::new().save_file(|file_path| { + /// .run(|app, _event| { + /// app.dialog().file().save_file(|file_path| { /// // do something with the optional file path here /// // the file path is `None` if the user closed the dialog /// }) @@ -451,10 +466,10 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::blocking::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// #[tauri::command] - /// async fn my_command() { - /// let file_path = FileDialogBuilder::new().pick_file(); + /// async fn my_command(app: tauri::AppHandle) { + /// let file_path = app.dialog().file().blocking_pick_file(); /// // do something with the optional file path here /// // the file path is `None` if the user closed the dialog /// } @@ -470,10 +485,10 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::blocking::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// #[tauri::command] - /// async fn my_command() { - /// let file_path = FileDialogBuilder::new().pick_files(); + /// async fn my_command(app: tauri::AppHandle) { + /// let file_path = app.dialog().file().blocking_pick_files(); /// // do something with the optional file paths here /// // the file paths value is `None` if the user closed the dialog /// } @@ -489,10 +504,10 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::blocking::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// #[tauri::command] - /// async fn my_command() { - /// let folder_path = FileDialogBuilder::new().pick_folder(); + /// async fn my_command(app: tauri::AppHandle) { + /// let folder_path = app.dialog().file().blocking_pick_folder(); /// // do something with the optional folder path here /// // the folder path is `None` if the user closed the dialog /// } @@ -509,10 +524,10 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::blocking::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// #[tauri::command] - /// async fn my_command() { - /// let folder_paths = FileDialogBuilder::new().pick_folders(); + /// async fn my_command(app: tauri::AppHandle) { + /// let folder_paths = app.dialog().file().blocking_pick_folders(); /// // do something with the optional folder paths here /// // the folder paths value is `None` if the user closed the dialog /// } @@ -529,10 +544,10 @@ impl FileDialogBuilder { /// # Examples /// /// ```rust,no_run - /// use tauri::api::dialog::blocking::FileDialogBuilder; + /// use tauri_plugin_dialog::DialogExt; /// #[tauri::command] - /// async fn my_command() { - /// let file_path = FileDialogBuilder::new().save_file(); + /// async fn my_command(app: tauri::AppHandle) { + /// let file_path = app.dialog().file().blocking_save_file(); /// // do something with the optional file path here /// // the file path is `None` if the user closed the dialog /// } diff --git a/plugins/dialog/test/tauri.conf.json b/plugins/dialog/test/tauri.conf.json new file mode 100644 index 00000000..8a9c0108 --- /dev/null +++ b/plugins/dialog/test/tauri.conf.json @@ -0,0 +1,22 @@ +{ + "$schema": "../../../node_modules/.pnpm/@tauri-apps+cli@2.0.0-alpha.8/node_modules/@tauri-apps/cli/schema.json", + "build": { + "distDir": ".", + "devPath": "http://localhost:4000" + }, + "tauri": { + "bundle": { + "identifier": "studio.tauri.example", + "active": true, + "icon": ["../../../examples/api/src-tauri/icons/icon.png"] + }, + "windows": [ + { + "title": "Tauri App" + } + ], + "security": { + "csp": "default-src blob: data: filesystem: ws: wss: http: https: tauri: 'unsafe-eval' 'unsafe-inline' 'self'" + } + } +} diff --git a/plugins/fs-watch/.gitignore b/plugins/fs-watch/.gitignore deleted file mode 100644 index b512c09d..00000000 --- a/plugins/fs-watch/.gitignore +++ /dev/null @@ -1 +0,0 @@ -node_modules \ No newline at end of file diff --git a/plugins/fs-watch/Cargo.toml b/plugins/fs-watch/Cargo.toml deleted file mode 100644 index 8431bae0..00000000 --- a/plugins/fs-watch/Cargo.toml +++ /dev/null @@ -1,19 +0,0 @@ -[package] -name = "tauri-plugin-fs-watch" -version = "0.0.0" -description = "Watch files and directories for changes." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html - -[dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true -notify = { version = "5" , features = ["serde"] } -notify-debouncer-mini = { version = "0.2.1" , features = ["serde"] } diff --git a/plugins/fs-watch/banner.png b/plugins/fs-watch/banner.png deleted file mode 100644 index 6e77fe16..00000000 Binary files a/plugins/fs-watch/banner.png and /dev/null differ diff --git a/plugins/fs-watch/guest-js/index.ts b/plugins/fs-watch/guest-js/index.ts deleted file mode 100644 index 05ed07e5..00000000 --- a/plugins/fs-watch/guest-js/index.ts +++ /dev/null @@ -1,119 +0,0 @@ -import { invoke } from "@tauri-apps/api/tauri"; -import { UnlistenFn } from "@tauri-apps/api/event"; -import { appWindow, WebviewWindow } from "@tauri-apps/api/window"; - -const w: WebviewWindow = appWindow; - -export interface WatchOptions { - recursive?: boolean; -} - -export interface DebouncedWatchOptions extends WatchOptions { - delayMs?: number; -} - -export type RawEvent = { - type: RawEventKind; - paths: string[]; - attrs: unknown; -}; - -type RawEventKind = - | "any " - | { - access?: unknown; - } - | { - create?: unknown; - } - | { - modify?: unknown; - } - | { - remove?: unknown; - } - | "other"; - -export type DebouncedEvent = - | { kind: "any"; path: string } - | { kind: "AnyContinous"; path: string }; - -async function unwatch(id: number): Promise { - await invoke("plugin:fs-watch|unwatch", { id }); -} - -export async function watch( - paths: string | string[], - cb: (event: DebouncedEvent) => void, - options: DebouncedWatchOptions = {} -): Promise { - const opts = { - recursive: false, - delayMs: 2000, - ...options, - }; - let watchPaths; - if (typeof paths === "string") { - watchPaths = [paths]; - } else { - watchPaths = paths; - } - - const id = window.crypto.getRandomValues(new Uint32Array(1))[0]; - - await invoke("plugin:fs-watch|watch", { - id, - paths: watchPaths, - options: opts, - }); - - const unlisten = await w.listen( - `watcher://debounced-event/${id}`, - (event) => { - cb(event.payload); - } - ); - - return () => { - void unwatch(id); - unlisten(); - }; -} - -export async function watchImmediate( - paths: string | string[], - cb: (event: RawEvent) => void, - options: WatchOptions = {} -): Promise { - const opts = { - recursive: false, - ...options, - delayMs: null, - }; - let watchPaths; - if (typeof paths === "string") { - watchPaths = [paths]; - } else { - watchPaths = paths; - } - - const id = window.crypto.getRandomValues(new Uint32Array(1))[0]; - - await invoke("plugin:fs-watch|watch", { - id, - paths: watchPaths, - options: opts, - }); - - const unlisten = await w.listen( - `watcher://raw-event/${id}`, - (event) => { - cb(event.payload); - } - ); - - return () => { - void unwatch(id); - unlisten(); - }; -} diff --git a/plugins/fs-watch/tsconfig.json b/plugins/fs-watch/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/fs-watch/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/fs/CHANGELOG.md b/plugins/fs/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/fs/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/fs/Cargo.lock b/plugins/fs/Cargo.lock deleted file mode 100644 index 64ff9543..00000000 --- a/plugins/fs/Cargo.lock +++ /dev/null @@ -1,3591 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "aho-corasick" -version = "0.7.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" -dependencies = [ - "memchr", -] - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "anyhow" -version = "1.0.70" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7de8ce5e0f9f8d88245311066a578d72b7af3e7088f32783804676302df237e4" - -[[package]] -name = "atk" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39991bc421ddf72f70159011b323ff49b0f783cc676a7287c59453da2e2531cf" -dependencies = [ - "atk-sys", - "bitflags", - "glib", - "libc", -] - -[[package]] -name = "atk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11ad703eb64dc058024f0e57ccfa069e15a413b98dbd50a1a950e743b7f11148" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "base64" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" - -[[package]] -name = "base64" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "block" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" - -[[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 = "brotli" -version = "3.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a0b1dbcc8ae29329621f8d4f0d835787c1c38bb1401979b49d13b0b305ff68" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b6561fd3f895a11e8f72af2cb7d22e08366bebc2b6b57f7744c4bda27034744" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bstr" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d4260bcc2e8fc9df1eac4919a720effeb63a3f0952f5bf4944adfa18897f09" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" - -[[package]] -name = "bytemuck" -version = "1.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17febce684fd15d89027105661fec94afb475cb995fbc59d2865198446ba2eea" - -[[package]] -name = "byteorder" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" - -[[package]] -name = "bytes" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" -dependencies = [ - "serde", -] - -[[package]] -name = "cairo-rs" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3125b15ec28b84c238f6f476c6034016a5f6cc0221cb514ca46c532139fc97d" -dependencies = [ - "bitflags", - "cairo-sys-rs", - "glib", - "libc", - "once_cell", - "thiserror", -] - -[[package]] -name = "cairo-sys-rs" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c48f4af05fabdcfa9658178e1326efa061853f040ce7d72e33af6885196f421" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "cargo_toml" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bfbc36312494041e2cdd5f06697b7e89d4b76f42773a0b5556ac290ff22acc2" -dependencies = [ - "serde", - "toml 0.5.11", -] - -[[package]] -name = "cc" -version = "1.0.79" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" - -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - -[[package]] -name = "cfb" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d38f2da7a0a2c4ccf0065be06397cc26a81f4e528be095826eee9d4adbb8c60f" -dependencies = [ - "byteorder", - "fnv", - "uuid", -] - -[[package]] -name = "cfg-expr" -version = "0.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a35b255461940a32985c627ce82900867c61db1659764d3675ea81963f72a4c6" -dependencies = [ - "smallvec", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "cocoa" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f425db7937052c684daec3bd6375c8abe2d146dca4b8b143d6db777c39138f3a" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation", - "core-graphics", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa-foundation" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "931d3837c286f56e3c58423ce4eba12d08db2374461a785c86f672b08b5650d6" -dependencies = [ - "bitflags", - "block", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "color_quant" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" - -[[package]] -name = "combine" -version = "4.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" - -[[package]] -name = "core-graphics" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" -dependencies = [ - "bitflags", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" -dependencies = [ - "bitflags", - "core-foundation", - "foreign-types", - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "280a9f2d8b3a38871a3c8a46fb80db65e5e5ed97da80c4d08bf27fb63e35e181" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c063cd8cc95f5c377ed0d4b49a4b21f632396ff690e8470c29b3359b346984b" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "cssparser" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "754b69d351cdc2d8ee09ae203db831e005560fc6030da058f86ad60c92a9cb0a" -dependencies = [ - "cssparser-macros", - "dtoa-short", - "itoa 0.4.8", - "matches", - "phf 0.8.0", - "proc-macro2", - "quote", - "smallvec", - "syn 1.0.109", -] - -[[package]] -name = "cssparser-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfae75de57f2b2e85e8768c3ea840fd159c8f33e2b6522c7835b7abac81be16e" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ctor" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d2301688392eb071b0bf1a37be05c469d3cc4dbbd95df672fe28ab021e6a096" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 1.0.109", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "derive_more" -version = "0.99.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version", - "syn 1.0.109", -] - -[[package]] -name = "digest" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dirs-next" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" -dependencies = [ - "cfg-if", - "dirs-sys-next", -] - -[[package]] -name = "dirs-sys-next" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dispatch" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" - -[[package]] -name = "dtoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" - -[[package]] -name = "dtoa-short" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde03329ae10e79ede66c9ce4dc930aa8599043b0743008548680f25b91502d6" -dependencies = [ - "dtoa", -] - -[[package]] -name = "dunce" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bd4b30a6560bbd9b4620f4de34c3f14f60848e58a9b7216801afcb4c7b31c3c" - -[[package]] -name = "embed_plist" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" - -[[package]] -name = "encoding_rs" -version = "0.8.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071a31f4ee85403370b58aca746f01041ede6f0da2730960ad001edc2b71b394" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "errno" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bcfec3a70f97c962c307b2d2c56e358cf1d00b558d74262b5f929ee8cc7e73a" -dependencies = [ - "errno-dragonfly", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] - -[[package]] -name = "fastrand" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" -dependencies = [ - "instant", -] - -[[package]] -name = "fdeflate" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d329bdeac514ee06249dabc27877490f17f5d371ec693360768b838e19f3ae10" -dependencies = [ - "simd-adler32", -] - -[[package]] -name = "field-offset" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3cf3a800ff6e860c863ca6d4b16fd999db8b752819c1606884047b73e468535" -dependencies = [ - "memoffset", - "rustc_version", -] - -[[package]] -name = "filetime" -version = "0.2.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cbc844cecaee9d4443931972e1289c8ff485cb4cc2767cb03ca139ed6885153" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.2.16", - "windows-sys 0.48.0", -] - -[[package]] -name = "flate2" -version = "1.0.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" -dependencies = [ - "crc32fast", - "miniz_oxide 0.6.2", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futf" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df420e2e84819663797d1ec6544b13c5be84629e7bb00dc960d6917db2987843" -dependencies = [ - "mac", - "new_debug_unreachable", -] - -[[package]] -name = "futures-channel" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" -dependencies = [ - "futures-core", -] - -[[package]] -name = "futures-core" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" - -[[package]] -name = "futures-executor" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" - -[[package]] -name = "futures-macro" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "futures-sink" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" - -[[package]] -name = "futures-task" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" - -[[package]] -name = "futures-util" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" -dependencies = [ - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "fxhash" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" -dependencies = [ - "byteorder", -] - -[[package]] -name = "gdk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa9cb33da481c6c040404a11f8212d193889e9b435db2c14fd86987f630d3ce1" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk-pixbuf", - "gdk-sys", - "gio", - "glib", - "libc", - "pango", -] - -[[package]] -name = "gdk-pixbuf" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3578c60dee9d029ad86593ed88cb40f35c1b83360e12498d055022385dd9a05" -dependencies = [ - "bitflags", - "gdk-pixbuf-sys", - "gio", - "glib", - "libc", -] - -[[package]] -name = "gdk-pixbuf-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3092cf797a5f1210479ea38070d9ae8a5b8e9f8f1be9f32f4643c529c7d70016" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gdk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d76354f97a913e55b984759a997b693aa7dc71068c9e98bcce51aa167a0a5c5a" -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.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4511710212ed3020b61a8622a37aa6f0dd2a84516575da92e9b96928dcbe83ba" -dependencies = [ - "gdk-sys", - "glib-sys", - "gobject-sys", - "libc", - "pkg-config", - "system-deps", -] - -[[package]] -name = "gdkx11-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fa2bf8b5b8c414bc5d05e48b271896d0fd3ddb57464a3108438082da61de6af" -dependencies = [ - "gdk-sys", - "glib-sys", - "libc", - "system-deps", - "x11", -] - -[[package]] -name = "generator" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33a20a288a94683f5f4da0adecdbe095c94a77c295e514cc6484e9394dd8376e" -dependencies = [ - "cc", - "libc", - "log", - "rustversion", - "windows", -] - -[[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.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c85e1d9ab2eadba7e5040d4e09cbd6d072b76a557ad64e797c2cb9d4da21d7e4" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gio" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a1c84b4534a290a29160ef5c6eff2a9c95833111472e824fc5cb78b513dd092" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-io", - "futures-util", - "gio-sys", - "glib", - "libc", - "once_cell", - "pin-project-lite", - "smallvec", - "thiserror", -] - -[[package]] -name = "gio-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9b693b8e39d042a95547fc258a7b07349b1f0b48f4b2fa3108ba3c51c0b5229" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", - "winapi", -] - -[[package]] -name = "glib" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddd4df61a866ed7259d6189b8bcb1464989a77f1d85d25d002279bbe9dd38b2f" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-executor", - "futures-task", - "futures-util", - "gio-sys", - "glib-macros", - "glib-sys", - "gobject-sys", - "libc", - "once_cell", - "smallvec", - "thiserror", -] - -[[package]] -name = "glib-macros" -version = "0.16.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb1a9325847aa46f1e96ffea37611b9d51fc4827e67f79e7de502a297560a67b" -dependencies = [ - "anyhow", - "heck", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "glib-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c61a4f46316d06bfa33a7ac22df6f0524c8be58e3db2d9ca99ccb1f357b62a65" -dependencies = [ - "libc", - "system-deps", -] - -[[package]] -name = "glob" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" - -[[package]] -name = "globset" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "029d74589adefde59de1a0c4f4732695c32805624aec7b68d91503d4dba79afc" -dependencies = [ - "aho-corasick", - "bstr", - "fnv", - "log", - "regex", -] - -[[package]] -name = "gobject-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3520bb9c07ae2a12c7f2fbb24d4efc11231c8146a86956413fb1a79bb760a0f1" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gtk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4d3507d43908c866c805f74c9dd593c0ce7ba5c38e576e41846639cdcd4bee6" -dependencies = [ - "atk", - "bitflags", - "cairo-rs", - "field-offset", - "futures-channel", - "gdk", - "gdk-pixbuf", - "gio", - "glib", - "gtk-sys", - "gtk3-macros", - "libc", - "once_cell", - "pango", - "pkg-config", -] - -[[package]] -name = "gtk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b5f8946685d5fe44497007786600c2f368ff6b1e61a16251c89f72a97520a3" -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.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "096eb63c6fedf03bafe65e5924595785eaf1bcb7200dac0f2cbe9c9738f05ad8" -dependencies = [ - "anyhow", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "h2" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66b91535aa35fea1523ad1b86cb6b53c28e0ae566ba4a460f4457e936cad7c6f" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" - -[[package]] -name = "hermit-abi" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286" - -[[package]] -name = "html5ever" -version = "0.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c13fb08e5d4dfc151ee5e88bae63f7773d61852f3bdc73c9f4b9e1bde03148" -dependencies = [ - "log", - "mac", - "markup5ever", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "http" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" -dependencies = [ - "bytes", - "fnv", - "itoa 1.0.6", -] - -[[package]] -name = "http-body" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" -dependencies = [ - "bytes", - "http", - "pin-project-lite", -] - -[[package]] -name = "http-range" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21dec9db110f5f872ed9699c3ecf50cf16f423502706ba5c72462e28d3157573" - -[[package]] -name = "httparse" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" - -[[package]] -name = "httpdate" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" - -[[package]] -name = "hyper" -version = "0.14.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab302d72a6f11a3b910431ff93aae7e773078c769f0a3ef15fb9ec692ed147d4" -dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "httpdate", - "itoa 1.0.6", - "pin-project-lite", - "socket2", - "tokio", - "tower-service", - "tracing", - "want", -] - -[[package]] -name = "ico" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3804960be0bb5e4edb1e1ad67afd321a9ecfd875c3e65c099468fd2717d7cae" -dependencies = [ - "byteorder", - "png", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe7873dab538a9a44ad79ede1faf5f30d49f9a5c883ddbab48bce81b64b7492" -dependencies = [ - "globset", - "lazy_static", - "log", - "memchr", - "regex", - "same-file", - "thread_local", - "walkdir", - "winapi-util", -] - -[[package]] -name = "image" -version = "0.24.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "527909aa81e20ac3a44803521443a765550f09b5130c2c2fa1ea59c2f8f50a3a" -dependencies = [ - "bytemuck", - "byteorder", - "color_quant", - "num-rational", - "num-traits", -] - -[[package]] -name = "indexmap" -version = "1.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown", -] - -[[package]] -name = "infer" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a898e4b7951673fce96614ce5751d13c40fc5674bc2d759288e46c3ab62598b3" -dependencies = [ - "cfb", -] - -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "io-lifetimes" -version = "1.0.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c66c74d2ae7e79a5a8f7ac924adbe38ee42a859c6539ad869eb51f0b52dc220" -dependencies = [ - "hermit-abi 0.3.1", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "ipnet" -version = "2.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12b6ee2129af8d4fb011108c73d99a1b83a85977f23b82460c0ae2e25bb4b57f" - -[[package]] -name = "itoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4" - -[[package]] -name = "itoa" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "453ad9f582a441959e5f0d088b02ce04cfe8d51a8eaf077f12ac6d3e94164ca6" - -[[package]] -name = "javascriptcore-rs" -version = "0.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "110b9902c80c12bf113c432d0b71c7a94490b294a8234f326fd0abca2fac0b00" -dependencies = [ - "bitflags", - "glib", - "javascriptcore-rs-sys", -] - -[[package]] -name = "javascriptcore-rs-sys" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98a216519a52cd941a733a0ad3f1023cfdb1cd47f3955e8e863ed56f558f916c" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "jni" -version = "0.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039022cdf4d7b1cf548d31f60ae783138e5fd42013f6271049d7df7afadef96c" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - -[[package]] -name = "jni-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" - -[[package]] -name = "js-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "json-patch" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e712e62827c382a77b87f590532febb1f8b2fdbc3eefa1ee37fe7281687075ef" -dependencies = [ - "serde", - "serde_json", - "thiserror", - "treediff", -] - -[[package]] -name = "kuchiki" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ea8e9c6e031377cff82ee3001dc8026cdf431ed4e2e6b51f98ab8c73484a358" -dependencies = [ - "cssparser", - "html5ever", - "matches", - "selectors", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.141" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3304a64d199bb964be99741b7a14d26972741915b3649639149b2479bb46f4b5" - -[[package]] -name = "line-wrap" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30344350a2a51da54c1d53be93fade8a237e545dbcc4bdbe635413f2117cab9" -dependencies = [ - "safemem", -] - -[[package]] -name = "linux-raw-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d59d8c75012853d2e872fb56bc8a2e53718e2cafe1a4c823143141c6d90c322f" - -[[package]] -name = "lock_api" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "loom" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff50ecb28bb86013e935fb6683ab1f6d3a20016f123c76fd4c27470076ac30f5" -dependencies = [ - "cfg-if", - "generator", - "scoped-tls", - "serde", - "serde_json", - "tracing", - "tracing-subscriber", -] - -[[package]] -name = "mac" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4" - -[[package]] -name = "malloc_buf" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb" -dependencies = [ - "libc", -] - -[[package]] -name = "markup5ever" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a24f40fb03852d1cdd84330cddcaf98e9ec08a7b7768e952fad3b4cf048ec8fd" -dependencies = [ - "log", - "phf 0.8.0", - "phf_codegen", - "string_cache", - "string_cache_codegen", - "tendril", -] - -[[package]] -name = "matchers" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" -dependencies = [ - "regex-automata", -] - -[[package]] -name = "matches" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "memoffset" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d61c719bcfbcf5d62b3a09efa6088de8c54bc0bfcd3ea7ae39fcc186108b8de1" -dependencies = [ - "autocfg", -] - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" -dependencies = [ - "adler", -] - -[[package]] -name = "miniz_oxide" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" -dependencies = [ - "adler", - "simd-adler32", -] - -[[package]] -name = "mio" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b9d9a46eff5b4ff64b45a9e316a6d1e0bc719ef429cbec4dc630684212bfdf9" -dependencies = [ - "libc", - "log", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.45.0", -] - -[[package]] -name = "ndk" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2032c77e030ddee34a6787a64166008da93f6a352b629261d0fee232b8742dd4" -dependencies = [ - "bitflags", - "jni-sys", - "ndk-sys", - "num_enum", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5a6ae77c8ee183dcbbba6150e2e6b9f3f4196a7666c02a715a95692ec1fa97" -dependencies = [ - "jni-sys", -] - -[[package]] -name = "new_debug_unreachable" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" - -[[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] -name = "nu-ansi-term" -version = "0.46.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" -dependencies = [ - "overload", - "winapi", -] - -[[package]] -name = "num-integer" -version = "0.1.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b" -dependencies = [ - "hermit-abi 0.2.6", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" -dependencies = [ - "num_enum_derive", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "objc" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1" -dependencies = [ - "malloc_buf", - "objc_exception", -] - -[[package]] -name = "objc_exception" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad970fb455818ad6cba4c122ad012fae53ae8b4795f86378bce65e4f6bab2ca4" -dependencies = [ - "cc", -] - -[[package]] -name = "objc_id" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b" -dependencies = [ - "objc", -] - -[[package]] -name = "once_cell" -version = "1.17.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7e5500299e16ebb147ae15a00a942af264cf3688f47923b8fc2cd5858f23ad3" - -[[package]] -name = "overload" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" - -[[package]] -name = "pango" -version = "0.16.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdff66b271861037b89d028656184059e03b0b6ccb36003820be19f7200b1e94" -dependencies = [ - "bitflags", - "gio", - "glib", - "libc", - "once_cell", - "pango-sys", -] - -[[package]] -name = "pango-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e134909a9a293e04d2cc31928aa95679c5e4df954d0b85483159bd20d8f047f" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9069cbb9f99e3a5083476ccb29ceb1de18b9118cafa53e90c9551235de2b9521" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.2.16", - "smallvec", - "windows-sys 0.45.0", -] - -[[package]] -name = "percent-encoding" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" - -[[package]] -name = "phf" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dfb61232e34fcb633f43d12c58f83c1df82962dcdfa565a4e866ffc17dafe12" -dependencies = [ - "phf_macros 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", -] - -[[package]] -name = "phf" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259" -dependencies = [ - "phf_macros 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", -] - -[[package]] -name = "phf_codegen" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbffee61585b0411840d3ece935cce9cb6321f01c45477d30066498cd5e1a815" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", -] - -[[package]] -name = "phf_generator" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17367f0cc86f2d25802b2c26ee58a7b23faeccf78a396094c13dced0d0182526" -dependencies = [ - "phf_shared 0.8.0", - "rand 0.7.3", -] - -[[package]] -name = "phf_generator" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d5285893bb5eb82e6aaf5d59ee909a06a16737a8970984dd7746ba9283498d6" -dependencies = [ - "phf_shared 0.10.0", - "rand 0.8.5", -] - -[[package]] -name = "phf_macros" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6fde18ff429ffc8fe78e2bf7f8b7a5a5a6e2a8b58bc5a9ac69198bbda9189c" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "phf_macros" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fdf3184dd560f160dd73922bea2d5cd6e8f064bf4b13110abd81b03697b4e0" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "phf_shared" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c00cf8b9eafe68dde5e9eaa2cef8ee84a9336a47d566ec55ca16589633b65af7" -dependencies = [ - "siphasher", -] - -[[package]] -name = "phf_shared" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" - -[[package]] -name = "plist" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bd9647b268a3d3e14ff09c23201133a62589c658db02bb7388c7246aafe0590" -dependencies = [ - "base64 0.21.0", - "indexmap", - "line-wrap", - "quick-xml", - "serde", - "time", -] - -[[package]] -name = "png" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aaeebc51f9e7d2c150d3f3bfeb667f2aa985db5ef1e3d212847bdedb488beeaa" -dependencies = [ - "bitflags", - "crc32fast", - "fdeflate", - "flate2", - "miniz_oxide 0.7.1", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[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", -] - -[[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-macro-hack" -version = "0.5.20+deprecated" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" - -[[package]] -name = "proc-macro2" -version = "1.0.56" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b63bdb0cd06f1f4dedf69b254734f9b45af66e4a031e42a7480257d9898b435" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quick-xml" -version = "0.28.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ce5e73202a820a31f8a0ee32ada5e21029c81fd9e3ebf668a40832e4219d9d1" -dependencies = [ - "memchr", -] - -[[package]] -name = "quote" -version = "1.0.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4424af4bf778aae2051a77b60283332f386554255d722233d09fbfc7e30da2fc" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", - "rand_pcg", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.9", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_pcg" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "raw-window-handle" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2ff9a1f06a88b01621b7ae906ef0211290d1c8a168a15542486a8f61c0833b9" - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_syscall" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.9", - "redox_syscall 0.2.16", - "thiserror", -] - -[[package]] -name = "regex" -version = "1.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b1f693b24f6ac912f4893ef08244d70b6067480d2f1a46e950c9691e6749d1d" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" - -[[package]] -name = "reqwest" -version = "0.11.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27b71749df584b7f4cac2c426c127a7c785a5106cc98f7a8feb044115f0fa254" -dependencies = [ - "base64 0.21.0", - "bytes", - "encoding_rs", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "hyper", - "ipnet", - "js-sys", - "log", - "mime", - "once_cell", - "percent-encoding", - "pin-project-lite", - "serde", - "serde_json", - "serde_urlencoded", - "tokio", - "tokio-util", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "wasm-streams", - "web-sys", - "winreg", -] - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.37.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85597d61f83914ddeba6a47b3b8ffe7365107221c2e557ed94426489fefb5f77" -dependencies = [ - "bitflags", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys", - "windows-sys 0.48.0", -] - -[[package]] -name = "rustversion" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f3208ce4d8448b3f3e7d168a73f5e0c43a61e32930de3bceeccedb388b6bf06" - -[[package]] -name = "ryu" -version = "1.0.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91339c0467de62360649f8d3e185ca8de4224ff281f66000de5eb2a77a79041" - -[[package]] -name = "safemem" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef703b7cb59335eae2eb93ceb664c0eb7ea6bf567079d843e09420219668e072" - -[[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 = "scoped-tls" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" - -[[package]] -name = "scopeguard" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "selectors" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df320f1889ac4ba6bc0cdc9c9af7af4bd64bb927bccdf32d81140dc1f9be12fe" -dependencies = [ - "bitflags", - "cssparser", - "derive_more", - "fxhash", - "log", - "matches", - "phf 0.8.0", - "phf_codegen", - "precomputed-hash", - "servo_arc", - "smallvec", - "thin-slice", -] - -[[package]] -name = "semver" -version = "1.0.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bebd363326d05ec3e2f532ab7660680f3b02130d780c299bca73469d521bc0ed" -dependencies = [ - "serde", -] - -[[package]] -name = "serde" -version = "1.0.160" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb2f3770c8bce3bcda7e149193a069a0f4365bda1fa5cd88e03bca26afc1216c" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.160" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291a097c63d8497e00160b166a967a4a79c64f3facdd01cbd7502231688d77df" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "serde_json" -version = "1.0.96" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "057d394a50403bcac12672b2b18fb387ab6d289d957dab67dd201875391e52f1" -dependencies = [ - "itoa 1.0.6", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcec881020c684085e55a25f7fd888954d56609ef363479dc5a1305eb0d40cab" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "serde_spanned" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0efd8caf556a6cebd3b285caf480045fcc1ac04f6bd786b09a6f11af30c4fcf4" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa 1.0.6", - "ryu", - "serde", -] - -[[package]] -name = "serde_with" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" -dependencies = [ - "serde", - "serde_with_macros", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "serialize-to-javascript" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9823f2d3b6a81d98228151fdeaf848206a7855a7a042bbf9bf870449a66cafb" -dependencies = [ - "serde", - "serde_json", - "serialize-to-javascript-impl", -] - -[[package]] -name = "serialize-to-javascript-impl" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74064874e9f6a15f04c1f3cb627902d0e6b410abbf36668afa873c61889f1763" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "servo_arc" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d98238b800e0d1576d8b6e3de32827c2d74bee68bb97748dcf5071fb53965432" -dependencies = [ - "nodrop", - "stable_deref_trait", -] - -[[package]] -name = "sha2" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sharded-slab" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31" -dependencies = [ - "lazy_static", -] - -[[package]] -name = "simd-adler32" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "238abfbb77c1915110ad968465608b68e869e0772622c9656714e73e5a1a522f" - -[[package]] -name = "siphasher" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de" - -[[package]] -name = "slab" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6528351c9bc8ab22353f9d776db39a20288e8d6c37ef8cfe3317cf875eecfc2d" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" - -[[package]] -name = "socket2" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "soup3" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82bc46048125fefd69d30b32b9d263d6556c9ffe82a7a7df181a86d912da5616" -dependencies = [ - "bitflags", - "futures-channel", - "gio", - "glib", - "libc", - "once_cell", - "soup3-sys", -] - -[[package]] -name = "soup3-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "014bbeb1c4cdb30739dc181e8d98b7908f124d9555843afa89b5570aaf4ec62b" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "stable_deref_trait" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" - -[[package]] -name = "state" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe866e1e51e8260c9eed836a042a5e7f6726bb2b411dffeaa712e19c388f23b" -dependencies = [ - "loom", -] - -[[package]] -name = "string_cache" -version = "0.8.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91138e76242f575eb1d3b38b4f1362f10d3a43f47d182a5b359af488a02293b" -dependencies = [ - "new_debug_unreachable", - "once_cell", - "parking_lot", - "phf_shared 0.10.0", - "precomputed-hash", - "serde", -] - -[[package]] -name = "string_cache_codegen" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bb30289b722be4ff74a408c3cc27edeaad656e06cb1fe8fa9231fa59c728988" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro2", - "quote", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "swift-rs" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05e51d6f2b5fff4808614f429f8a7655ac8bcfe218185413f3a60c508482c2d6" -dependencies = [ - "base64 0.21.0", - "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", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a34fcf3e8b60f57e6a14301a2e916d323af98b0ea63c599441eec8558660c822" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-deps" -version = "6.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "555fc8147af6256f3931a36bb83ad0023240ce9cf2b319dec8236fd1f220b05f" -dependencies = [ - "cfg-expr", - "heck", - "pkg-config", - "toml 0.7.3", - "version-compare", -] - -[[package]] -name = "tao" -version = "0.18.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f2340617d383561b0ea25358b97ec2c2ba04db48c458ce71dd1b38d7fd09ac5" -dependencies = [ - "bitflags", - "cairo-rs", - "cc", - "cocoa", - "core-foundation", - "core-graphics", - "crossbeam-channel", - "dispatch", - "gdk", - "gdk-pixbuf", - "gdk-sys", - "gdkwayland-sys", - "gdkx11-sys", - "gio", - "glib", - "glib-sys", - "gtk", - "image", - "instant", - "jni", - "lazy_static", - "libc", - "log", - "ndk", - "ndk-context", - "ndk-sys", - "objc", - "once_cell", - "parking_lot", - "png", - "raw-window-handle", - "scopeguard", - "serde", - "tao-macros", - "unicode-segmentation", - "uuid", - "windows", - "windows-implement", - "x11-dl", -] - -[[package]] -name = "tao-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b27a4bcc5eb524658234589bdffc7e7bfb996dbae6ce9393bfd39cb4159b445" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "tar" -version = "0.4.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b55807c0344e1e6c04d7c965f5289c39a8d94ae23ed5c0b57aabac549f871c6" -dependencies = [ - "filetime", - "libc", - "xattr", -] - -[[package]] -name = "tauri" -version = "2.0.0-alpha.8" -source = "git+https://github.com/tauri-apps/tauri?branch=next#22a763381622407d58ae72aa24c0afff00b40e04" -dependencies = [ - "anyhow", - "bytes", - "cocoa", - "dirs-next", - "embed_plist", - "encoding_rs", - "flate2", - "futures-util", - "glib", - "glob", - "gtk", - "heck", - "http", - "ignore", - "jni", - "libc", - "log", - "objc", - "once_cell", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "reqwest", - "semver", - "serde", - "serde_json", - "serde_repr", - "serialize-to-javascript", - "state", - "swift-rs", - "tar", - "tauri-build", - "tauri-macros", - "tauri-runtime", - "tauri-runtime-wry", - "tauri-utils", - "tempfile", - "thiserror", - "tokio", - "url", - "uuid", - "webkit2gtk", - "webview2-com", - "windows", -] - -[[package]] -name = "tauri-build" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#22a763381622407d58ae72aa24c0afff00b40e04" -dependencies = [ - "anyhow", - "cargo_toml", - "filetime", - "heck", - "json-patch", - "semver", - "serde", - "serde_json", - "swift-rs", - "tauri-utils", - "tauri-winres", - "walkdir", -] - -[[package]] -name = "tauri-codegen" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#22a763381622407d58ae72aa24c0afff00b40e04" -dependencies = [ - "base64 0.21.0", - "brotli", - "ico", - "json-patch", - "plist", - "png", - "proc-macro2", - "quote", - "semver", - "serde", - "serde_json", - "sha2", - "tauri-utils", - "thiserror", - "time", - "url", - "uuid", - "walkdir", -] - -[[package]] -name = "tauri-macros" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#22a763381622407d58ae72aa24c0afff00b40e04" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn 1.0.109", - "tauri-codegen", - "tauri-utils", -] - -[[package]] -name = "tauri-plugin-fs" -version = "0.1.0" -dependencies = [ - "anyhow", - "serde", - "tauri", - "thiserror", -] - -[[package]] -name = "tauri-runtime" -version = "0.13.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#22a763381622407d58ae72aa24c0afff00b40e04" -dependencies = [ - "gtk", - "http", - "http-range", - "jni", - "rand 0.8.5", - "raw-window-handle", - "serde", - "serde_json", - "tauri-utils", - "thiserror", - "url", - "uuid", - "webview2-com", - "windows", -] - -[[package]] -name = "tauri-runtime-wry" -version = "0.13.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#22a763381622407d58ae72aa24c0afff00b40e04" -dependencies = [ - "cocoa", - "gtk", - "jni", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "tauri-runtime", - "tauri-utils", - "uuid", - "webkit2gtk", - "webview2-com", - "windows", - "wry", -] - -[[package]] -name = "tauri-utils" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#22a763381622407d58ae72aa24c0afff00b40e04" -dependencies = [ - "brotli", - "ctor", - "glob", - "heck", - "html5ever", - "infer", - "json-patch", - "kuchiki", - "memchr", - "phf 0.10.1", - "proc-macro2", - "quote", - "semver", - "serde", - "serde_json", - "serde_with", - "thiserror", - "url", - "walkdir", - "windows", -] - -[[package]] -name = "tauri-winres" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b7a78dc04f75fb5ab815e66ac561c81e92a968a40f29e7c21afd152d694fad8" -dependencies = [ - "toml 0.5.11", - "version_check", -] - -[[package]] -name = "tempfile" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9fbec84f381d5795b08656e4912bec604d162bff9291d6189a78f4c8ab87998" -dependencies = [ - "cfg-if", - "fastrand", - "redox_syscall 0.3.5", - "rustix", - "windows-sys 0.45.0", -] - -[[package]] -name = "tendril" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d24a120c5fc464a3458240ee02c299ebcb9d67b5249c8848b09d639dca8d7bb0" -dependencies = [ - "futf", - "mac", - "utf-8", -] - -[[package]] -name = "thin-slice" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c" - -[[package]] -name = "thiserror" -version = "1.0.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "978c9a314bd8dc99be594bc3c175faaa9794be04a5a5e153caba6915336cebac" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9456a42c5b0d803c8cd86e73dd7cc9edd429499f37a3550d286d5e86720569f" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "thread_local" -version = "1.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdd6f064ccff2d6567adcb3873ca630700f00b5ad3f060c25b5dcfd9a4ce152" -dependencies = [ - "cfg-if", - "once_cell", -] - -[[package]] -name = "time" -version = "0.3.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd0cbfecb4d19b5ea75bb31ad904eb5b9fa13f21079c3b92017ebdf4999a5890" -dependencies = [ - "itoa 1.0.6", - "serde", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd" - -[[package]] -name = "time-macros" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd80a657e71da814b8e5d60d3374fc6d35045062245d80224748ae522dd76f36" -dependencies = [ - "time-core", -] - -[[package]] -name = "tinyvec" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.27.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0de47a4eecbe11f498978a9b29d792f0d2692d1dd003650c24c76510e3bc001" -dependencies = [ - "autocfg", - "bytes", - "libc", - "mio", - "num_cpus", - "pin-project-lite", - "socket2", - "windows-sys 0.45.0", -] - -[[package]] -name = "tokio-util" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5427d89453009325de0d8f342c9490009f76e999cb7672d77e46267448f7e6b2" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", - "tracing", -] - -[[package]] -name = "toml" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" -dependencies = [ - "serde", -] - -[[package]] -name = "toml" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b403acf6f2bb0859c93c7f0d967cb4a75a7ac552100f9322faf64dc047669b21" -dependencies = [ - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab8ed2edee10b50132aed5f331333428b011c99402b5a534154ed15746f9622" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.19.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "239410c8609e8125456927e6707163a3b1fdb40561e4b803bc041f466ccfdc13" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" -dependencies = [ - "cfg-if", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "tracing-core" -version = "0.1.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" -dependencies = [ - "once_cell", - "valuable", -] - -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - -[[package]] -name = "tracing-subscriber" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6176eae26dd70d0c919749377897b54a9276bd7061339665dd68777926b5a70" -dependencies = [ - "matchers", - "nu-ansi-term", - "once_cell", - "regex", - "sharded-slab", - "smallvec", - "thread_local", - "tracing", - "tracing-core", - "tracing-log", -] - -[[package]] -name = "treediff" -version = "4.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52984d277bdf2a751072b5df30ec0377febdb02f7696d64c2d7d54630bac4303" -dependencies = [ - "serde_json", -] - -[[package]] -name = "try-lock" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" - -[[package]] -name = "typenum" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" - -[[package]] -name = "unicode-bidi" -version = "0.3.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" - -[[package]] -name = "unicode-ident" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5464a87b239f13a63a501f2701565754bae92d243d4bb7eb12f6d57d2269bf4" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - -[[package]] -name = "url" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", - "serde", -] - -[[package]] -name = "utf-8" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" - -[[package]] -name = "uuid" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b55a3fef2a1e3b3a00ce878640918820d3c51081576ac657d23af9fc7928fdb" -dependencies = [ - "getrandom 0.2.9", -] - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "version-compare" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "579a42fc0b8e0c63b76519a339be31bed574929511fa53c1a3acae26eb258f29" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36df944cda56c7d8d8b7496af378e6b16de9284591917d307c9b4d313c44e698" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" -dependencies = [ - "log", - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn 1.0.109", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f219e0d211ba40266969f6dbdd90636da12f75bee4fc9d6c23d1260dadb51454" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" - -[[package]] -name = "wasm-streams" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bbae3363c08332cadccd13b67db371814cd214c2524020932f0804b8cf7c078" -dependencies = [ - "futures-util", - "js-sys", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", -] - -[[package]] -name = "web-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "webkit2gtk" -version = "0.19.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8eea819afe15eb8dcdff4f19d8bfda540bae84d874c10e6f4b8faf2d6704bd1" -dependencies = [ - "bitflags", - "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 = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0ac7a95ddd3fdfcaf83d8e513b4b1ad101b95b413b6aa6662ed95f284fc3d5b" -dependencies = [ - "bitflags", - "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 = "webview2-com" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11296e5daf3a653b79bf47d66c380e4143d5b9c975818871179a3bda79499562" -dependencies = [ - "webview2-com-macros", - "webview2-com-sys", - "windows", - "windows-implement", -] - -[[package]] -name = "webview2-com-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaebe196c01691db62e9e4ca52c5ef1e4fd837dcae27dae3ada599b5a8fd05ac" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "webview2-com-sys" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cde542bed28058a5b028d459689ee57f1d06685bb6c266da3b91b1be6703952f" -dependencies = [ - "regex", - "serde", - "serde_json", - "thiserror", - "windows", - "windows-bindgen", - "windows-metadata", -] - -[[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.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi", -] - -[[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 = "windows" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e745dab35a0c4c77aa3ce42d595e13d2003d6902d6b08c9ef5fc326d08da12b" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-targets 0.42.2", -] - -[[package]] -name = "windows-bindgen" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "222204ecf46521382a4d88b4a1bbefca9f8855697b4ab7d20803901425e061a3" -dependencies = [ - "windows-metadata", - "windows-tokens", -] - -[[package]] -name = "windows-implement" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce87ca8e3417b02dc2a8a22769306658670ec92d78f1bd420d6310a67c245c6" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "windows-interface" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "853f69a591ecd4f810d29f17e902d40e349fb05b0b11fff63b08b826bfe39c7f" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "windows-metadata" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee78911e3f4ce32c1ad9d3c7b0bd95389662ad8d8f1a3155688fed70bd96e2b6" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.0", -] - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b1eb6f0cd7c80c79759c929114ef071b87354ce476d9d94271031c0497adfd5" -dependencies = [ - "windows_aarch64_gnullvm 0.48.0", - "windows_aarch64_msvc 0.48.0", - "windows_i686_gnu 0.48.0", - "windows_i686_msvc 0.48.0", - "windows_x86_64_gnu 0.48.0", - "windows_x86_64_gnullvm 0.48.0", - "windows_x86_64_msvc 0.48.0", -] - -[[package]] -name = "windows-tokens" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa4251900975a0d10841c5d4bde79c56681543367ef811f3fabb8d1803b0959b" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" - -[[package]] -name = "winnow" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae8970b36c66498d8ff1d66685dc86b91b29db0c7739899012f63a63814b4b28" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d0f4e272c85def139476380b12f9ac60926689dd2e01d4923222f40580869d" -dependencies = [ - "winapi", -] - -[[package]] -name = "wry" -version = "0.27.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8cf0dbfa7ccbd2e3832a3098b19d4b552360ea00a40b244a99caef46bffd84f" -dependencies = [ - "base64 0.13.1", - "block", - "cocoa", - "core-graphics", - "crossbeam-channel", - "dunce", - "gdk", - "gio", - "glib", - "gtk", - "html5ever", - "http", - "javascriptcore-rs", - "kuchiki", - "libc", - "log", - "objc", - "objc_id", - "once_cell", - "serde", - "serde_json", - "sha2", - "soup3", - "tao", - "thiserror", - "url", - "webkit2gtk", - "webkit2gtk-sys", - "webview2-com", - "windows", - "windows-implement", -] - -[[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 = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d1526bbe5aaeb5eb06885f4d987bcdfa5e23187055de9b83fe00156a821fabc" -dependencies = [ - "libc", -] diff --git a/plugins/fs/Cargo.toml b/plugins/fs/Cargo.toml index 6e2add71..e355ff6c 100644 --- a/plugins/fs/Cargo.toml +++ b/plugins/fs/Cargo.toml @@ -1,22 +1,21 @@ [package] name = "tauri-plugin-fs" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Access the file system." -edition = "2021" -#authors.workspace = true -#license.workspace = true -#edition.workspace = true -#rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -#serde.workspace = true -#serde_json.workspace = true -#tauri.workspace = true -#log.workspace = true -#thiserror.workspace = true -serde = "1" -thiserror = "1" -tauri = { git = "https://github.com/tauri-apps/tauri", branch = "next" } +serde = { workspace = true } +tauri = { workspace = true } +thiserror = { workspace = true } anyhow = "1" +uuid = { version = "1", features = [ "v4" ] } +glob = "0.3" +notify = { version = "5", optional = true, features = [ "serde" ] } +notify-debouncer-mini = { version = "0.2.1", optional = true, features = [ "serde" ] } + +[features] +watch = [ "notify", "notify-debouncer-mini" ] diff --git a/plugins/fs/README.md b/plugins/fs/README.md index 55756f5b..badc305d 100644 --- a/plugins/fs/README.md +++ b/plugins/fs/README.md @@ -1,10 +1,10 @@ -![tauri-plugin-fs](banner.png) +# File System Access the file system. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-fs = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-fs = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-fs +# or +npm add @tauri-apps/plugin-fs +# or +yarn add @tauri-apps/plugin-fs + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-fs#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-fs#v2 @@ -51,7 +60,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { metadata } from "tauri-plugin-fs-api"; +import { metadata } from "@tauri-apps/plugin-fs"; await metadata("/path/to/file"); ``` diff --git a/plugins/fs/banner.png b/plugins/fs/banner.png deleted file mode 100644 index b860c3c8..00000000 Binary files a/plugins/fs/banner.png and /dev/null differ diff --git a/plugins/fs/guest-js/index.ts b/plugins/fs/guest-js/index.ts index 66dd3591..af4d2e84 100644 --- a/plugins/fs/guest-js/index.ts +++ b/plugins/fs/guest-js/index.ts @@ -5,32 +5,6 @@ /** * Access the file system. * - * This package is also accessible with `window.__TAURI__.fs` when [`build.withGlobalTauri`](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in `tauri.conf.json` is set to `true`. - * - * The APIs must be added to [`tauri.allowlist.fs`](https://tauri.app/v1/api/config/#allowlistconfig.fs) in `tauri.conf.json`: - * ```json - * { - * "tauri": { - * "allowlist": { - * "fs": { - * "all": true, // enable all FS APIs - * "readFile": true, - * "writeFile": true, - * "readDir": true, - * "copyFile": true, - * "createDir": true, - * "removeDir": true, - * "removeFile": true, - * "renameFile": true, - * "metadata": true, - * "exists": true - * } - * } - * } - * } - * ``` - * It is recommended to allowlist only the APIs you use for optimal bundle size and security. - * * ## Security * * This module prevents path traversal, not allowing absolute paths or parent dir components @@ -45,11 +19,9 @@ * *databases* folder of the {@link path.appDataDir | $APPDATA directory}: * ```json * { - * "tauri": { - * "allowlist": { - * "fs": { - * "scope": ["$APPDATA/databases/*"] - * } + * "plugins": { + * "fs": { + * "scope": ["$APPDATA/databases/*"] * } * } * } @@ -73,7 +45,13 @@ * @module */ -import { invoke } from "@tauri-apps/api/tauri"; +import { BaseDirectory } from "@tauri-apps/api/path"; + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} interface Permissions { /** @@ -182,39 +160,8 @@ interface BackendMetadata { blocks: number | undefined; } -// TODO: pull BaseDirectory from @tauri-apps/api/path -/** - * @since 1.0.0 - */ -enum BaseDirectory { - Audio = 1, - Cache, - Config, - Data, - LocalData, - Document, - Download, - Picture, - Public, - Video, - Resource, - Temp, - AppConfig, - AppData, - AppLocalData, - AppCache, - AppLog, - - Desktop, - Executable, - Font, - Home, - Runtime, - Template, -} - /** - * @since 1.0.0 + * @since 2.0.0 */ interface FsOptions { dir?: BaseDirectory; @@ -222,7 +169,7 @@ interface FsOptions { } /** - * @since 1.0.0 + * @since 2.0.0 */ interface FsDirOptions { dir?: BaseDirectory; @@ -232,7 +179,7 @@ interface FsDirOptions { /** * Options object used to write a UTF-8 string to a file. * - * @since 1.0.0 + * @since 2.0.0 */ interface FsTextFileOption { /** Path to the file to write. */ @@ -246,7 +193,7 @@ type BinaryFileContents = Iterable | ArrayLike | ArrayBuffer; /** * Options object used to write a binary data to a file. * - * @since 1.0.0 + * @since 2.0.0 */ interface FsBinaryFileOption { /** Path to the file to write. */ @@ -256,7 +203,7 @@ interface FsBinaryFileOption { } /** - * @since 1.0.0 + * @since 2.0.0 */ interface FileEntry { path: string; @@ -273,18 +220,18 @@ interface FileEntry { * Reads a file as an UTF-8 encoded string. * @example * ```typescript - * import { readTextFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { readTextFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Read the text file in the `$APPCONFIG/app.conf` path * const contents = await readTextFile('app.conf', { dir: BaseDirectory.AppConfig }); * ``` * - * @since 1.0.0 + * @since 2.0.0 */ async function readTextFile( filePath: string, options: FsOptions = {} ): Promise { - return await invoke("plugin:fs|read_text_file", { + return await window.__TAURI_INVOKE__("plugin:fs|read_text_file", { path: filePath, options, }); @@ -294,18 +241,18 @@ async function readTextFile( * Reads a file as byte array. * @example * ```typescript - * import { readBinaryFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { readBinaryFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Read the image file in the `$RESOURCEDIR/avatar.png` path * const contents = await readBinaryFile('avatar.png', { dir: BaseDirectory.Resource }); * ``` * - * @since 1.0.0 + * @since 2.0.0 */ async function readBinaryFile( filePath: string, options: FsOptions = {} ): Promise { - const arr = await invoke("plugin:fs|read_file", { + const arr = await window.__TAURI_INVOKE__("plugin:fs|read_file", { path: filePath, options, }); @@ -317,12 +264,12 @@ async function readBinaryFile( * Writes a UTF-8 text file. * @example * ```typescript - * import { writeTextFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { writeTextFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Write a text file to the `$APPCONFIG/app.conf` path * await writeTextFile('app.conf', 'file contents', { dir: BaseDirectory.AppConfig }); * ``` * - * @since 1.0.0 + * @since 2.0.0 */ async function writeTextFile( path: string, @@ -334,13 +281,13 @@ async function writeTextFile( * Writes a UTF-8 text file. * @example * ```typescript - * import { writeTextFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { writeTextFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Write a text file to the `$APPCONFIG/app.conf` path * await writeTextFile({ path: 'app.conf', contents: 'file contents' }, { dir: BaseDirectory.AppConfig }); * ``` * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function writeTextFile( file: FsTextFileOption, @@ -352,7 +299,7 @@ async function writeTextFile( * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function writeTextFile( path: string | FsTextFileOption, @@ -381,7 +328,7 @@ async function writeTextFile( fileOptions = contents; } - return await invoke("plugin:fs|write_file", { + return await window.__TAURI_INVOKE__("plugin:fs|write_file", { path: file.path, contents: Array.from(new TextEncoder().encode(file.contents)), options: fileOptions, @@ -392,7 +339,7 @@ async function writeTextFile( * Writes a byte array content to a file. * @example * ```typescript - * import { writeBinaryFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { writeBinaryFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Write a binary file to the `$APPDATA/avatar.png` path * await writeBinaryFile('avatar.png', new Uint8Array([]), { dir: BaseDirectory.AppData }); * ``` @@ -400,7 +347,7 @@ async function writeTextFile( * @param options Configuration object. * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function writeBinaryFile( path: string, @@ -412,7 +359,7 @@ async function writeBinaryFile( * Writes a byte array content to a file. * @example * ```typescript - * import { writeBinaryFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { writeBinaryFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Write a binary file to the `$APPDATA/avatar.png` path * await writeBinaryFile({ path: 'avatar.png', contents: new Uint8Array([]) }, { dir: BaseDirectory.AppData }); * ``` @@ -421,7 +368,7 @@ async function writeBinaryFile( * @param options Configuration object. * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function writeBinaryFile( file: FsBinaryFileOption, @@ -433,7 +380,7 @@ async function writeBinaryFile( * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function writeBinaryFile( path: string | FsBinaryFileOption, @@ -463,7 +410,7 @@ async function writeBinaryFile( file.contents = contents ?? []; } - return await invoke("plugin:fs|write_binary_file", { + return await window.__TAURI_INVOKE__("plugin:fs|write_binary_file", { path: file.path, contents: Array.from( file.contents instanceof ArrayBuffer @@ -478,7 +425,7 @@ async function writeBinaryFile( * List directory files. * @example * ```typescript - * import { readDir, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { readDir, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Reads the `$APPDATA/users` directory recursively * const entries = await readDir('users', { dir: BaseDirectory.AppData, recursive: true }); * @@ -492,13 +439,13 @@ async function writeBinaryFile( * } * ``` * - * @since 1.0.0 + * @since 2.0.0 */ async function readDir( dir: string, options: FsDirOptions = {} ): Promise { - return await invoke("plugin:fs|read_dir", { + return await window.__TAURI_INVOKE__("plugin:fs|read_dir", { path: dir, options, }); @@ -510,20 +457,20 @@ async function readDir( * and the `recursive` option isn't set to true, the promise will be rejected. * @example * ```typescript - * import { createDir, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { createDir, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Create the `$APPDATA/users` directory * await createDir('users', { dir: BaseDirectory.AppData, recursive: true }); * ``` * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function createDir( dir: string, options: FsDirOptions = {} ): Promise { - return await invoke("plugin:fs|create_dir", { + return await window.__TAURI_INVOKE__("plugin:fs|create_dir", { path: dir, options, }); @@ -534,20 +481,20 @@ async function createDir( * If the directory is not empty and the `recursive` option isn't set to true, the promise will be rejected. * @example * ```typescript - * import { removeDir, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { removeDir, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Remove the directory `$APPDATA/users` * await removeDir('users', { dir: BaseDirectory.AppData }); * ``` * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function removeDir( dir: string, options: FsDirOptions = {} ): Promise { - return await invoke("plugin:fs|remove_dir", { + return await window.__TAURI_INVOKE__("plugin:fs|remove_dir", { path: dir, options, }); @@ -557,21 +504,21 @@ async function removeDir( * Copies a file to a destination. * @example * ```typescript - * import { copyFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { copyFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Copy the `$APPCONFIG/app.conf` file to `$APPCONFIG/app.conf.bk` * await copyFile('app.conf', 'app.conf.bk', { dir: BaseDirectory.AppConfig }); * ``` * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function copyFile( source: string, destination: string, options: FsOptions = {} ): Promise { - return await invoke("plugin:fs|copy_file", { + return await window.__TAURI_INVOKE__("plugin:fs|copy_file", { source, destination, options, @@ -582,20 +529,20 @@ async function copyFile( * Removes a file. * @example * ```typescript - * import { removeFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { removeFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Remove the `$APPConfig/app.conf` file * await removeFile('app.conf', { dir: BaseDirectory.AppConfig }); * ``` * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function removeFile( file: string, options: FsOptions = {} ): Promise { - return await invoke("plugin:fs|remove_file", { + return await window.__TAURI_INVOKE__("plugin:fs|remove_file", { path: file, options, }); @@ -605,21 +552,21 @@ async function removeFile( * Renames a file. * @example * ```typescript - * import { renameFile, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { renameFile, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Rename the `$APPDATA/avatar.png` file * await renameFile('avatar.png', 'deleted.png', { dir: BaseDirectory.AppData }); * ``` * * @returns A promise indicating the success or failure of the operation. * - * @since 1.0.0 + * @since 2.0.0 */ async function renameFile( oldPath: string, newPath: string, options: FsOptions = {} ): Promise { - return await invoke("plugin:fs|rename_file", { + return await window.__TAURI_INVOKE__("plugin:fs|rename_file", { oldPath, newPath, options, @@ -630,34 +577,36 @@ async function renameFile( * Check if a path exists. * @example * ```typescript - * import { exists, BaseDirectory } from 'tauri-plugin-fs-api'; + * import { exists, BaseDirectory } from '@tauri-apps/plugin-fs'; * // Check if the `$APPDATA/avatar.png` file exists * await exists('avatar.png', { dir: BaseDirectory.AppData }); * ``` * - * @since 1.0.0 + * @since 2.0.0 */ async function exists(path: string): Promise { - return await invoke("plugin:fs|exists", { path }); + return await window.__TAURI_INVOKE__("plugin:fs|exists", { path }); } /** * Returns the metadata for the given path. * - * @since 1.0.0 + * @since 2.0.0 */ async function metadata(path: string): Promise { - return await invoke("plugin:fs|metadata", { - path, - }).then((metadata) => { - const { accessedAtMs, createdAtMs, modifiedAtMs, ...data } = metadata; - return { - accessedAt: new Date(accessedAtMs), - createdAt: new Date(createdAtMs), - modifiedAt: new Date(modifiedAtMs), - ...data, - }; - }); + return await window + .__TAURI_INVOKE__("plugin:fs|metadata", { + path, + }) + .then((metadata) => { + const { accessedAtMs, createdAtMs, modifiedAtMs, ...data } = metadata; + return { + accessedAt: new Date(accessedAtMs), + createdAt: new Date(createdAtMs), + modifiedAt: new Date(modifiedAtMs), + ...data, + }; + }); } export type { diff --git a/plugins/fs/package.json b/plugins/fs/package.json index 0f4348e6..071c6f1a 100644 --- a/plugins/fs/package.json +++ b/plugins/fs/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-fs-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-fs", + "version": "2.0.0-alpha.0", "description": "Access the file system.", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/fs/src/api-iife.js b/plugins/fs/src/api-iife.js new file mode 100644 index 00000000..c87b63b8 --- /dev/null +++ b/plugins/fs/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_FS__=function(e){"use strict";var t=Object.defineProperty,n=(e,n)=>{for(var r in n)t(e,r,{get:n[r],enumerable:!0})},r=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},i=(e,t,n)=>(r(e,t,"read from private field"),n?n.call(e):t.get(e));function o(e,t=!1){let n=window.crypto.getRandomValues(new Uint32Array(1))[0],r=`_${n}`;return Object.defineProperty(window,r,{value:n=>(t&&Reflect.deleteProperty(window,r),e?.(n)),writable:!1,configurable:!0}),n}n({},{Channel:()=>c,PluginListener:()=>s,addPluginListener:()=>u,convertFileSrc:()=>l,invoke:()=>p,transformCallback:()=>o});var a,c=class{constructor(){this.__TAURI_CHANNEL_MARKER__=!0,((e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)})(this,a,(()=>{})),this.id=o((e=>{i(this,a).call(this,e)}))}set onmessage(e){((e,t,n,i)=>{r(e,t,"write to private field"),i?i.call(e,n):t.set(e,n)})(this,a,e)}get onmessage(){return i(this,a)}toJSON(){return`__CHANNEL__:${this.id}`}};a=new WeakMap;var s=class{constructor(e,t,n){this.plugin=e,this.event=t,this.channelId=n}async unregister(){return p(`plugin:${this.plugin}|remove_listener`,{event:this.event,channelId:this.channelId})}};async function u(e,t,n){let r=new c;return r.onmessage=n,p(`plugin:${e}|register_listener`,{event:t,handler:r}).then((()=>new s(e,t,r.id)))}async function p(e,t={}){return new Promise(((n,r)=>{let i=o((e=>{n(e),Reflect.deleteProperty(window,`_${a}`)}),!0),a=o((e=>{r(e),Reflect.deleteProperty(window,`_${i}`)}),!0);window.__TAURI_IPC__({cmd:e,callback:i,error:a,...t})}))}function l(e,t="asset"){let n=encodeURIComponent(e);return navigator.userAgent.includes("Windows")?`https://${t}.localhost/${n}`:`${t}://localhost/${n}`}function d(){return navigator.appVersion.includes("Win")}n({},{BaseDirectory:()=>y,appCacheDir:()=>g,appConfigDir:()=>f,appDataDir:()=>h,appLocalDataDir:()=>w,appLogDir:()=>x,audioDir:()=>v,basename:()=>H,cacheDir:()=>m,configDir:()=>A,dataDir:()=>D,delimiter:()=>$,desktopDir:()=>I,dirname:()=>M,documentDir:()=>R,downloadDir:()=>b,executableDir:()=>T,extname:()=>S,fontDir:()=>U,homeDir:()=>E,isAbsolute:()=>W,join:()=>B,localDataDir:()=>O,normalize:()=>z,pictureDir:()=>C,publicDir:()=>N,resolve:()=>k,resolveResource:()=>V,resourceDir:()=>P,runtimeDir:()=>j,sep:()=>L,templateDir:()=>F,videoDir:()=>K});var _,y=((_=y||{})[_.Audio=1]="Audio",_[_.Cache=2]="Cache",_[_.Config=3]="Config",_[_.Data=4]="Data",_[_.LocalData=5]="LocalData",_[_.Document=6]="Document",_[_.Download=7]="Download",_[_.Picture=8]="Picture",_[_.Public=9]="Public",_[_.Video=10]="Video",_[_.Resource=11]="Resource",_[_.Temp=12]="Temp",_[_.AppConfig=13]="AppConfig",_[_.AppData=14]="AppData",_[_.AppLocalData=15]="AppLocalData",_[_.AppCache=16]="AppCache",_[_.AppLog=17]="AppLog",_[_.Desktop=18]="Desktop",_[_.Executable=19]="Executable",_[_.Font=20]="Font",_[_.Home=21]="Home",_[_.Runtime=22]="Runtime",_[_.Template=23]="Template",_);async function f(){return p("plugin:path|resolve_directory",{directory:13})}async function h(){return p("plugin:path|resolve_directory",{directory:14})}async function w(){return p("plugin:path|resolve_directory",{directory:15})}async function g(){return p("plugin:path|resolve_directory",{directory:16})}async function v(){return p("plugin:path|resolve_directory",{directory:1})}async function m(){return p("plugin:path|resolve_directory",{directory:2})}async function A(){return p("plugin:path|resolve_directory",{directory:3})}async function D(){return p("plugin:path|resolve_directory",{directory:4})}async function I(){return p("plugin:path|resolve_directory",{directory:18})}async function R(){return p("plugin:path|resolve_directory",{directory:6})}async function b(){return p("plugin:path|resolve_directory",{directory:7})}async function T(){return p("plugin:path|resolve_directory",{directory:19})}async function U(){return p("plugin:path|resolve_directory",{directory:20})}async function E(){return p("plugin:path|resolve_directory",{directory:21})}async function O(){return p("plugin:path|resolve_directory",{directory:5})}async function C(){return p("plugin:path|resolve_directory",{directory:8})}async function N(){return p("plugin:path|resolve_directory",{directory:9})}async function P(){return p("plugin:path|resolve_directory",{directory:11})}async function V(e){return p("plugin:path|resolve_directory",{directory:11,path:e})}async function j(){return p("plugin:path|resolve_directory",{directory:22})}async function F(){return p("plugin:path|resolve_directory",{directory:23})}async function K(){return p("plugin:path|resolve_directory",{directory:10})}async function x(){return p("plugin:path|resolve_directory",{directory:17})}var L=d()?"\\":"/",$=d()?";":":";async function k(...e){return p("plugin:path|resolve",{paths:e})}async function z(e){return p("plugin:path|normalize",{path:e})}async function B(...e){return p("plugin:path|join",{paths:e})}async function M(e){return p("plugin:path|dirname",{path:e})}async function S(e){return p("plugin:path|extname",{path:e})}async function H(e,t){return p("plugin:path|basename",{path:e,ext:t})}async function W(e){return p("plugin:path|isAbsolute",{path:e})}async function J(e,t,n){"object"==typeof n&&Object.freeze(n),"object"==typeof e&&Object.freeze(e);const r={path:"",contents:""};let i=n;return"string"==typeof e?r.path=e:(r.path=e.path,r.contents=e.contents),"string"==typeof t?r.contents=null!=t?t:"":i=t,await window.__TAURI_INVOKE__("plugin:fs|write_file",{path:r.path,contents:Array.from((new TextEncoder).encode(r.contents)),options:i})}return e.BaseDirectory=y,e.Dir=y,e.copyFile=async function(e,t,n={}){return await window.__TAURI_INVOKE__("plugin:fs|copy_file",{source:e,destination:t,options:n})},e.createDir=async function(e,t={}){return await window.__TAURI_INVOKE__("plugin:fs|create_dir",{path:e,options:t})},e.exists=async function(e){return await window.__TAURI_INVOKE__("plugin:fs|exists",{path:e})},e.metadata=async function(e){return await window.__TAURI_INVOKE__("plugin:fs|metadata",{path:e}).then((e=>{const{accessedAtMs:t,createdAtMs:n,modifiedAtMs:r,...i}=e;return{accessedAt:new Date(t),createdAt:new Date(n),modifiedAt:new Date(r),...i}}))},e.readBinaryFile=async function(e,t={}){const n=await window.__TAURI_INVOKE__("plugin:fs|read_file",{path:e,options:t});return Uint8Array.from(n)},e.readDir=async function(e,t={}){return await window.__TAURI_INVOKE__("plugin:fs|read_dir",{path:e,options:t})},e.readTextFile=async function(e,t={}){return await window.__TAURI_INVOKE__("plugin:fs|read_text_file",{path:e,options:t})},e.removeDir=async function(e,t={}){return await window.__TAURI_INVOKE__("plugin:fs|remove_dir",{path:e,options:t})},e.removeFile=async function(e,t={}){return await window.__TAURI_INVOKE__("plugin:fs|remove_file",{path:e,options:t})},e.renameFile=async function(e,t,n={}){return await window.__TAURI_INVOKE__("plugin:fs|rename_file",{oldPath:e,newPath:t,options:n})},e.writeBinaryFile=async function(e,t,n){"object"==typeof n&&Object.freeze(n),"object"==typeof e&&Object.freeze(e);const r={path:"",contents:[]};let i=n;return"string"==typeof e?r.path=e:(r.path=e.path,r.contents=e.contents),t&&"dir"in t?i=t:"string"==typeof e&&(r.contents=null!=t?t:[]),await window.__TAURI_INVOKE__("plugin:fs|write_binary_file",{path:r.path,contents:Array.from(r.contents instanceof ArrayBuffer?new Uint8Array(r.contents):r.contents),options:i})},e.writeFile=J,e.writeTextFile=J,e}({});Object.defineProperty(window.__TAURI__,"fs",{value:__TAURI_FS__})} diff --git a/plugins/fs/src/commands.rs b/plugins/fs/src/commands.rs index cd1fc4e0..59255796 100644 --- a/plugins/fs/src/commands.rs +++ b/plugins/fs/src/commands.rs @@ -1,8 +1,13 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use crate::Scope; use anyhow::Context; use serde::{Deserialize, Serialize, Serializer}; use tauri::{ path::{BaseDirectory, SafePathBuf}, - FsScope, Manager, Runtime, Window, + Manager, Runtime, Window, }; #[cfg(unix)] @@ -16,7 +21,7 @@ use std::{ time::{SystemTime, UNIX_EPOCH}, }; -use crate::{Error, Result}; +use crate::{Error, FsExt, Result}; #[derive(Debug, thiserror::Error)] pub enum CommandError { @@ -120,7 +125,7 @@ pub fn write_file( #[derive(Clone, Copy)] struct ReadDirOptions<'a> { - pub scope: Option<&'a FsScope>, + pub scope: Option<&'a Scope>, } #[derive(Debug, Serialize)] @@ -189,7 +194,7 @@ pub fn read_dir( &resolved_path, recursive, ReadDirOptions { - scope: Some(&window.fs_scope()), + scope: Some(window.fs_scope()), }, ) .with_context(|| format!("path: {}", resolved_path.display())) diff --git a/plugins/fs/src/config.rs b/plugins/fs/src/config.rs new file mode 100644 index 00000000..f6c9b235 --- /dev/null +++ b/plugins/fs/src/config.rs @@ -0,0 +1,61 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use std::path::PathBuf; + +use serde::Deserialize; + +#[derive(Debug, Deserialize)] +pub struct Config { + pub scope: FsScope, +} + +/// Protocol scope definition. +/// It is a list of glob patterns that restrict the API access from the webview. +/// +/// Each pattern can start with a variable that resolves to a system base directory. +/// The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, +/// `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, +/// `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$APP`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, +/// `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`. +#[derive(Debug, PartialEq, Eq, Clone, Deserialize)] +#[serde(untagged)] +pub enum FsScope { + /// A list of paths that are allowed by this scope. + AllowedPaths(Vec), + /// A complete scope configuration. + Scope { + /// A list of paths that are allowed by this scope. + #[serde(default)] + allow: Vec, + /// A list of paths that are not allowed by this scope. + /// This gets precedence over the [`Self::Scope::allow`] list. + #[serde(default)] + deny: Vec, + }, +} + +impl Default for FsScope { + fn default() -> Self { + Self::AllowedPaths(Vec::new()) + } +} + +impl FsScope { + /// The list of allowed paths. + pub fn allowed_paths(&self) -> &Vec { + match self { + Self::AllowedPaths(p) => p, + Self::Scope { allow, .. } => allow, + } + } + + /// The list of forbidden paths. + pub fn forbidden_paths(&self) -> Option<&Vec> { + match self { + Self::AllowedPaths(_) => None, + Self::Scope { deny, .. } => Some(deny), + } + } +} diff --git a/plugins/fs/src/error.rs b/plugins/fs/src/error.rs index df109d43..effc017f 100644 --- a/plugins/fs/src/error.rs +++ b/plugins/fs/src/error.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::path::PathBuf; use serde::{Serialize, Serializer}; @@ -10,6 +14,13 @@ pub enum Error { PathForbidden(PathBuf), #[error("failed to resolve path: {0}")] CannotResolvePath(tauri::path::Error), + /// Invalid glob pattern. + #[error("invalid glob pattern: {0}")] + GlobPattern(#[from] glob::PatternError), + /// Watcher error. + #[cfg(feature = "watch")] + #[error(transparent)] + Watch(#[from] notify::Error), } impl Serialize for Error { diff --git a/plugins/fs/src/lib.rs b/plugins/fs/src/lib.rs index 5c1b2658..9156661f 100644 --- a/plugins/fs/src/lib.rs +++ b/plugins/fs/src/lib.rs @@ -2,20 +2,43 @@ // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT +use config::FsScope; use tauri::{ plugin::{Builder as PluginBuilder, TauriPlugin}, - Runtime, + FileDropEvent, Manager, RunEvent, Runtime, WindowEvent, }; mod commands; +mod config; mod error; +mod scope; +#[cfg(feature = "watch")] +mod watcher; +pub use config::Config; pub use error::Error; +pub use scope::{Event as ScopeEvent, Scope}; type Result = std::result::Result; -pub fn init() -> TauriPlugin { - PluginBuilder::new("fs") +pub trait FsExt { + fn fs_scope(&self) -> &Scope; + fn try_fs_scope(&self) -> Option<&Scope>; +} + +impl> FsExt for T { + fn fs_scope(&self) -> &Scope { + self.state::().inner() + } + + fn try_fs_scope(&self) -> Option<&Scope> { + self.try_state::().map(|s| s.inner()) + } +} + +pub fn init() -> TauriPlugin> { + PluginBuilder::>::new("fs") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![ commands::read_file, commands::read_text_file, @@ -27,7 +50,43 @@ pub fn init() -> TauriPlugin { commands::remove_file, commands::rename_file, commands::exists, - commands::metadata + commands::metadata, + #[cfg(feature = "watch")] + watcher::watch, + #[cfg(feature = "watch")] + watcher::unwatch ]) + .setup(|app: &tauri::AppHandle, api| { + let default_scope = FsScope::default(); + app.manage(Scope::new( + app, + api.config() + .as_ref() + .map(|c| &c.scope) + .unwrap_or(&default_scope), + )?); + + #[cfg(feature = "watch")] + app.manage(watcher::WatcherCollection::default()); + + Ok(()) + }) + .on_event(|app, event| { + if let RunEvent::WindowEvent { + label: _, + event: WindowEvent::FileDrop(FileDropEvent::Dropped(paths)), + .. + } = event + { + let scope = app.fs_scope(); + for path in paths { + if path.is_file() { + let _ = scope.allow_file(path); + } else { + let _ = scope.allow_directory(path, false); + } + } + } + }) .build() } diff --git a/plugins/fs/src/scope.rs b/plugins/fs/src/scope.rs new file mode 100644 index 00000000..609506fc --- /dev/null +++ b/plugins/fs/src/scope.rs @@ -0,0 +1,368 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use std::{ + collections::{HashMap, HashSet}, + fmt, + path::{Path, PathBuf, MAIN_SEPARATOR}, + sync::{Arc, Mutex}, +}; + +use crate::config::FsScope; +pub use glob::Pattern; +use uuid::Uuid; + +use crate::{Manager, Runtime}; + +/// Scope change event. +#[derive(Debug, Clone)] +pub enum Event { + /// A path has been allowed. + PathAllowed(PathBuf), + /// A path has been forbidden. + PathForbidden(PathBuf), +} + +type EventListener = Box; + +/// Scope for filesystem access. +#[derive(Clone)] +pub struct Scope { + allowed_patterns: Arc>>, + forbidden_patterns: Arc>>, + event_listeners: Arc>>, +} + +impl fmt::Debug for Scope { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + f.debug_struct("Scope") + .field( + "allowed_patterns", + &self + .allowed_patterns + .lock() + .unwrap() + .iter() + .map(|p| p.as_str()) + .collect::>(), + ) + .field( + "forbidden_patterns", + &self + .forbidden_patterns + .lock() + .unwrap() + .iter() + .map(|p| p.as_str()) + .collect::>(), + ) + .finish() + } +} + +fn push_pattern, F: Fn(&str) -> Result>( + list: &mut HashSet, + pattern: P, + f: F, +) -> crate::Result<()> { + let path: PathBuf = pattern.as_ref().components().collect(); + list.insert(f(&path.to_string_lossy())?); + #[cfg(windows)] + { + if let Ok(p) = std::fs::canonicalize(&path) { + list.insert(f(&p.to_string_lossy())?); + } else { + list.insert(f(&format!("\\\\?\\{}", path.display()))?); + } + } + Ok(()) +} + +impl Scope { + /// Creates a new scope from a `FsScope` configuration. + pub(crate) fn new>( + manager: &M, + scope: &FsScope, + ) -> crate::Result { + let mut allowed_patterns = HashSet::new(); + for path in scope.allowed_paths() { + if let Ok(path) = manager.path().parse(path) { + push_pattern(&mut allowed_patterns, path, Pattern::new)?; + } + } + + let mut forbidden_patterns = HashSet::new(); + if let Some(forbidden_paths) = scope.forbidden_paths() { + for path in forbidden_paths { + if let Ok(path) = manager.path().parse(path) { + push_pattern(&mut forbidden_patterns, path, Pattern::new)?; + } + } + } + + Ok(Self { + allowed_patterns: Arc::new(Mutex::new(allowed_patterns)), + forbidden_patterns: Arc::new(Mutex::new(forbidden_patterns)), + event_listeners: Default::default(), + }) + } + + /// The list of allowed patterns. + pub fn allowed_patterns(&self) -> HashSet { + self.allowed_patterns.lock().unwrap().clone() + } + + /// The list of forbidden patterns. + pub fn forbidden_patterns(&self) -> HashSet { + self.forbidden_patterns.lock().unwrap().clone() + } + + /// Listen to an event on this scope. + pub fn listen(&self, f: F) -> Uuid { + let id = Uuid::new_v4(); + self.event_listeners.lock().unwrap().insert(id, Box::new(f)); + id + } + + fn trigger(&self, event: Event) { + let listeners = self.event_listeners.lock().unwrap(); + let handlers = listeners.values(); + for listener in handlers { + listener(&event); + } + } + + /// Extend the allowed patterns with the given directory. + /// + /// After this function has been called, the frontend will be able to use the Tauri API to read + /// the directory and all of its files. If `recursive` is `true`, subdirectories will be accessible too. + pub fn allow_directory>(&self, path: P, recursive: bool) -> crate::Result<()> { + let path = path.as_ref(); + { + let mut list = self.allowed_patterns.lock().unwrap(); + + // allow the directory to be read + push_pattern(&mut list, path, escaped_pattern)?; + // allow its files and subdirectories to be read + push_pattern(&mut list, path, |p| { + escaped_pattern_with(p, if recursive { "**" } else { "*" }) + })?; + } + self.trigger(Event::PathAllowed(path.to_path_buf())); + Ok(()) + } + + /// Extend the allowed patterns with the given file path. + /// + /// After this function has been called, the frontend will be able to use the Tauri API to read the contents of this file. + pub fn allow_file>(&self, path: P) -> crate::Result<()> { + let path = path.as_ref(); + push_pattern( + &mut self.allowed_patterns.lock().unwrap(), + path, + escaped_pattern, + )?; + self.trigger(Event::PathAllowed(path.to_path_buf())); + Ok(()) + } + + /// Set the given directory path to be forbidden by this scope. + /// + /// **Note:** this takes precedence over allowed paths, so its access gets denied **always**. + pub fn forbid_directory>(&self, path: P, recursive: bool) -> crate::Result<()> { + let path = path.as_ref(); + { + let mut list = self.forbidden_patterns.lock().unwrap(); + + // allow the directory to be read + push_pattern(&mut list, path, escaped_pattern)?; + // allow its files and subdirectories to be read + push_pattern(&mut list, path, |p| { + escaped_pattern_with(p, if recursive { "**" } else { "*" }) + })?; + } + self.trigger(Event::PathForbidden(path.to_path_buf())); + Ok(()) + } + + /// Set the given file path to be forbidden by this scope. + /// + /// **Note:** this takes precedence over allowed paths, so its access gets denied **always**. + pub fn forbid_file>(&self, path: P) -> crate::Result<()> { + let path = path.as_ref(); + push_pattern( + &mut self.forbidden_patterns.lock().unwrap(), + path, + escaped_pattern, + )?; + self.trigger(Event::PathForbidden(path.to_path_buf())); + Ok(()) + } + + /// Determines if the given path is allowed on this scope. + pub fn is_allowed>(&self, path: P) -> bool { + let path = path.as_ref(); + let path = if !path.exists() { + crate::Result::Ok(path.to_path_buf()) + } else { + std::fs::canonicalize(path).map_err(Into::into) + }; + + if let Ok(path) = path { + let path: PathBuf = path.components().collect(); + let options = glob::MatchOptions { + // this is needed so `/dir/*` doesn't match files within subdirectories such as `/dir/subdir/file.txt` + // see: https://github.com/tauri-apps/tauri/security/advisories/GHSA-6mv3-wm7j-h4w5 + require_literal_separator: true, + // dotfiles are not supposed to be exposed by default + #[cfg(unix)] + require_literal_leading_dot: true, + ..Default::default() + }; + + let forbidden = self + .forbidden_patterns + .lock() + .unwrap() + .iter() + .any(|p| p.matches_path_with(&path, options)); + + if forbidden { + false + } else { + let allowed = self + .allowed_patterns + .lock() + .unwrap() + .iter() + .any(|p| p.matches_path_with(&path, options)); + allowed + } + } else { + false + } + } +} + +fn escaped_pattern(p: &str) -> Result { + Pattern::new(&glob::Pattern::escape(p)) +} + +fn escaped_pattern_with(p: &str, append: &str) -> Result { + Pattern::new(&format!( + "{}{}{append}", + glob::Pattern::escape(p), + MAIN_SEPARATOR + )) +} + +#[cfg(test)] +mod tests { + use super::Scope; + + fn new_scope() -> Scope { + Scope { + allowed_patterns: Default::default(), + forbidden_patterns: Default::default(), + event_listeners: Default::default(), + } + } + + #[test] + fn path_is_escaped() { + let scope = new_scope(); + #[cfg(unix)] + { + scope.allow_directory("/home/tauri/**", false).unwrap(); + assert!(scope.is_allowed("/home/tauri/**")); + assert!(scope.is_allowed("/home/tauri/**/file")); + assert!(!scope.is_allowed("/home/tauri/anyfile")); + } + #[cfg(windows)] + { + scope.allow_directory("C:\\home\\tauri\\**", false).unwrap(); + assert!(scope.is_allowed("C:\\home\\tauri\\**")); + assert!(scope.is_allowed("C:\\home\\tauri\\**\\file")); + assert!(!scope.is_allowed("C:\\home\\tauri\\anyfile")); + } + + let scope = new_scope(); + #[cfg(unix)] + { + scope.allow_file("/home/tauri/**").unwrap(); + assert!(scope.is_allowed("/home/tauri/**")); + assert!(!scope.is_allowed("/home/tauri/**/file")); + assert!(!scope.is_allowed("/home/tauri/anyfile")); + } + #[cfg(windows)] + { + scope.allow_file("C:\\home\\tauri\\**").unwrap(); + assert!(scope.is_allowed("C:\\home\\tauri\\**")); + assert!(!scope.is_allowed("C:\\home\\tauri\\**\\file")); + assert!(!scope.is_allowed("C:\\home\\tauri\\anyfile")); + } + + let scope = new_scope(); + #[cfg(unix)] + { + scope.allow_directory("/home/tauri", true).unwrap(); + scope.forbid_directory("/home/tauri/**", false).unwrap(); + assert!(!scope.is_allowed("/home/tauri/**")); + assert!(!scope.is_allowed("/home/tauri/**/file")); + assert!(scope.is_allowed("/home/tauri/**/inner/file")); + assert!(scope.is_allowed("/home/tauri/inner/folder/anyfile")); + assert!(scope.is_allowed("/home/tauri/anyfile")); + } + #[cfg(windows)] + { + scope.allow_directory("C:\\home\\tauri", true).unwrap(); + scope + .forbid_directory("C:\\home\\tauri\\**", false) + .unwrap(); + assert!(!scope.is_allowed("C:\\home\\tauri\\**")); + assert!(!scope.is_allowed("C:\\home\\tauri\\**\\file")); + assert!(scope.is_allowed("C:\\home\\tauri\\**\\inner\\file")); + assert!(scope.is_allowed("C:\\home\\tauri\\inner\\folder\\anyfile")); + assert!(scope.is_allowed("C:\\home\\tauri\\anyfile")); + } + + let scope = new_scope(); + #[cfg(unix)] + { + scope.allow_directory("/home/tauri", true).unwrap(); + scope.forbid_file("/home/tauri/**").unwrap(); + assert!(!scope.is_allowed("/home/tauri/**")); + assert!(scope.is_allowed("/home/tauri/**/file")); + assert!(scope.is_allowed("/home/tauri/**/inner/file")); + assert!(scope.is_allowed("/home/tauri/anyfile")); + } + #[cfg(windows)] + { + scope.allow_directory("C:\\home\\tauri", true).unwrap(); + scope.forbid_file("C:\\home\\tauri\\**").unwrap(); + assert!(!scope.is_allowed("C:\\home\\tauri\\**")); + assert!(scope.is_allowed("C:\\home\\tauri\\**\\file")); + assert!(scope.is_allowed("C:\\home\\tauri\\**\\inner\\file")); + assert!(scope.is_allowed("C:\\home\\tauri\\anyfile")); + } + + let scope = new_scope(); + #[cfg(unix)] + { + scope.allow_directory("/home/tauri", false).unwrap(); + assert!(scope.is_allowed("/home/tauri/**")); + assert!(!scope.is_allowed("/home/tauri/**/file")); + assert!(!scope.is_allowed("/home/tauri/**/inner/file")); + assert!(scope.is_allowed("/home/tauri/anyfile")); + } + #[cfg(windows)] + { + scope.allow_directory("C:\\home\\tauri", false).unwrap(); + assert!(scope.is_allowed("C:\\home\\tauri\\**")); + assert!(!scope.is_allowed("C:\\home\\tauri\\**\\file")); + assert!(!scope.is_allowed("C:\\home\\tauri\\**\\inner\\file")); + assert!(scope.is_allowed("C:\\home\\tauri\\anyfile")); + } + } +} diff --git a/plugins/fs-watch/src/lib.rs b/plugins/fs/src/watcher.rs similarity index 60% rename from plugins/fs-watch/src/lib.rs rename to plugins/fs/src/watcher.rs index 3185d148..647342c7 100644 --- a/plugins/fs-watch/src/lib.rs +++ b/plugins/fs/src/watcher.rs @@ -1,11 +1,13 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use notify::{Config, Event, RecommendedWatcher, RecursiveMode, Watcher}; use notify_debouncer_mini::{new_debouncer, DebounceEventResult, Debouncer}; -use serde::{ser::Serializer, Deserialize, Serialize}; -use tauri::{ - command, - plugin::{Builder as PluginBuilder, TauriPlugin}, - Manager, Runtime, State, Window, -}; +use serde::Deserialize; +use tauri::{api::ipc::Channel, command, Runtime, State}; + +use crate::Result; use std::{ collections::HashMap, @@ -18,51 +20,33 @@ use std::{ time::Duration, }; -type Result = std::result::Result; type Id = u32; -#[derive(Debug, thiserror::Error)] -pub enum Error { - #[error(transparent)] - Watch(#[from] notify::Error), -} - -impl Serialize for Error { - fn serialize(&self, serializer: S) -> std::result::Result - where - S: Serializer, - { - serializer.serialize_str(self.to_string().as_ref()) - } -} - #[derive(Default)] -struct WatcherCollection(Mutex)>>); +pub struct WatcherCollection(Mutex)>>); enum WatcherKind { Debouncer(Debouncer), Watcher(RecommendedWatcher), } -fn watch_raw(window: Window, rx: Receiver>, id: Id) { +fn watch_raw(on_event: Channel, rx: Receiver>) { spawn(move || { - let event_name = format!("watcher://raw-event/{id}"); while let Ok(event) = rx.recv() { if let Ok(event) = event { // TODO: Should errors be emitted too? - let _ = window.emit(&event_name, event); + let _ = on_event.send(&event); } } }); } -fn watch_debounced(window: Window, rx: Receiver, id: Id) { +fn watch_debounced(on_event: Channel, rx: Receiver) { spawn(move || { - let event_name = format!("watcher://debounced-event/{id}"); while let Ok(event) = rx.recv() { if let Ok(event) = event { // TODO: Should errors be emitted too? - let _ = window.emit(&event_name, event); + let _ = on_event.send(&event); } } }); @@ -70,18 +54,18 @@ fn watch_debounced(window: Window, rx: Receiver, recursive: bool, } #[command] -async fn watch( - window: Window, +pub async fn watch( watchers: State<'_, WatcherCollection>, id: Id, paths: Vec, options: WatchOptions, + on_event: Channel, ) -> Result<()> { let mode = if options.recursive { RecursiveMode::Recursive @@ -96,7 +80,7 @@ async fn watch( for path in &paths { watcher.watch(path, mode)?; } - watch_debounced(window, rx, id); + watch_debounced(on_event, rx); WatcherKind::Debouncer(debouncer) } else { let (tx, rx) = channel(); @@ -104,7 +88,7 @@ async fn watch( for path in &paths { watcher.watch(path, mode)?; } - watch_raw(window, rx, id); + watch_raw(on_event, rx); WatcherKind::Watcher(watcher) }; @@ -114,7 +98,7 @@ async fn watch( } #[command] -async fn unwatch(watchers: State<'_, WatcherCollection>, id: Id) -> Result<()> { +pub async fn unwatch(watchers: State<'_, WatcherCollection>, id: Id) -> Result<()> { if let Some((watcher, paths)) = watchers.0.lock().unwrap().remove(&id) { match watcher { WatcherKind::Debouncer(mut debouncer) => { @@ -131,13 +115,3 @@ async fn unwatch(watchers: State<'_, WatcherCollection>, id: Id) -> Result<()> { } Ok(()) } - -pub fn init() -> TauriPlugin { - PluginBuilder::new("fs-watch") - .invoke_handler(tauri::generate_handler![watch, unwatch]) - .setup(|app, _api| { - app.manage(WatcherCollection::default()); - Ok(()) - }) - .build() -} diff --git a/plugins/fs/tsconfig.json b/plugins/fs/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/fs/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/fs/tsconfig.json b/plugins/fs/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/fs/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/global-shortcut/CHANGELOG.md b/plugins/global-shortcut/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/global-shortcut/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/global-shortcut/Cargo.toml b/plugins/global-shortcut/Cargo.toml index 84269574..b281d2b0 100644 --- a/plugins/global-shortcut/Cargo.toml +++ b/plugins/global-shortcut/Cargo.toml @@ -1,14 +1,17 @@ [package] name = "tauri-plugin-global-shortcut" -version = "0.0.0" -edition.workspace = true -authors.workspace = true -license.workspace = true +version = "2.0.0-alpha.0" +description = "Register global hotkeys listeners on your Tauri application." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true -global-hotkey = "0.2" +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } + +[target."cfg(not(any(target_os = \"android\", target_os = \"ios\")))".dependencies] +global-hotkey = "0.2.1" diff --git a/plugins/global-shortcut/README.md b/plugins/global-shortcut/README.md index f1611804..7c151730 100644 --- a/plugins/global-shortcut/README.md +++ b/plugins/global-shortcut/README.md @@ -1,10 +1,12 @@ -![plugin-shortcut](banner.jpg) +# Global Shortcut - +Register global shortcuts. + +- Supported platforms: Windows, Linux and macOS. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -17,7 +19,10 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: `src-tauri/Cargo.toml` ```toml -[dependencies] +# you can add the dependencies on the `[dependencies]` section if you do not target mobile +[target."cfg(not(any(target_os = \"android\", target_os = \"ios\")))".dependencies] +tauri-plugin-global-shortcut = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-shortcut = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,11 +31,18 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh -pnpm add https://github.com/tauri-apps/tauri-plugin-shortcut#v2 +pnpm add @tauri-apps/plugin-global-shortcut +# or +npm add @tauri-apps/plugin-global-shortcut +# or +yarn add @tauri-apps/plugin-global-shortcut + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-global-shortcut#v2 # or -npm add https://github.com/tauri-apps/tauri-plugin-shortcut#v2 +npm add https://github.com/tauri-apps/tauri-plugin-global-shortcut#v2 # or -yarn add https://github.com/tauri-apps/tauri-plugin-shortcut#v2 +yarn add https://github.com/tauri-apps/tauri-plugin-global-shortcut#v2 ``` ## Usage @@ -42,7 +54,11 @@ First you need to register the core plugin with Tauri: ```rust fn main() { tauri::Builder::default() - .plugin(tauri_plugin_shortcut::init()) + .setup(|app| { + #[cfg(desktop)] + app.handle().plugin(tauri_plugin_shortcut::init())?; + Ok(()) + }) .run(tauri::generate_context!()) .expect("error while running tauri application"); } diff --git a/plugins/global-shortcut/guest-js/index.ts b/plugins/global-shortcut/guest-js/index.ts index c2c66756..16ef0055 100644 --- a/plugins/global-shortcut/guest-js/index.ts +++ b/plugins/global-shortcut/guest-js/index.ts @@ -5,23 +5,17 @@ /** * Register global shortcuts. * - * The APIs must be added to [`tauri.allowlist.globalShortcut`](https://tauri.app/v1/api/config/#allowlistconfig.globalshortcut) in `tauri.conf.json`: - * ```json - * { - * "tauri": { - * "allowlist": { - * "globalShortcut": { - * "all": true // enable all global shortcut APIs - * } - * } - * } - * } - * ``` - * It is recommended to allowlist only the APIs you use for optimal bundle size and security. * @module */ -import { invoke, transformCallback } from "@tauri-apps/api/tauri"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + __TAURI__: { + transformCallback: (cb: (payload: T) => void) => number; + }; + } +} export type ShortcutHandler = (shortcut: string) => void; @@ -29,7 +23,7 @@ export type ShortcutHandler = (shortcut: string) => void; * Register a global shortcut. * @example * ```typescript - * import { register } from 'tauri-plugin-global-shortcut-api'; + * import { register } from '@tauri-apps/plugin-global-shortcut'; * await register('CommandOrControl+Shift+C', () => { * console.log('Shortcut triggered'); * }); @@ -38,15 +32,15 @@ export type ShortcutHandler = (shortcut: string) => void; * @param shortcut Shortcut definition, modifiers and key separated by "+" e.g. CmdOrControl+Q * @param handler Shortcut handler callback - takes the triggered shortcut as argument * - * @since 1.0.0 + * @since 2.0.0 */ async function register( shortcut: string, handler: ShortcutHandler ): Promise { - return await invoke("plugin:globalShortcut|register", { + return await window.__TAURI_INVOKE__("plugin:globalShortcut|register", { shortcut, - handler: transformCallback(handler), + handler: window.__TAURI__.transformCallback(handler), }); } @@ -54,7 +48,7 @@ async function register( * Register a collection of global shortcuts. * @example * ```typescript - * import { registerAll } from 'tauri-plugin-global-shortcut-api'; + * import { registerAll } from '@tauri-apps/plugin-global-shortcut'; * await registerAll(['CommandOrControl+Shift+C', 'Ctrl+Alt+F12'], (shortcut) => { * console.log(`Shortcut ${shortcut} triggered`); * }); @@ -63,15 +57,15 @@ async function register( * @param shortcuts Array of shortcut definitions, modifiers and key separated by "+" e.g. CmdOrControl+Q * @param handler Shortcut handler callback - takes the triggered shortcut as argument * - * @since 1.0.0 + * @since 2.0.0 */ async function registerAll( shortcuts: string[], handler: ShortcutHandler ): Promise { - return await invoke("plugin:globalShortcut|register_all", { + return await window.__TAURI_INVOKE__("plugin:globalShortcut|register_all", { shortcuts, - handler: transformCallback(handler), + handler: window.__TAURI__.transformCallback(handler), }); } @@ -82,16 +76,16 @@ async function registerAll( * * @example * ```typescript - * import { isRegistered } from 'tauri-plugin-global-shortcut-api'; + * import { isRegistered } from '@tauri-apps/plugin-global-shortcut'; * const isRegistered = await isRegistered('CommandOrControl+P'); * ``` * * @param shortcut shortcut definition, modifiers and key separated by "+" e.g. CmdOrControl+Q * - * @since 1.0.0 + * @since 2.0.0 */ async function isRegistered(shortcut: string): Promise { - return await invoke("plugin:globalShortcut|is_registered", { + return await window.__TAURI_INVOKE__("plugin:globalShortcut|is_registered", { shortcut, }); } @@ -100,16 +94,16 @@ async function isRegistered(shortcut: string): Promise { * Unregister a global shortcut. * @example * ```typescript - * import { unregister } from 'tauri-plugin-global-shortcut-api'; + * import { unregister } from '@tauri-apps/plugin-global-shortcut'; * await unregister('CmdOrControl+Space'); * ``` * * @param shortcut shortcut definition, modifiers and key separated by "+" e.g. CmdOrControl+Q * - * @since 1.0.0 + * @since 2.0.0 */ async function unregister(shortcut: string): Promise { - return await invoke("plugin:globalShortcut|unregister", { + return await window.__TAURI_INVOKE__("plugin:globalShortcut|unregister", { shortcut, }); } @@ -118,14 +112,14 @@ async function unregister(shortcut: string): Promise { * Unregisters all shortcuts registered by the application. * @example * ```typescript - * import { unregisterAll } from 'tauri-plugin-global-shortcut-api'; + * import { unregisterAll } from '@tauri-apps/plugin-global-shortcut'; * await unregisterAll(); * ``` * - * @since 1.0.0 + * @since 2.0.0 */ async function unregisterAll(): Promise { - return await invoke("plugin:globalShortcut|unregister_all"); + return await window.__TAURI_INVOKE__("plugin:globalShortcut|unregister_all"); } export { register, registerAll, isRegistered, unregister, unregisterAll }; diff --git a/plugins/global-shortcut/package.json b/plugins/global-shortcut/package.json index 5b8cf29d..227625c1 100644 --- a/plugins/global-shortcut/package.json +++ b/plugins/global-shortcut/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-global-shortcut-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-global-shortcut", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/global-shortcut/src/api-iife.js b/plugins/global-shortcut/src/api-iife.js new file mode 100644 index 00000000..542aa04f --- /dev/null +++ b/plugins/global-shortcut/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_GLOBALSHORTCUT__=function(_){"use strict";return _.isRegistered=async function(_){return await window.__TAURI_INVOKE__("plugin:globalShortcut|is_registered",{shortcut:_})},_.register=async function(_,t){return await window.__TAURI_INVOKE__("plugin:globalShortcut|register",{shortcut:_,handler:window.__TAURI__.transformCallback(t)})},_.registerAll=async function(_,t){return await window.__TAURI_INVOKE__("plugin:globalShortcut|register_all",{shortcuts:_,handler:window.__TAURI__.transformCallback(t)})},_.unregister=async function(_){return await window.__TAURI_INVOKE__("plugin:globalShortcut|unregister",{shortcut:_})},_.unregisterAll=async function(){return await window.__TAURI_INVOKE__("plugin:globalShortcut|unregister_all")},_}({});Object.defineProperty(window.__TAURI__,"globalShortcut",{value:__TAURI_GLOBALSHORTCUT__})} diff --git a/plugins/global-shortcut/src/error.rs b/plugins/global-shortcut/src/error.rs index f9bf2460..8157000c 100644 --- a/plugins/global-shortcut/src/error.rs +++ b/plugins/global-shortcut/src/error.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use serde::{Serialize, Serializer}; #[derive(Debug, thiserror::Error)] diff --git a/plugins/global-shortcut/src/lib.rs b/plugins/global-shortcut/src/lib.rs index 7c34fc21..86fb28dd 100644 --- a/plugins/global-shortcut/src/lib.rs +++ b/plugins/global-shortcut/src/lib.rs @@ -1,3 +1,9 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +#![cfg(not(any(target_os = "android", target_os = "ios")))] + use std::{ collections::HashMap, str::FromStr, @@ -277,6 +283,7 @@ impl Builder { pub fn build(self) -> TauriPlugin { let handler = self.handler; PluginBuilder::new("globalShortcut") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![ register, register_all, diff --git a/plugins/http/CHANGELOG.md b/plugins/http/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/http/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/http/Cargo.lock b/plugins/http/Cargo.lock deleted file mode 100644 index 21d5e94e..00000000 --- a/plugins/http/Cargo.lock +++ /dev/null @@ -1,3874 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "aho-corasick" -version = "0.7.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" -dependencies = [ - "memchr", -] - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "anyhow" -version = "1.0.70" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7de8ce5e0f9f8d88245311066a578d72b7af3e7088f32783804676302df237e4" - -[[package]] -name = "atk" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39991bc421ddf72f70159011b323ff49b0f783cc676a7287c59453da2e2531cf" -dependencies = [ - "atk-sys", - "bitflags", - "glib", - "libc", -] - -[[package]] -name = "atk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11ad703eb64dc058024f0e57ccfa069e15a413b98dbd50a1a950e743b7f11148" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "base64" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" - -[[package]] -name = "base64" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "block" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" - -[[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 = "brotli" -version = "3.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a0b1dbcc8ae29329621f8d4f0d835787c1c38bb1401979b49d13b0b305ff68" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b6561fd3f895a11e8f72af2cb7d22e08366bebc2b6b57f7744c4bda27034744" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bstr" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d4260bcc2e8fc9df1eac4919a720effeb63a3f0952f5bf4944adfa18897f09" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" - -[[package]] -name = "bytemuck" -version = "1.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17febce684fd15d89027105661fec94afb475cb995fbc59d2865198446ba2eea" - -[[package]] -name = "byteorder" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" - -[[package]] -name = "bytes" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" -dependencies = [ - "serde", -] - -[[package]] -name = "cairo-rs" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3125b15ec28b84c238f6f476c6034016a5f6cc0221cb514ca46c532139fc97d" -dependencies = [ - "bitflags", - "cairo-sys-rs", - "glib", - "libc", - "once_cell", - "thiserror", -] - -[[package]] -name = "cairo-sys-rs" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c48f4af05fabdcfa9658178e1326efa061853f040ce7d72e33af6885196f421" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "cargo_toml" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bfbc36312494041e2cdd5f06697b7e89d4b76f42773a0b5556ac290ff22acc2" -dependencies = [ - "serde", - "toml 0.5.11", -] - -[[package]] -name = "cc" -version = "1.0.79" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" - -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - -[[package]] -name = "cfb" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d38f2da7a0a2c4ccf0065be06397cc26a81f4e528be095826eee9d4adbb8c60f" -dependencies = [ - "byteorder", - "fnv", - "uuid", -] - -[[package]] -name = "cfg-expr" -version = "0.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a35b255461940a32985c627ce82900867c61db1659764d3675ea81963f72a4c6" -dependencies = [ - "smallvec", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "cocoa" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f425db7937052c684daec3bd6375c8abe2d146dca4b8b143d6db777c39138f3a" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation", - "core-graphics", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa-foundation" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "931d3837c286f56e3c58423ce4eba12d08db2374461a785c86f672b08b5650d6" -dependencies = [ - "bitflags", - "block", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "color_quant" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" - -[[package]] -name = "combine" -version = "4.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" - -[[package]] -name = "core-graphics" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" -dependencies = [ - "bitflags", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" -dependencies = [ - "bitflags", - "core-foundation", - "foreign-types", - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "280a9f2d8b3a38871a3c8a46fb80db65e5e5ed97da80c4d08bf27fb63e35e181" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c063cd8cc95f5c377ed0d4b49a4b21f632396ff690e8470c29b3359b346984b" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "cssparser" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "754b69d351cdc2d8ee09ae203db831e005560fc6030da058f86ad60c92a9cb0a" -dependencies = [ - "cssparser-macros", - "dtoa-short", - "itoa 0.4.8", - "matches", - "phf 0.8.0", - "proc-macro2", - "quote", - "smallvec", - "syn 1.0.109", -] - -[[package]] -name = "cssparser-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfae75de57f2b2e85e8768c3ea840fd159c8f33e2b6522c7835b7abac81be16e" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ctor" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d2301688392eb071b0bf1a37be05c469d3cc4dbbd95df672fe28ab021e6a096" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 1.0.109", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "derive_more" -version = "0.99.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version", - "syn 1.0.109", -] - -[[package]] -name = "digest" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dirs-next" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" -dependencies = [ - "cfg-if", - "dirs-sys-next", -] - -[[package]] -name = "dirs-sys-next" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dispatch" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" - -[[package]] -name = "dtoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" - -[[package]] -name = "dtoa-short" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde03329ae10e79ede66c9ce4dc930aa8599043b0743008548680f25b91502d6" -dependencies = [ - "dtoa", -] - -[[package]] -name = "dunce" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bd4b30a6560bbd9b4620f4de34c3f14f60848e58a9b7216801afcb4c7b31c3c" - -[[package]] -name = "embed_plist" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" - -[[package]] -name = "encoding_rs" -version = "0.8.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071a31f4ee85403370b58aca746f01041ede6f0da2730960ad001edc2b71b394" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "errno" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bcfec3a70f97c962c307b2d2c56e358cf1d00b558d74262b5f929ee8cc7e73a" -dependencies = [ - "errno-dragonfly", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "errno-dragonfly" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" -dependencies = [ - "cc", - "libc", -] - -[[package]] -name = "fastrand" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" -dependencies = [ - "instant", -] - -[[package]] -name = "fdeflate" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d329bdeac514ee06249dabc27877490f17f5d371ec693360768b838e19f3ae10" -dependencies = [ - "simd-adler32", -] - -[[package]] -name = "field-offset" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3cf3a800ff6e860c863ca6d4b16fd999db8b752819c1606884047b73e468535" -dependencies = [ - "memoffset", - "rustc_version", -] - -[[package]] -name = "filetime" -version = "0.2.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cbc844cecaee9d4443931972e1289c8ff485cb4cc2767cb03ca139ed6885153" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.2.16", - "windows-sys 0.48.0", -] - -[[package]] -name = "flate2" -version = "1.0.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" -dependencies = [ - "crc32fast", - "miniz_oxide 0.6.2", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futf" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df420e2e84819663797d1ec6544b13c5be84629e7bb00dc960d6917db2987843" -dependencies = [ - "mac", - "new_debug_unreachable", -] - -[[package]] -name = "futures-channel" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" -dependencies = [ - "futures-core", -] - -[[package]] -name = "futures-core" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" - -[[package]] -name = "futures-executor" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" - -[[package]] -name = "futures-macro" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "futures-sink" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" - -[[package]] -name = "futures-task" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" - -[[package]] -name = "futures-util" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" -dependencies = [ - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "fxhash" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" -dependencies = [ - "byteorder", -] - -[[package]] -name = "gdk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa9cb33da481c6c040404a11f8212d193889e9b435db2c14fd86987f630d3ce1" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk-pixbuf", - "gdk-sys", - "gio", - "glib", - "libc", - "pango", -] - -[[package]] -name = "gdk-pixbuf" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3578c60dee9d029ad86593ed88cb40f35c1b83360e12498d055022385dd9a05" -dependencies = [ - "bitflags", - "gdk-pixbuf-sys", - "gio", - "glib", - "libc", -] - -[[package]] -name = "gdk-pixbuf-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3092cf797a5f1210479ea38070d9ae8a5b8e9f8f1be9f32f4643c529c7d70016" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gdk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d76354f97a913e55b984759a997b693aa7dc71068c9e98bcce51aa167a0a5c5a" -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.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4511710212ed3020b61a8622a37aa6f0dd2a84516575da92e9b96928dcbe83ba" -dependencies = [ - "gdk-sys", - "glib-sys", - "gobject-sys", - "libc", - "pkg-config", - "system-deps", -] - -[[package]] -name = "gdkx11-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fa2bf8b5b8c414bc5d05e48b271896d0fd3ddb57464a3108438082da61de6af" -dependencies = [ - "gdk-sys", - "glib-sys", - "libc", - "system-deps", - "x11", -] - -[[package]] -name = "generator" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33a20a288a94683f5f4da0adecdbe095c94a77c295e514cc6484e9394dd8376e" -dependencies = [ - "cc", - "libc", - "log", - "rustversion", - "windows", -] - -[[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.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c85e1d9ab2eadba7e5040d4e09cbd6d072b76a557ad64e797c2cb9d4da21d7e4" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gio" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a1c84b4534a290a29160ef5c6eff2a9c95833111472e824fc5cb78b513dd092" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-io", - "futures-util", - "gio-sys", - "glib", - "libc", - "once_cell", - "pin-project-lite", - "smallvec", - "thiserror", -] - -[[package]] -name = "gio-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e9b693b8e39d042a95547fc258a7b07349b1f0b48f4b2fa3108ba3c51c0b5229" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", - "winapi", -] - -[[package]] -name = "glib" -version = "0.16.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddd4df61a866ed7259d6189b8bcb1464989a77f1d85d25d002279bbe9dd38b2f" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-executor", - "futures-task", - "futures-util", - "gio-sys", - "glib-macros", - "glib-sys", - "gobject-sys", - "libc", - "once_cell", - "smallvec", - "thiserror", -] - -[[package]] -name = "glib-macros" -version = "0.16.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb1a9325847aa46f1e96ffea37611b9d51fc4827e67f79e7de502a297560a67b" -dependencies = [ - "anyhow", - "heck", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "glib-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c61a4f46316d06bfa33a7ac22df6f0524c8be58e3db2d9ca99ccb1f357b62a65" -dependencies = [ - "libc", - "system-deps", -] - -[[package]] -name = "glob" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" - -[[package]] -name = "globset" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "029d74589adefde59de1a0c4f4732695c32805624aec7b68d91503d4dba79afc" -dependencies = [ - "aho-corasick", - "bstr", - "fnv", - "log", - "regex", -] - -[[package]] -name = "gobject-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3520bb9c07ae2a12c7f2fbb24d4efc11231c8146a86956413fb1a79bb760a0f1" -dependencies = [ - "glib-sys", - "libc", - "system-deps", -] - -[[package]] -name = "gtk" -version = "0.16.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4d3507d43908c866c805f74c9dd593c0ce7ba5c38e576e41846639cdcd4bee6" -dependencies = [ - "atk", - "bitflags", - "cairo-rs", - "field-offset", - "futures-channel", - "gdk", - "gdk-pixbuf", - "gio", - "glib", - "gtk-sys", - "gtk3-macros", - "libc", - "once_cell", - "pango", - "pkg-config", -] - -[[package]] -name = "gtk-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89b5f8946685d5fe44497007786600c2f368ff6b1e61a16251c89f72a97520a3" -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.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "096eb63c6fedf03bafe65e5924595785eaf1bcb7200dac0f2cbe9c9738f05ad8" -dependencies = [ - "anyhow", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "h2" -version = "0.3.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17f8a914c2987b688368b5138aa05321db91f4090cf26118185672ad588bce21" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" - -[[package]] -name = "hermit-abi" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286" - -[[package]] -name = "html5ever" -version = "0.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c13fb08e5d4dfc151ee5e88bae63f7773d61852f3bdc73c9f4b9e1bde03148" -dependencies = [ - "log", - "mac", - "markup5ever", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "http" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" -dependencies = [ - "bytes", - "fnv", - "itoa 1.0.6", -] - -[[package]] -name = "http-body" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" -dependencies = [ - "bytes", - "http", - "pin-project-lite", -] - -[[package]] -name = "http-range" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21dec9db110f5f872ed9699c3ecf50cf16f423502706ba5c72462e28d3157573" - -[[package]] -name = "httparse" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" - -[[package]] -name = "httpdate" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" - -[[package]] -name = "hyper" -version = "0.14.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab302d72a6f11a3b910431ff93aae7e773078c769f0a3ef15fb9ec692ed147d4" -dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "httpdate", - "itoa 1.0.6", - "pin-project-lite", - "socket2", - "tokio", - "tower-service", - "tracing", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.23.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1788965e61b367cd03a62950836d5cd41560c3577d90e40e0819373194d1661c" -dependencies = [ - "http", - "hyper", - "rustls", - "tokio", - "tokio-rustls", -] - -[[package]] -name = "hyper-tls" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" -dependencies = [ - "bytes", - "hyper", - "native-tls", - "tokio", - "tokio-native-tls", -] - -[[package]] -name = "ico" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3804960be0bb5e4edb1e1ad67afd321a9ecfd875c3e65c099468fd2717d7cae" -dependencies = [ - "byteorder", - "png", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe7873dab538a9a44ad79ede1faf5f30d49f9a5c883ddbab48bce81b64b7492" -dependencies = [ - "globset", - "lazy_static", - "log", - "memchr", - "regex", - "same-file", - "thread_local", - "walkdir", - "winapi-util", -] - -[[package]] -name = "image" -version = "0.24.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "527909aa81e20ac3a44803521443a765550f09b5130c2c2fa1ea59c2f8f50a3a" -dependencies = [ - "bytemuck", - "byteorder", - "color_quant", - "num-rational", - "num-traits", -] - -[[package]] -name = "indexmap" -version = "1.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown", -] - -[[package]] -name = "infer" -version = "0.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a898e4b7951673fce96614ce5751d13c40fc5674bc2d759288e46c3ab62598b3" -dependencies = [ - "cfb", -] - -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "io-lifetimes" -version = "1.0.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c66c74d2ae7e79a5a8f7ac924adbe38ee42a859c6539ad869eb51f0b52dc220" -dependencies = [ - "hermit-abi 0.3.1", - "libc", - "windows-sys 0.48.0", -] - -[[package]] -name = "ipnet" -version = "2.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12b6ee2129af8d4fb011108c73d99a1b83a85977f23b82460c0ae2e25bb4b57f" - -[[package]] -name = "itoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4" - -[[package]] -name = "itoa" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "453ad9f582a441959e5f0d088b02ce04cfe8d51a8eaf077f12ac6d3e94164ca6" - -[[package]] -name = "javascriptcore-rs" -version = "0.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "110b9902c80c12bf113c432d0b71c7a94490b294a8234f326fd0abca2fac0b00" -dependencies = [ - "bitflags", - "glib", - "javascriptcore-rs-sys", -] - -[[package]] -name = "javascriptcore-rs-sys" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98a216519a52cd941a733a0ad3f1023cfdb1cd47f3955e8e863ed56f558f916c" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "jni" -version = "0.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039022cdf4d7b1cf548d31f60ae783138e5fd42013f6271049d7df7afadef96c" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - -[[package]] -name = "jni-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" - -[[package]] -name = "js-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "json-patch" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e712e62827c382a77b87f590532febb1f8b2fdbc3eefa1ee37fe7281687075ef" -dependencies = [ - "serde", - "serde_json", - "thiserror", - "treediff", -] - -[[package]] -name = "kuchiki" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ea8e9c6e031377cff82ee3001dc8026cdf431ed4e2e6b51f98ab8c73484a358" -dependencies = [ - "cssparser", - "html5ever", - "matches", - "selectors", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.141" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3304a64d199bb964be99741b7a14d26972741915b3649639149b2479bb46f4b5" - -[[package]] -name = "line-wrap" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30344350a2a51da54c1d53be93fade8a237e545dbcc4bdbe635413f2117cab9" -dependencies = [ - "safemem", -] - -[[package]] -name = "linux-raw-sys" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f508063cc7bb32987c71511216bd5a32be15bccb6a80b52df8b9d7f01fc3aa2" - -[[package]] -name = "lock_api" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "loom" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff50ecb28bb86013e935fb6683ab1f6d3a20016f123c76fd4c27470076ac30f5" -dependencies = [ - "cfg-if", - "generator", - "scoped-tls", - "serde", - "serde_json", - "tracing", - "tracing-subscriber", -] - -[[package]] -name = "mac" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4" - -[[package]] -name = "malloc_buf" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb" -dependencies = [ - "libc", -] - -[[package]] -name = "markup5ever" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a24f40fb03852d1cdd84330cddcaf98e9ec08a7b7768e952fad3b4cf048ec8fd" -dependencies = [ - "log", - "phf 0.8.0", - "phf_codegen", - "string_cache", - "string_cache_codegen", - "tendril", -] - -[[package]] -name = "matchers" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" -dependencies = [ - "regex-automata", -] - -[[package]] -name = "matches" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "memoffset" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d61c719bcfbcf5d62b3a09efa6088de8c54bc0bfcd3ea7ae39fcc186108b8de1" -dependencies = [ - "autocfg", -] - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "mime_guess" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4192263c238a5f0d0c6bfd21f336a313a4ce1c450542449ca191bb657b4642ef" -dependencies = [ - "mime", - "unicase", -] - -[[package]] -name = "miniz_oxide" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" -dependencies = [ - "adler", -] - -[[package]] -name = "miniz_oxide" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" -dependencies = [ - "adler", - "simd-adler32", -] - -[[package]] -name = "mio" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b9d9a46eff5b4ff64b45a9e316a6d1e0bc719ef429cbec4dc630684212bfdf9" -dependencies = [ - "libc", - "log", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.45.0", -] - -[[package]] -name = "native-tls" -version = "0.2.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07226173c32f2926027b63cce4bcd8076c3552846cbe7925f3aaffeac0a3b92e" -dependencies = [ - "lazy_static", - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "ndk" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2032c77e030ddee34a6787a64166008da93f6a352b629261d0fee232b8742dd4" -dependencies = [ - "bitflags", - "jni-sys", - "ndk-sys", - "num_enum", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5a6ae77c8ee183dcbbba6150e2e6b9f3f4196a7666c02a715a95692ec1fa97" -dependencies = [ - "jni-sys", -] - -[[package]] -name = "new_debug_unreachable" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" - -[[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] -name = "nu-ansi-term" -version = "0.46.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" -dependencies = [ - "overload", - "winapi", -] - -[[package]] -name = "num-integer" -version = "0.1.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b" -dependencies = [ - "hermit-abi 0.2.6", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" -dependencies = [ - "num_enum_derive", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "objc" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1" -dependencies = [ - "malloc_buf", - "objc_exception", -] - -[[package]] -name = "objc_exception" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad970fb455818ad6cba4c122ad012fae53ae8b4795f86378bce65e4f6bab2ca4" -dependencies = [ - "cc", -] - -[[package]] -name = "objc_id" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b" -dependencies = [ - "objc", -] - -[[package]] -name = "once_cell" -version = "1.17.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7e5500299e16ebb147ae15a00a942af264cf3688f47923b8fc2cd5858f23ad3" - -[[package]] -name = "openssl" -version = "0.10.50" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e30d8bc91859781f0a943411186324d580f2bbeb71b452fe91ae344806af3f1" -dependencies = [ - "bitflags", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "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.15", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-src" -version = "111.25.2+1.1.1t" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "320708a054ad9b3bf314688b5db87cf4d6683d64cfc835e2337924ae62bf4431" -dependencies = [ - "cc", -] - -[[package]] -name = "openssl-sys" -version = "0.9.85" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d3d193fb1488ad46ffe3aaabc912cc931d02ee8518fe2959aea8ef52718b0c0" -dependencies = [ - "cc", - "libc", - "openssl-src", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "overload" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" - -[[package]] -name = "pango" -version = "0.16.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdff66b271861037b89d028656184059e03b0b6ccb36003820be19f7200b1e94" -dependencies = [ - "bitflags", - "gio", - "glib", - "libc", - "once_cell", - "pango-sys", -] - -[[package]] -name = "pango-sys" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e134909a9a293e04d2cc31928aa95679c5e4df954d0b85483159bd20d8f047f" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9069cbb9f99e3a5083476ccb29ceb1de18b9118cafa53e90c9551235de2b9521" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.2.16", - "smallvec", - "windows-sys 0.45.0", -] - -[[package]] -name = "percent-encoding" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" - -[[package]] -name = "phf" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dfb61232e34fcb633f43d12c58f83c1df82962dcdfa565a4e866ffc17dafe12" -dependencies = [ - "phf_macros 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", -] - -[[package]] -name = "phf" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259" -dependencies = [ - "phf_macros 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", -] - -[[package]] -name = "phf_codegen" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbffee61585b0411840d3ece935cce9cb6321f01c45477d30066498cd5e1a815" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", -] - -[[package]] -name = "phf_generator" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17367f0cc86f2d25802b2c26ee58a7b23faeccf78a396094c13dced0d0182526" -dependencies = [ - "phf_shared 0.8.0", - "rand 0.7.3", -] - -[[package]] -name = "phf_generator" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d5285893bb5eb82e6aaf5d59ee909a06a16737a8970984dd7746ba9283498d6" -dependencies = [ - "phf_shared 0.10.0", - "rand 0.8.5", -] - -[[package]] -name = "phf_macros" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6fde18ff429ffc8fe78e2bf7f8b7a5a5a6e2a8b58bc5a9ac69198bbda9189c" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "phf_macros" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fdf3184dd560f160dd73922bea2d5cd6e8f064bf4b13110abd81b03697b4e0" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "phf_shared" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c00cf8b9eafe68dde5e9eaa2cef8ee84a9336a47d566ec55ca16589633b65af7" -dependencies = [ - "siphasher", -] - -[[package]] -name = "phf_shared" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" - -[[package]] -name = "plist" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bd9647b268a3d3e14ff09c23201133a62589c658db02bb7388c7246aafe0590" -dependencies = [ - "base64 0.21.0", - "indexmap", - "line-wrap", - "quick-xml", - "serde", - "time", -] - -[[package]] -name = "png" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aaeebc51f9e7d2c150d3f3bfeb667f2aa985db5ef1e3d212847bdedb488beeaa" -dependencies = [ - "bitflags", - "crc32fast", - "fdeflate", - "flate2", - "miniz_oxide 0.7.1", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[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", -] - -[[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-macro-hack" -version = "0.5.20+deprecated" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" - -[[package]] -name = "proc-macro2" -version = "1.0.56" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b63bdb0cd06f1f4dedf69b254734f9b45af66e4a031e42a7480257d9898b435" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quick-xml" -version = "0.28.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ce5e73202a820a31f8a0ee32ada5e21029c81fd9e3ebf668a40832e4219d9d1" -dependencies = [ - "memchr", -] - -[[package]] -name = "quote" -version = "1.0.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4424af4bf778aae2051a77b60283332f386554255d722233d09fbfc7e30da2fc" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", - "rand_pcg", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.9", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_pcg" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "raw-window-handle" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2ff9a1f06a88b01621b7ae906ef0211290d1c8a168a15542486a8f61c0833b9" - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_syscall" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.9", - "redox_syscall 0.2.16", - "thiserror", -] - -[[package]] -name = "regex" -version = "1.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b1f693b24f6ac912f4893ef08244d70b6067480d2f1a46e950c9691e6749d1d" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" - -[[package]] -name = "reqwest" -version = "0.11.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27b71749df584b7f4cac2c426c127a7c785a5106cc98f7a8feb044115f0fa254" -dependencies = [ - "base64 0.21.0", - "bytes", - "encoding_rs", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "hyper", - "hyper-rustls", - "hyper-tls", - "ipnet", - "js-sys", - "log", - "mime", - "mime_guess", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "tokio", - "tokio-native-tls", - "tokio-rustls", - "tokio-util", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "wasm-streams", - "web-sys", - "webpki-roots", - "winreg", -] - -[[package]] -name = "ring" -version = "0.16.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" -dependencies = [ - "cc", - "libc", - "once_cell", - "spin", - "untrusted", - "web-sys", - "winapi", -] - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.37.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "722529a737f5a942fdbac3a46cee213053196737c5eaa3386d52e85b786f2659" -dependencies = [ - "bitflags", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys", - "windows-sys 0.48.0", -] - -[[package]] -name = "rustls" -version = "0.20.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fff78fc74d175294f4e83b28343315ffcfb114b156f0185e9741cb5570f50e2f" -dependencies = [ - "log", - "ring", - "sct", - "webpki", -] - -[[package]] -name = "rustls-pemfile" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d194b56d58803a43635bdc398cd17e383d6f71f9182b9a192c127ca42494a59b" -dependencies = [ - "base64 0.21.0", -] - -[[package]] -name = "rustversion" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f3208ce4d8448b3f3e7d168a73f5e0c43a61e32930de3bceeccedb388b6bf06" - -[[package]] -name = "ryu" -version = "1.0.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91339c0467de62360649f8d3e185ca8de4224ff281f66000de5eb2a77a79041" - -[[package]] -name = "safemem" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef703b7cb59335eae2eb93ceb664c0eb7ea6bf567079d843e09420219668e072" - -[[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.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "713cfb06c7059f3588fb8044c0fad1d09e3c01d225e25b9220dbfdcf16dbb1b3" -dependencies = [ - "windows-sys 0.42.0", -] - -[[package]] -name = "scoped-tls" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" - -[[package]] -name = "scopeguard" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "sct" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d53dcdb7c9f8158937a7981b48accfd39a43af418591a5d008c7b22b5e1b7ca4" -dependencies = [ - "ring", - "untrusted", -] - -[[package]] -name = "security-framework" -version = "2.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a332be01508d814fed64bf28f798a146d73792121129962fdf335bb3c49a4254" -dependencies = [ - "bitflags", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31c9bb296072e961fcbd8853511dd39c2d8be2deb1e17c6860b1d30732b323b4" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "selectors" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df320f1889ac4ba6bc0cdc9c9af7af4bd64bb927bccdf32d81140dc1f9be12fe" -dependencies = [ - "bitflags", - "cssparser", - "derive_more", - "fxhash", - "log", - "matches", - "phf 0.8.0", - "phf_codegen", - "precomputed-hash", - "servo_arc", - "smallvec", - "thin-slice", -] - -[[package]] -name = "semver" -version = "1.0.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bebd363326d05ec3e2f532ab7660680f3b02130d780c299bca73469d521bc0ed" -dependencies = [ - "serde", -] - -[[package]] -name = "serde" -version = "1.0.160" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb2f3770c8bce3bcda7e149193a069a0f4365bda1fa5cd88e03bca26afc1216c" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.160" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291a097c63d8497e00160b166a967a4a79c64f3facdd01cbd7502231688d77df" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "serde_json" -version = "1.0.96" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "057d394a50403bcac12672b2b18fb387ab6d289d957dab67dd201875391e52f1" -dependencies = [ - "itoa 1.0.6", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcec881020c684085e55a25f7fd888954d56609ef363479dc5a1305eb0d40cab" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "serde_spanned" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0efd8caf556a6cebd3b285caf480045fcc1ac04f6bd786b09a6f11af30c4fcf4" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa 1.0.6", - "ryu", - "serde", -] - -[[package]] -name = "serde_with" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" -dependencies = [ - "serde", - "serde_with_macros", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "serialize-to-javascript" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9823f2d3b6a81d98228151fdeaf848206a7855a7a042bbf9bf870449a66cafb" -dependencies = [ - "serde", - "serde_json", - "serialize-to-javascript-impl", -] - -[[package]] -name = "serialize-to-javascript-impl" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74064874e9f6a15f04c1f3cb627902d0e6b410abbf36668afa873c61889f1763" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "servo_arc" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d98238b800e0d1576d8b6e3de32827c2d74bee68bb97748dcf5071fb53965432" -dependencies = [ - "nodrop", - "stable_deref_trait", -] - -[[package]] -name = "sha2" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sharded-slab" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31" -dependencies = [ - "lazy_static", -] - -[[package]] -name = "simd-adler32" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "238abfbb77c1915110ad968465608b68e869e0772622c9656714e73e5a1a522f" - -[[package]] -name = "siphasher" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de" - -[[package]] -name = "slab" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6528351c9bc8ab22353f9d776db39a20288e8d6c37ef8cfe3317cf875eecfc2d" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" - -[[package]] -name = "socket2" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "soup3" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82bc46048125fefd69d30b32b9d263d6556c9ffe82a7a7df181a86d912da5616" -dependencies = [ - "bitflags", - "futures-channel", - "gio", - "glib", - "libc", - "once_cell", - "soup3-sys", -] - -[[package]] -name = "soup3-sys" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "014bbeb1c4cdb30739dc181e8d98b7908f124d9555843afa89b5570aaf4ec62b" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps", -] - -[[package]] -name = "spin" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" - -[[package]] -name = "stable_deref_trait" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" - -[[package]] -name = "state" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe866e1e51e8260c9eed836a042a5e7f6726bb2b411dffeaa712e19c388f23b" -dependencies = [ - "loom", -] - -[[package]] -name = "string_cache" -version = "0.8.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f91138e76242f575eb1d3b38b4f1362f10d3a43f47d182a5b359af488a02293b" -dependencies = [ - "new_debug_unreachable", - "once_cell", - "parking_lot", - "phf_shared 0.10.0", - "precomputed-hash", - "serde", -] - -[[package]] -name = "string_cache_codegen" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bb30289b722be4ff74a408c3cc27edeaad656e06cb1fe8fa9231fa59c728988" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro2", - "quote", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "swift-rs" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05e51d6f2b5fff4808614f429f8a7655ac8bcfe218185413f3a60c508482c2d6" -dependencies = [ - "base64 0.21.0", - "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", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a34fcf3e8b60f57e6a14301a2e916d323af98b0ea63c599441eec8558660c822" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-deps" -version = "6.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "555fc8147af6256f3931a36bb83ad0023240ce9cf2b319dec8236fd1f220b05f" -dependencies = [ - "cfg-expr", - "heck", - "pkg-config", - "toml 0.7.3", - "version-compare", -] - -[[package]] -name = "tao" -version = "0.18.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f2340617d383561b0ea25358b97ec2c2ba04db48c458ce71dd1b38d7fd09ac5" -dependencies = [ - "bitflags", - "cairo-rs", - "cc", - "cocoa", - "core-foundation", - "core-graphics", - "crossbeam-channel", - "dispatch", - "gdk", - "gdk-pixbuf", - "gdk-sys", - "gdkwayland-sys", - "gdkx11-sys", - "gio", - "glib", - "glib-sys", - "gtk", - "image", - "instant", - "jni", - "lazy_static", - "libc", - "log", - "ndk", - "ndk-context", - "ndk-sys", - "objc", - "once_cell", - "parking_lot", - "png", - "raw-window-handle", - "scopeguard", - "serde", - "tao-macros", - "unicode-segmentation", - "uuid", - "windows", - "windows-implement", - "x11-dl", -] - -[[package]] -name = "tao-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b27a4bcc5eb524658234589bdffc7e7bfb996dbae6ce9393bfd39cb4159b445" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "tar" -version = "0.4.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b55807c0344e1e6c04d7c965f5289c39a8d94ae23ed5c0b57aabac549f871c6" -dependencies = [ - "filetime", - "libc", - "xattr", -] - -[[package]] -name = "tauri" -version = "2.0.0-alpha.8" -source = "git+https://github.com/tauri-apps/tauri?branch=next#2d5378bfc1ba817ee2f331b41738a90e5997e5e8" -dependencies = [ - "anyhow", - "bytes", - "cocoa", - "dirs-next", - "embed_plist", - "encoding_rs", - "flate2", - "futures-util", - "glib", - "glob", - "gtk", - "heck", - "http", - "ignore", - "jni", - "libc", - "log", - "objc", - "once_cell", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "reqwest", - "semver", - "serde", - "serde_json", - "serde_repr", - "serialize-to-javascript", - "state", - "swift-rs", - "tar", - "tauri-build", - "tauri-macros", - "tauri-runtime", - "tauri-runtime-wry", - "tauri-utils", - "tempfile", - "thiserror", - "tokio", - "url", - "uuid", - "webkit2gtk", - "webview2-com", - "windows", -] - -[[package]] -name = "tauri-build" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#2d5378bfc1ba817ee2f331b41738a90e5997e5e8" -dependencies = [ - "anyhow", - "cargo_toml", - "filetime", - "heck", - "json-patch", - "semver", - "serde", - "serde_json", - "swift-rs", - "tauri-utils", - "tauri-winres", - "walkdir", -] - -[[package]] -name = "tauri-codegen" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#2d5378bfc1ba817ee2f331b41738a90e5997e5e8" -dependencies = [ - "base64 0.21.0", - "brotli", - "ico", - "json-patch", - "plist", - "png", - "proc-macro2", - "quote", - "semver", - "serde", - "serde_json", - "sha2", - "tauri-utils", - "thiserror", - "time", - "url", - "uuid", - "walkdir", -] - -[[package]] -name = "tauri-macros" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#2d5378bfc1ba817ee2f331b41738a90e5997e5e8" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn 1.0.109", - "tauri-codegen", - "tauri-utils", -] - -[[package]] -name = "tauri-plugin-http" -version = "0.1.0" -dependencies = [ - "bytes", - "glob", - "http", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "tauri", - "thiserror", -] - -[[package]] -name = "tauri-runtime" -version = "0.13.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#2d5378bfc1ba817ee2f331b41738a90e5997e5e8" -dependencies = [ - "gtk", - "http", - "http-range", - "jni", - "rand 0.8.5", - "raw-window-handle", - "serde", - "serde_json", - "tauri-utils", - "thiserror", - "url", - "uuid", - "webview2-com", - "windows", -] - -[[package]] -name = "tauri-runtime-wry" -version = "0.13.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#2d5378bfc1ba817ee2f331b41738a90e5997e5e8" -dependencies = [ - "cocoa", - "gtk", - "jni", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "tauri-runtime", - "tauri-utils", - "uuid", - "webkit2gtk", - "webview2-com", - "windows", - "wry", -] - -[[package]] -name = "tauri-utils" -version = "2.0.0-alpha.4" -source = "git+https://github.com/tauri-apps/tauri?branch=next#2d5378bfc1ba817ee2f331b41738a90e5997e5e8" -dependencies = [ - "brotli", - "ctor", - "glob", - "heck", - "html5ever", - "infer", - "json-patch", - "kuchiki", - "memchr", - "phf 0.10.1", - "proc-macro2", - "quote", - "semver", - "serde", - "serde_json", - "serde_with", - "thiserror", - "url", - "walkdir", - "windows", -] - -[[package]] -name = "tauri-winres" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b7a78dc04f75fb5ab815e66ac561c81e92a968a40f29e7c21afd152d694fad8" -dependencies = [ - "toml 0.5.11", - "version_check", -] - -[[package]] -name = "tempfile" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9fbec84f381d5795b08656e4912bec604d162bff9291d6189a78f4c8ab87998" -dependencies = [ - "cfg-if", - "fastrand", - "redox_syscall 0.3.5", - "rustix", - "windows-sys 0.45.0", -] - -[[package]] -name = "tendril" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d24a120c5fc464a3458240ee02c299ebcb9d67b5249c8848b09d639dca8d7bb0" -dependencies = [ - "futf", - "mac", - "utf-8", -] - -[[package]] -name = "thin-slice" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c" - -[[package]] -name = "thiserror" -version = "1.0.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "978c9a314bd8dc99be594bc3c175faaa9794be04a5a5e153caba6915336cebac" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9456a42c5b0d803c8cd86e73dd7cc9edd429499f37a3550d286d5e86720569f" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.15", -] - -[[package]] -name = "thread_local" -version = "1.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdd6f064ccff2d6567adcb3873ca630700f00b5ad3f060c25b5dcfd9a4ce152" -dependencies = [ - "cfg-if", - "once_cell", -] - -[[package]] -name = "time" -version = "0.3.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd0cbfecb4d19b5ea75bb31ad904eb5b9fa13f21079c3b92017ebdf4999a5890" -dependencies = [ - "itoa 1.0.6", - "serde", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd" - -[[package]] -name = "time-macros" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd80a657e71da814b8e5d60d3374fc6d35045062245d80224748ae522dd76f36" -dependencies = [ - "time-core", -] - -[[package]] -name = "tinyvec" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.27.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0de47a4eecbe11f498978a9b29d792f0d2692d1dd003650c24c76510e3bc001" -dependencies = [ - "autocfg", - "bytes", - "libc", - "mio", - "num_cpus", - "pin-project-lite", - "socket2", - "windows-sys 0.45.0", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.23.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c43ee83903113e03984cb9e5cebe6c04a5116269e900e3ddba8f068a62adda59" -dependencies = [ - "rustls", - "tokio", - "webpki", -] - -[[package]] -name = "tokio-util" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5427d89453009325de0d8f342c9490009f76e999cb7672d77e46267448f7e6b2" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", - "tracing", -] - -[[package]] -name = "toml" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" -dependencies = [ - "serde", -] - -[[package]] -name = "toml" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b403acf6f2bb0859c93c7f0d967cb4a75a7ac552100f9322faf64dc047669b21" -dependencies = [ - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab8ed2edee10b50132aed5f331333428b011c99402b5a534154ed15746f9622" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.19.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "239410c8609e8125456927e6707163a3b1fdb40561e4b803bc041f466ccfdc13" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" -dependencies = [ - "cfg-if", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "tracing-core" -version = "0.1.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" -dependencies = [ - "once_cell", - "valuable", -] - -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - -[[package]] -name = "tracing-subscriber" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6176eae26dd70d0c919749377897b54a9276bd7061339665dd68777926b5a70" -dependencies = [ - "matchers", - "nu-ansi-term", - "once_cell", - "regex", - "sharded-slab", - "smallvec", - "thread_local", - "tracing", - "tracing-core", - "tracing-log", -] - -[[package]] -name = "treediff" -version = "4.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52984d277bdf2a751072b5df30ec0377febdb02f7696d64c2d7d54630bac4303" -dependencies = [ - "serde_json", -] - -[[package]] -name = "try-lock" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" - -[[package]] -name = "typenum" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" - -[[package]] -name = "unicase" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "50f37be617794602aabbeee0be4f259dc1778fabe05e2d67ee8f79326d5cb4f6" -dependencies = [ - "version_check", -] - -[[package]] -name = "unicode-bidi" -version = "0.3.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" - -[[package]] -name = "unicode-ident" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5464a87b239f13a63a501f2701565754bae92d243d4bb7eb12f6d57d2269bf4" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - -[[package]] -name = "untrusted" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" - -[[package]] -name = "url" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", - "serde", -] - -[[package]] -name = "utf-8" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" - -[[package]] -name = "uuid" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b55a3fef2a1e3b3a00ce878640918820d3c51081576ac657d23af9fc7928fdb" -dependencies = [ - "getrandom 0.2.9", -] - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[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.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "579a42fc0b8e0c63b76519a339be31bed574929511fa53c1a3acae26eb258f29" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36df944cda56c7d8d8b7496af378e6b16de9284591917d307c9b4d313c44e698" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" -dependencies = [ - "log", - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn 1.0.109", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f219e0d211ba40266969f6dbdd90636da12f75bee4fc9d6c23d1260dadb51454" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.84" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" - -[[package]] -name = "wasm-streams" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bbae3363c08332cadccd13b67db371814cd214c2524020932f0804b8cf7c078" -dependencies = [ - "futures-util", - "js-sys", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", -] - -[[package]] -name = "web-sys" -version = "0.3.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "webkit2gtk" -version = "0.19.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8eea819afe15eb8dcdff4f19d8bfda540bae84d874c10e6f4b8faf2d6704bd1" -dependencies = [ - "bitflags", - "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 = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0ac7a95ddd3fdfcaf83d8e513b4b1ad101b95b413b6aa6662ed95f284fc3d5b" -dependencies = [ - "bitflags", - "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" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f095d78192e208183081cc07bc5515ef55216397af48b873e5edcd72637fa1bd" -dependencies = [ - "ring", - "untrusted", -] - -[[package]] -name = "webpki-roots" -version = "0.22.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c71e40d7d2c34a5106301fb632274ca37242cd0c9d3e64dbece371a40a2d87" -dependencies = [ - "webpki", -] - -[[package]] -name = "webview2-com" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11296e5daf3a653b79bf47d66c380e4143d5b9c975818871179a3bda79499562" -dependencies = [ - "webview2-com-macros", - "webview2-com-sys", - "windows", - "windows-implement", -] - -[[package]] -name = "webview2-com-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaebe196c01691db62e9e4ca52c5ef1e4fd837dcae27dae3ada599b5a8fd05ac" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "webview2-com-sys" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cde542bed28058a5b028d459689ee57f1d06685bb6c266da3b91b1be6703952f" -dependencies = [ - "regex", - "serde", - "serde_json", - "thiserror", - "windows", - "windows-bindgen", - "windows-metadata", -] - -[[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.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi", -] - -[[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 = "windows" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e745dab35a0c4c77aa3ce42d595e13d2003d6902d6b08c9ef5fc326d08da12b" -dependencies = [ - "windows-implement", - "windows-interface", - "windows-targets 0.42.2", -] - -[[package]] -name = "windows-bindgen" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "222204ecf46521382a4d88b4a1bbefca9f8855697b4ab7d20803901425e061a3" -dependencies = [ - "windows-metadata", - "windows-tokens", -] - -[[package]] -name = "windows-implement" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce87ca8e3417b02dc2a8a22769306658670ec92d78f1bd420d6310a67c245c6" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "windows-interface" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "853f69a591ecd4f810d29f17e902d40e349fb05b0b11fff63b08b826bfe39c7f" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "windows-metadata" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee78911e3f4ce32c1ad9d3c7b0bd95389662ad8d8f1a3155688fed70bd96e2b6" - -[[package]] -name = "windows-sys" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" -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-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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.0", -] - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b1eb6f0cd7c80c79759c929114ef071b87354ce476d9d94271031c0497adfd5" -dependencies = [ - "windows_aarch64_gnullvm 0.48.0", - "windows_aarch64_msvc 0.48.0", - "windows_i686_gnu 0.48.0", - "windows_i686_msvc 0.48.0", - "windows_x86_64_gnu 0.48.0", - "windows_x86_64_gnullvm 0.48.0", - "windows_x86_64_msvc 0.48.0", -] - -[[package]] -name = "windows-tokens" -version = "0.44.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa4251900975a0d10841c5d4bde79c56681543367ef811f3fabb8d1803b0959b" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" - -[[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.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" - -[[package]] -name = "winnow" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae8970b36c66498d8ff1d66685dc86b91b29db0c7739899012f63a63814b4b28" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80d0f4e272c85def139476380b12f9ac60926689dd2e01d4923222f40580869d" -dependencies = [ - "winapi", -] - -[[package]] -name = "wry" -version = "0.27.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8cf0dbfa7ccbd2e3832a3098b19d4b552360ea00a40b244a99caef46bffd84f" -dependencies = [ - "base64 0.13.1", - "block", - "cocoa", - "core-graphics", - "crossbeam-channel", - "dunce", - "gdk", - "gio", - "glib", - "gtk", - "html5ever", - "http", - "javascriptcore-rs", - "kuchiki", - "libc", - "log", - "objc", - "objc_id", - "once_cell", - "serde", - "serde_json", - "sha2", - "soup3", - "tao", - "thiserror", - "url", - "webkit2gtk", - "webkit2gtk-sys", - "webview2-com", - "windows", - "windows-implement", -] - -[[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 = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d1526bbe5aaeb5eb06885f4d987bcdfa5e23187055de9b83fe00156a821fabc" -dependencies = [ - "libc", -] diff --git a/plugins/http/Cargo.toml b/plugins/http/Cargo.toml index ef5741c6..f1fb6082 100644 --- a/plugins/http/Cargo.toml +++ b/plugins/http/Cargo.toml @@ -1,22 +1,17 @@ [package] name = "tauri-plugin-http" -version = "0.0.0" -edition = "2021" -#edition.workspace = true -#authors.workspace = true -#license.workspace = true +version = "2.0.0-alpha.0" +description = "Access an HTTP client written in Rust." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } [dependencies] -#serde.workspace = true -#serde_json.workspace = true -#tauri.workspace = true -#log.workspace = true -#thiserror.workspace = true -tauri = { git = "https://github.com/tauri-apps/tauri", branch = "next" } -serde = "1" -serde_json = "1" -thiserror = "1" - +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +thiserror = { workspace = true } +tauri-plugin-fs = { path = "../fs", version = "2.0.0-alpha.0" } glob = "0.3" rand = "0.8" bytes = { version = "1", features = [ "serde" ] } @@ -25,7 +20,7 @@ http = "0.2" reqwest = { version = "0.11", default-features = false, features = [ "json", "stream" ] } [features] -http-multipart = [ "reqwest/multipart" ] +multipart = [ "reqwest/multipart" ] native-tls = [ "reqwest/native-tls" ] native-tls-vendored = [ "reqwest/native-tls-vendored" ] rustls-tls = [ "reqwest/rustls-tls" ] diff --git a/plugins/http/README.md b/plugins/http/README.md index 0bace1a5..440e5a18 100644 --- a/plugins/http/README.md +++ b/plugins/http/README.md @@ -1,10 +1,10 @@ -![plugin-http](banner.jpg) +# HTTP - +Access the HTTP client written in Rust. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,7 +18,9 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] -tauri-plugin-fs-extra = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +tauri-plugin-http = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-http = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` You can install the JavaScript Guest bindings using your preferred JavaScript package manager: @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-http +# or +npm add @tauri-apps/plugin-http +# or +yarn add @tauri-apps/plugin-http + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-http#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-http#v2 @@ -51,7 +60,11 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript - +import { fetch } from "@tauri-apps/plugin-http"; +const response = await fetch("http://localhost:3003/users/2", { + method: "GET", + timeout: 30, +}); ``` ## Contributing diff --git a/plugins/http/guest-js/index.ts b/plugins/http/guest-js/index.ts index 47e5e323..60378402 100644 --- a/plugins/http/guest-js/index.ts +++ b/plugins/http/guest-js/index.ts @@ -5,21 +5,6 @@ /** * Access the HTTP client written in Rust. * - * The APIs must be allowlisted on `tauri.conf.json`: - * ```json - * { - * "tauri": { - * "allowlist": { - * "http": { - * "all": true, // enable all http APIs - * "request": true // enable HTTP request API - * } - * } - * } - * } - * ``` - * It is recommended to allowlist only the APIs you use for optimal bundle size and security. - * * ## Security * * This API has a scope configuration that forces you to restrict the URLs and paths that can be accessed using glob patterns. @@ -27,11 +12,9 @@ * For instance, this scope configuration only allows making HTTP requests to the GitHub API for the `tauri-apps` organization: * ```json * { - * "tauri": { - * "allowlist": { - * "http": { - * "scope": ["https://api.github.com/repos/tauri-apps/*"] - * } + * "plugins": { + * "http": { + * "scope": ["https://api.github.com/repos/tauri-apps/*"] * } * } * } @@ -41,10 +24,14 @@ * @module */ -import { invoke } from "@tauri-apps/api/tauri"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} /** - * @since 1.0.0 + * @since 2.0.0 */ interface Duration { secs: number; @@ -52,7 +39,7 @@ interface Duration { } /** - * @since 1.0.0 + * @since 2.0.0 */ interface ClientOptions { /** @@ -64,7 +51,7 @@ interface ClientOptions { } /** - * @since 1.0.0 + * @since 2.0.0 */ enum ResponseType { JSON = 1, @@ -73,7 +60,7 @@ enum ResponseType { } /** - * @since 1.0.0 + * @since 2.0.0 */ interface FilePart { file: string | T; @@ -86,7 +73,7 @@ type Part = string | Uint8Array | FilePart; /** * The body object to be used on POST and PUT requests. * - * @since 1.0.0 + * @since 2.0.0 */ class Body { type: string; @@ -103,12 +90,12 @@ class Body { * and the value is either a string or a file object. * * By default it sets the `application/x-www-form-urlencoded` Content-Type header, - * but you can set it to `multipart/form-data` if the Cargo feature `http-multipart` is enabled. + * but you can set it to `multipart/form-data` if the Cargo feature `multipart` is enabled. * - * Note that a file path must be allowed in the `fs` allowlist scope. + * Note that a file path must be allowed in the `fs` scope. * @example * ```typescript - * import { Body } from "tauri-plugin-http-api" + * import { Body } from "@tauri-apps/plugin-http" * const body = Body.form({ * key: 'value', * image: { @@ -128,6 +115,8 @@ class Body { * @param data The body data. * * @returns The body object ready to be used on the POST and PUT requests. + * + * @since 2.0.0 */ static form(data: Record | FormData): Body { const form: Record> = {}; @@ -169,7 +158,7 @@ class Body { * Creates a new JSON body. * @example * ```typescript - * import { Body } from "tauri-plugin-http-api" + * import { Body } from "@tauri-apps/plugin-http" * Body.json({ * registered: true, * name: 'tauri' @@ -179,6 +168,8 @@ class Body { * @param data The body JSON object. * * @returns The body object ready to be used on the POST and PUT requests. + * + * @since 2.0.0 */ static json(data: Record): Body { return new Body("Json", data); @@ -188,13 +179,15 @@ class Body { * Creates a new UTF-8 string body. * @example * ```typescript - * import { Body } from "tauri-plugin-http-api" + * import { Body } from "@tauri-apps/plugin-http" * Body.text('The body content as a string'); * ``` * * @param value The body string. * * @returns The body object ready to be used on the POST and PUT requests. + * + * @since 2.0.0 */ static text(value: string): Body { return new Body("Text", value); @@ -204,13 +197,15 @@ class Body { * Creates a new byte array body. * @example * ```typescript - * import { Body } from "tauri-plugin-http-api" + * import { Body } from "@tauri-apps/plugin-http" * Body.bytes(new Uint8Array([1, 2, 3])); * ``` * * @param bytes The body byte array. * * @returns The body object ready to be used on the POST and PUT requests. + * + * @since 2.0.0 */ static bytes( bytes: Iterable | ArrayLike | ArrayBuffer @@ -238,7 +233,7 @@ type HttpVerb = /** * Options object sent to the backend. * - * @since 1.0.0 + * @since 2.0.0 */ interface HttpOptions { method: HttpVerb; @@ -267,7 +262,7 @@ interface IResponse { /** * Response object. * - * @since 1.0.0 + * @since 2.0.0 * */ class Response { /** The request URL. */ @@ -295,7 +290,7 @@ class Response { } /** - * @since 1.0.0 + * @since 2.0.0 */ class Client { id: number; @@ -308,13 +303,13 @@ class Client { * Drops the client instance. * @example * ```typescript - * import { getClient } from 'tauri-plugin-http-api'; + * import { getClient } from '@tauri-apps/plugin-http'; * const client = await getClient(); * await client.drop(); * ``` */ async drop(): Promise { - return invoke("plugin:http|drop_client", { + return window.__TAURI_INVOKE__("plugin:http|drop_client", { client: this.id, }); } @@ -323,7 +318,7 @@ class Client { * Makes an HTTP request. * @example * ```typescript - * import { getClient } from 'tauri-plugin-http-api'; + * import { getClient } from '@tauri-apps/plugin-http'; * const client = await getClient(); * const response = await client.request({ * method: 'GET', @@ -337,37 +332,39 @@ class Client { if (jsonResponse) { options.responseType = ResponseType.Text; } - return invoke>("plugin:http|request", { - clientId: this.id, - options, - }).then((res) => { - const response = new Response(res); - if (jsonResponse) { - /* eslint-disable */ - try { - response.data = JSON.parse(response.data as string); - } catch (e) { - if (response.ok && (response.data as unknown as string) === "") { - response.data = {} as T; - } else if (response.ok) { - throw Error( - `Failed to parse response \`${response.data}\` as JSON: ${e}; + return window + .__TAURI_INVOKE__>("plugin:http|request", { + clientId: this.id, + options, + }) + .then((res) => { + const response = new Response(res); + if (jsonResponse) { + /* eslint-disable */ + try { + response.data = JSON.parse(response.data as string); + } catch (e) { + if (response.ok && (response.data as unknown as string) === "") { + response.data = {} as T; + } else if (response.ok) { + throw Error( + `Failed to parse response \`${response.data}\` as JSON: ${e}; try setting the \`responseType\` option to \`ResponseType.Text\` or \`ResponseType.Binary\` if the API does not return a JSON response.` - ); + ); + } } + /* eslint-enable */ + return response; } - /* eslint-enable */ return response; - } - return response; - }); + }); } /** * Makes a GET request. * @example * ```typescript - * import { getClient, ResponseType } from 'tauri-plugin-http-api'; + * import { getClient, ResponseType } from '@tauri-apps/plugin-http'; * const client = await getClient(); * const response = await client.get('http://localhost:3003/users', { * timeout: 30, @@ -388,7 +385,7 @@ class Client { * Makes a POST request. * @example * ```typescript - * import { getClient, Body, ResponseType } from 'tauri-plugin-http-api'; + * import { getClient, Body, ResponseType } from '@tauri-apps/plugin-http'; * const client = await getClient(); * const response = await client.post('http://localhost:3003/users', { * body: Body.json({ @@ -417,7 +414,7 @@ class Client { * Makes a PUT request. * @example * ```typescript - * import { getClient, Body } from 'tauri-plugin-http-api'; + * import { getClient, Body } from '@tauri-apps/plugin-http'; * const client = await getClient(); * const response = await client.put('http://localhost:3003/users/1', { * body: Body.form({ @@ -447,7 +444,7 @@ class Client { * Makes a PATCH request. * @example * ```typescript - * import { getClient, Body } from 'tauri-plugin-http-api'; + * import { getClient, Body } from '@tauri-apps/plugin-http'; * const client = await getClient(); * const response = await client.patch('http://localhost:3003/users/1', { * body: Body.json({ email: 'contact@tauri.app' }) @@ -466,7 +463,7 @@ class Client { * Makes a DELETE request. * @example * ```typescript - * import { getClient } from 'tauri-plugin-http-api'; + * import { getClient } from '@tauri-apps/plugin-http'; * const client = await getClient(); * const response = await client.delete('http://localhost:3003/users/1'); * ``` @@ -484,7 +481,7 @@ class Client { * Creates a new client using the specified options. * @example * ```typescript - * import { getClient } from 'tauri-plugin-http-api'; + * import { getClient } from '@tauri-apps/plugin-http'; * const client = await getClient(); * ``` * @@ -492,12 +489,14 @@ class Client { * * @returns A promise resolving to the client instance. * - * @since 1.0.0 + * @since 2.0.0 */ async function getClient(options?: ClientOptions): Promise { - return invoke("plugin:http|create_client", { - options, - }).then((id) => new Client(id)); + return window + .__TAURI_INVOKE__("plugin:http|create_client", { + options, + }) + .then((id) => new Client(id)); } /** @internal */ @@ -507,7 +506,7 @@ let defaultClient: Client | null = null; * Perform an HTTP request using the default client. * @example * ```typescript - * import { fetch } from 'tauri-plugin-http-api'; + * import { fetch } from '@tauri-apps/plugin-http'; * const response = await fetch('http://localhost:3003/users/2', { * method: 'GET', * timeout: 30, diff --git a/plugins/http/package.json b/plugins/http/package.json index cb35a774..d1fe48e2 100644 --- a/plugins/http/package.json +++ b/plugins/http/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-http-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-http", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/http/src/api-iife.js b/plugins/http/src/api-iife.js new file mode 100644 index 00000000..e99aa35b --- /dev/null +++ b/plugins/http/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_HTTP__=function(e){"use strict";var t;e.ResponseType=void 0,(t=e.ResponseType||(e.ResponseType={}))[t.JSON=1]="JSON",t[t.Text=2]="Text",t[t.Binary=3]="Binary";class r{constructor(e,t){this.type=e,this.payload=t}static form(e){const t={},s=(e,r)=>{if(null!==r){let s;s="string"==typeof r?r:r instanceof Uint8Array||Array.isArray(r)?Array.from(r):r instanceof File?{file:r.name,mime:r.type,fileName:r.name}:"string"==typeof r.file?{file:r.file,mime:r.mime,fileName:r.fileName}:{file:Array.from(r.file),mime:r.mime,fileName:r.fileName},t[String(e)]=s}};if(e instanceof FormData)for(const[t,r]of e)s(t,r);else for(const[t,r]of Object.entries(e))s(t,r);return new r("Form",t)}static json(e){return new r("Json",e)}static text(e){return new r("Text",e)}static bytes(e){return new r("Bytes",Array.from(e instanceof ArrayBuffer?new Uint8Array(e):e))}}class s{constructor(e){this.url=e.url,this.status=e.status,this.ok=this.status>=200&&this.status<300,this.headers=e.headers,this.rawHeaders=e.rawHeaders,this.data=e.data}}class n{constructor(e){this.id=e}async drop(){return window.__TAURI_INVOKE__("plugin:http|drop_client",{client:this.id})}async request(t){const r=!t.responseType||t.responseType===e.ResponseType.JSON;return r&&(t.responseType=e.ResponseType.Text),window.__TAURI_INVOKE__("plugin:http|request",{clientId:this.id,options:t}).then((e=>{const t=new s(e);if(r){try{t.data=JSON.parse(t.data)}catch(e){if(t.ok&&""===t.data)t.data={};else if(t.ok)throw Error(`Failed to parse response \`${t.data}\` as JSON: ${e};\n try setting the \`responseType\` option to \`ResponseType.Text\` or \`ResponseType.Binary\` if the API does not return a JSON response.`)}return t}return t}))}async get(e,t){return this.request({method:"GET",url:e,...t})}async post(e,t,r){return this.request({method:"POST",url:e,body:t,...r})}async put(e,t,r){return this.request({method:"PUT",url:e,body:t,...r})}async patch(e,t){return this.request({method:"PATCH",url:e,...t})}async delete(e,t){return this.request({method:"DELETE",url:e,...t})}}async function i(e){return window.__TAURI_INVOKE__("plugin:http|create_client",{options:e}).then((e=>new n(e)))}let o=null;return e.Body=r,e.Client=n,e.Response=s,e.fetch=async function(e,t){var r;return null===o&&(o=await i()),o.request({url:e,method:null!==(r=null==t?void 0:t.method)&&void 0!==r?r:"GET",...t})},e.getClient=i,e}({});Object.defineProperty(window.__TAURI__,"http",{value:__TAURI_HTTP__})} diff --git a/plugins/http/src/commands/client.rs b/plugins/http/src/commands/client.rs index 2b7131a7..07614a53 100644 --- a/plugins/http/src/commands/client.rs +++ b/plugins/http/src/commands/client.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::{collections::HashMap, path::PathBuf, time::Duration}; use reqwest::{header, Method, Url}; @@ -91,7 +95,7 @@ impl Client { headers: &mut Option, form_body: FormBody, ) -> crate::Result { - #[cfg(feature = "http-multipart")] + #[cfg(feature = "multipart")] if matches!( headers .as_ref() diff --git a/plugins/http/src/commands/mod.rs b/plugins/http/src/commands/mod.rs index 24acf09e..94c71324 100644 --- a/plugins/http/src/commands/mod.rs +++ b/plugins/http/src/commands/mod.rs @@ -1,9 +1,11 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use tauri::{path::SafePathBuf, AppHandle, Runtime, State}; +use tauri_plugin_fs::FsExt; -use crate::{ - - ClientId, Http, -}; +use crate::{ClientId, Http}; mod client; use client::{Body, ClientBuilder, FilePart, FormPart, HttpRequestBuilder, ResponseData}; @@ -41,7 +43,6 @@ pub async fn request( client_id: ClientId, options: Box, ) -> super::Result { - use crate::Manager; if http.scope.is_allowed(&options.url) { let client = http .clients @@ -58,7 +59,12 @@ pub async fn request( .. } = value { - if SafePathBuf::new(path.clone()).is_err() || !app.fs_scope().is_allowed(path) { + if SafePathBuf::new(path.clone()).is_err() + || !app + .try_fs_scope() + .map(|s| s.is_allowed(path)) + .unwrap_or_default() + { return Err(crate::Error::PathNotAllowed(path.clone())); } } diff --git a/plugins/http/src/config.rs b/plugins/http/src/config.rs new file mode 100644 index 00000000..4e9d7317 --- /dev/null +++ b/plugins/http/src/config.rs @@ -0,0 +1,23 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use reqwest::Url; +use serde::Deserialize; + +#[derive(Deserialize)] +pub struct Config { + pub scope: HttpAllowlistScope, +} + +/// HTTP API scope definition. +/// It is a list of URLs that can be accessed by the webview when using the HTTP APIs. +/// The scoped URL is matched against the request URL using a glob pattern. +/// +/// Examples: +/// - "https://**": allows all HTTPS urls +/// - "https://*.github.com/tauri-apps/tauri": allows any subdomain of "github.com" with the "tauri-apps/api" path +/// - "https://myapi.service.com/users/*": allows access to any URLs that begins with "https://myapi.service.com/users/" +#[allow(rustdoc::bare_urls)] +#[derive(Debug, Default, PartialEq, Eq, Clone, Deserialize)] +pub struct HttpAllowlistScope(pub Vec); diff --git a/plugins/http/src/error.rs b/plugins/http/src/error.rs index f1234cbb..8b49b0f7 100644 --- a/plugins/http/src/error.rs +++ b/plugins/http/src/error.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::path::PathBuf; use reqwest::Url; diff --git a/plugins/http/src/lib.rs b/plugins/http/src/lib.rs index 5f905c54..d63107cc 100644 --- a/plugins/http/src/lib.rs +++ b/plugins/http/src/lib.rs @@ -1,3 +1,8 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use config::{Config, HttpAllowlistScope}; pub use reqwest as client; use tauri::{ plugin::{Builder, TauriPlugin}, @@ -7,6 +12,7 @@ use tauri::{ use std::{collections::HashMap, sync::Mutex}; mod commands; +mod config; mod error; mod scope; @@ -33,18 +39,25 @@ impl> HttpExt for T { } } -pub fn init() -> TauriPlugin { - Builder::new("http") +pub fn init() -> TauriPlugin> { + Builder::>::new("http") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![ commands::create_client, commands::drop_client, commands::request ]) - .setup(|app, _api| { + .setup(|app, api| { + let default_scope = HttpAllowlistScope::default(); app.manage(Http { app: app.clone(), clients: Default::default(), - scope: scope::Scope::new(&app.config().tauri.allowlist.http.scope), + scope: scope::Scope::new( + api.config() + .as_ref() + .map(|c| &c.scope) + .unwrap_or(&default_scope), + ), }); Ok(()) }) diff --git a/plugins/http/src/scope.rs b/plugins/http/src/scope.rs index 115ba78a..1b802ace 100644 --- a/plugins/http/src/scope.rs +++ b/plugins/http/src/scope.rs @@ -2,9 +2,9 @@ // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT +use crate::config::HttpAllowlistScope; use glob::Pattern; use reqwest::Url; -use tauri::utils::config::HttpAllowlistScope; /// Scope for filesystem access. #[derive(Debug, Clone)] @@ -13,7 +13,7 @@ pub struct Scope { } impl Scope { - /// Creates a new scope from the allowlist's `http` scope configuration. + /// Creates a new scope from the scope configuration. pub(crate) fn new(scope: &HttpAllowlistScope) -> Self { Self { allowed_urls: scope @@ -38,12 +38,12 @@ impl Scope { #[cfg(test)] mod tests { - use tauri_utils::config::HttpAllowlistScope; + use crate::config::HttpAllowlistScope; #[test] fn is_allowed() { // plain URL - let scope = super::Scope::for_http_api(&HttpAllowlistScope(vec!["http://localhost:8080" + let scope = super::Scope::new(&HttpAllowlistScope(vec!["http://localhost:8080" .parse() .unwrap()])); assert!(scope.is_allowed(&"http://localhost:8080".parse().unwrap())); @@ -56,10 +56,9 @@ mod tests { assert!(!scope.is_allowed(&"http://local:8080".parse().unwrap())); // URL with fixed path - let scope = - super::Scope::for_http_api(&HttpAllowlistScope(vec!["http://localhost:8080/file.png" - .parse() - .unwrap()])); + let scope = super::Scope::new(&HttpAllowlistScope(vec!["http://localhost:8080/file.png" + .parse() + .unwrap()])); assert!(scope.is_allowed(&"http://localhost:8080/file.png".parse().unwrap())); @@ -68,25 +67,22 @@ mod tests { assert!(!scope.is_allowed(&"http://localhost:8080/file.png/other.jpg".parse().unwrap())); // URL with glob pattern - let scope = - super::Scope::for_http_api(&HttpAllowlistScope(vec!["http://localhost:8080/*.png" - .parse() - .unwrap()])); + let scope = super::Scope::new(&HttpAllowlistScope(vec!["http://localhost:8080/*.png" + .parse() + .unwrap()])); assert!(scope.is_allowed(&"http://localhost:8080/file.png".parse().unwrap())); assert!(scope.is_allowed(&"http://localhost:8080/assets/file.png".parse().unwrap())); assert!(!scope.is_allowed(&"http://localhost:8080/file.jpeg".parse().unwrap())); - let scope = - super::Scope::for_http_api(&HttpAllowlistScope(vec!["http://*".parse().unwrap()])); + let scope = super::Scope::new(&HttpAllowlistScope(vec!["http://*".parse().unwrap()])); assert!(scope.is_allowed(&"http://something.else".parse().unwrap())); assert!(!scope.is_allowed(&"http://something.else/path/to/file".parse().unwrap())); assert!(!scope.is_allowed(&"https://something.else".parse().unwrap())); - let scope = - super::Scope::for_http_api(&HttpAllowlistScope(vec!["http://**".parse().unwrap()])); + let scope = super::Scope::new(&HttpAllowlistScope(vec!["http://**".parse().unwrap()])); assert!(scope.is_allowed(&"http://something.else".parse().unwrap())); assert!(scope.is_allowed(&"http://something.else/path/to/file".parse().unwrap())); diff --git a/plugins/localhost/CHANGELOG.md b/plugins/localhost/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/localhost/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/localhost/Cargo.toml b/plugins/localhost/Cargo.toml index 12fad9a0..a5586cbe 100644 --- a/plugins/localhost/Cargo.toml +++ b/plugins/localhost/Cargo.toml @@ -1,19 +1,17 @@ [package] name = "tauri-plugin-localhost" -version = "0.1.0" +version = "2.0.0-alpha.0" description = "Expose your apps assets through a localhost server instead of the default custom protocol." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } tiny_http = "0.12" -http = "0.2" \ No newline at end of file +http = "0.2" diff --git a/plugins/localhost/README.md b/plugins/localhost/README.md index 2a0e9fc3..5b83bf4b 100644 --- a/plugins/localhost/README.md +++ b/plugins/localhost/README.md @@ -6,7 +6,7 @@ Expose your apps assets through a localhost server instead of the default custom ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -20,8 +20,10 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] -tauri-plugin-localhost = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } portpicker = "0.1" # used in the example to pick a random free port +tauri-plugin-localhost = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-localhost = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` ## Usage @@ -31,27 +33,26 @@ First you need to register the core plugin with Tauri: `src-tauri/src/main.rs` ```rust -use tauri::{utils::config::AppUrl, window::WindowBuilder, WindowUrl}; +use tauri::{Manager, window::WindowBuilder, WindowUrl}; fn main() { let port = portpicker::pick_unused_port().expect("failed to find unused port"); - let mut context = tauri::generate_context!(); - let url = format!("http://localhost:{}", port).parse().unwrap(); - let window_url = WindowUrl::External(url); - // rewrite the config so the IPC is enabled on this URL - context.config_mut().build.dist_dir = AppUrl::Url(window_url.clone()); - context.config_mut().build.dev_path = AppUrl::Url(window_url.clone()); - tauri::Builder::default() .plugin(tauri_plugin_localhost::Builder::new(port).build()) .setup(move |app| { - WindowBuilder::new(app, "main".to_string(), window_url) + app.ipc_scope().configure_remote_access( + RemoteDomainAccessScope::new(format!("localhost:{}", port)) + .add_window("main") + ); + + let url = format!("http://localhost:{}", port).parse().unwrap(); + WindowBuilder::new(app, "main".to_string(), WindowUrl::External(url)) .title("Localhost Example") .build()?; Ok(()) }) - .run(context) + .run(tauri::generate_context!()) .expect("error while running tauri application"); } ``` diff --git a/plugins/localhost/src/lib.rs b/plugins/localhost/src/lib.rs index 11a0b75c..e34a9ace 100644 --- a/plugins/localhost/src/lib.rs +++ b/plugins/localhost/src/lib.rs @@ -1,4 +1,4 @@ -// Copyright 2019-2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT diff --git a/plugins/log/CHANGELOG.md b/plugins/log/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/log/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/log/Cargo.toml b/plugins/log/Cargo.toml index c3370549..06a19f4a 100644 --- a/plugins/log/Cargo.toml +++ b/plugins/log/Cargo.toml @@ -1,25 +1,23 @@ [package] name = "tauri-plugin-log" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Configurable logging for your Tauri app." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [build-dependencies] -tauri-build.workspace = true +tauri-build = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } serde_repr = "0.1" byte-unit = "4.0" -log = { workspace = true, features = ["kv_unstable"] } -time = { version = "0.3", features = ["formatting", "local-offset"] } +log = { workspace = true, features = [ "kv_unstable" ] } +time = { version = "0.3", features = [ "formatting", "local-offset" ] } fern = "0.6" [target."cfg(target_os = \"android\")".dependencies] @@ -31,4 +29,4 @@ objc = "0.2" cocoa = "0.24" [features] -colored = ["fern/colored"] \ No newline at end of file +colored = [ "fern/colored" ] diff --git a/plugins/log/README.md b/plugins/log/README.md index 779f9056..50aaecbf 100644 --- a/plugins/log/README.md +++ b/plugins/log/README.md @@ -4,7 +4,7 @@ Configurable logging for your Tauri app. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-log = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-log = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-log +# or +npm add @tauri-apps/plugin-log +# or +yarn add @tauri-apps/plugin-log + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-log#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-log#v2 @@ -57,7 +66,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { trace, info, error, attachConsole } from "tauri-plugin-log-api"; +import { trace, info, error, attachConsole } from "@tauri-apps/plugin-log"; // with LogTarget::Webview enabled this function will print logs to the browser console const detach = await attachConsole(); diff --git a/plugins/log/guest-js/index.ts b/plugins/log/guest-js/index.ts index 4fb4b0c9..108bf05e 100644 --- a/plugins/log/guest-js/index.ts +++ b/plugins/log/guest-js/index.ts @@ -1,10 +1,20 @@ -import { invoke } from "@tauri-apps/api/tauri"; +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import { listen, UnlistenFn } from "@tauri-apps/api/event"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} + export type LogOptions = { file?: string; line?: number; -} & Record; + keyValues?: Record; +}; enum LogLevel { /** @@ -50,14 +60,14 @@ async function log( return name.length > 0 && location !== "[native code]"; }); - const { file, line, ...keyValues } = options ?? {}; + const { file, line, keyValues } = options ?? {}; let location = filtered?.[0]?.filter((v) => v.length > 0).join("@"); if (location === "Error") { location = "webview::unknown"; } - await invoke("plugin:log|log", { + await window.__TAURI_INVOKE__("plugin:log|log", { level, message, location, @@ -75,7 +85,7 @@ async function log( * # Examples * * ```js - * import { error } from 'tauri-plugin-log-api'; + * import { error } from '@tauri-apps/plugin-log'; * * const err_info = "No connection"; * const port = 22; @@ -98,7 +108,7 @@ export async function error( * # Examples * * ```js - * import { warn } from 'tauri-plugin-log-api'; + * import { warn } from '@tauri-apps/plugin-log'; * * const warn_description = "Invalid Input"; * @@ -120,7 +130,7 @@ export async function warn( * # Examples * * ```js - * import { info } from 'tauri-plugin-log-api'; + * import { info } from '@tauri-apps/plugin-log'; * * const conn_info = { port: 40, speed: 3.20 }; * @@ -142,7 +152,7 @@ export async function info( * # Examples * * ```js - * import { debug } from 'tauri-plugin-log-api'; + * import { debug } from '@tauri-apps/plugin-log'; * * const pos = { x: 3.234, y: -1.223 }; * @@ -164,7 +174,7 @@ export async function debug( * # Examples * * ```js - * import { trace } from 'tauri-plugin-log-api'; + * import { trace } from '@tauri-apps/plugin-log'; * * let pos = { x: 3.234, y: -1.223 }; * diff --git a/plugins/log/ios/Package.swift b/plugins/log/ios/Package.swift index 4f736418..4afbbbdb 100644 --- a/plugins/log/ios/Package.swift +++ b/plugins/log/ios/Package.swift @@ -1,5 +1,7 @@ // swift-tools-version:5.3 -// The swift-tools-version declares the minimum version of Swift required to build this package. +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT import PackageDescription diff --git a/plugins/log/ios/Sources/LogPlugin.swift b/plugins/log/ios/Sources/LogPlugin.swift index 954f357e..cefdc858 100644 --- a/plugins/log/ios/Sources/LogPlugin.swift +++ b/plugins/log/ios/Sources/LogPlugin.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import UIKit import Tauri import SwiftRs diff --git a/plugins/log/package.json b/plugins/log/package.json index b610090d..388c7aa6 100644 --- a/plugins/log/package.json +++ b/plugins/log/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-log-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-log", + "version": "2.0.0-alpha.0", "description": "Configurable logging for your Tauri app.", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/log/src/api-iife.js b/plugins/log/src/api-iife.js new file mode 100644 index 00000000..0eb88e8f --- /dev/null +++ b/plugins/log/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_LOG__=function(e){"use strict";var n=Object.defineProperty,t=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},r=(e,n,t)=>{if(!n.has(e))throw TypeError("Cannot "+t)},a=(e,n,t)=>(r(e,n,"read from private field"),t?t.call(e):n.get(e)),i=(e,n,t,a)=>(r(e,n,"write to private field"),a?a.call(e,t):n.set(e,t),t);function o(e,n=!1){let t=window.crypto.getRandomValues(new Uint32Array(1))[0],r=`_${t}`;return Object.defineProperty(window,r,{value:t=>(n&&Reflect.deleteProperty(window,r),e?.(t)),writable:!1,configurable:!0}),t}t({},{Channel:()=>c,PluginListener:()=>s,addPluginListener:()=>u,convertFileSrc:()=>_,invoke:()=>d,transformCallback:()=>o});var l,c=class{constructor(){this.__TAURI_CHANNEL_MARKER__=!0,((e,n,t)=>{if(n.has(e))throw TypeError("Cannot add the same private member more than once");n instanceof WeakSet?n.add(e):n.set(e,t)})(this,l,(()=>{})),this.id=o((e=>{a(this,l).call(this,e)}))}set onmessage(e){i(this,l,e)}get onmessage(){return a(this,l)}toJSON(){return`__CHANNEL__:${this.id}`}};l=new WeakMap;var s=class{constructor(e,n,t){this.plugin=e,this.event=n,this.channelId=t}async unregister(){return d(`plugin:${this.plugin}|remove_listener`,{event:this.event,channelId:this.channelId})}};async function u(e,n,t){let r=new c;return r.onmessage=t,d(`plugin:${e}|register_listener`,{event:n,handler:r}).then((()=>new s(e,n,r.id)))}async function d(e,n={}){return new Promise(((t,r)=>{let a=o((e=>{t(e),Reflect.deleteProperty(window,`_${i}`)}),!0),i=o((e=>{r(e),Reflect.deleteProperty(window,`_${a}`)}),!0);window.__TAURI_IPC__({cmd:e,callback:a,error:i,...n})}))}function _(e,n="asset"){let t=encodeURIComponent(e);return navigator.userAgent.includes("Windows")?`https://${n}.localhost/${t}`:`${n}://localhost/${t}`}async function w(e,n){await d("plugin:event|unlisten",{event:e,eventId:n})}async function f(e,n,t){return d("plugin:event|listen",{event:e,windowLabel:n,handler:o(t)}).then((n=>async()=>w(e,n)))}t({},{TauriEvent:()=>h,emit:()=>I,listen:()=>E,once:()=>y});var v,g,h=((v=h||{}).WINDOW_RESIZED="tauri://resize",v.WINDOW_MOVED="tauri://move",v.WINDOW_CLOSE_REQUESTED="tauri://close-requested",v.WINDOW_CREATED="tauri://window-created",v.WINDOW_DESTROYED="tauri://destroyed",v.WINDOW_FOCUS="tauri://focus",v.WINDOW_BLUR="tauri://blur",v.WINDOW_SCALE_FACTOR_CHANGED="tauri://scale-change",v.WINDOW_THEME_CHANGED="tauri://theme-changed",v.WINDOW_FILE_DROP="tauri://file-drop",v.WINDOW_FILE_DROP_HOVER="tauri://file-drop-hover",v.WINDOW_FILE_DROP_CANCELLED="tauri://file-drop-cancelled",v.MENU="tauri://menu",v);async function E(e,n){return f(e,null,n)}async function y(e,n){return async function(e,n,t){return f(e,n,(n=>{t(n),w(e,n.id).catch((()=>{}))}))}(e,null,n)}async function I(e,n){return async function(e,n,t){await d("plugin:event|emit",{event:e,windowLabel:n,payload:t})}(e,void 0,n)}async function p(e,n,t){var r,a;const i=null===(r=(new Error).stack)||void 0===r?void 0:r.split("\n").map((e=>e.split("@"))),o=null==i?void 0:i.filter((([e,n])=>e.length>0&&"[native code]"!==n)),{file:l,line:c,keyValues:s}=null!=t?t:{};let u=null===(a=null==o?void 0:o[0])||void 0===a?void 0:a.filter((e=>e.length>0)).join("@");"Error"===u&&(u="webview::unknown"),await window.__TAURI_INVOKE__("plugin:log|log",{level:e,message:n,location:u,file:l,line:c,keyValues:s})}return function(e){e[e.Trace=1]="Trace",e[e.Debug=2]="Debug",e[e.Info=3]="Info",e[e.Warn=4]="Warn",e[e.Error=5]="Error"}(g||(g={})),e.attachConsole=async function(){return await E("log://log",(e=>{const n=e.payload,t=n.message.replace(/[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g,"");switch(n.level){case g.Trace:console.log(t);break;case g.Debug:console.debug(t);break;case g.Info:console.info(t);break;case g.Warn:console.warn(t);break;case g.Error:console.error(t);break;default:throw new Error(`unknown log level ${n.level}`)}}))},e.debug=async function(e,n){await p(g.Debug,e,n)},e.error=async function(e,n){await p(g.Error,e,n)},e.info=async function(e,n){await p(g.Info,e,n)},e.trace=async function(e,n){await p(g.Trace,e,n)},e.warn=async function(e,n){await p(g.Warn,e,n)},e}({});Object.defineProperty(window.__TAURI__,"log",{value:__TAURI_LOG__})} diff --git a/plugins/log/src/lib.rs b/plugins/log/src/lib.rs index cbb6dd29..05794dd7 100644 --- a/plugins/log/src/lib.rs +++ b/plugins/log/src/lib.rs @@ -1,8 +1,10 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT -use fern::FormatCallback; +//! Logging for Tauri applications. + +use fern::{Filter, FormatCallback}; use log::{logger, RecordBuilder}; use log::{LevelFilter, Record}; use serde::Serialize; @@ -23,6 +25,8 @@ use tauri::{ pub use fern; use time::OffsetDateTime; +pub const WEBVIEW_TARGET: &str = "Webview"; + #[cfg(target_os = "ios")] mod ios { use cocoa::base::id; @@ -58,7 +62,10 @@ mod ios { const DEFAULT_MAX_FILE_SIZE: u128 = 40000; const DEFAULT_ROTATION_STRATEGY: RotationStrategy = RotationStrategy::KeepOne; const DEFAULT_TIMEZONE_STRATEGY: TimezoneStrategy = TimezoneStrategy::UseUtc; -const DEFAULT_LOG_TARGETS: [LogTarget; 2] = [LogTarget::Stdout, LogTarget::LogDir]; +const DEFAULT_LOG_TARGETS: [Target; 2] = [ + Target::new(TargetKind::Stdout), + Target::new(TargetKind::LogDir { file_name: None }), +]; /// An enum representing the available verbosity levels of the logger. /// @@ -141,7 +148,7 @@ struct RecordPayload { } /// An enum representing the available targets of the logger. -pub enum LogTarget { +pub enum TargetKind { /// Print logs to stdout. Stdout, /// Print logs to stderr. @@ -149,7 +156,10 @@ pub enum LogTarget { /// Write logs to the given directory. /// /// The plugin will ensure the directory exists before writing logs. - Folder(PathBuf), + Folder { + path: PathBuf, + file_name: Option, + }, /// Write logs to the OS specififc logs directory. /// /// ### Platform-specific @@ -159,13 +169,38 @@ pub enum LogTarget { /// | Linux | `{configDir}/{bundleIdentifier}` | `/home/alice/.config/com.tauri.dev` | /// | macOS | `{homeDir}/Library/Logs/{bundleIdentifier}` | `/Users/Alice/Library/Logs/com.tauri.dev` | /// | Windows | `{configDir}/{bundleIdentifier}` | `C:\Users\Alice\AppData\Roaming\com.tauri.dev` | - LogDir, + LogDir { file_name: Option }, /// Forward logs to the webview (via the `log://log` event). /// /// This requires the webview to subscribe to log events, via this plugins `attachConsole` function. Webview, } +/// A log target. +pub struct Target { + kind: TargetKind, + filters: Vec>, +} + +impl Target { + #[inline] + pub const fn new(kind: TargetKind) -> Self { + Self { + kind, + filters: Vec::new(), + } + } + + #[inline] + pub fn filter(mut self, filter: F) -> Self + where + F: Fn(&log::Metadata) -> bool + Send + Sync + 'static, + { + self.filters.push(Box::new(filter)); + self + } +} + #[tauri::command] fn log( level: LogLevel, @@ -176,9 +211,18 @@ fn log( key_values: Option>, ) { let location = location.unwrap_or("webview"); + + let level = log::Level::from(level); + + let metadata = log::MetadataBuilder::new() + .level(level) + .target(WEBVIEW_TARGET) + .build(); + let mut builder = RecordBuilder::new(); builder - .level(level.into()) + .level(level) + .metadata(metadata) .target(location) .file(file) .line(line); @@ -198,7 +242,7 @@ pub struct Builder { rotation_strategy: RotationStrategy, timezone_strategy: TimezoneStrategy, max_file_size: u128, - targets: Vec, + targets: Vec, } impl Default for Builder { @@ -290,12 +334,37 @@ impl Builder { self } - pub fn target(mut self, target: LogTarget) -> Self { + /// Removes all targets. Useful to ignore the default targets and reconfigure them. + pub fn clear_targets(mut self) -> Self { + self.targets.clear(); + self + } + + /// Adds a log target to the logger. + /// + /// ```rust + /// use tauri_plugin_log::{Target, TargetKind}; + /// tauri_plugin_log::Builder::new() + /// .target(Target::new(TargetKind::Webview)); + /// ``` + pub fn target(mut self, target: Target) -> Self { self.targets.push(target); self } - pub fn targets(mut self, targets: impl IntoIterator) -> Self { + /// Adds a collection of targets to the logger. + /// + /// ```rust + /// use tauri_plugin_log::{Target, TargetKind, WEBVIEW_TARGET}; + /// tauri_plugin_log::Builder::new() + /// .clear_targets() + /// .targets([ + /// Target::new(TargetKind::Webview), + /// Target::new(TargetKind::LogDir { file_name: Some("webview".into()) }).filter(|metadata| metadata.target() == WEBVIEW_TARGET), + /// Target::new(TargetKind::LogDir { file_name: Some("rust".into()) }).filter(|metadata| metadata.target() != WEBVIEW_TARGET), + /// ]); + /// ``` + pub fn targets(mut self, targets: impl IntoIterator) -> Self { self.targets = Vec::from_iter(targets); self } @@ -320,19 +389,25 @@ impl Builder { pub fn build(mut self) -> TauriPlugin { plugin::Builder::new("log") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![log]) .setup(move |app_handle, _api| { let app_name = &app_handle.package_info().name; // setup targets - for target in &self.targets { - let logger = match target { + for target in self.targets { + let mut target_dispatch = fern::Dispatch::new(); + for filter in target.filters { + target_dispatch = target_dispatch.filter(filter); + } + + let logger = match target.kind { #[cfg(target_os = "android")] - LogTarget::Stdout | LogTarget::Stderr => { + TargetKind::Stdout | TargetKind::Stderr => { fern::Output::call(android_logger::log) } #[cfg(target_os = "ios")] - LogTarget::Stdout | LogTarget::Stderr => { + TargetKind::Stdout | TargetKind::Stderr => { fern::Output::call(move |record| { let message = format!("{}", record.args()); unsafe { @@ -348,17 +423,17 @@ impl Builder { }) } #[cfg(desktop)] - LogTarget::Stdout => std::io::stdout().into(), + TargetKind::Stdout => std::io::stdout().into(), #[cfg(desktop)] - LogTarget::Stderr => std::io::stderr().into(), - LogTarget::Folder(path) => { + TargetKind::Stderr => std::io::stderr().into(), + TargetKind::Folder { path, file_name } => { if !path.exists() { - fs::create_dir_all(path).unwrap(); + fs::create_dir_all(&path).unwrap(); } fern::log_file(get_log_file_path( &path, - app_name, + file_name.as_deref().unwrap_or(app_name), &self.rotation_strategy, &self.timezone_strategy, self.max_file_size, @@ -366,9 +441,9 @@ impl Builder { .into() } #[cfg(mobile)] - LogTarget::LogDir => continue, + TargetKind::LogDir { .. } => continue, #[cfg(desktop)] - LogTarget::LogDir => { + TargetKind::LogDir { file_name } => { let path = app_handle.path().app_log_dir().unwrap(); if !path.exists() { fs::create_dir_all(&path).unwrap(); @@ -376,14 +451,14 @@ impl Builder { fern::log_file(get_log_file_path( &path, - app_name, + file_name.as_deref().unwrap_or(app_name), &self.rotation_strategy, &self.timezone_strategy, self.max_file_size, )?)? .into() } - LogTarget::Webview => { + TargetKind::Webview => { let app_handle = app_handle.clone(); fern::Output::call(move |record| { @@ -398,7 +473,9 @@ impl Builder { }) } }; - self.dispatch = self.dispatch.chain(logger); + target_dispatch = target_dispatch.chain(logger); + + self.dispatch = self.dispatch.chain(target_dispatch); } self.dispatch.apply()?; @@ -411,12 +488,12 @@ impl Builder { fn get_log_file_path( dir: &impl AsRef, - app_name: &str, + file_name: &str, rotation_strategy: &RotationStrategy, timezone_strategy: &TimezoneStrategy, max_file_size: u128, ) -> plugin::Result { - let path = dir.as_ref().join(format!("{app_name}.log")); + let path = dir.as_ref().join(format!("{file_name}.log")); if path.exists() { let log_size = File::open(&path)?.metadata()?.len() as u128; @@ -425,7 +502,7 @@ fn get_log_file_path( RotationStrategy::KeepAll => { let to = dir.as_ref().join(format!( "{}_{}.log", - app_name, + file_name, timezone_strategy .get_now() .format( diff --git a/plugins/log/tsconfig.json b/plugins/log/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/log/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/log/tsconfig.json b/plugins/log/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/log/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/mirrors.txt b/plugins/mirrors.txt index c785da72..dfa1a2b3 100644 --- a/plugins/mirrors.txt +++ b/plugins/mirrors.txt @@ -1,20 +1,23 @@ +app authenticator autostart cli -clipboard +clipboard-manager dialog fs -fs-watch global-shortcut http -localhost log -persisted-scope +notification +os positioner +process shell sql store stronghold +updater upload websocket +window window-state diff --git a/plugins/notification/CHANGELOG.md b/plugins/notification/CHANGELOG.md new file mode 100644 index 00000000..263a20f0 --- /dev/null +++ b/plugins/notification/CHANGELOG.md @@ -0,0 +1,10 @@ +# Changelog + +## \[2.0.0-alpha.1] + +- [`d8b4aca`](https://github.com/tauri-apps/plugins-workspace/commit/d8b4aca69f628b170804ecb982e2c319d026ef47)([#414](https://github.com/tauri-apps/plugins-workspace/pull/414)) Use `window.__TAURI_INVOKE__` instead of `window.__TAURI__` in init.js, fixes usage in apps without `withGlobalTauri` enabled. +- [`7d71ad4`](https://github.com/tauri-apps/plugins-workspace/commit/7d71ad4e587bcf47ea34645f5b226945e487b765) Play a default sound when showing a notification on Windows. + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/notification/Cargo.toml b/plugins/notification/Cargo.toml index f136b2e5..fddbde5c 100644 --- a/plugins/notification/Cargo.toml +++ b/plugins/notification/Cargo.toml @@ -1,24 +1,24 @@ [package] name = "tauri-plugin-notification" -version = "0.1.0" -edition.workspace = true -authors.workspace = true -license.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +version = "2.0.0-alpha.1" +description = "Send desktop and mobile notifications on your Tauri application." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } +links = "tauri-plugin-notification" [build-dependencies] -tauri-build.workspace = true +tauri-build = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } rand = "0.8" -time = { version = "0.3", features = ["serde", "parsing", "formatting"] } -url = { version = "2", features = ["serde"] } +time = { version = "0.3", features = [ "serde", "parsing", "formatting" ] } +url = { version = "2", features = [ "serde" ] } serde_repr = "0.1" [target."cfg(any(target_os = \"macos\", windows, target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"openbsd\", target_os = \"netbsd\"))".dependencies] diff --git a/plugins/notification/README.md b/plugins/notification/README.md index ed5545a2..08f9dfd3 100644 --- a/plugins/notification/README.md +++ b/plugins/notification/README.md @@ -1,10 +1,10 @@ -![{{plugin name}}](banner.jpg) +# Notification - +Send message notifications (brief auto-expiring OS window element) to your user. Can also be used with the Notification Web API. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,7 +18,9 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] - = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "dev" } +tauri-plugin-notification = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-notification = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` You can install the JavaScript Guest bindings using your preferred JavaScript package manager: @@ -26,11 +28,18 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh -pnpm add +pnpm add @tauri-apps/plugin-notification # or -npm add +npm add @tauri-apps/plugin-notification # or -yarn add +yarn add @tauri-apps/plugin-notification + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-notification#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-notification#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-notification#v2 ``` ## Usage @@ -42,7 +51,7 @@ First you need to register the core plugin with Tauri: ```rust fn main() { tauri::Builder::default() - .plugin() + .plugin(tauri_plugin_notification::init()) .run(tauri::generate_context!()) .expect("error while running tauri application"); } diff --git a/plugins/notification/android/src/androidTest/java/ExampleInstrumentedTest.kt b/plugins/notification/android/src/androidTest/java/ExampleInstrumentedTest.kt index 814a39af..88ede7f4 100644 --- a/plugins/notification/android/src/androidTest/java/ExampleInstrumentedTest.kt +++ b/plugins/notification/android/src/androidTest/java/ExampleInstrumentedTest.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import androidx.test.platform.app.InstrumentationRegistry diff --git a/plugins/notification/android/src/main/AndroidManifest.xml b/plugins/notification/android/src/main/AndroidManifest.xml index 986d5f85..28ccac30 100644 --- a/plugins/notification/android/src/main/AndroidManifest.xml +++ b/plugins/notification/android/src/main/AndroidManifest.xml @@ -1,5 +1,4 @@ - + diff --git a/plugins/notification/android/src/main/java/AssetUtils.kt b/plugins/notification/android/src/main/java/AssetUtils.kt index c97cd528..fafccf7a 100644 --- a/plugins/notification/android/src/main/java/AssetUtils.kt +++ b/plugins/notification/android/src/main/java/AssetUtils.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import android.annotation.SuppressLint diff --git a/plugins/notification/android/src/main/java/ChannelManager.kt b/plugins/notification/android/src/main/java/ChannelManager.kt index cf68e666..2ae740e5 100644 --- a/plugins/notification/android/src/main/java/ChannelManager.kt +++ b/plugins/notification/android/src/main/java/ChannelManager.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import android.app.NotificationChannel diff --git a/plugins/notification/android/src/main/java/Notification.kt b/plugins/notification/android/src/main/java/Notification.kt index 3839807b..9076fa8f 100644 --- a/plugins/notification/android/src/main/java/Notification.kt +++ b/plugins/notification/android/src/main/java/Notification.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import android.content.ContentResolver diff --git a/plugins/notification/android/src/main/java/NotificationAction.kt b/plugins/notification/android/src/main/java/NotificationAction.kt index c1a964b4..d50d0fe9 100644 --- a/plugins/notification/android/src/main/java/NotificationAction.kt +++ b/plugins/notification/android/src/main/java/NotificationAction.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import app.tauri.Logger diff --git a/plugins/notification/android/src/main/java/NotificationAttachment.kt b/plugins/notification/android/src/main/java/NotificationAttachment.kt index 1cc35e89..56a13818 100644 --- a/plugins/notification/android/src/main/java/NotificationAttachment.kt +++ b/plugins/notification/android/src/main/java/NotificationAttachment.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import app.tauri.plugin.JSObject diff --git a/plugins/notification/android/src/main/java/NotificationPlugin.kt b/plugins/notification/android/src/main/java/NotificationPlugin.kt index f87bcf17..2b6043dc 100644 --- a/plugins/notification/android/src/main/java/NotificationPlugin.kt +++ b/plugins/notification/android/src/main/java/NotificationPlugin.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import android.Manifest diff --git a/plugins/notification/android/src/main/java/NotificationSchedule.kt b/plugins/notification/android/src/main/java/NotificationSchedule.kt index 89edbc9d..64c83486 100644 --- a/plugins/notification/android/src/main/java/NotificationSchedule.kt +++ b/plugins/notification/android/src/main/java/NotificationSchedule.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import android.annotation.SuppressLint diff --git a/plugins/notification/android/src/main/java/NotificationStorage.kt b/plugins/notification/android/src/main/java/NotificationStorage.kt index bfddfcc2..4d55a9a4 100644 --- a/plugins/notification/android/src/main/java/NotificationStorage.kt +++ b/plugins/notification/android/src/main/java/NotificationStorage.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import android.content.Context diff --git a/plugins/notification/android/src/main/java/TauriNotificationManager.kt b/plugins/notification/android/src/main/java/TauriNotificationManager.kt index 79e67908..2f948069 100644 --- a/plugins/notification/android/src/main/java/TauriNotificationManager.kt +++ b/plugins/notification/android/src/main/java/TauriNotificationManager.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import android.annotation.SuppressLint diff --git a/plugins/notification/android/src/test/java/ExampleUnitTest.kt b/plugins/notification/android/src/test/java/ExampleUnitTest.kt index 46693a0f..134a27d4 100644 --- a/plugins/notification/android/src/test/java/ExampleUnitTest.kt +++ b/plugins/notification/android/src/test/java/ExampleUnitTest.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package app.tauri.notification import org.junit.Test diff --git a/plugins/notification/build.rs b/plugins/notification/build.rs index 86ac3f0a..743096a6 100644 --- a/plugins/notification/build.rs +++ b/plugins/notification/build.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::process::exit; fn main() { diff --git a/plugins/notification/guest-js/index.ts b/plugins/notification/guest-js/index.ts index 78919356..7de70375 100644 --- a/plugins/notification/guest-js/index.ts +++ b/plugins/notification/guest-js/index.ts @@ -6,30 +6,19 @@ * Send toast notifications (brief auto-expiring OS window element) to your user. * Can also be used with the Notification Web API. * - * This package is also accessible with `window.__TAURI__.notification` when [`build.withGlobalTauri`](https://tauri.app/v1/api/config/#buildconfig.withglobaltauri) in `tauri.conf.json` is set to `true`. - * - * The APIs must be added to [`tauri.allowlist.notification`](https://tauri.app/v1/api/config/#allowlistconfig.notification) in `tauri.conf.json`: - * ```json - * { - * "tauri": { - * "allowlist": { - * "notification": { - * "all": true // enable all notification APIs - * } - * } - * } - * } - * ``` - * It is recommended to allowlist only the APIs you use for optimal bundle size and security. * @module */ -import { invoke, transformCallback } from "@tauri-apps/api/tauri"; +import { + invoke, + PluginListener, + addPluginListener, +} from "@tauri-apps/api/tauri"; /** * Options to send a notification. * - * @since 1.0.0 + * @since 2.0.0 */ interface Options { /** @@ -311,7 +300,7 @@ type Permission = "granted" | "denied" | "default"; * const permissionGranted = await isPermissionGranted(); * ``` * - * @since 1.0.0 + * @since 2.0.0 */ async function isPermissionGranted(): Promise { if (window.Notification.permission !== "default") { @@ -334,7 +323,7 @@ async function isPermissionGranted(): Promise { * * @returns A promise resolving to whether the user granted the permission or not. * - * @since 1.0.0 + * @since 2.0.0 */ async function requestPermission(): Promise { return window.Notification.requestPermission(); @@ -356,7 +345,7 @@ async function requestPermission(): Promise { * } * ``` * - * @since 1.0.0 + * @since 2.0.0 */ function sendNotification(options: Options | string): void { if (typeof options === "string") { @@ -551,59 +540,16 @@ async function channels(): Promise { return invoke("plugin:notification|getActive"); } -class EventChannel { - id: number; - unregisterFn: (channel: EventChannel) => Promise; - - constructor( - id: number, - unregisterFn: (channel: EventChannel) => Promise - ) { - this.id = id; - this.unregisterFn = unregisterFn; - } - - toJSON(): string { - return `__CHANNEL__:${this.id}`; - } - - async unregister(): Promise { - return this.unregisterFn(this); - } -} - -// TODO: use addPluginListener API on @tauri-apps/api/tauri 2.0.0-alpha.4 async function onNotificationReceived( cb: (notification: Options) => void -): Promise { - const channelId = transformCallback(cb); - const handler = new EventChannel(channelId, (channel) => - invoke("plugin:notification|remove_listener", { - event: "notification", - channelId: channel.id, - }) - ); - return invoke("plugin:notification|register_listener", { - event: "notification", - handler, - }).then(() => handler); +): Promise { + return addPluginListener("notification", "notification", cb); } -// TODO: use addPluginListener API on @tauri-apps/api/tauri 2.0.0-alpha.4 async function onAction( cb: (notification: Options) => void -): Promise { - const channelId = transformCallback(cb); - const handler = new EventChannel(channelId, (channel) => - invoke("plugin:notification|remove_listener", { - event: "actionPerformed", - channelId: channel.id, - }) - ); - return invoke("plugin:notification|register_listener", { - event: "actionPerformed", - handler, - }).then(() => handler); +): Promise { + return addPluginListener("notification", "actionPerformed", cb); } export type { diff --git a/plugins/notification/ios/Package.swift b/plugins/notification/ios/Package.swift index bfcaf338..1a2c4801 100644 --- a/plugins/notification/ios/Package.swift +++ b/plugins/notification/ios/Package.swift @@ -1,5 +1,9 @@ // swift-tools-version:5.3 -// The swift-tools-version declares the minimum version of Swift required to build this package. +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + + import PackageDescription diff --git a/plugins/notification/ios/Sources/Notification.swift b/plugins/notification/ios/Sources/Notification.swift index 52b1016f..e6f0d077 100644 --- a/plugins/notification/ios/Sources/Notification.swift +++ b/plugins/notification/ios/Sources/Notification.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import Tauri import UserNotifications diff --git a/plugins/notification/ios/Sources/NotificationCategory.swift b/plugins/notification/ios/Sources/NotificationCategory.swift index 74a1e194..ae37ffc3 100644 --- a/plugins/notification/ios/Sources/NotificationCategory.swift +++ b/plugins/notification/ios/Sources/NotificationCategory.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import Tauri import UserNotifications diff --git a/plugins/notification/ios/Sources/NotificationHandler.swift b/plugins/notification/ios/Sources/NotificationHandler.swift index 1f7cb8ba..ac569bdf 100644 --- a/plugins/notification/ios/Sources/NotificationHandler.swift +++ b/plugins/notification/ios/Sources/NotificationHandler.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import Tauri import UserNotifications diff --git a/plugins/notification/ios/Sources/NotificationManager.swift b/plugins/notification/ios/Sources/NotificationManager.swift index 857636fb..183b4dd5 100644 --- a/plugins/notification/ios/Sources/NotificationManager.swift +++ b/plugins/notification/ios/Sources/NotificationManager.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import Foundation import UserNotifications diff --git a/plugins/notification/ios/Sources/NotificationPlugin.swift b/plugins/notification/ios/Sources/NotificationPlugin.swift index 217c999d..29e01865 100644 --- a/plugins/notification/ios/Sources/NotificationPlugin.swift +++ b/plugins/notification/ios/Sources/NotificationPlugin.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import SwiftRs import Tauri import UIKit diff --git a/plugins/notification/ios/Tests/PluginTests/PluginTests.swift b/plugins/notification/ios/Tests/PluginTests/PluginTests.swift index 4f8e9ace..99992ce4 100644 --- a/plugins/notification/ios/Tests/PluginTests/PluginTests.swift +++ b/plugins/notification/ios/Tests/PluginTests/PluginTests.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import XCTest @testable import ExamplePlugin diff --git a/plugins/notification/package.json b/plugins/notification/package.json index 52d81e45..1b18b55c 100644 --- a/plugins/notification/package.json +++ b/plugins/notification/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-notification-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-notification", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/notification/src/api-iife.js b/plugins/notification/src/api-iife.js new file mode 100644 index 00000000..4ef6d877 --- /dev/null +++ b/plugins/notification/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_NOTIFICATION__=function(n){"use strict";var e=Object.defineProperty,i=(n,e,i)=>{if(!e.has(n))throw TypeError("Cannot "+i)},t=(n,e,t)=>(i(n,e,"read from private field"),t?t.call(n):e.get(n)),o=(n,e,t,o)=>(i(n,e,"write to private field"),o?o.call(n,t):e.set(n,t),t);function r(n,e=!1){let i=window.crypto.getRandomValues(new Uint32Array(1))[0],t=`_${i}`;return Object.defineProperty(window,t,{value:i=>(e&&Reflect.deleteProperty(window,t),n?.(i)),writable:!1,configurable:!0}),i}((n,i)=>{for(var t in i)e(n,t,{get:i[t],enumerable:!0})})({},{Channel:()=>a,PluginListener:()=>f,addPluginListener:()=>d,convertFileSrc:()=>p,invoke:()=>_,transformCallback:()=>r});var c,a=class{constructor(){this.__TAURI_CHANNEL_MARKER__=!0,((n,e,i)=>{if(e.has(n))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(n):e.set(n,i)})(this,c,(()=>{})),this.id=r((n=>{t(this,c).call(this,n)}))}set onmessage(n){o(this,c,n)}get onmessage(){return t(this,c)}toJSON(){return`__CHANNEL__:${this.id}`}};c=new WeakMap;var s,l,u,f=class{constructor(n,e,i){this.plugin=n,this.event=e,this.channelId=i}async unregister(){return _(`plugin:${this.plugin}|remove_listener`,{event:this.event,channelId:this.channelId})}};async function d(n,e,i){let t=new a;return t.onmessage=i,_(`plugin:${n}|register_listener`,{event:e,handler:t}).then((()=>new f(n,e,t.id)))}async function _(n,e={}){return new Promise(((i,t)=>{let o=r((n=>{i(n),Reflect.deleteProperty(window,`_${c}`)}),!0),c=r((n=>{t(n),Reflect.deleteProperty(window,`_${o}`)}),!0);window.__TAURI_IPC__({cmd:n,callback:o,error:c,...e})}))}function p(n,e="asset"){let i=encodeURIComponent(n);return navigator.userAgent.includes("Windows")?`https://${e}.localhost/${i}`:`${e}://localhost/${i}`}return function(n){n.Year="Year",n.Month="Month",n.TwoWeeks="TwoWeeks",n.Week="Week",n.Day="Day",n.Hour="Hour",n.Minute="Minute",n.Second="Second"}(s||(s={})),n.Importance=void 0,(l=n.Importance||(n.Importance={}))[l.None=0]="None",l[l.Min=1]="Min",l[l.Low=2]="Low",l[l.Default=3]="Default",l[l.High=4]="High",n.Visibility=void 0,(u=n.Visibility||(n.Visibility={}))[u.Secret=-1]="Secret",u[u.Private=0]="Private",u[u.Public=1]="Public",n.active=async function(){return _("plugin:notification|get_active")},n.cancel=async function(n){return _("plugin:notification|cancel",{notifications:n})},n.cancelAll=async function(){return _("plugin:notification|cancel")},n.channels=async function(){return _("plugin:notification|getActive")},n.createChannel=async function(n){return _("plugin:notification|create_channel",{...n})},n.isPermissionGranted=async function(){return"default"!==window.Notification.permission?Promise.resolve("granted"===window.Notification.permission):_("plugin:notification|is_permission_granted")},n.onAction=async function(n){return d("notification","actionPerformed",n)},n.onNotificationReceived=async function(n){return d("notification","notification",n)},n.pending=async function(){return _("plugin:notification|get_pending")},n.registerActionTypes=async function(n){return _("plugin:notification|register_action_types",{types:n})},n.removeActive=async function(n){return _("plugin:notification|remove_active",{notifications:n})},n.removeAllActive=async function(){return _("plugin:notification|remove_active")},n.removeChannel=async function(n){return _("plugin:notification|delete_channel",{id:n})},n.requestPermission=async function(){return window.Notification.requestPermission()},n.sendNotification=function(n){"string"==typeof n?new window.Notification(n):new window.Notification(n.title,n)},n}({});Object.defineProperty(window.__TAURI__,"notification",{value:__TAURI_NOTIFICATION__})} diff --git a/plugins/notification/src/desktop.rs b/plugins/notification/src/desktop.rs index 47be71b5..401f6569 100644 --- a/plugins/notification/src/desktop.rs +++ b/plugins/notification/src/desktop.rs @@ -72,15 +72,16 @@ mod imp { /// /// # Examples /// ```rust,no_run - /// use tauri::api::notification::Notification; + /// use tauri_plugin_notification::NotificationExt; /// // first we build the application to access the Tauri configuration /// let app = tauri::Builder::default() /// // on an actual app, remove the string argument - /// .build(tauri::generate_context!("test/fixture/src-tauri/tauri.conf.json")) + /// .build(tauri::generate_context!("test/tauri.conf.json")) /// .expect("error while building tauri application"); /// /// // shows a notification with the given title and body - /// Notification::new(&app.config().tauri.bundle.identifier) + /// app.notification() + /// .builder() /// .title("New message") /// .body("You've got a new message.") /// .show(); @@ -136,15 +137,20 @@ mod imp { /// # Examples /// /// ```no_run - /// use tauri::api::notification::Notification; + /// use tauri_plugin_notification::NotificationExt; /// - /// // on an actual app, remove the string argument - /// let context = tauri::generate_context!("test/fixture/src-tauri/tauri.conf.json"); - /// Notification::new(&context.config().tauri.bundle.identifier) - /// .title("Tauri") - /// .body("Tauri is awesome!") - /// .show() - /// .unwrap(); + /// tauri::Builder::default() + /// .setup(|app| { + /// app.notification() + /// .builder() + /// .title("Tauri") + /// .body("Tauri is awesome!") + /// .show() + /// .unwrap(); + /// Ok(()) + /// }) + /// .run(tauri::generate_context!("test/tauri.conf.json")) + /// .expect("error while running tauri application"); /// ``` /// /// ## Platform-specific @@ -178,6 +184,9 @@ mod imp { { notification.app_id(&self.identifier); } + + // will be parsed as a `::winrt_notification::Sound` + notification.sound_name("Default"); } #[cfg(target_os = "macos")] { @@ -200,22 +209,18 @@ mod imp { /// # Examples /// /// ```no_run - /// use tauri::api::notification::Notification; - /// - /// // on an actual app, remove the string argument - /// let context = tauri::generate_context!("test/fixture/src-tauri/tauri.conf.json"); - /// let identifier = context.config().tauri.bundle.identifier.clone(); + /// use tauri_plugin_notification::NotificationExt; /// /// tauri::Builder::default() /// .setup(move |app| { - /// Notification::new(&identifier) + /// app.notification().builder() /// .title("Tauri") /// .body("Tauri is awesome!") - /// .notify(&app.handle()) + /// .show() /// .unwrap(); /// Ok(()) /// }) - /// .run(context) + /// .run(tauri::generate_context!("test/tauri.conf.json")) /// .expect("error while running tauri application"); /// ``` #[cfg(feature = "windows7-compat")] @@ -241,7 +246,7 @@ mod imp { #[cfg(all(windows, feature = "windows7-compat"))] fn notify_win7(self, app: &tauri::AppHandle) -> crate::Result<()> { let app = app.clone(); - let default_window_icon = app.manager.inner.default_window_icon.clone(); + let default_window_icon = app.default_window_icon().cloned(); let _ = app.run_on_main_thread(move || { let mut notification = win7_notifications::Notification::new(); if let Some(body) = self.body { diff --git a/plugins/notification/src/init.js b/plugins/notification/src/init.js index d69acf61..1fbf3c52 100644 --- a/plugins/notification/src/init.js +++ b/plugins/notification/src/init.js @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + (function () { let permissionSettable = false; let permissionValue = "default"; @@ -6,7 +10,7 @@ if (window.Notification.permission !== "default") { return Promise.resolve(window.Notification.permission === "granted"); } - return window.__TAURI__.invoke("plugin:notification|is_permission_granted"); + return window.__TAURI_INVOKE__("plugin:notification|is_permission_granted"); } function setNotificationPermission(value) { @@ -30,7 +34,7 @@ Object.freeze(options); } - return window.__TAURI__.invoke("plugin:notification|notify", { + return window.__TAURI_INVOKE__("plugin:notification|notify", { options: typeof options === "string" ? { diff --git a/plugins/notification/src/lib.rs b/plugins/notification/src/lib.rs index 6e566fe2..03f6db09 100644 --- a/plugins/notification/src/lib.rs +++ b/plugins/notification/src/lib.rs @@ -212,13 +212,15 @@ impl> crate::NotificationExt for T { /// Initializes the plugin. pub fn init() -> TauriPlugin { + let mut init_script = include_str!("init.js").to_string(); + init_script.push_str(include_str!("api-iife.js")); Builder::new("notification") .invoke_handler(tauri::generate_handler![ commands::notify, commands::request_permission, commands::is_permission_granted ]) - .js_init_script(include_str!("init.js").into()) + .js_init_script(init_script) .setup(|app, api| { #[cfg(mobile)] let notification = mobile::init(app, api)?; diff --git a/plugins/notification/test/tauri.conf.json b/plugins/notification/test/tauri.conf.json new file mode 100644 index 00000000..8a9c0108 --- /dev/null +++ b/plugins/notification/test/tauri.conf.json @@ -0,0 +1,22 @@ +{ + "$schema": "../../../node_modules/.pnpm/@tauri-apps+cli@2.0.0-alpha.8/node_modules/@tauri-apps/cli/schema.json", + "build": { + "distDir": ".", + "devPath": "http://localhost:4000" + }, + "tauri": { + "bundle": { + "identifier": "studio.tauri.example", + "active": true, + "icon": ["../../../examples/api/src-tauri/icons/icon.png"] + }, + "windows": [ + { + "title": "Tauri App" + } + ], + "security": { + "csp": "default-src blob: data: filesystem: ws: wss: http: https: tauri: 'unsafe-eval' 'unsafe-inline' 'self'" + } + } +} diff --git a/plugins/os/CHANGELOG.md b/plugins/os/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/os/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/os/Cargo.toml b/plugins/os/Cargo.toml new file mode 100644 index 00000000..ef2f8a6d --- /dev/null +++ b/plugins/os/Cargo.toml @@ -0,0 +1,17 @@ +[package] +name = "tauri-plugin-os" +version = "2.0.0-alpha.0" +description = "Read information about the operating system." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } + +[dependencies] +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } +os_info = "3" +sys-locale = "0.3" +gethostname = "0.4" diff --git a/plugins/os/LICENSE.spdx b/plugins/os/LICENSE.spdx new file mode 100644 index 00000000..cdd0df5a --- /dev/null +++ b/plugins/os/LICENSE.spdx @@ -0,0 +1,20 @@ +SPDXVersion: SPDX-2.1 +DataLicense: CC0-1.0 +PackageName: tauri +DataFormat: SPDXRef-1 +PackageSupplier: Organization: The Tauri Programme in the Commons Conservancy +PackageHomePage: https://tauri.app +PackageLicenseDeclared: Apache-2.0 +PackageLicenseDeclared: MIT +PackageCopyrightText: 2019-2022, The Tauri Programme in the Commons Conservancy +PackageSummary: Tauri is a rust project that enables developers to make secure +and small desktop applications using a web frontend. + +PackageComment: The package includes the following libraries; see +Relationship information. + +Created: 2019-05-20T09:00:00Z +PackageDownloadLocation: git://github.com/tauri-apps/tauri +PackageDownloadLocation: git+https://github.com/tauri-apps/tauri.git +PackageDownloadLocation: git+ssh://github.com/tauri-apps/tauri.git +Creator: Person: Daniel Thompson-Yvetot \ No newline at end of file diff --git a/plugins/os/LICENSE_APACHE-2.0 b/plugins/os/LICENSE_APACHE-2.0 new file mode 100644 index 00000000..4947287f --- /dev/null +++ b/plugins/os/LICENSE_APACHE-2.0 @@ -0,0 +1,177 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS \ No newline at end of file diff --git a/plugins/os/LICENSE_MIT b/plugins/os/LICENSE_MIT new file mode 100644 index 00000000..4d754725 --- /dev/null +++ b/plugins/os/LICENSE_MIT @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2017 - Present Tauri Apps Contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/plugins/clipboard/README.md b/plugins/os/README.md similarity index 67% rename from plugins/clipboard/README.md rename to plugins/os/README.md index 2879c77b..27ed03ad 100644 --- a/plugins/clipboard/README.md +++ b/plugins/os/README.md @@ -1,10 +1,10 @@ -![plugin-clipboard](banner.jpg) +# Operating System - +Read information about the operating system. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,7 +18,9 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] -tauri-plugin-clipboard = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +tauri-plugin-os = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-os = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` You can install the JavaScript Guest bindings using your preferred JavaScript package manager: @@ -26,11 +28,18 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh -pnpm add https://github.com/tauri-apps/tauri-plugin-clipboard#v2 +pnpm add @tauri-apps/plugin-os # or -npm add https://github.com/tauri-apps/tauri-plugin-clipboard#v2 +npm add @tauri-apps/plugin-os # or -yarn add https://github.com/tauri-apps/tauri-plugin-clipboard#v2 +yarn add @tauri-apps/plugin-os + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-os#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-os#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-os#v2 ``` ## Usage @@ -42,7 +51,7 @@ First you need to register the core plugin with Tauri: ```rust fn main() { tauri::Builder::default() - .plugin(tauri_plugin_clipboard::init()) + .plugin(tauri_plugin_os::init()) .run(tauri::generate_context!()) .expect("error while running tauri application"); } @@ -51,7 +60,8 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript - +import { version } from "@tauri-apps/plugin-os"; +const osVersion = await version(); ``` ## Contributing diff --git a/plugins/os/guest-js/index.ts b/plugins/os/guest-js/index.ts new file mode 100644 index 00000000..2b94895d --- /dev/null +++ b/plugins/os/guest-js/index.ts @@ -0,0 +1,187 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +/** + * Provides operating system-related utility methods and properties. + * + * @module + */ + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} + +type Platform = + | "linux" + | "macos" + | "ios" + | "freebsd" + | "dragonfly" + | "netbsd" + | "openbsd" + | "solaris" + | "android" + | "windows"; + +type OsType = "linux" | "windows" | "macss" | "ios" | "android"; + +type Arch = + | "x86" + | "x86_64" + | "arm" + | "aarch64" + | "mips" + | "mips64" + | "powerpc" + | "powerpc64" + | "riscv64" + | "s390x" + | "sparc64"; + +function isWindows(): boolean { + return navigator.appVersion.includes("Win"); +} + +/** + * The operating system-specific end-of-line marker. + * - `\n` on POSIX + * - `\r\n` on Windows + * + * @since 2.0.0 + * */ +const EOL = isWindows() ? "\r\n" : "\n"; + +/** + * Returns a string describing the specific operating system in use. + * The value is set at compile time. Possible values are `'linux'`, `'macos'`, `'ios'`, `'freebsd'`, `'dragonfly'`, `'netbsd'`, `'openbsd'`, `'solaris'`, `'android'`, `'windows'` + * + * @example + * ```typescript + * import { platform } from '@tauri-apps/plugin-os'; + * const platformName = await platform(); + * ``` + * + * @since 2.0.0 + * + */ +async function platform(): Promise { + return window.__TAURI_INVOKE__("plugin:os|platform"); +} + +/** + * Returns the current operating system version. + * @example + * ```typescript + * import { version } from '@tauri-apps/plugin-os'; + * const osVersion = await version(); + * ``` + * + * @since 2.0.0 + */ +async function version(): Promise { + return window.__TAURI_INVOKE__("plugin:os|version"); +} + +type Family = "unix" | "windows"; + +/** + * Returns the current operating system family. Possible values are `'unix'`, `'windows'`. + * @example + * ```typescript + * import { family } from '@tauri-apps/plugin-os'; + * const family = await family(); + * ``` + * + * @since 2.0.0 + */ +async function family(): Promise { + return window.__TAURI_INVOKE__("plugin:os|family"); +} + +/** + * Returns the current operating system type. Returns `'linux'` on Linux, `'macos'` on macOS, `'windows'` on Windows, `'ios'` on iOS and `'android'` on Android. + * @example + * ```typescript + * import { type } from '@tauri-apps/plugin-os'; + * const osType = await type(); + * ``` + * + * @since 2.0.0 + */ +async function type(): Promise { + return window.__TAURI_INVOKE__("plugin:os|os_type"); +} + +/** + * Returns the current operating system architecture. + * Possible values are `'x86'`, `'x86_64'`, `'arm'`, `'aarch64'`, `'mips'`, `'mips64'`, `'powerpc'`, `'powerpc64'`, `'riscv64'`, `'s390x'`, `'sparc64'`. + * @example + * ```typescript + * import { arch } from '@tauri-apps/plugin-os'; + * const archName = await arch(); + * ``` + * + * @since 2.0.0 + */ +async function arch(): Promise { + return window.__TAURI_INVOKE__("plugin:os|arch"); +} + +/** + * Returns a String with a `BCP-47` language tag inside. If the locale couldn’t be obtained, `null` is returned instead. + * @example + * ```typescript + * import { locale } from '@tauri-apps/plugin-os'; + * const locale = await locale(); + * if (locale) { + * // use the locale string here + * } + * ``` + * + * @since 2.0.0 + */ +async function locale(): Promise { + return window.__TAURI_INVOKE__("plugin:os|locale"); +} + +/** + * Returns the file extension, if any, used for executable binaries on this platform. Possible values are `'exe'` and `''` (empty string). + * @example + * ```typescript + * import { exeExtension } from '@tauri-apps/plugin-os'; + * const exeExt = await exeExtension(); + * ``` + * + * @since 2.0.0 + */ +async function exeExtension(): Promise { + return window.__TAURI_INVOKE__("plugin:os|exe_extension"); +} + +/** + * Returns the host name of the operating system. + * @example + * ```typescript + * import { hostname } from '@tauri-apps/api/os'; + * const hostname = await hostname(); + * ``` + */ +async function hostname(): Promise { + return window.__TAURI_INVOKE__("plugin:os|hostname"); +} + +export { + EOL, + platform, + family, + version, + type, + arch, + locale, + exeExtension, + hostname, +}; +export type { Platform, OsType, Arch, Family }; diff --git a/plugins/os/package.json b/plugins/os/package.json new file mode 100644 index 00000000..e2aae9c2 --- /dev/null +++ b/plugins/os/package.json @@ -0,0 +1,32 @@ +{ + "name": "@tauri-apps/plugin-os", + "version": "2.0.0-alpha.0", + "license": "MIT or APACHE-2.0", + "authors": [ + "Tauri Programme within The Commons Conservancy" + ], + "type": "module", + "browser": "dist-js/index.min.js", + "module": "dist-js/index.mjs", + "types": "dist-js/index.d.ts", + "exports": { + "import": "./dist-js/index.mjs", + "types": "./dist-js/index.d.ts", + "browser": "./dist-js/index.min.js" + }, + "scripts": { + "build": "rollup -c" + }, + "files": [ + "dist-js", + "!dist-js/**/*.map", + "README.md", + "LICENSE" + ], + "devDependencies": { + "tslib": "^2.5.0" + }, + "dependencies": { + "@tauri-apps/api": "2.0.0-alpha.4" + } +} diff --git a/plugins/os/rollup.config.mjs b/plugins/os/rollup.config.mjs new file mode 100644 index 00000000..6555e98b --- /dev/null +++ b/plugins/os/rollup.config.mjs @@ -0,0 +1,11 @@ +import { readFileSync } from "fs"; + +import { createConfig } from "../../shared/rollup.config.mjs"; + +export default createConfig({ + input: "guest-js/index.ts", + pkg: JSON.parse( + readFileSync(new URL("./package.json", import.meta.url), "utf8") + ), + external: [/^@tauri-apps\/api/], +}); diff --git a/plugins/os/src/api-iife.js b/plugins/os/src/api-iife.js new file mode 100644 index 00000000..382e6d15 --- /dev/null +++ b/plugins/os/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_OS__=function(n){"use strict";const _=navigator.appVersion.includes("Win")?"\r\n":"\n";return n.EOL=_,n.arch=async function(){return window.__TAURI_INVOKE__("plugin:os|arch")},n.exeExtension=async function(){return window.__TAURI_INVOKE__("plugin:os|exe_extension")},n.family=async function(){return window.__TAURI_INVOKE__("plugin:os|family")},n.hostname=async function(){return window.__TAURI_INVOKE__("plugin:os|hostname")},n.locale=async function(){return window.__TAURI_INVOKE__("plugin:os|locale")},n.platform=async function(){return window.__TAURI_INVOKE__("plugin:os|platform")},n.type=async function(){return window.__TAURI_INVOKE__("plugin:os|os_type")},n.version=async function(){return window.__TAURI_INVOKE__("plugin:os|version")},n}({});Object.defineProperty(window.__TAURI__,"os",{value:__TAURI_OS__})} diff --git a/plugins/os/src/commands.rs b/plugins/os/src/commands.rs new file mode 100644 index 00000000..fdfa09a0 --- /dev/null +++ b/plugins/os/src/commands.rs @@ -0,0 +1,43 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +#[tauri::command] +pub fn platform() -> &'static str { + crate::platform() +} + +#[tauri::command] +pub fn version() -> String { + crate::version().to_string() +} + +#[tauri::command] +pub fn os_type() -> String { + crate::type_().to_string() +} + +#[tauri::command] +pub fn family() -> &'static str { + crate::family() +} + +#[tauri::command] +pub fn arch() -> &'static str { + crate::arch() +} + +#[tauri::command] +pub fn exe_extension() -> &'static str { + crate::exe_extension() +} + +#[tauri::command] +pub fn locale() -> Option { + crate::locale() +} + +#[tauri::command] +pub fn hostname() -> String { + crate::hostname() +} diff --git a/plugins/os/src/error.rs b/plugins/os/src/error.rs new file mode 100644 index 00000000..f5d8816a --- /dev/null +++ b/plugins/os/src/error.rs @@ -0,0 +1,17 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use serde::{Serialize, Serializer}; + +#[derive(Debug, thiserror::Error)] +pub enum Error {} + +impl Serialize for Error { + fn serialize(&self, serializer: S) -> std::result::Result + where + S: Serializer, + { + serializer.serialize_str(self.to_string().as_ref()) + } +} diff --git a/plugins/os/src/lib.rs b/plugins/os/src/lib.rs new file mode 100644 index 00000000..ccbbdfef --- /dev/null +++ b/plugins/os/src/lib.rs @@ -0,0 +1,107 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use std::fmt::Display; + +pub use os_info::Version; +use tauri::{ + plugin::{Builder, TauriPlugin}, + Runtime, +}; + +mod commands; +mod error; + +pub use error::Error; + +pub enum OsType { + Linux, + Windows, + Macos, + IOS, + Android, +} + +impl Display for OsType { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + match self { + Self::Linux => write!(f, "linux"), + Self::Windows => write!(f, "windows"), + Self::Macos => write!(f, "macos"), + Self::IOS => write!(f, "ios"), + Self::Android => write!(f, "android"), + } + } +} + +/// Returns a string describing the specific operating system in use, see [std::env::consts::OS]. +pub fn platform() -> &'static str { + std::env::consts::OS +} + +/// Returns the current operating system version. +pub fn version() -> Version { + os_info::get().version().clone() +} + +/// Returns the current operating system type. +pub fn type_() -> OsType { + #[cfg(any( + target_os = "linux", + target_os = "dragonfly", + target_os = "freebsd", + target_os = "netbsd", + target_os = "openbsd" + ))] + return OsType::Linux; + #[cfg(target_os = "windows")] + return OsType::Windows; + #[cfg(target_os = "macos")] + return OsType::Macos; + #[cfg(target_os = "ios")] + return OsType::IOS; + #[cfg(target_os = "android")] + return OsType::Android; +} + +/// Returns the current operating system family, see [std::env::consts::FAMILY]. +pub fn family() -> &'static str { + std::env::consts::FAMILY +} + +/// Returns the current operating system architecture, see [std::env::consts::ARCH]. +pub fn arch() -> &'static str { + std::env::consts::ARCH +} + +/// Returns the file extension, if any, used for executable binaries on this platform. Example value is `exe`, see [std::env::consts::EXE_EXTENSION]. +pub fn exe_extension() -> &'static str { + std::env::consts::EXE_EXTENSION +} + +/// Returns the current operating system locale with the `BCP-47` language tag. If the locale couldn’t be obtained, `None` is returned instead. +pub fn locale() -> Option { + sys_locale::get_locale() +} + +/// Returns the current operating system hostname. +pub fn hostname() -> String { + gethostname::gethostname().to_string_lossy().to_string() +} + +pub fn init() -> TauriPlugin { + Builder::new("os") + .js_init_script(include_str!("api-iife.js").to_string()) + .invoke_handler(tauri::generate_handler![ + commands::platform, + commands::version, + commands::os_type, + commands::family, + commands::arch, + commands::exe_extension, + commands::locale, + commands::hostname + ]) + .build() +} diff --git a/plugins/os/tsconfig.json b/plugins/os/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/os/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/persisted-scope/CHANGELOG.md b/plugins/persisted-scope/CHANGELOG.md new file mode 100644 index 00000000..5bb1d362 --- /dev/null +++ b/plugins/persisted-scope/CHANGELOG.md @@ -0,0 +1,12 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`ebb2eb2`](https://github.com/tauri-apps/plugins-workspace/commit/ebb2eb2fe2ebfbb70530d16a983d396aa5829aa1)([#274](https://github.com/tauri-apps/plugins-workspace/pull/274)) Recursively unescape saved patterns before allowing/forbidding them. This effectively prevents `.persisted-scope` files from blowing up, which caused Out-Of-Memory issues, while automatically fixing existing broken files seamlessly. +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! + +## \[0.1.1] + +- The MSRV was raised to 1.64! +- The plugin now recursively unescapes saved patterns before allowing/forbidding them. This effectively prevents `.persisted-scope` files from blowing up, which caused Out-Of-Memory issues, while automatically fixing existing broken files seamlessly. + - [ebb2eb2](https://github.com/tauri-apps/plugins-workspace/commit/ebb2eb2fe2ebfbb70530d16a983d396aa5829aa1) fix(persisted-scope): Prevent out-of-memory issues, fixes [#274](https://github.com/tauri-apps/plugins-workspace/pull/274) ([#328](https://github.com/tauri-apps/plugins-workspace/pull/328)) on 2023-04-26 diff --git a/plugins/persisted-scope/Cargo.toml b/plugins/persisted-scope/Cargo.toml index 4e1f24d0..ea38618d 100644 --- a/plugins/persisted-scope/Cargo.toml +++ b/plugins/persisted-scope/Cargo.toml @@ -1,22 +1,21 @@ [package] name = "tauri-plugin-persisted-scope" -version = "0.1.0" +version = "2.0.0-alpha.0" description = "Save filesystem and asset scopes and restore them when the app is reopened." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } aho-corasick = "1.0" bincode = "1" +tauri-plugin-fs = { path = "../fs", version = "2.0.0-alpha.0" } [features] -protocol-asset = [ "tauri/protocol-asset" ] \ No newline at end of file +protocol-asset = [ "tauri/protocol-asset" ] diff --git a/plugins/persisted-scope/README.md b/plugins/persisted-scope/README.md index 2dd60751..1a7e19bf 100644 --- a/plugins/persisted-scope/README.md +++ b/plugins/persisted-scope/README.md @@ -4,7 +4,7 @@ Save filesystem and asset scopes and restore them when the app is reopened. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-persisted-scope = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-persisted-scope = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` diff --git a/plugins/persisted-scope/src/lib.rs b/plugins/persisted-scope/src/lib.rs index 1473056c..f1e02c18 100644 --- a/plugins/persisted-scope/src/lib.rs +++ b/plugins/persisted-scope/src/lib.rs @@ -1,4 +1,4 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT @@ -6,8 +6,9 @@ use aho_corasick::AhoCorasick; use serde::{Deserialize, Serialize}; use tauri::{ plugin::{Builder, TauriPlugin}, - AppHandle, FsScopeEvent, Manager, Runtime, + AppHandle, Manager, Runtime, }; +use tauri_plugin_fs::{FsExt, ScopeEvent as FsScopeEvent}; use std::{ fs::{create_dir_all, File}, @@ -59,45 +60,45 @@ fn fix_pattern(ac: &AhoCorasick, s: &str) -> String { } fn save_scopes(app: &AppHandle, app_dir: &Path, scope_state_path: &Path) { - let fs_scope = app.fs_scope(); - - let scope = Scope { - allowed_paths: fs_scope - .allowed_patterns() - .into_iter() - .map(|p| p.to_string()) - .collect(), - forbidden_patterns: fs_scope - .forbidden_patterns() - .into_iter() - .map(|p| p.to_string()) - .collect(), - }; - - let _ = create_dir_all(app_dir) - .and_then(|_| File::create(scope_state_path)) - .map_err(Error::Io) - .and_then(|mut f| { - f.write_all(&bincode::serialize(&scope).map_err(Error::from)?) - .map_err(Into::into) - }); + if let Some(fs_scope) = app.try_fs_scope() { + let scope = Scope { + allowed_paths: fs_scope + .allowed_patterns() + .into_iter() + .map(|p| p.to_string()) + .collect(), + forbidden_patterns: fs_scope + .forbidden_patterns() + .into_iter() + .map(|p| p.to_string()) + .collect(), + }; + + let _ = create_dir_all(app_dir) + .and_then(|_| File::create(scope_state_path)) + .map_err(Error::Io) + .and_then(|mut f| { + f.write_all(&bincode::serialize(&scope).map_err(Error::from)?) + .map_err(Into::into) + }); + } } pub fn init() -> TauriPlugin { Builder::new("persisted-scope") .setup(|app, _api| { - let fs_scope = app.fs_scope(); - #[cfg(feature = "protocol-asset")] - let asset_protocol_scope = app.asset_protocol_scope(); + let fs_scope = app.try_fs_scope(); + let core_scopes = app.state::(); let app = app.clone(); let app_dir = app.path().app_data_dir(); if let Ok(app_dir) = app_dir { let scope_state_path = app_dir.join(SCOPE_STATE_FILENAME); - let _ = fs_scope.forbid_file(&scope_state_path); - #[cfg(feature = "protocol-asset")] - let _ = asset_protocol_scope.forbid_file(&scope_state_path); + if let Some(s) = fs_scope { + let _ = s.forbid_file(&scope_state_path); + } + let _ = core_scopes.forbid_file(&scope_state_path); // We're trying to fix broken .persisted-scope files seamlessly, so we'll be running this on the values read on the saved file. // We will still save some semi-broken values because the scope events are quite spammy and we don't want to reduce runtime performance any further. @@ -111,16 +112,18 @@ pub fn init() -> TauriPlugin { for allowed in &scope.allowed_paths { let allowed = fix_pattern(&ac, allowed); - let _ = fs_scope.allow_file(&allowed); - #[cfg(feature = "protocol-asset")] - let _ = asset_protocol_scope.allow_file(&allowed); + if let Some(s) = fs_scope { + let _ = s.allow_file(&allowed); + } + let _ = core_scopes.allow_file(&allowed); } for forbidden in &scope.forbidden_patterns { let forbidden = fix_pattern(&ac, forbidden); - let _ = fs_scope.forbid_file(&forbidden); - #[cfg(feature = "protocol-asset")] - let _ = asset_protocol_scope.forbid_file(&forbidden); + if let Some(s) = fs_scope { + let _ = s.forbid_file(&forbidden); + } + let _ = core_scopes.forbid_file(&forbidden); } // Manually save the fixed scopes to disk once. @@ -128,11 +131,13 @@ pub fn init() -> TauriPlugin { save_scopes(&app, &app_dir, &scope_state_path); } - fs_scope.listen(move |event| { - if let FsScopeEvent::PathAllowed(_) = event { - save_scopes(&app, &app_dir, &scope_state_path); - } - }); + if let Some(s) = fs_scope { + s.listen(move |event| { + if let FsScopeEvent::PathAllowed(_) = event { + save_scopes(&app, &app_dir, &scope_state_path); + } + }); + } } Ok(()) }) diff --git a/plugins/positioner/CHANGELOG.md b/plugins/positioner/CHANGELOG.md index 71199780..f0814299 100644 --- a/plugins/positioner/CHANGELOG.md +++ b/plugins/positioner/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! + ## \[0.2.7] - Update Tauri to v1.0.0 diff --git a/plugins/positioner/Cargo.toml b/plugins/positioner/Cargo.toml index dcab86c9..25927a26 100644 --- a/plugins/positioner/Cargo.toml +++ b/plugins/positioner/Cargo.toml @@ -1,21 +1,19 @@ [package] name = "tauri-plugin-positioner" -version = "1.0.4" +version = "2.0.0-alpha.0" description = "Position your windows at well-known locations." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } serde_repr = "0.1" [features] -system-tray = [ "tauri/system-tray" ] \ No newline at end of file +system-tray = [ "tauri/system-tray" ] diff --git a/plugins/positioner/README.md b/plugins/positioner/README.md index ac2a152f..e80eb516 100644 --- a/plugins/positioner/README.md +++ b/plugins/positioner/README.md @@ -6,7 +6,7 @@ This plugin is a port of [electron-positioner](https://github.com/jenslind/elect ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -20,8 +20,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] -tauri-plugin-positioner = "1.0" -# or through git +tauri-plugin-positioner = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-positioner = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -30,16 +30,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh -pnpm add tauri-plugin-positioner-api +pnpm add @tauri-apps/plugin-positioner # or -npm add tauri-plugin-positioner-api +npm add @tauri-apps/plugin-positioner # or -yarn add tauri-plugin-positioner-api -``` - -Or through git: +yarn add @tauri-apps/plugin-positioner -```sh +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-positioner#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-positioner#v2 @@ -69,7 +66,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { move_window, Position } from "tauri-plugin-positioner-api"; +import { move_window, Position } from "@tauri-apps/plugin-positioner"; move_window(Position.TopRight); ``` diff --git a/plugins/positioner/guest-js/index.ts b/plugins/positioner/guest-js/index.ts index dffbf54e..cf6d0f24 100644 --- a/plugins/positioner/guest-js/index.ts +++ b/plugins/positioner/guest-js/index.ts @@ -1,7 +1,13 @@ // Copyright 2021 Jonas Kruckenberg +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT -import { invoke } from "@tauri-apps/api/tauri"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} /** * Well known window positions. @@ -31,7 +37,7 @@ export enum Position { * @param to The {@link Position} to move to. */ export async function moveWindow(to: Position): Promise { - await invoke("plugin:positioner|move_window", { + await window.__TAURI_INVOKE__("plugin:positioner|move_window", { position: to, }); } diff --git a/plugins/positioner/package.json b/plugins/positioner/package.json index 83acb56f..2f064127 100644 --- a/plugins/positioner/package.json +++ b/plugins/positioner/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-positioner-api", - "version": "0.2.7", + "name": "@tauri-apps/plugin-positioner", + "version": "2.0.0-alpha.0", "description": "Position your windows at well-known locations.", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/positioner/src/api-iife.js b/plugins/positioner/src/api-iife.js new file mode 100644 index 00000000..47be9b4d --- /dev/null +++ b/plugins/positioner/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_POSITIONER__=function(t){"use strict";var o;return t.Position=void 0,(o=t.Position||(t.Position={}))[o.TopLeft=0]="TopLeft",o[o.TopRight=1]="TopRight",o[o.BottomLeft=2]="BottomLeft",o[o.BottomRight=3]="BottomRight",o[o.TopCenter=4]="TopCenter",o[o.BottomCenter=5]="BottomCenter",o[o.LeftCenter=6]="LeftCenter",o[o.RightCenter=7]="RightCenter",o[o.Center=8]="Center",o[o.TrayLeft=9]="TrayLeft",o[o.TrayBottomLeft=10]="TrayBottomLeft",o[o.TrayRight=11]="TrayRight",o[o.TrayBottomRight=12]="TrayBottomRight",o[o.TrayCenter=13]="TrayCenter",o[o.TrayBottomCenter=14]="TrayBottomCenter",t.moveWindow=async function(t){await window.__TAURI_INVOKE__("plugin:positioner|move_window",{position:t})},t}({});Object.defineProperty(window.__TAURI__,"positioner",{value:__TAURI_POSITIONER__})} diff --git a/plugins/positioner/src/ext.rs b/plugins/positioner/src/ext.rs index 01d34cf5..196209ad 100644 --- a/plugins/positioner/src/ext.rs +++ b/plugins/positioner/src/ext.rs @@ -1,4 +1,6 @@ // Copyright 2021 Jonas Kruckenberg +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT #[cfg(feature = "system-tray")] diff --git a/plugins/positioner/src/lib.rs b/plugins/positioner/src/lib.rs index ab8cc922..b7f83c41 100644 --- a/plugins/positioner/src/lib.rs +++ b/plugins/positioner/src/lib.rs @@ -1,4 +1,6 @@ // Copyright 2021 Jonas Kruckenberg +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT //! A plugin for Tauri that helps position your windows at well-known locations. @@ -9,6 +11,8 @@ //! //! Note: This requires attaching the Tauri plugin, *even* when using the trait extension only. +#![cfg(not(any(target_os = "android", target_os = "ios")))] + mod ext; pub use ext::*; @@ -58,8 +62,9 @@ async fn move_window(window: tauri::Window, position: Position) - /// The Tauri plugin that exposes [`WindowExt::move_window`] to the webview. pub fn init() -> TauriPlugin { - let plugin = - plugin::Builder::new("positioner").invoke_handler(tauri::generate_handler![move_window]); + let plugin = plugin::Builder::new("positioner") + .js_init_script(include_str!("api-iife.js").to_string()) + .invoke_handler(tauri::generate_handler![move_window]); #[cfg(feature = "system-tray")] let plugin = plugin.setup(|app_handle, _api| { diff --git a/plugins/positioner/tsconfig.json b/plugins/positioner/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/positioner/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/positioner/tsconfig.json b/plugins/positioner/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/positioner/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/process/CHANGELOG.md b/plugins/process/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/process/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/process/Cargo.toml b/plugins/process/Cargo.toml new file mode 100644 index 00000000..f018daa1 --- /dev/null +++ b/plugins/process/Cargo.toml @@ -0,0 +1,10 @@ +[package] +name = "tauri-plugin-process" +version = "2.0.0-alpha.0" +description = "Access the current process of your Tauri application." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } + +[dependencies] +tauri = { workspace = true } diff --git a/plugins/process/LICENSE.spdx b/plugins/process/LICENSE.spdx new file mode 100644 index 00000000..cdd0df5a --- /dev/null +++ b/plugins/process/LICENSE.spdx @@ -0,0 +1,20 @@ +SPDXVersion: SPDX-2.1 +DataLicense: CC0-1.0 +PackageName: tauri +DataFormat: SPDXRef-1 +PackageSupplier: Organization: The Tauri Programme in the Commons Conservancy +PackageHomePage: https://tauri.app +PackageLicenseDeclared: Apache-2.0 +PackageLicenseDeclared: MIT +PackageCopyrightText: 2019-2022, The Tauri Programme in the Commons Conservancy +PackageSummary: Tauri is a rust project that enables developers to make secure +and small desktop applications using a web frontend. + +PackageComment: The package includes the following libraries; see +Relationship information. + +Created: 2019-05-20T09:00:00Z +PackageDownloadLocation: git://github.com/tauri-apps/tauri +PackageDownloadLocation: git+https://github.com/tauri-apps/tauri.git +PackageDownloadLocation: git+ssh://github.com/tauri-apps/tauri.git +Creator: Person: Daniel Thompson-Yvetot \ No newline at end of file diff --git a/plugins/process/LICENSE_APACHE-2.0 b/plugins/process/LICENSE_APACHE-2.0 new file mode 100644 index 00000000..4947287f --- /dev/null +++ b/plugins/process/LICENSE_APACHE-2.0 @@ -0,0 +1,177 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS \ No newline at end of file diff --git a/plugins/process/LICENSE_MIT b/plugins/process/LICENSE_MIT new file mode 100644 index 00000000..4d754725 --- /dev/null +++ b/plugins/process/LICENSE_MIT @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2017 - Present Tauri Apps Contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/plugins/process/README.md b/plugins/process/README.md new file mode 100644 index 00000000..fad3e821 --- /dev/null +++ b/plugins/process/README.md @@ -0,0 +1,78 @@ +# Process + +This plugin provides APIs to access the current process. To spawn child processes, see the [`shell`](https://github.com/tauri-apps/tauri-plugin-shell) plugin. + +## Install + +_This plugin requires a Rust version of at least **1.65**_ + +There are three general methods of installation that we can recommend. + +1. Use crates.io and npm (easiest, and requires you to trust that our publishing pipeline worked) +2. Pull sources directly from Github using git tags / revision hashes (most secure) +3. Git submodule install this repo in your tauri project and then use file protocol to ingest the source (most secure, but inconvenient to use) + +Install the Core plugin by adding the following to your `Cargo.toml` file: + +`src-tauri/Cargo.toml` + +```toml +[dependencies] +tauri-plugin-process = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-process = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +``` + +You can install the JavaScript Guest bindings using your preferred JavaScript package manager: + +> Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. + +```sh +pnpm add @tauri-apps/plugin-process +# or +npm add @tauri-apps/plugin-process +# or +yarn add @tauri-apps/plugin-process + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-process#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-process#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-process#v2 +``` + +## Usage + +First you need to register the core plugin with Tauri: + +`src-tauri/src/main.rs` + +```rust +fn main() { + tauri::Builder::default() + .plugin(tauri_plugin_process::init()) + .run(tauri::generate_context!()) + .expect("error while running tauri application"); +} +``` + +Afterwards all the plugin's APIs are available through the JavaScript guest bindings: + +```javascript +import { exit, relaunch } from "@tauri-apps/plugin-process"; +// exit the app with the given status code +await exit(0); +// restart the app +await relaunch(); +``` + +## Contributing + +PRs accepted. Please make sure to read the Contributing Guide before making a pull request. + +## License + +Code: (c) 2015 - Present - The Tauri Programme within The Commons Conservancy. + +MIT or MIT/Apache 2.0 where applicable. diff --git a/plugins/process/guest-js/index.ts b/plugins/process/guest-js/index.ts new file mode 100644 index 00000000..853e0d29 --- /dev/null +++ b/plugins/process/guest-js/index.ts @@ -0,0 +1,49 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +/** + * Perform operations on the current process. + * @module + */ + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} + +/** + * Exits immediately with the given `exitCode`. + * @example + * ```typescript + * import { exit } from '@tauri-apps/plugin-process'; + * await exit(1); + * ``` + * + * @param code The exit code to use. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ +async function exit(code = 0): Promise { + return window.__TAURI_INVOKE__("plugin:process|exit", { code }); +} + +/** + * Exits the current instance of the app then relaunches it. + * @example + * ```typescript + * import { relaunch } from '@tauri-apps/plugin-process'; + * await relaunch(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ +async function relaunch(): Promise { + return window.__TAURI_INVOKE__("plugin:process|restart"); +} + +export { exit, relaunch }; diff --git a/plugins/process/package.json b/plugins/process/package.json new file mode 100644 index 00000000..d5517cf3 --- /dev/null +++ b/plugins/process/package.json @@ -0,0 +1,32 @@ +{ + "name": "@tauri-apps/plugin-process", + "version": "2.0.0-alpha.0", + "license": "MIT or APACHE-2.0", + "authors": [ + "Tauri Programme within The Commons Conservancy" + ], + "type": "module", + "browser": "dist-js/index.min.js", + "module": "dist-js/index.mjs", + "types": "dist-js/index.d.ts", + "exports": { + "import": "./dist-js/index.mjs", + "types": "./dist-js/index.d.ts", + "browser": "./dist-js/index.min.js" + }, + "scripts": { + "build": "rollup -c" + }, + "files": [ + "dist-js", + "!dist-js/**/*.map", + "README.md", + "LICENSE" + ], + "devDependencies": { + "tslib": "^2.5.0" + }, + "dependencies": { + "@tauri-apps/api": "2.0.0-alpha.4" + } +} diff --git a/plugins/process/rollup.config.mjs b/plugins/process/rollup.config.mjs new file mode 100644 index 00000000..6555e98b --- /dev/null +++ b/plugins/process/rollup.config.mjs @@ -0,0 +1,11 @@ +import { readFileSync } from "fs"; + +import { createConfig } from "../../shared/rollup.config.mjs"; + +export default createConfig({ + input: "guest-js/index.ts", + pkg: JSON.parse( + readFileSync(new URL("./package.json", import.meta.url), "utf8") + ), + external: [/^@tauri-apps\/api/], +}); diff --git a/plugins/process/src/api-iife.js b/plugins/process/src/api-iife.js new file mode 100644 index 00000000..89dfd475 --- /dev/null +++ b/plugins/process/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_PROCESS__=function(_){"use strict";return _.exit=async function(_=0){return window.__TAURI_INVOKE__("plugin:process|exit",{code:_})},_.relaunch=async function(){return window.__TAURI_INVOKE__("plugin:process|restart")},_}({});Object.defineProperty(window.__TAURI__,"process",{value:__TAURI_PROCESS__})} diff --git a/plugins/process/src/commands.rs b/plugins/process/src/commands.rs new file mode 100644 index 00000000..2c27a3d2 --- /dev/null +++ b/plugins/process/src/commands.rs @@ -0,0 +1,15 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use tauri::{AppHandle, Runtime}; + +#[tauri::command] +pub fn exit(app: AppHandle, code: i32) { + app.exit(code) +} + +#[tauri::command] +pub fn restart(app: AppHandle) { + app.restart() +} diff --git a/plugins/process/src/lib.rs b/plugins/process/src/lib.rs new file mode 100644 index 00000000..d6c327b3 --- /dev/null +++ b/plugins/process/src/lib.rs @@ -0,0 +1,17 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use tauri::{ + plugin::{Builder, TauriPlugin}, + Runtime, +}; + +mod commands; + +pub fn init() -> TauriPlugin { + Builder::new("process") + .js_init_script(include_str!("api-iife.js").to_string()) + .invoke_handler(tauri::generate_handler![commands::exit, commands::restart]) + .build() +} diff --git a/plugins/process/tsconfig.json b/plugins/process/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/process/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/shell/CHANGELOG.md b/plugins/shell/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/shell/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/shell/Cargo.toml b/plugins/shell/Cargo.toml index fa517099..2502b782 100644 --- a/plugins/shell/Cargo.toml +++ b/plugins/shell/Cargo.toml @@ -1,18 +1,19 @@ [package] name = "tauri-plugin-shell" -version = "0.0.0" -edition.workspace = true -authors.workspace = true -license.workspace = true +version = "2.0.0-alpha.0" +description = "Access the system shell. Allows you to spawn child processes and manage files and URLs using their default application." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } shared_child = "1" regex = "1" open = "4" encoding_rs = "0.8" -os_pipe = "1" \ No newline at end of file +os_pipe = "1" diff --git a/plugins/shell/README.md b/plugins/shell/README.md index 36385bf4..4d06a1e9 100644 --- a/plugins/shell/README.md +++ b/plugins/shell/README.md @@ -1,10 +1,10 @@ -![plugin-shell](banner.jpg) +# Shell - +Access the system shell. Allows you to spawn child processes and manage files and URLs using their default application. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-shell = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-shell = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-shell +# or +npm add @tauri-apps/plugin-shell +# or +yarn add @tauri-apps/plugin-shell + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-shell#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-shell#v2 @@ -51,7 +60,8 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript - +import { Command } from "@tauri-apps/plugin-shell"; +Command.create("git", ["commit", "-m", "the commit message"]); ``` ## Contributing diff --git a/plugins/shell/guest-js/index.ts b/plugins/shell/guest-js/index.ts index 0cf86b0b..32c34f6e 100644 --- a/plugins/shell/guest-js/index.ts +++ b/plugins/shell/guest-js/index.ts @@ -6,36 +6,19 @@ * Access the system shell. * Allows you to spawn child processes and manage files and URLs using their default application. * - * The APIs must be added to [`tauri.allowlist.shell`](https://tauri.app/v1/api/config/#allowlistconfig.shell) in `tauri.conf.json`: - * ```json - * { - * "tauri": { - * "allowlist": { - * "shell": { - * "all": true, // enable all shell APIs - * "execute": true, // enable process spawn APIs - * "sidecar": true, // enable spawning sidecars - * "open": true // enable opening files/URLs using the default program - * } - * } - * } - * } - * ``` - * It is recommended to allowlist only the APIs you use for optimal bundle size and security. - * * ## Security * * This API has a scope configuration that forces you to restrict the programs and arguments that can be used. * * ### Restricting access to the {@link open | `open`} API * - * On the allowlist, `open: true` means that the {@link open} API can be used with any URL, + * On the configuration object, `open: true` means that the {@link open} API can be used with any URL, * as the argument is validated with the `^((mailto:\w+)|(tel:\w+)|(https?://\w+)).+` regex. * You can change that regex by changing the boolean value to a string, e.g. `open: ^https://github.com/`. * * ### Restricting access to the {@link Command | `Command`} APIs * - * The `shell` allowlist object has a `scope` field that defines an array of CLIs that can be used. + * The plugin configuration object has a `scope` field that defines an array of CLIs that can be used. * Each CLI is a configuration object `{ name: string, cmd: string, sidecar?: bool, args?: boolean | Arg[] }`. * * - `name`: the unique identifier of the command, passed to the {@link Command.create | Command.create function}. @@ -55,18 +38,22 @@ * Configuration: * ```json * { - * "scope": [ - * { - * "name": "run-git-commit", - * "cmd": "git", - * "args": ["commit", "-m", { "validator": "\\S+" }] + * "plugins": { + * "shell": { + * "scope": [ + * { + * "name": "run-git-commit", + * "cmd": "git", + * "args": ["commit", "-m", { "validator": "\\S+" }] + * } + * ] * } - * ] + * } * } * ``` * Usage: * ```typescript - * import { Command } from 'tauri-plugin-shell-api' + * import { Command } from '@tauri-apps/plugin-shell' * Command.create('run-git-commit', ['commit', '-m', 'the commit message']) * ``` * @@ -75,10 +62,17 @@ * @module */ -import { invoke, transformCallback } from "@tauri-apps/api/tauri"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + __TAURI__: { + transformCallback: (cb: (payload: T) => void) => number; + }; + } +} /** - * @since 1.0.0 + * @since 2.0.0 */ interface SpawnOptions { /** Current working directory. */ @@ -88,7 +82,7 @@ interface SpawnOptions { /** * Character encoding for stdout/stderr * - * @since 1.1.0 + * @since 2.0.0 * */ encoding?: string; } @@ -99,7 +93,7 @@ interface InternalSpawnOptions extends SpawnOptions { } /** - * @since 1.0.0 + * @since 2.0.0 */ interface ChildProcess { /** Exit code of the process. `null` if the process was terminated by a signal on Unix. */ @@ -121,6 +115,8 @@ interface ChildProcess { * @param args Program arguments. * @param options Configuration for the process spawn. * @returns A promise resolving to the process id. + * + * @since 2.0.0 */ async function execute( onEvent: (event: CommandEvent) => void, @@ -132,16 +128,16 @@ async function execute( Object.freeze(args); } - return invoke("plugin:shell|execute", { + return window.__TAURI_INVOKE__("plugin:shell|execute", { program, args, options, - onEventFn: transformCallback(onEvent), + onEventFn: window.__TAURI__.transformCallback(onEvent), }); } /** - * @since 1.0.0 + * @since 2.0.0 */ // eslint-disable-next-line @typescript-eslint/no-explicit-any class EventEmitter> { @@ -153,7 +149,7 @@ class EventEmitter> { /** * Alias for `emitter.on(eventName, listener)`. * - * @since 1.1.0 + * @since 2.0.0 */ addListener( eventName: N, @@ -165,7 +161,7 @@ class EventEmitter> { /** * Alias for `emitter.off(eventName, listener)`. * - * @since 1.1.0 + * @since 2.0.0 */ removeListener( eventName: N, @@ -182,7 +178,7 @@ class EventEmitter> { * * Returns a reference to the `EventEmitter`, so that calls can be chained. * - * @since 1.0.0 + * @since 2.0.0 */ on( eventName: N, @@ -204,7 +200,7 @@ class EventEmitter> { * * Returns a reference to the `EventEmitter`, so that calls can be chained. * - * @since 1.1.0 + * @since 2.0.0 */ once( eventName: N, @@ -222,7 +218,7 @@ class EventEmitter> { * Removes the all specified listener from the listener array for the event eventName * Returns a reference to the `EventEmitter`, so that calls can be chained. * - * @since 1.1.0 + * @since 2.0.0 */ off( eventName: N, @@ -242,7 +238,7 @@ class EventEmitter> { * * Returns a reference to the `EventEmitter`, so that calls can be chained. * - * @since 1.1.0 + * @since 2.0.0 */ removeAllListeners(event?: N): this { if (event) { @@ -261,6 +257,8 @@ class EventEmitter> { * to each. * * @returns `true` if the event had listeners, `false` otherwise. + * + * @since 2.0.0 */ emit(eventName: N, arg: E[typeof eventName]): boolean { if (eventName in this.eventListeners) { @@ -276,7 +274,7 @@ class EventEmitter> { /** * Returns the number of listeners listening to the event named `eventName`. * - * @since 1.1.0 + * @since 2.0.0 */ listenerCount(eventName: N): number { if (eventName in this.eventListeners) @@ -293,7 +291,7 @@ class EventEmitter> { * * Returns a reference to the `EventEmitter`, so that calls can be chained. * - * @since 1.1.0 + * @since 2.0.0 */ prependListener( eventName: N, @@ -315,7 +313,7 @@ class EventEmitter> { * * Returns a reference to the `EventEmitter`, so that calls can be chained. * - * @since 1.1.0 + * @since 2.0.0 */ prependOnceListener( eventName: N, @@ -332,7 +330,7 @@ class EventEmitter> { } /** - * @since 1.1.0 + * @since 2.0.0 */ class Child { /** The child process `pid`. */ @@ -348,7 +346,7 @@ class Child { * @param data The message to write, either a string or a byte array. * @example * ```typescript - * import { Command } from 'tauri-plugin-shell-api'; + * import { Command } from '@tauri-apps/plugin-shell'; * const command = Command.create('node'); * const child = await command.spawn(); * await child.write('message'); @@ -356,9 +354,11 @@ class Child { * ``` * * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 */ async write(data: IOPayload): Promise { - return invoke("plugin:shell|stdin_write", { + return window.__TAURI_INVOKE__("plugin:shell|stdin_write", { pid: this.pid, // correctly serialize Uint8Arrays buffer: typeof data === "string" ? data : Array.from(data), @@ -369,9 +369,11 @@ class Child { * Kills the child process. * * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 */ async kill(): Promise { - return invoke("plugin:shell|kill", { + return window.__TAURI_INVOKE__("plugin:shell|kill", { cmd: "killChild", pid: this.pid, }); @@ -392,7 +394,7 @@ interface OutputEvents { * It emits the `close` and `error` events. * @example * ```typescript - * import { Command } from 'tauri-plugin-shell-api'; + * import { Command } from '@tauri-apps/plugin-shell'; * const command = Command.create('node'); * command.on('close', data => { * console.log(`command finished with code ${data.code} and signal ${data.signal}`) @@ -405,7 +407,7 @@ interface OutputEvents { * console.log('pid:', child.pid); * ``` * - * @since 1.1.0 + * @since 2.0.0 * */ class Command extends EventEmitter { @@ -425,7 +427,7 @@ class Command extends EventEmitter { * Creates a new `Command` instance. * * @param program The program name to execute. - * It must be configured on `tauri.conf.json > tauri > allowlist > shell > scope`. + * It must be configured on `tauri.conf.json > plugins > shell > scope`. * @param args Program arguments. * @param options Spawn options. */ @@ -456,13 +458,13 @@ class Command extends EventEmitter { * Creates a command to execute the given program. * @example * ```typescript - * import { Command } from 'tauri-plugin-shell-api'; + * import { Command } from '@tauri-apps/plugin-shell'; * const command = Command.create('my-app', ['run', 'tauri']); * const output = await command.execute(); * ``` * * @param program The program to execute. - * It must be configured on `tauri.conf.json > tauri > allowlist > shell > scope`. + * It must be configured on `tauri.conf.json > plugins > shell > scope`. */ static create( program: string, @@ -488,13 +490,13 @@ class Command extends EventEmitter { * Creates a command to execute the given sidecar program. * @example * ```typescript - * import { Command } from 'tauri-plugin-shell-api'; + * import { Command } from '@tauri-apps/plugin-shell'; * const command = Command.sidecar('my-sidecar'); * const output = await command.execute(); * ``` * * @param program The program to execute. - * It must be configured on `tauri.conf.json > tauri > allowlist > shell > scope`. + * It must be configured on `tauri.conf.json > plugins > shell > scope`. */ static sidecar( program: string, @@ -510,6 +512,8 @@ class Command extends EventEmitter { * Executes the command as a child process, returning a handle to it. * * @returns A promise resolving to the child process handle. + * + * @since 2.0.0 */ async spawn(): Promise { return execute( @@ -539,7 +543,7 @@ class Command extends EventEmitter { * Executes the command as a child process, waiting for it to finish and collecting all of its output. * @example * ```typescript - * import { Command } from 'tauri-plugin-shell-api'; + * import { Command } from '@tauri-apps/plugin-shell'; * const output = await Command.create('echo', 'message').execute(); * assert(output.code === 0); * assert(output.signal === null); @@ -548,6 +552,8 @@ class Command extends EventEmitter { * ``` * * @returns A promise resolving to the child process output. + * + * @since 2.0.0 */ async execute(): Promise> { return new Promise((resolve, reject) => { @@ -624,7 +630,7 @@ type CommandEvent = * * @example * ```typescript - * import { open } from 'tauri-plugin-shell-api'; + * import { open } from '@tauri-apps/plugin-shell'; * // opens the given URL on the default browser: * await open('https://github.com/tauri-apps/tauri'); * // opens the given URL using `firefox`: @@ -634,15 +640,15 @@ type CommandEvent = * ``` * * @param path The path or URL to open. - * This value is matched against the string regex defined on `tauri.conf.json > tauri > allowlist > shell > open`, + * This value is matched against the string regex defined on `tauri.conf.json > plugins > shell > open`, * which defaults to `^((mailto:\w+)|(tel:\w+)|(https?://\w+)).+`. * @param openWith The app to open the file or URL with. * Defaults to the system default application for the specified path type. * - * @since 1.0.0 + * @since 2.0.0 */ async function open(path: string, openWith?: string): Promise { - return invoke("plugin:shell|open", { + return window.__TAURI_INVOKE__("plugin:shell|open", { path, with: openWith, }); diff --git a/plugins/shell/package.json b/plugins/shell/package.json index b6025864..79d2c0c1 100644 --- a/plugins/shell/package.json +++ b/plugins/shell/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-shell-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-shell", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/shell/src/api-iife.js b/plugins/shell/src/api-iife.js new file mode 100644 index 00000000..cb6b28ac --- /dev/null +++ b/plugins/shell/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_SHELL__=function(e){"use strict";class t{constructor(){this.eventListeners=Object.create(null)}addListener(e,t){return this.on(e,t)}removeListener(e,t){return this.off(e,t)}on(e,t){return e in this.eventListeners?this.eventListeners[e].push(t):this.eventListeners[e]=[t],this}once(e,t){const s=n=>{this.removeListener(e,s),t(n)};return this.addListener(e,s)}off(e,t){return e in this.eventListeners&&(this.eventListeners[e]=this.eventListeners[e].filter((e=>e!==t))),this}removeAllListeners(e){return e?delete this.eventListeners[e]:this.eventListeners=Object.create(null),this}emit(e,t){if(e in this.eventListeners){const s=this.eventListeners[e];for(const e of s)e(t);return!0}return!1}listenerCount(e){return e in this.eventListeners?this.eventListeners[e].length:0}prependListener(e,t){return e in this.eventListeners?this.eventListeners[e].unshift(t):this.eventListeners[e]=[t],this}prependOnceListener(e,t){const s=n=>{this.removeListener(e,s),t(n)};return this.prependListener(e,s)}}class s{constructor(e){this.pid=e}async write(e){return window.__TAURI_INVOKE__("plugin:shell|stdin_write",{pid:this.pid,buffer:"string"==typeof e?e:Array.from(e)})}async kill(){return window.__TAURI_INVOKE__("plugin:shell|kill",{cmd:"killChild",pid:this.pid})}}class n extends t{constructor(e,s=[],n){super(),this.stdout=new t,this.stderr=new t,this.program=e,this.args="string"==typeof s?[s]:s,this.options=null!=n?n:{}}static create(e,t=[],s){return new n(e,t,s)}static sidecar(e,t=[],s){const r=new n(e,t,s);return r.options.sidecar=!0,r}async spawn(){return async function(e,t,s=[],n){return"object"==typeof s&&Object.freeze(s),window.__TAURI_INVOKE__("plugin:shell|execute",{program:t,args:s,options:n,onEventFn:window.__TAURI__.transformCallback(e)})}((e=>{switch(e.event){case"Error":this.emit("error",e.payload);break;case"Terminated":this.emit("close",e.payload);break;case"Stdout":this.stdout.emit("data",e.payload);break;case"Stderr":this.stderr.emit("data",e.payload)}}),this.program,this.args,this.options).then((e=>new s(e)))}async execute(){return new Promise(((e,t)=>{this.on("error",t);const s=[],n=[];this.stdout.on("data",(e=>{s.push(e)})),this.stderr.on("data",(e=>{n.push(e)})),this.on("close",(t=>{e({code:t.code,signal:t.signal,stdout:this.collectOutput(s),stderr:this.collectOutput(n)})})),this.spawn().catch(t)}))}collectOutput(e){return"raw"===this.options.encoding?e.reduce(((e,t)=>new Uint8Array([...e,...t,10])),new Uint8Array):e.join("\n")}}return e.Child=s,e.Command=n,e.EventEmitter=t,e.open=async function(e,t){return window.__TAURI_INVOKE__("plugin:shell|open",{path:e,with:t})},e}({});Object.defineProperty(window.__TAURI__,"shell",{value:__TAURI_SHELL__})} diff --git a/plugins/shell/src/commands.rs b/plugins/shell/src/commands.rs index 226022d5..e4b63e24 100644 --- a/plugins/shell/src/commands.rs +++ b/plugins/shell/src/commands.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::{collections::HashMap, path::PathBuf, string::FromUtf8Error}; use encoding_rs::Encoding; diff --git a/plugins/shell/src/config.rs b/plugins/shell/src/config.rs new file mode 100644 index 00000000..5dd32862 --- /dev/null +++ b/plugins/shell/src/config.rs @@ -0,0 +1,150 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use std::path::PathBuf; + +use serde::{de::Error as DeError, Deserialize, Deserializer}; + +/// Configuration for the shell plugin. +#[derive(Debug, Default, PartialEq, Eq, Clone, Deserialize)] +#[serde(rename_all = "camelCase", deny_unknown_fields)] +pub struct Config { + /// Access scope for the binary execution APIs. + /// Sidecars are automatically enabled. + #[serde(default)] + pub scope: ShellAllowlistScope, + /// Open URL with the user's default application. + #[serde(default)] + pub open: ShellAllowlistOpen, +} + +/// A command allowed to be executed by the webview API. +#[derive(Debug, PartialEq, Eq, Clone)] +pub struct ShellAllowedCommand { + /// The name for this allowed shell command configuration. + /// + /// This name will be used inside of the webview API to call this command along with + /// any specified arguments. + pub name: String, + + /// The command name. + /// It can start with a variable that resolves to a system base directory. + /// The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, + /// `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, + /// `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$APP`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, + /// `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`. + // use default just so the schema doesn't flag it as required + pub command: PathBuf, + + /// The allowed arguments for the command execution. + pub args: ShellAllowedArgs, + + /// If this command is a sidecar command. + pub sidecar: bool, +} + +impl<'de> Deserialize<'de> for ShellAllowedCommand { + fn deserialize(deserializer: D) -> Result + where + D: Deserializer<'de>, + { + #[derive(Deserialize)] + struct InnerShellAllowedCommand { + name: String, + #[serde(rename = "cmd")] + command: Option, + #[serde(default)] + args: ShellAllowedArgs, + #[serde(default)] + sidecar: bool, + } + + let config = InnerShellAllowedCommand::deserialize(deserializer)?; + + if !config.sidecar && config.command.is_none() { + return Err(DeError::custom( + "The shell scope `command` value is required.", + )); + } + + Ok(ShellAllowedCommand { + name: config.name, + command: config.command.unwrap_or_default(), + args: config.args, + sidecar: config.sidecar, + }) + } +} + +/// A set of command arguments allowed to be executed by the webview API. +/// +/// A value of `true` will allow any arguments to be passed to the command. `false` will disable all +/// arguments. A list of [`ShellAllowedArg`] will set those arguments as the only valid arguments to +/// be passed to the attached command configuration. +#[derive(Debug, PartialEq, Eq, Clone, Deserialize)] +#[serde(untagged, deny_unknown_fields)] +#[non_exhaustive] +pub enum ShellAllowedArgs { + /// Use a simple boolean to allow all or disable all arguments to this command configuration. + Flag(bool), + + /// A specific set of [`ShellAllowedArg`] that are valid to call for the command configuration. + List(Vec), +} + +impl Default for ShellAllowedArgs { + fn default() -> Self { + Self::Flag(false) + } +} + +/// A command argument allowed to be executed by the webview API. +#[derive(Debug, PartialEq, Eq, Clone, Deserialize)] +#[serde(untagged, deny_unknown_fields)] +#[non_exhaustive] +pub enum ShellAllowedArg { + /// A non-configurable argument that is passed to the command in the order it was specified. + Fixed(String), + + /// A variable that is set while calling the command from the webview API. + /// + Var { + /// [regex] validator to require passed values to conform to an expected input. + /// + /// This will require the argument value passed to this variable to match the `validator` regex + /// before it will be executed. + /// + /// [regex]: https://docs.rs/regex/latest/regex/#syntax + validator: String, + }, +} + +/// Shell scope definition. +/// It is a list of command names and associated CLI arguments that restrict the API access from the webview. +#[derive(Debug, Default, PartialEq, Eq, Clone, Deserialize)] + +pub struct ShellAllowlistScope(pub Vec); + +/// Defines the `shell > open` api scope. +#[derive(Debug, PartialEq, Eq, Clone, Deserialize)] +#[serde(untagged, deny_unknown_fields)] +#[non_exhaustive] +pub enum ShellAllowlistOpen { + /// If the shell open API should be enabled. + /// + /// If enabled, the default validation regex (`^((mailto:\w+)|(tel:\w+)|(https?://\w+)).+`) is used. + Flag(bool), + + /// Enable the shell open API, with a custom regex that the opened path must match against. + /// + /// If using a custom regex to support a non-http(s) schema, care should be used to prevent values + /// that allow flag-like strings to pass validation. e.g. `--enable-debugging`, `-i`, `/R`. + Validate(String), +} + +impl Default for ShellAllowlistOpen { + fn default() -> Self { + Self::Flag(false) + } +} diff --git a/plugins/shell/src/error.rs b/plugins/shell/src/error.rs index 968e70a6..0a673e8a 100644 --- a/plugins/shell/src/error.rs +++ b/plugins/shell/src/error.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::path::PathBuf; use serde::{Serialize, Serializer}; diff --git a/plugins/shell/src/init.js b/plugins/shell/src/init.js new file mode 100644 index 00000000..61cbe3b4 --- /dev/null +++ b/plugins/shell/src/init.js @@ -0,0 +1,39 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +(function () { + // open links with the API + function openLinks() { + document.querySelector("body").addEventListener("click", function (e) { + var target = e.target; + while (target != null) { + if (target.matches("a")) { + if ( + target.href && + ["http://", "https://", "mailto:", "tel:"].some((v) => + target.href.startsWith(v) + ) && + target.target === "_blank" + ) { + window.__TAURI_INVOKE__("plugin:shell|open", { + path: target.href, + }); + e.preventDefault(); + } + break; + } + target = target.parentElement; + } + }); + } + + if ( + document.readyState === "complete" || + document.readyState === "interactive" + ) { + openLinks(); + } else { + window.addEventListener("DOMContentLoaded", openLinks, true); + } +})(); diff --git a/plugins/shell/src/lib.rs b/plugins/shell/src/lib.rs index 70c98dd9..d7637ea5 100644 --- a/plugins/shell/src/lib.rs +++ b/plugins/shell/src/lib.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::{ collections::HashMap, sync::{Arc, Mutex}, @@ -8,16 +12,17 @@ use regex::Regex; use scope::{Scope, ScopeAllowedCommand, ScopeConfig}; use tauri::{ plugin::{Builder, TauriPlugin}, - utils::config::{ShellAllowedArg, ShellAllowedArgs, ShellAllowlistOpen, ShellAllowlistScope}, AppHandle, Manager, RunEvent, Runtime, }; mod commands; +mod config; mod error; mod open; pub mod process; mod scope; +use config::{Config, ShellAllowedArg, ShellAllowedArgs, ShellAllowlistOpen, ShellAllowlistScope}; pub use error::Error; type Result = std::result::Result; type ChildStore = Arc>>; @@ -61,25 +66,25 @@ impl> ShellExt for T { } } -pub fn init() -> TauriPlugin { - Builder::new("shell") +pub fn init() -> TauriPlugin> { + let mut init_script = include_str!("init.js").to_string(); + init_script.push_str(include_str!("api-iife.js")); + + Builder::>::new("shell") + .js_init_script(init_script) .invoke_handler(tauri::generate_handler![ commands::execute, commands::stdin_write, commands::kill, commands::open ]) - .setup(|app, _api| { + .setup(|app, api| { + let default_config = Config::default(); + let config = api.config().as_ref().unwrap_or(&default_config); app.manage(Shell { app: app.clone(), children: Default::default(), - scope: Scope::new( - app, - shell_scope( - app.config().tauri.allowlist.shell.scope.clone(), - &app.config().tauri.allowlist.shell.open, - ), - ), + scope: Scope::new(app, shell_scope(config.scope.clone(), &config.open)), }); Ok(()) }) @@ -111,7 +116,6 @@ fn shell_scope(scope: ShellAllowlistScope, open: &ShellAllowlistOpen) -> ScopeCo Regex::new(validator).unwrap_or_else(|e| panic!("invalid regex {validator}: {e}")); Some(validator) } - _ => panic!("unknown shell open format, unable to prepare"), }; ScopeConfig { @@ -136,11 +140,9 @@ fn get_allowed_clis(scope: ShellAllowlistScope) -> HashMap panic!("unknown shell scope arg, unable to prepare"), }); Some(list.collect()) } - _ => panic!("unknown shell scope command, unable to prepare"), }; ( diff --git a/plugins/shell/src/open.rs b/plugins/shell/src/open.rs index 5cc50927..a46d3f14 100644 --- a/plugins/shell/src/open.rs +++ b/plugins/shell/src/open.rs @@ -104,7 +104,7 @@ impl Program { /// Opens path or URL with the program specified in `with`, or system default if `None`. /// /// The path will be matched against the shell open validation regex, defaulting to `^((mailto:\w+)|(tel:\w+)|(https?://\w+)).+`. -/// A custom validation regex may be supplied in the config in `tauri > allowlist > scope > open`. +/// A custom validation regex may be supplied in the config in `plugins > shell > scope > open`. /// /// # Examples /// diff --git a/plugins/shell/src/process/mod.rs b/plugins/shell/src/process/mod.rs index 1b3befd7..d677d636 100644 --- a/plugins/shell/src/process/mod.rs +++ b/plugins/shell/src/process/mod.rs @@ -200,24 +200,29 @@ impl Command { /// # Examples /// /// ```rust,no_run - /// use tauri::api::process::{Command, CommandEvent}; - /// tauri::async_runtime::spawn(async move { - /// let (mut rx, mut child) = Command::new("cargo") - /// .args(["tauri", "dev"]) - /// .spawn() - /// .expect("Failed to spawn cargo"); + /// use tauri_plugin_shell::{process::CommandEvent, ShellExt}; + /// tauri::Builder::default() + /// .setup(|app| { + /// let handle = app.handle(); + /// tauri::async_runtime::spawn(async move { + /// let (mut rx, mut child) = handle.shell().command("cargo") + /// .args(["tauri", "dev"]) + /// .spawn() + /// .expect("Failed to spawn cargo"); /// - /// let mut i = 0; - /// while let Some(event) = rx.recv().await { - /// if let CommandEvent::Stdout(line) = event { - /// println!("got: {}", String::from_utf8(line).unwrap()); - /// i += 1; - /// if i == 4 { - /// child.write("message from Rust\n".as_bytes()).unwrap(); - /// i = 0; + /// let mut i = 0; + /// while let Some(event) = rx.recv().await { + /// if let CommandEvent::Stdout(line) = event { + /// println!("got: {}", String::from_utf8(line).unwrap()); + /// i += 1; + /// if i == 4 { + /// child.write("message from Rust\n".as_bytes()).unwrap(); + /// i = 0; + /// } + /// } /// } - /// } - /// } + /// }); + /// Ok(()) /// }); /// ``` pub fn spawn(self) -> crate::Result<(Receiver, CommandChild)> { @@ -288,9 +293,13 @@ impl Command { /// /// # Examples /// ```rust,no_run - /// use tauri::api::process::Command; - /// let status = Command::new("which").args(["ls"]).status().unwrap(); - /// println!("`which` finished with status: {:?}", status.code()); + /// use tauri_plugin_shell::ShellExt; + /// tauri::Builder::default() + /// .setup(|app| { + /// let status = tauri::async_runtime::block_on(async move { app.shell().command("which").args(["ls"]).status().await.unwrap() }); + /// println!("`which` finished with status: {:?}", status.code()); + /// Ok(()) + /// }); /// ``` pub async fn status(self) -> crate::Result { let (mut rx, _child) = self.spawn()?; @@ -310,10 +319,14 @@ impl Command { /// # Examples /// /// ```rust,no_run - /// use tauri::api::process::Command; - /// let output = Command::new("echo").args(["TAURI"]).output().unwrap(); - /// assert!(output.status.success()); - /// assert_eq!(String::from_utf8(output.stdout).unwrap(), "TAURI"); + /// use tauri_plugin_shell::ShellExt; + /// tauri::Builder::default() + /// .setup(|app| { + /// let output = tauri::async_runtime::block_on(async move { app.shell().command("echo").args(["TAURI"]).output().await.unwrap() }); + /// assert!(output.status.success()); + /// assert_eq!(String::from_utf8(output.stdout).unwrap(), "TAURI"); + /// Ok(()) + /// }); /// ``` pub async fn output(self) -> crate::Result { let (mut rx, _child) = self.spawn()?; @@ -387,7 +400,7 @@ mod tests { #[cfg(not(windows))] #[test] fn test_cmd_spawn_output() { - let cmd = Command::new("cat").args(["test/api/test.txt"]); + let cmd = Command::new("cat").args(["test/test.txt"]); let (mut rx, _) = cmd.spawn().unwrap(); tauri::async_runtime::block_on(async move { @@ -408,7 +421,7 @@ mod tests { #[cfg(not(windows))] #[test] fn test_cmd_spawn_raw_output() { - let cmd = Command::new("cat").args(["test/api/test.txt"]); + let cmd = Command::new("cat").args(["test/test.txt"]); let (mut rx, _) = cmd.spawn().unwrap(); tauri::async_runtime::block_on(async move { @@ -430,7 +443,7 @@ mod tests { #[test] // test the failure case fn test_cmd_spawn_fail() { - let cmd = Command::new("cat").args(["test/api/"]); + let cmd = Command::new("cat").args(["test/"]); let (mut rx, _) = cmd.spawn().unwrap(); tauri::async_runtime::block_on(async move { @@ -442,7 +455,7 @@ mod tests { CommandEvent::Stderr(line) => { assert_eq!( String::from_utf8(line).unwrap(), - "cat: test/api/: Is a directory" + "cat: test/: Is a directory" ); } _ => {} @@ -455,7 +468,7 @@ mod tests { #[test] // test the failure case (raw encoding) fn test_cmd_spawn_raw_fail() { - let cmd = Command::new("cat").args(["test/api/"]); + let cmd = Command::new("cat").args(["test/"]); let (mut rx, _) = cmd.spawn().unwrap(); tauri::async_runtime::block_on(async move { @@ -467,7 +480,7 @@ mod tests { CommandEvent::Stderr(line) => { assert_eq!( String::from_utf8(line).unwrap(), - "cat: test/api/: Is a directory" + "cat: test/: Is a directory" ); } _ => {} @@ -479,7 +492,7 @@ mod tests { #[cfg(not(windows))] #[test] fn test_cmd_output_output() { - let cmd = Command::new("cat").args(["test/api/test.txt"]); + let cmd = Command::new("cat").args(["test/test.txt"]); let output = tauri::async_runtime::block_on(cmd.output()).unwrap(); assert_eq!(String::from_utf8(output.stderr).unwrap(), ""); @@ -492,13 +505,13 @@ mod tests { #[cfg(not(windows))] #[test] fn test_cmd_output_output_fail() { - let cmd = Command::new("cat").args(["test/api/"]); + let cmd = Command::new("cat").args(["test/"]); let output = tauri::async_runtime::block_on(cmd.output()).unwrap(); assert_eq!(String::from_utf8(output.stdout).unwrap(), ""); assert_eq!( String::from_utf8(output.stderr).unwrap(), - "cat: test/api/: Is a directory\n" + "cat: test/: Is a directory\n" ); } } diff --git a/plugins/shell/src/scope.rs b/plugins/shell/src/scope.rs index 871f3940..67ebde6a 100644 --- a/plugins/shell/src/scope.rs +++ b/plugins/shell/src/scope.rs @@ -248,7 +248,7 @@ impl Scope { /// Open a path in the default (or specified) browser. /// - /// The path is validated against the `tauri > allowlist > shell > open` validation regex, which + /// The path is validated against the `plugins > shell > open` validation regex, which /// defaults to `^((mailto:\w+)|(tel:\w+)|(https?://\w+)).+`. pub fn open(&self, path: &str, with: Option) -> Result<(), Error> { // ensure we pass validation if the configuration has one diff --git a/plugins/shell/test/test.txt b/plugins/shell/test/test.txt new file mode 100644 index 00000000..ec77307a --- /dev/null +++ b/plugins/shell/test/test.txt @@ -0,0 +1 @@ +This is a test doc! \ No newline at end of file diff --git a/plugins/single-instance/CHANGELOG.md b/plugins/single-instance/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/single-instance/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/single-instance/Cargo.toml b/plugins/single-instance/Cargo.toml index be46f3aa..9c4fc139 100644 --- a/plugins/single-instance/Cargo.toml +++ b/plugins/single-instance/Cargo.toml @@ -1,33 +1,31 @@ [package] name = "tauri-plugin-single-instance" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Ensure a single instance of your tauri app is running." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true -exclude = ["/examples"] - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } +exclude = [ "/examples" ] [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } -[target.'cfg(target_os = "windows")'.dependencies.windows-sys] +[target."cfg(target_os = \"windows\")".dependencies.windows-sys] version = "0.48" features = [ - "Win32_System_Threading", - "Win32_System_DataExchange", - "Win32_Foundation", - "Win32_UI_WindowsAndMessaging", - "Win32_Security", - "Win32_System_LibraryLoader", - "Win32_Graphics_Gdi", + "Win32_System_Threading", + "Win32_System_DataExchange", + "Win32_Foundation", + "Win32_UI_WindowsAndMessaging", + "Win32_Security", + "Win32_System_LibraryLoader", + "Win32_Graphics_Gdi" ] -[target.'cfg(target_os = "linux")'.dependencies] +[target."cfg(target_os = \"linux\")".dependencies] zbus = "3" diff --git a/plugins/single-instance/README.md b/plugins/single-instance/README.md index 18ad3f6f..2cb2d88e 100644 --- a/plugins/single-instance/README.md +++ b/plugins/single-instance/README.md @@ -4,7 +4,7 @@ Ensure a single instance of your tauri app is running. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-single-instance = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-single-instance = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` diff --git a/plugins/single-instance/examples/vanilla/package.json b/plugins/single-instance/examples/vanilla/package.json index a2967169..750f083e 100644 --- a/plugins/single-instance/examples/vanilla/package.json +++ b/plugins/single-instance/examples/vanilla/package.json @@ -8,7 +8,7 @@ }, "author": "", "license": "MIT", - "dependencies": { - "@tauri-apps/cli": "^2.0.0-alpha.8" + "devDependencies": { + "@tauri-apps/cli": "^2.0.0-alpha.9" } } diff --git a/plugins/single-instance/examples/vanilla/src-tauri/Cargo.lock b/plugins/single-instance/examples/vanilla/src-tauri/Cargo.lock deleted file mode 100644 index 588ea9a6..00000000 --- a/plugins/single-instance/examples/vanilla/src-tauri/Cargo.lock +++ /dev/null @@ -1,4064 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "adler32" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aae1277d39aeec15cb388266ecc24b11c80469deae6067e17a1a7aa9e5c1f234" - -[[package]] -name = "aho-corasick" -version = "0.7.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4f55bd91a0978cbfd91c457a164bab8b4001c833b7f323132c0a4e1922dd44e" -dependencies = [ - "memchr", -] - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "ansi_term" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d52a9bb7ec0cf484c551830a7ce27bd20d67eac647e1befb56b0be4ee39a55d2" -dependencies = [ - "winapi", -] - -[[package]] -name = "anyhow" -version = "1.0.65" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98161a4e3e2184da77bb14f02184cdd111e83bbbcc9979dfee3c44b9a85f5602" - -[[package]] -name = "app" -version = "0.1.0" -dependencies = [ - "serde", - "serde_json", - "tauri", - "tauri-build", - "tauri-plugin-single-instance", -] - -[[package]] -name = "async-broadcast" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d26004fe83b2d1cd3a97609b21e39f9a31535822210fe83205d2ce48866ea61" -dependencies = [ - "event-listener", - "futures-core", - "parking_lot", -] - -[[package]] -name = "async-channel" -version = "1.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14485364214912d3b19cc3435dde4df66065127f05fa0d75c712f36f12c2f28" -dependencies = [ - "concurrent-queue", - "event-listener", - "futures-core", -] - -[[package]] -name = "async-executor" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "871f9bb5e0a22eeb7e8cf16641feb87c9dc67032ccf8ff49e772eb9941d3a965" -dependencies = [ - "async-task", - "concurrent-queue", - "fastrand", - "futures-lite", - "once_cell", - "slab", -] - -[[package]] -name = "async-io" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83e21f3a490c72b3b0cf44962180e60045de2925d8dff97918f7ee43c8f637c7" -dependencies = [ - "autocfg", - "concurrent-queue", - "futures-lite", - "libc", - "log", - "once_cell", - "parking", - "polling", - "slab", - "socket2", - "waker-fn", - "winapi", -] - -[[package]] -name = "async-lock" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8101efe8695a6c17e02911402145357e718ac92d3ff88ae8419e84b1707b685" -dependencies = [ - "event-listener", - "futures-lite", -] - -[[package]] -name = "async-recursion" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2cda8f4bcc10624c4e85bc66b3f452cca98cfa5ca002dc83a16aad2367641bea" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "async-task" -version = "4.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a40729d2133846d9ed0ea60a8b9541bccddab49cd30f0715a1da672fe9a2524" - -[[package]] -name = "async-trait" -version = "0.1.58" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e805d94e6b5001b651426cf4cd446b1ab5f319d27bab5c644f61de0a804360c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "atk" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c3d816ce6f0e2909a96830d6911c2aff044370b1ef92d7f267b43bae5addedd" -dependencies = [ - "atk-sys", - "bitflags", - "glib", - "libc", -] - -[[package]] -name = "atk-sys" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58aeb089fb698e06db8089971c7ee317ab9644bade33383f63631437b03aafb6" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps 6.0.2", -] - -[[package]] -name = "attohttpc" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fcf00bc6d5abb29b5f97e3c61a90b6d3caa12f3faf897d4a3e3607c050a35a7" -dependencies = [ - "flate2", - "http", - "log", - "native-tls", - "serde", - "serde_json", - "serde_urlencoded", - "url", -] - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "base64" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fd" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "block" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" - -[[package]] -name = "block-buffer" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69cce20737498f97b993470a6e536b8523f0af7892a4f928cceb1ac5e52ebe7e" -dependencies = [ - "generic-array", -] - -[[package]] -name = "brotli" -version = "3.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a0b1dbcc8ae29329621f8d4f0d835787c1c38bb1401979b49d13b0b305ff68" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59ad2d4653bf5ca36ae797b1f4bb4dbddb60ce49ca4aed8a2ce4829f60425b80" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bstr" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3569f383e8f1598449f1a423e72e99569137b47740b1da11ef19af3d5c3223" -dependencies = [ - "memchr", -] - -[[package]] -name = "bumpalo" -version = "3.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1ad822118d20d2c234f427000d5acc36eabe1e29a348c89b63dd60b13f28e5d" - -[[package]] -name = "bytemuck" -version = "1.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f5715e491b5a1598fc2bef5a606847b5dc1d48ea625bd3c02c00de8285591da" - -[[package]] -name = "byteorder" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" - -[[package]] -name = "bytes" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec8a7b6a70fde80372154c65702f00a0f56f3e1c36abbc6c440484be248856db" - -[[package]] -name = "cache-padded" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1db59621ec70f09c5e9b597b220c7a2b43611f4710dc03ceb8748637775692c" - -[[package]] -name = "cairo-rs" -version = "0.15.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c76ee391b03d35510d9fa917357c7f1855bd9a6659c95a1b392e33f49b3369bc" -dependencies = [ - "bitflags", - "cairo-sys-rs", - "glib", - "libc", - "thiserror", -] - -[[package]] -name = "cairo-sys-rs" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c55d429bef56ac9172d25fecb85dc8068307d17acd74b377866b7a1ef25d3c8" -dependencies = [ - "glib-sys", - "libc", - "system-deps 6.0.2", -] - -[[package]] -name = "cargo_toml" -version = "0.11.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e72c3ff59e3b7d24630206bb63a73af65da4ed5df1f76ee84dfafb9fee2ba60e" -dependencies = [ - "serde", - "serde_derive", - "toml", -] - -[[package]] -name = "cc" -version = "1.0.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11" - -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - -[[package]] -name = "cfb" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74f89d248799e3f15f91b70917f65381062a01bb8e222700ea0e5a7ff9785f9c" -dependencies = [ - "byteorder", - "uuid 0.8.2", -] - -[[package]] -name = "cfg-expr" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3431df59f28accaf4cb4eed4a9acc66bea3f3c3753aa6cdc2f024174ef232af7" -dependencies = [ - "smallvec", -] - -[[package]] -name = "cfg-expr" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0aacacf4d96c24b2ad6eb8ee6df040e4f27b0d0b39a5710c30091baa830485db" -dependencies = [ - "smallvec", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "cocoa" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f63902e9223530efb4e26ccd0cf55ec30d592d3b42e21a28defc42a9586e832" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation", - "core-graphics", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa-foundation" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ade49b65d560ca58c403a479bb396592b155c0185eada742ee323d1d68d6318" -dependencies = [ - "bitflags", - "block", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "color_quant" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" - -[[package]] -name = "combine" -version = "4.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] - -[[package]] -name = "concurrent-queue" -version = "1.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af4780a44ab5696ea9e28294517f1fffb421a83a25af521333c838635509db9c" -dependencies = [ - "cache-padded", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dc" - -[[package]] -name = "core-graphics" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" -dependencies = [ - "bitflags", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" -dependencies = [ - "bitflags", - "core-foundation", - "foreign-types", - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28d997bd5e24a5928dd43e46dc529867e207907fe0b239c3477d924f7f2ca320" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2dd04ddaf88237dc3b8d8f9a3c1004b506b54b3313403944054d23c0870c521" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51887d4adc7b564537b15adcfb307936f8075dfcd5f00dde9a9f1d29383682bc" -dependencies = [ - "cfg-if", - "once_cell", -] - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "cssparser" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "754b69d351cdc2d8ee09ae203db831e005560fc6030da058f86ad60c92a9cb0a" -dependencies = [ - "cssparser-macros", - "dtoa-short", - "itoa 0.4.8", - "matches", - "phf 0.8.0", - "proc-macro2", - "quote", - "smallvec", - "syn", -] - -[[package]] -name = "cssparser-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfae75de57f2b2e85e8768c3ea840fd159c8f33e2b6522c7835b7abac81be16e" -dependencies = [ - "quote", - "syn", -] - -[[package]] -name = "ctor" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdffe87e1d521a10f9696f833fe502293ea446d7f256c06128293a4119bdf4cb" -dependencies = [ - "quote", - "syn", -] - -[[package]] -name = "cty" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b365fabc795046672053e29c954733ec3b05e4be654ab130fe8f1f94d7051f35" - -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core", - "quote", - "syn", -] - -[[package]] -name = "dbus" -version = "0.9.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f8bcdd56d2e5c4ed26a529c5a9029f5db8290d433497506f958eae3be148eb6" -dependencies = [ - "libc", - "libdbus-sys", - "winapi", -] - -[[package]] -name = "deflate" -version = "0.7.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "707b6a7b384888a70c8d2e8650b3e60170dfc6a67bb4aa67b6dfca57af4bedb4" -dependencies = [ - "adler32", - "byteorder", -] - -[[package]] -name = "derivative" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "derive_more" -version = "0.99.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version 0.4.0", - "syn", -] - -[[package]] -name = "digest" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adfbc57365a37acbd2ebf2b64d7e69bb766e2fea813521ed536f5d0520dcf86c" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dirs" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3aa72a6f96ea37bbc5aa912f6788242832f75369bdfdadcb0e38423f100059" -dependencies = [ - "dirs-sys", -] - -[[package]] -name = "dirs-next" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" -dependencies = [ - "cfg-if", - "dirs-sys-next", -] - -[[package]] -name = "dirs-sys" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dirs-sys-next" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dispatch" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" - -[[package]] -name = "dtoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" - -[[package]] -name = "dtoa-short" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde03329ae10e79ede66c9ce4dc930aa8599043b0743008548680f25b91502d6" -dependencies = [ - "dtoa", -] - -[[package]] -name = "embed_plist" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" - -[[package]] -name = "encoding_rs" -version = "0.8.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9852635589dc9f9ea1b6fe9f05b50ef208c85c834a562f0c6abb1c475736ec2b" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "enumflags2" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e75d4cd21b95383444831539909fbb14b9dc3fdceb2a6f5d36577329a1f55ccb" -dependencies = [ - "enumflags2_derive", - "serde", -] - -[[package]] -name = "enumflags2_derive" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f58dc3c5e468259f19f2d46304a6b28f1c3d034442e14b322d2b850e36f6d5ae" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "event-listener" -version = "2.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" - -[[package]] -name = "fastrand" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a407cfaa3385c4ae6b23e84623d48c2798d06e3e6a1878f7f59f17b3f86499" -dependencies = [ - "instant", -] - -[[package]] -name = "field-offset" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e1c54951450cbd39f3dbcf1005ac413b49487dabf18a720ad2383eccfeffb92" -dependencies = [ - "memoffset", - "rustc_version 0.3.3", -] - -[[package]] -name = "filetime" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94a7bbaa59354bc20dd75b67f23e2797b4490e9d6928203fb105c79e448c86c" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "windows-sys 0.36.1", -] - -[[package]] -name = "flate2" -version = "1.0.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f82b0f4c27ad9f8bfd1f3208d882da2b09c301bc1c828fd3a00d0216d2fbbff6" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futf" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df420e2e84819663797d1ec6544b13c5be84629e7bb00dc960d6917db2987843" -dependencies = [ - "mac", - "new_debug_unreachable", -] - -[[package]] -name = "futures-channel" -version = "0.3.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30bdd20c28fadd505d0fd6712cdfcb0d4b5648baf45faef7f852afb2399bb050" -dependencies = [ - "futures-core", -] - -[[package]] -name = "futures-core" -version = "0.3.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04909a7a7e4633ae6c4a9ab280aeb86da1236243a77b694a49eacd659a4bd3ac" - -[[package]] -name = "futures-executor" -version = "0.3.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ff63c23854bee61b6e9cd331d523909f238fc7636290b96826e9cfa5faa00ab" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbf4d2a7a308fd4578637c0b17c7e1c7ba127b8f6ba00b29f717e9655d85eb68" - -[[package]] -name = "futures-lite" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7694489acd39452c77daa48516b894c153f192c3578d5a839b62c58099fcbf48" -dependencies = [ - "fastrand", - "futures-core", - "futures-io", - "memchr", - "parking", - "pin-project-lite", - "waker-fn", -] - -[[package]] -name = "futures-macro" -version = "0.3.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bdfb8ce053d86b91919aad980c220b1fb8401a9394410e1c289ed7e66b61835d" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "futures-sink" -version = "0.3.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39c15cf1a4aa79df40f1bb462fb39676d0ad9e366c2a33b590d7c66f4f81fcf9" - -[[package]] -name = "futures-task" -version = "0.3.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ffb393ac5d9a6eaa9d3fdf37ae2776656b706e200c8e16b1bdb227f5198e6ea" - -[[package]] -name = "futures-util" -version = "0.3.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "197676987abd2f9cadff84926f410af1c183608d36641465df73ae8211dc65d6" -dependencies = [ - "futures-core", - "futures-macro", - "futures-sink", - "futures-task", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "fxhash" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" -dependencies = [ - "byteorder", -] - -[[package]] -name = "gdk" -version = "0.15.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6e05c1f572ab0e1f15be94217f0dc29088c248b14f792a5ff0af0d84bcda9e8" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk-pixbuf", - "gdk-sys", - "gio", - "glib", - "libc", - "pango", -] - -[[package]] -name = "gdk-pixbuf" -version = "0.15.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad38dd9cc8b099cceecdf41375bb6d481b1b5a7cd5cd603e10a69a9383f8619a" -dependencies = [ - "bitflags", - "gdk-pixbuf-sys", - "gio", - "glib", - "libc", -] - -[[package]] -name = "gdk-pixbuf-sys" -version = "0.15.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "140b2f5378256527150350a8346dbdb08fadc13453a7a2d73aecd5fab3c402a7" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps 6.0.2", -] - -[[package]] -name = "gdk-sys" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32e7a08c1e8f06f4177fb7e51a777b8c1689f743a7bc11ea91d44d2226073a88" -dependencies = [ - "cairo-sys-rs", - "gdk-pixbuf-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "pango-sys", - "pkg-config", - "system-deps 6.0.2", -] - -[[package]] -name = "gdkx11-sys" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4b7f8c7a84b407aa9b143877e267e848ff34106578b64d1e0a24bf550716178" -dependencies = [ - "gdk-sys", - "glib-sys", - "libc", - "system-deps 6.0.2", - "x11", -] - -[[package]] -name = "generator" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc184cace1cea8335047a471cc1da80f18acf8a76f3bab2028d499e328948ec7" -dependencies = [ - "cc", - "libc", - "log", - "rustversion", - "windows 0.32.0", -] - -[[package]] -name = "generic-array" -version = "0.14.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bff49e947297f3312447abdca79f45f4738097cc82b06e72054d2223f601f1b9" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4eb1a864a501629691edf6c15a593b7a51eebaa1e8468e9ddc623de7c9b58ec6" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gio" -version = "0.15.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68fdbc90312d462781a395f7a16d96a2b379bb6ef8cd6310a2df272771c4283b" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-io", - "gio-sys", - "glib", - "libc", - "once_cell", - "thiserror", -] - -[[package]] -name = "gio-sys" -version = "0.15.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32157a475271e2c4a023382e9cab31c4584ee30a97da41d3c4e9fdd605abcf8d" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps 6.0.2", - "winapi", -] - -[[package]] -name = "glib" -version = "0.15.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "edb0306fbad0ab5428b0ca674a23893db909a98582969c9b537be4ced78c505d" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-executor", - "futures-task", - "glib-macros", - "glib-sys", - "gobject-sys", - "libc", - "once_cell", - "smallvec", - "thiserror", -] - -[[package]] -name = "glib-macros" -version = "0.15.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25a68131a662b04931e71891fb14aaf65ee4b44d08e8abc10f49e77418c86c64" -dependencies = [ - "anyhow", - "heck 0.4.0", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "glib-sys" -version = "0.15.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef4b192f8e65e9cf76cbf4ea71fa8e3be4a0e18ffe3d68b8da6836974cc5bad4" -dependencies = [ - "libc", - "system-deps 6.0.2", -] - -[[package]] -name = "glob" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b919933a397b79c37e33b77bb2aa3dc8eb6e165ad809e58ff75bc7db2e34574" - -[[package]] -name = "globset" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a1e17342619edbc21a964c2afbeb6c820c6a2560032872f397bb97ea127bd0a" -dependencies = [ - "aho-corasick", - "bstr", - "fnv", - "log", - "regex", -] - -[[package]] -name = "gobject-sys" -version = "0.15.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d57ce44246becd17153bd035ab4d32cfee096a657fc01f2231c9278378d1e0a" -dependencies = [ - "glib-sys", - "libc", - "system-deps 6.0.2", -] - -[[package]] -name = "gtk" -version = "0.15.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92e3004a2d5d6d8b5057d2b57b3712c9529b62e82c77f25c1fecde1fd5c23bd0" -dependencies = [ - "atk", - "bitflags", - "cairo-rs", - "field-offset", - "futures-channel", - "gdk", - "gdk-pixbuf", - "gio", - "glib", - "gtk-sys", - "gtk3-macros", - "libc", - "once_cell", - "pango", - "pkg-config", -] - -[[package]] -name = "gtk-sys" -version = "0.15.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5bc2f0587cba247f60246a0ca11fe25fb733eabc3de12d1965fc07efab87c84" -dependencies = [ - "atk-sys", - "cairo-sys-rs", - "gdk-pixbuf-sys", - "gdk-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "pango-sys", - "system-deps 6.0.2", -] - -[[package]] -name = "gtk3-macros" -version = "0.15.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24f518afe90c23fba585b2d7697856f9e6a7bbc62f65588035e66f6afb01a2e9" -dependencies = [ - "anyhow", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - -[[package]] -name = "heck" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "heck" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2540771e65fc8cb83cd6e8a237f70c319bd5c29f78ed1084ba5d50eeac86f7f9" - -[[package]] -name = "hermit-abi" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" -dependencies = [ - "libc", -] - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "html5ever" -version = "0.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c13fb08e5d4dfc151ee5e88bae63f7773d61852f3bdc73c9f4b9e1bde03148" -dependencies = [ - "log", - "mac", - "markup5ever", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "http" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75f43d41e26995c17e71ee126451dd3941010b0514a81a9d11f3b341debc2399" -dependencies = [ - "bytes", - "fnv", - "itoa 1.0.3", -] - -[[package]] -name = "http-range" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21dec9db110f5f872ed9699c3ecf50cf16f423502706ba5c72462e28d3157573" - -[[package]] -name = "ico" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a4b3331534254a9b64095ae60d3dc2a8225a7a70229cd5888be127cdc1f6804" -dependencies = [ - "byteorder", - "png 0.11.0", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "713f1b139373f96a2e0ce3ac931cd01ee973c3c5dd7c40c0c2efe96ad2b6751d" -dependencies = [ - "crossbeam-utils", - "globset", - "lazy_static", - "log", - "memchr", - "regex", - "same-file", - "thread_local", - "walkdir", - "winapi-util", -] - -[[package]] -name = "image" -version = "0.24.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd8e4fb07cf672b1642304e731ef8a6a4c7891d67bb4fd4f5ce58cd6ed86803c" -dependencies = [ - "bytemuck", - "byteorder", - "color_quant", - "num-rational", - "num-traits", -] - -[[package]] -name = "indexmap" -version = "1.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10a35a97730320ffe8e2d410b5d3b69279b98d2c14bdb8b70ea89ecf7888d41e" -dependencies = [ - "autocfg", - "hashbrown", -] - -[[package]] -name = "infer" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20b2b533137b9cad970793453d4f921c2e91312a6d88b1085c07bc15fc51bb3b" -dependencies = [ - "cfb", -] - -[[package]] -name = "inflate" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5f9f47468e9a76a6452271efadc88fe865a82be91fe75e6c0c57b87ccea59d4" -dependencies = [ - "adler32", -] - -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "itoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4" - -[[package]] -name = "itoa" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8af84674fe1f223a982c933a0ee1086ac4d4052aa0fb8060c12c6ad838e754" - -[[package]] -name = "javascriptcore-rs" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf053e7843f2812ff03ef5afe34bb9c06ffee120385caad4f6b9967fcd37d41c" -dependencies = [ - "bitflags", - "glib", - "javascriptcore-rs-sys", -] - -[[package]] -name = "javascriptcore-rs-sys" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "905fbb87419c5cde6e3269537e4ea7d46431f3008c5d057e915ef3f115e7793c" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps 5.0.0", -] - -[[package]] -name = "jni" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6df18c2e3db7e453d3c6ac5b3e9d5182664d28788126d39b91f2d1e22b017ec" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - -[[package]] -name = "jni-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" - -[[package]] -name = "js-sys" -version = "0.3.60" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49409df3e3bf0856b916e2ceaca09ee28e6871cf7d9ce97a692cacfdb2a25a47" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "json-patch" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f995a3c8f2bc3dd52a18a583e90f9ec109c047fa1603a853e46bcda14d2e279d" -dependencies = [ - "serde", - "serde_json", - "treediff", -] - -[[package]] -name = "kuchiki" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ea8e9c6e031377cff82ee3001dc8026cdf431ed4e2e6b51f98ab8c73484a358" -dependencies = [ - "cssparser", - "html5ever", - "matches", - "selectors", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.137" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc7fcc620a3bff7cdd7a365be3376c97191aeaccc2a603e600951e452615bf89" - -[[package]] -name = "libdbus-sys" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c185b5b7ad900923ef3a8ff594083d4d9b5aea80bb4f32b8342363138c0d456b" -dependencies = [ - "pkg-config", -] - -[[package]] -name = "line-wrap" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30344350a2a51da54c1d53be93fade8a237e545dbcc4bdbe635413f2117cab9" -dependencies = [ - "safemem", -] - -[[package]] -name = "lock_api" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "loom" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff50ecb28bb86013e935fb6683ab1f6d3a20016f123c76fd4c27470076ac30f5" -dependencies = [ - "cfg-if", - "generator", - "scoped-tls", - "serde", - "serde_json", - "tracing", - "tracing-subscriber", -] - -[[package]] -name = "mac" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4" - -[[package]] -name = "mac-notification-sys" -version = "0.5.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e72d50edb17756489e79d52eb146927bec8eba9dd48faadf9ef08bca3791ad5" -dependencies = [ - "cc", - "dirs-next", - "objc-foundation", - "objc_id", - "time", -] - -[[package]] -name = "malloc_buf" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb" -dependencies = [ - "libc", -] - -[[package]] -name = "markup5ever" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a24f40fb03852d1cdd84330cddcaf98e9ec08a7b7768e952fad3b4cf048ec8fd" -dependencies = [ - "log", - "phf 0.8.0", - "phf_codegen", - "string_cache", - "string_cache_codegen", - "tendril", -] - -[[package]] -name = "matchers" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" -dependencies = [ - "regex-automata", -] - -[[package]] -name = "matches" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3e378b66a060d48947b590737b30a1be76706c8dd7b8ba0f2fe3989c68a853f" - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "memoffset" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aa361d4faea93603064a027415f07bd8e1d5c88c9fbf68bf56a285428fd79ce" -dependencies = [ - "autocfg", -] - -[[package]] -name = "miniz_oxide" -version = "0.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96590ba8f175222643a85693f33d26e9c8a015f599c216509b1a6894af675d34" -dependencies = [ - "adler", -] - -[[package]] -name = "native-tls" -version = "0.2.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd7e2f3618557f980e0b17e8856252eee3c97fa12c54dff0ca290fb6266ca4a9" -dependencies = [ - "lazy_static", - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "ndk" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2032c77e030ddee34a6787a64166008da93f6a352b629261d0fee232b8742dd4" -dependencies = [ - "bitflags", - "jni-sys", - "ndk-sys", - "num_enum", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5a6ae77c8ee183dcbbba6150e2e6b9f3f4196a7666c02a715a95692ec1fa97" -dependencies = [ - "jni-sys", -] - -[[package]] -name = "new_debug_unreachable" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" - -[[package]] -name = "nix" -version = "0.25.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e322c04a9e3440c327fca7b6c8a63e6890a32fa2ad689db972425f07e0d22abb" -dependencies = [ - "autocfg", - "bitflags", - "cfg-if", - "libc", - "memoffset", - "pin-utils", -] - -[[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] -name = "notify-rust" -version = "4.5.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "368e89ea58df747ce88be669ae44e79783c1d30bfd540ad0fc520b3f41f0b3b0" -dependencies = [ - "dbus", - "mac-notification-sys", - "tauri-winrt-notification", -] - -[[package]] -name = "num-integer" -version = "0.1.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-iter" -version = "0.1.43" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d03e6c028c5dc5cac6e2dec0efda81fc887605bb3d884578bb6d6bf7514e252" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "578ede34cf02f8924ab9447f50c28075b4d3e5b269972345e7e0372b38c6cdcd" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19e64526ebdee182341572e50e9ad03965aa510cd94427a4549448f285e957a1" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf5395665662ef45796a4ff5486c5d41d29e0c09640af4c5f17fd94ee2c119c9" -dependencies = [ - "num_enum_derive", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b0498641e53dd6ac1a4f22547548caa6864cc4933784319cd1775271c5a46ce" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "num_threads" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2819ce041d2ee131036f4fc9d6ae7ae125a3a40e97ba64d04fe799ad9dabbb44" -dependencies = [ - "libc", -] - -[[package]] -name = "objc" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1" -dependencies = [ - "malloc_buf", - "objc_exception", -] - -[[package]] -name = "objc-foundation" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1add1b659e36c9607c7aab864a76c7a4c2760cd0cd2e120f3fb8b952c7e22bf9" -dependencies = [ - "block", - "objc", - "objc_id", -] - -[[package]] -name = "objc_exception" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad970fb455818ad6cba4c122ad012fae53ae8b4795f86378bce65e4f6bab2ca4" -dependencies = [ - "cc", -] - -[[package]] -name = "objc_id" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b" -dependencies = [ - "objc", -] - -[[package]] -name = "once_cell" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e82dad04139b71a90c080c8463fe0dc7902db5192d939bd0950f074d014339e1" - -[[package]] -name = "open" -version = "3.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4a3100141f1733ea40b53381b0ae3117330735ef22309a190ac57b9576ea716" -dependencies = [ - "pathdiff", - "windows-sys 0.36.1", -] - -[[package]] -name = "openssl" -version = "0.10.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12fc0523e3bd51a692c8850d075d74dc062ccf251c0110668cbd921917118a13" -dependencies = [ - "bitflags", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b501e44f11665960c7e7fcf062c7d96a14ade4aa98116c004b2e37b5be7d736c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.76" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5230151e44c0f05157effb743e8d517472843121cf9243e8b81393edb5acd9ce" -dependencies = [ - "autocfg", - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "ordered-stream" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "034ce384018b245e8d8424bbe90577fbd91a533be74107e465e3474eb2285eef" -dependencies = [ - "futures-core", - "pin-project-lite", -] - -[[package]] -name = "os_info" -version = "3.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4750134fb6a5d49afc80777394ad5d95b04bc12068c6abb92fae8f43817270f" -dependencies = [ - "log", - "serde", - "winapi", -] - -[[package]] -name = "os_pipe" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c92f2b54f081d635c77e7120862d48db8e91f7f21cef23ab1b4fe9971c59f55" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "pango" -version = "0.15.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22e4045548659aee5313bde6c582b0d83a627b7904dd20dc2d9ef0895d414e4f" -dependencies = [ - "bitflags", - "glib", - "libc", - "once_cell", - "pango-sys", -] - -[[package]] -name = "pango-sys" -version = "0.15.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2a00081cde4661982ed91d80ef437c20eacaf6aa1a5962c0279ae194662c3aa" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps 6.0.2", -] - -[[package]] -name = "parking" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "427c3892f9e783d91cc128285287e70a59e206ca452770ece88a76f7a3eddd72" - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09a279cbf25cb0757810394fbc1e359949b59e348145c643a939a525692e6929" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-sys 0.36.1", -] - -[[package]] -name = "paste" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1de2e551fb905ac83f73f7aedf2f0cb4a0da7e35efa24a202a936269f1f18e1" - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "percent-encoding" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" - -[[package]] -name = "pest" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb779fcf4bb850fbbb0edc96ff6cf34fd90c4b1a112ce042653280d9a7364048" -dependencies = [ - "thiserror", - "ucd-trie", -] - -[[package]] -name = "phf" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dfb61232e34fcb633f43d12c58f83c1df82962dcdfa565a4e866ffc17dafe12" -dependencies = [ - "phf_macros 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", -] - -[[package]] -name = "phf" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fabbf1ead8a5bcbc20f5f8b939ee3f5b0f6f281b6ad3468b84656b658b455259" -dependencies = [ - "phf_macros 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", -] - -[[package]] -name = "phf_codegen" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbffee61585b0411840d3ece935cce9cb6321f01c45477d30066498cd5e1a815" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", -] - -[[package]] -name = "phf_generator" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17367f0cc86f2d25802b2c26ee58a7b23faeccf78a396094c13dced0d0182526" -dependencies = [ - "phf_shared 0.8.0", - "rand 0.7.3", -] - -[[package]] -name = "phf_generator" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d5285893bb5eb82e6aaf5d59ee909a06a16737a8970984dd7746ba9283498d6" -dependencies = [ - "phf_shared 0.10.0", - "rand 0.8.5", -] - -[[package]] -name = "phf_macros" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6fde18ff429ffc8fe78e2bf7f8b7a5a5a6e2a8b58bc5a9ac69198bbda9189c" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "phf_macros" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fdf3184dd560f160dd73922bea2d5cd6e8f064bf4b13110abd81b03697b4e0" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "phf_shared" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c00cf8b9eafe68dde5e9eaa2cef8ee84a9336a47d566ec55ca16589633b65af7" -dependencies = [ - "siphasher", -] - -[[package]] -name = "phf_shared" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1df8c4ec4b0627e53bdf214615ad287367e482558cf84b109250b37464dc03ae" - -[[package]] -name = "plist" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd39bc6cdc9355ad1dc5eeedefee696bb35c34caf21768741e81826c0bbd7225" -dependencies = [ - "base64", - "indexmap", - "line-wrap", - "serde", - "time", - "xml-rs", -] - -[[package]] -name = "png" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0b0cabbbd20c2d7f06dbf015e06aad59b6ca3d9ed14848783e98af9aaf19925" -dependencies = [ - "bitflags", - "deflate", - "inflate", - "num-iter", -] - -[[package]] -name = "png" -version = "0.17.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f0e7f4c94ec26ff209cee506314212639d6c91b80afb82984819fafce9df01c" -dependencies = [ - "bitflags", - "crc32fast", - "flate2", - "miniz_oxide", -] - -[[package]] -name = "polling" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "899b00b9c8ab553c743b3e11e87c5c7d423b2a2de229ba95b24a756344748011" -dependencies = [ - "autocfg", - "cfg-if", - "libc", - "log", - "wepoll-ffi", - "winapi", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb9f9e6e233e5c4a35559a617bf40a4ec447db2e84c20b55a6f83167b7e57872" - -[[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.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eda0fc3b0fb7c975631757e14d9049da17374063edb6ebbcbc54d880d4fe94e9" -dependencies = [ - "once_cell", - "thiserror", - "toml", -] - -[[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", - "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-macro-hack" -version = "0.5.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbf0c48bc1d91375ae5c3cd81e3722dff1abcf81a30960240640d223f59fe0e5" - -[[package]] -name = "proc-macro2" -version = "1.0.47" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ea3d908b0e36316caf9e9e2c4625cdde190a7e6f440d794667ed17a1855e725" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quick-xml" -version = "0.23.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11bafc859c6815fbaffbbbf4229ecb767ac913fecb27f9ad4343662e9ef099ea" -dependencies = [ - "memchr", -] - -[[package]] -name = "quote" -version = "1.0.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbe448f377a7d6961e30f5955f9b8d106c3f5e449d493ee1b125c1d43c2b5179" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", - "rand_pcg", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.7", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_pcg" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "raw-window-handle" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed7e3d950b66e19e0c372f3fa3fbbcf85b1746b571f74e0c2af6042a5c93420a" -dependencies = [ - "cty", -] - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.7", - "redox_syscall", - "thiserror", -] - -[[package]] -name = "regex" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c4eb3267174b8c6c2f654116623910a0fef09c4753f8dd83db29c48a0df988b" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3f87b73ce11b1619a3c6332f45341e0047173771e8b8b73f87bfeefb7b56244" - -[[package]] -name = "remove_dir_all" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7" -dependencies = [ - "winapi", -] - -[[package]] -name = "rfd" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0149778bd99b6959285b0933288206090c50e2327f47a9c463bfdbf45c8823ea" -dependencies = [ - "block", - "dispatch", - "glib-sys", - "gobject-sys", - "gtk-sys", - "js-sys", - "lazy_static", - "log", - "objc", - "objc-foundation", - "objc_id", - "raw-window-handle", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "windows 0.37.0", -] - -[[package]] -name = "rustc_version" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" -dependencies = [ - "semver 0.11.0", -] - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver 1.0.14", -] - -[[package]] -name = "rustversion" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97477e48b4cf8603ad5f7aaf897467cf42ab4218a38ef76fb14c2d6773a6d6a8" - -[[package]] -name = "ryu" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4501abdff3ae82a1c1b477a17252eb69cee9e66eb915c1abaa4f44d873df9f09" - -[[package]] -name = "safemem" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef703b7cb59335eae2eb93ceb664c0eb7ea6bf567079d843e09420219668e072" - -[[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.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88d6731146462ea25d9244b2ed5fd1d716d25c52e4d54aa4fb0f3c4e9854dbe2" -dependencies = [ - "lazy_static", - "windows-sys 0.36.1", -] - -[[package]] -name = "scoped-tls" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea6a9290e3c9cf0f18145ef7ffa62d68ee0bf5fcd651017e586dc7fd5da448c2" - -[[package]] -name = "scopeguard" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "security-framework" -version = "2.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bc1bb97804af6631813c55739f771071e0f2ed33ee20b68c86ec505d906356c" -dependencies = [ - "bitflags", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0160a13a177a45bfb43ce71c01580998474f556ad854dcbca936dd2841a5c556" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "selectors" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df320f1889ac4ba6bc0cdc9c9af7af4bd64bb927bccdf32d81140dc1f9be12fe" -dependencies = [ - "bitflags", - "cssparser", - "derive_more", - "fxhash", - "log", - "matches", - "phf 0.8.0", - "phf_codegen", - "precomputed-hash", - "servo_arc", - "smallvec", - "thin-slice", -] - -[[package]] -name = "semver" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" -dependencies = [ - "semver-parser", -] - -[[package]] -name = "semver" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e25dfac463d778e353db5be2449d1cce89bd6fd23c9f1ea21310ce6e5a1b29c4" -dependencies = [ - "serde", -] - -[[package]] -name = "semver-parser" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" -dependencies = [ - "pest", -] - -[[package]] -name = "serde" -version = "1.0.145" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "728eb6351430bccb993660dfffc5a72f91ccc1295abaa8ce19b27ebe4f75568b" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.145" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81fa1584d3d1bcacd84c277a0dfe21f5b0f6accf4a23d04d4c6d61f1af522b4c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.85" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e55a28e3aaef9d5ce0506d0a14dbba8054ddc7e499ef522dd8b26859ec9d4a44" -dependencies = [ - "itoa 1.0.3", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fe39d9fbb0ebf5eb2c7cb7e2a47e4f462fad1379f1166b8ae49ad9eae89a7ca" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa 1.0.3", - "ryu", - "serde", -] - -[[package]] -name = "serde_with" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" -dependencies = [ - "serde", - "serde_with_macros", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serialize-to-javascript" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9823f2d3b6a81d98228151fdeaf848206a7855a7a042bbf9bf870449a66cafb" -dependencies = [ - "serde", - "serde_json", - "serialize-to-javascript-impl", -] - -[[package]] -name = "serialize-to-javascript-impl" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74064874e9f6a15f04c1f3cb627902d0e6b410abbf36668afa873c61889f1763" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "servo_arc" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d98238b800e0d1576d8b6e3de32827c2d74bee68bb97748dcf5071fb53965432" -dependencies = [ - "nodrop", - "stable_deref_trait", -] - -[[package]] -name = "sha1" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f04293dc80c3993519f2d7f6f511707ee7094fe0c6d3406feb330cdb3540eba3" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sha2" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sharded-slab" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31" -dependencies = [ - "lazy_static", -] - -[[package]] -name = "shared_child" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0d94659ad3c2137fef23ae75b03d5241d633f8acded53d672decfa0e6e0caef" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "siphasher" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de" - -[[package]] -name = "slab" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4614a76b2a8be0058caa9dbbaf66d988527d86d003c11a94fbd335d7661edcef" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fd0db749597d91ff862fd1d55ea87f7855a744a8425a64695b6fca237d1dad1" - -[[package]] -name = "socket2" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02e2d2db9033d13a1567121ddd7a095ee144db4e1ca1b1bda3419bc0da294ebd" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "soup2" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2b4d76501d8ba387cf0fefbe055c3e0a59891d09f0f995ae4e4b16f6b60f3c0" -dependencies = [ - "bitflags", - "gio", - "glib", - "libc", - "once_cell", - "soup2-sys", -] - -[[package]] -name = "soup2-sys" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "009ef427103fcb17f802871647a7fa6c60cbb654b4c4e4c0ac60a31c5f6dc9cf" -dependencies = [ - "bitflags", - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps 5.0.0", -] - -[[package]] -name = "stable_deref_trait" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" - -[[package]] -name = "state" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbe866e1e51e8260c9eed836a042a5e7f6726bb2b411dffeaa712e19c388f23b" -dependencies = [ - "loom", -] - -[[package]] -name = "static_assertions" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" - -[[package]] -name = "string_cache" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "213494b7a2b503146286049378ce02b482200519accc31872ee8be91fa820a08" -dependencies = [ - "new_debug_unreachable", - "once_cell", - "parking_lot", - "phf_shared 0.10.0", - "precomputed-hash", - "serde", -] - -[[package]] -name = "string_cache_codegen" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bb30289b722be4ff74a408c3cc27edeaad656e06cb1fe8fa9231fa59c728988" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro2", - "quote", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "strum" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7ac893c7d471c8a21f31cfe213ec4f6d9afeed25537c772e08ef3f005f8729e" -dependencies = [ - "strum_macros", -] - -[[package]] -name = "strum_macros" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "339f799d8b549e3744c7ac7feb216383e4005d94bdb22561b3ab8f3b808ae9fb" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "syn" -version = "1.0.103" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a864042229133ada95abf3b54fdc62ef5ccabe9515b64717bcb9a1919e59445d" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-deps" -version = "5.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18db855554db7bd0e73e06cf7ba3df39f97812cb11d3f75e71c39bf45171797e" -dependencies = [ - "cfg-expr 0.9.1", - "heck 0.3.3", - "pkg-config", - "toml", - "version-compare 0.0.11", -] - -[[package]] -name = "system-deps" -version = "6.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a45a1c4c9015217e12347f2a411b57ce2c4fc543913b14b6fe40483328e709" -dependencies = [ - "cfg-expr 0.10.3", - "heck 0.4.0", - "pkg-config", - "toml", - "version-compare 0.1.0", -] - -[[package]] -name = "tao" -version = "0.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43336f5d1793543ba96e2a1e75f3a5c7dcd592743be06a0ab3a190f4fcb4b934" -dependencies = [ - "bitflags", - "cairo-rs", - "cc", - "cocoa", - "core-foundation", - "core-graphics", - "crossbeam-channel", - "dispatch", - "gdk", - "gdk-pixbuf", - "gdk-sys", - "gdkx11-sys", - "gio", - "glib", - "glib-sys", - "gtk", - "image", - "instant", - "jni", - "lazy_static", - "libc", - "log", - "ndk", - "ndk-context", - "ndk-sys", - "objc", - "once_cell", - "parking_lot", - "paste", - "png 0.17.6", - "raw-window-handle", - "scopeguard", - "serde", - "unicode-segmentation", - "uuid 1.1.2", - "windows 0.39.0", - "windows-implement", - "x11-dl", -] - -[[package]] -name = "tar" -version = "0.4.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b55807c0344e1e6c04d7c965f5289c39a8d94ae23ed5c0b57aabac549f871c6" -dependencies = [ - "filetime", - "libc", - "xattr", -] - -[[package]] -name = "tauri" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2643e2769a6bf922c274a0e6828a7dd20f9fa6d0fe4e04775d0a7eae81f82d37" -dependencies = [ - "anyhow", - "attohttpc", - "cocoa", - "dirs-next", - "embed_plist", - "encoding_rs", - "flate2", - "futures-util", - "glib", - "glob", - "gtk", - "heck 0.4.0", - "http", - "ignore", - "notify-rust", - "objc", - "once_cell", - "open", - "os_info", - "os_pipe", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "regex", - "rfd", - "semver 1.0.14", - "serde", - "serde_json", - "serde_repr", - "serialize-to-javascript", - "shared_child", - "state", - "tar", - "tauri-macros", - "tauri-runtime", - "tauri-runtime-wry", - "tauri-utils", - "tempfile", - "thiserror", - "tokio", - "url", - "uuid 1.1.2", - "webkit2gtk", - "webview2-com", - "windows 0.39.0", -] - -[[package]] -name = "tauri-build" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0991fb306849897439dbd4a72e4cbed2413e2eb26cb4b3ba220b94edba8b4b88" -dependencies = [ - "anyhow", - "cargo_toml", - "heck 0.4.0", - "json-patch", - "semver 1.0.14", - "serde_json", - "tauri-utils", - "winres", -] - -[[package]] -name = "tauri-codegen" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "356fa253e40ae4d6ff02075011f2f2bb4066f5c9d8c1e16ca6912d7b75903ba6" -dependencies = [ - "base64", - "brotli", - "ico", - "json-patch", - "plist", - "png 0.17.6", - "proc-macro2", - "quote", - "regex", - "semver 1.0.14", - "serde", - "serde_json", - "sha2", - "tauri-utils", - "thiserror", - "time", - "uuid 1.1.2", - "walkdir", -] - -[[package]] -name = "tauri-macros" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6051fd6940ddb22af452340d03c66a3e2f5d72e0788d4081d91e31528ccdc4d" -dependencies = [ - "heck 0.4.0", - "proc-macro2", - "quote", - "syn", - "tauri-codegen", - "tauri-utils", -] - -[[package]] -name = "tauri-plugin-single-instance" -version = "0.0.0" -dependencies = [ - "tauri", - "windows-sys 0.42.0", - "zbus", -] - -[[package]] -name = "tauri-runtime" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d49439a5ea47f474572b854972f42eda2e02a470be5ca9609cc83bb66945abe2" -dependencies = [ - "gtk", - "http", - "http-range", - "infer", - "rand 0.8.5", - "raw-window-handle", - "serde", - "serde_json", - "tauri-utils", - "thiserror", - "uuid 1.1.2", - "webview2-com", - "windows 0.39.0", -] - -[[package]] -name = "tauri-runtime-wry" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28dce920995fd49907aa9bea7249ed1771454f11f7611924c920a1f75fb614d4" -dependencies = [ - "cocoa", - "gtk", - "percent-encoding", - "rand 0.8.5", - "raw-window-handle", - "tauri-runtime", - "tauri-utils", - "uuid 1.1.2", - "webkit2gtk", - "webview2-com", - "windows 0.39.0", - "wry", -] - -[[package]] -name = "tauri-utils" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e8fdae6f29cef959809a3c3afef510c5b715a446a597ab8b791497585363f39" -dependencies = [ - "brotli", - "ctor", - "glob", - "heck 0.4.0", - "html5ever", - "json-patch", - "kuchiki", - "memchr", - "phf 0.10.1", - "proc-macro2", - "quote", - "semver 1.0.14", - "serde", - "serde_json", - "serde_with", - "thiserror", - "url", - "walkdir", - "windows 0.39.0", -] - -[[package]] -name = "tauri-winrt-notification" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c58de036c4d2e20717024de2a3c4bf56c301f07b21bc8ef9b57189fce06f1f3b" -dependencies = [ - "quick-xml", - "strum", - "windows 0.39.0", -] - -[[package]] -name = "tempfile" -version = "3.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cdb1ef4eaeeaddc8fbd371e5017057064af0911902ef36b39801f67cc6d79e4" -dependencies = [ - "cfg-if", - "fastrand", - "libc", - "redox_syscall", - "remove_dir_all", - "winapi", -] - -[[package]] -name = "tendril" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d24a120c5fc464a3458240ee02c299ebcb9d67b5249c8848b09d639dca8d7bb0" -dependencies = [ - "futf", - "mac", - "utf-8", -] - -[[package]] -name = "thin-slice" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c" - -[[package]] -name = "thiserror" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a99cb8c4b9a8ef0e7907cd3b617cc8dc04d571c4e73c8ae403d80ac160bb122" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a891860d3c8d66fec8e73ddb3765f90082374dbaaa833407b904a94f1a7eb43" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "thread_local" -version = "1.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5516c27b78311c50bf42c071425c560ac799b11c30b31f87e3081965fe5e0180" -dependencies = [ - "once_cell", -] - -[[package]] -name = "time" -version = "0.3.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c3f9a28b618c3a6b9251b6908e9c99e04b9e5c02e6581ccbb67d59c34ef7f9b" -dependencies = [ - "itoa 1.0.3", - "libc", - "num_threads", -] - -[[package]] -name = "tinyvec" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c" - -[[package]] -name = "tokio" -version = "1.21.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0020c875007ad96677dcc890298f4b942882c5d4eb7cc8f439fc3bf813dc9c95" -dependencies = [ - "autocfg", - "bytes", - "memchr", - "num_cpus", - "once_cell", - "pin-project-lite", -] - -[[package]] -name = "toml" -version = "0.5.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d82e1a7758622a465f8cee077614c73484dac5b836c02ff6a40d5d1010324d7" -dependencies = [ - "serde", -] - -[[package]] -name = "tracing" -version = "0.1.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" -dependencies = [ - "cfg-if", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tracing-core" -version = "0.1.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" -dependencies = [ - "once_cell", - "valuable", -] - -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - -[[package]] -name = "tracing-subscriber" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60db860322da191b40952ad9affe65ea23e7dd6a5c442c2c42865810c6ab8e6b" -dependencies = [ - "ansi_term", - "matchers", - "once_cell", - "regex", - "sharded-slab", - "smallvec", - "thread_local", - "tracing", - "tracing-core", - "tracing-log", -] - -[[package]] -name = "treediff" -version = "3.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "761e8d5ad7ce14bb82b7e61ccc0ca961005a275a060b9644a2431aa11553c2ff" -dependencies = [ - "serde_json", -] - -[[package]] -name = "typenum" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcf81ac59edc17cc8697ff311e8f5ef2d99fcbd9817b34cec66f90b6c3dfd987" - -[[package]] -name = "ucd-trie" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e79c4d996edb816c91e4308506774452e55e95c3c9de07b6729e17e15a5ef81" - -[[package]] -name = "uds_windows" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce65604324d3cce9b966701489fbd0cf318cb1f7bd9dd07ac9a4ee6fb791930d" -dependencies = [ - "tempfile", - "winapi", -] - -[[package]] -name = "unicode-bidi" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "099b7128301d285f79ddd55b9a83d5e6b9e97c92e0ea0daebee7263e932de992" - -[[package]] -name = "unicode-ident" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcc811dc4066ac62f84f11307873c4850cb653bfa9b1719cee2bd2204a4bc5dd" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fdbf052a0783de01e944a6ce7a8cb939e295b1e7be835a1112c3b9a7f047a5a" - -[[package]] -name = "url" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", - "serde", -] - -[[package]] -name = "utf-8" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" - -[[package]] -name = "uuid" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7" - -[[package]] -name = "uuid" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd6469f4314d5f1ffec476e05f17cc9a78bc7a27a6a857842170bdf8d6f98d2f" -dependencies = [ - "getrandom 0.2.7", -] - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[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.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c18c859eead79d8b95d09e4678566e8d70105c4e7b251f707a03df32442661b" - -[[package]] -name = "version-compare" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe88247b92c1df6b6de80ddc290f3976dbdf2f5f5d3fd049a9fb598c6dd5ca73" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "waker-fn" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d5b2c62b4012a3e1eca5a7e077d13b3bf498c4073e33ccd58626607748ceeca" - -[[package]] -name = "walkdir" -version = "2.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "808cf2735cd4b6866113f648b791c6adc5714537bc222d9347bb203386ffda56" -dependencies = [ - "same-file", - "winapi", - "winapi-util", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaf9f5aceeec8be17c128b2e93e031fb8a4d469bb9c4ae2d7dc1888b26887268" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8ffb332579b0557b52d268b91feab8df3615f265d5270fec2a8c95b17c1142" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23639446165ca5a5de86ae1d8896b737ae80319560fbaa4c2887b7da6e7ebd7d" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "052be0f94026e6cbc75cdefc9bae13fd6052cdcaf532fa6c45e7ae33a1e6c810" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07bc0c051dc5f23e307b13285f9d75df86bfdf816c5721e573dec1f9b8aa193c" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c38c045535d93ec4f0b4defec448e4291638ee608530863b1e2ba115d4fff7f" - -[[package]] -name = "web-sys" -version = "0.3.60" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcda906d8be16e728fd5adc5b729afad4e444e106ab28cd1c7256e54fa61510f" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "webkit2gtk" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29952969fb5e10fe834a52eb29ad0814ccdfd8387159b0933edf1344a1c9cdcc" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk", - "gdk-sys", - "gio", - "gio-sys", - "glib", - "glib-sys", - "gobject-sys", - "gtk", - "gtk-sys", - "javascriptcore-rs", - "libc", - "once_cell", - "soup2", - "webkit2gtk-sys", -] - -[[package]] -name = "webkit2gtk-sys" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d76ca6ecc47aeba01ec61e480139dda143796abcae6f83bcddf50d6b5b1dcf3" -dependencies = [ - "atk-sys", - "bitflags", - "cairo-sys-rs", - "gdk-pixbuf-sys", - "gdk-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "gtk-sys", - "javascriptcore-rs-sys", - "libc", - "pango-sys", - "pkg-config", - "soup2-sys", - "system-deps 6.0.2", -] - -[[package]] -name = "webview2-com" -version = "0.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4a769c9f1a64a8734bde70caafac2b96cada12cd4aefa49196b3a386b8b4178" -dependencies = [ - "webview2-com-macros", - "webview2-com-sys", - "windows 0.39.0", - "windows-implement", -] - -[[package]] -name = "webview2-com-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaebe196c01691db62e9e4ca52c5ef1e4fd837dcae27dae3ada599b5a8fd05ac" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "webview2-com-sys" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aac48ef20ddf657755fdcda8dfed2a7b4fc7e4581acce6fe9b88c3d64f29dee7" -dependencies = [ - "regex", - "serde", - "serde_json", - "thiserror", - "windows 0.39.0", - "windows-bindgen", - "windows-metadata", -] - -[[package]] -name = "wepoll-ffi" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d743fdedc5c64377b5fc2bc036b01c7fd642205a0d96356034ae3404d49eb7fb" -dependencies = [ - "cc", -] - -[[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.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi", -] - -[[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 = "windows" -version = "0.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbedf6db9096bc2364adce0ae0aa636dcd89f3c3f2cd67947062aaf0ca2a10ec" -dependencies = [ - "windows_aarch64_msvc 0.32.0", - "windows_i686_gnu 0.32.0", - "windows_i686_msvc 0.32.0", - "windows_x86_64_gnu 0.32.0", - "windows_x86_64_msvc 0.32.0", -] - -[[package]] -name = "windows" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57b543186b344cc61c85b5aab0d2e3adf4e0f99bc076eff9aa5927bcc0b8a647" -dependencies = [ - "windows_aarch64_msvc 0.37.0", - "windows_i686_gnu 0.37.0", - "windows_i686_msvc 0.37.0", - "windows_x86_64_gnu 0.37.0", - "windows_x86_64_msvc 0.37.0", -] - -[[package]] -name = "windows" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1c4bd0a50ac6020f65184721f758dba47bb9fbc2133df715ec74a237b26794a" -dependencies = [ - "windows-implement", - "windows_aarch64_msvc 0.39.0", - "windows_i686_gnu 0.39.0", - "windows_i686_msvc 0.39.0", - "windows_x86_64_gnu 0.39.0", - "windows_x86_64_msvc 0.39.0", -] - -[[package]] -name = "windows-bindgen" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68003dbd0e38abc0fb85b939240f4bce37c43a5981d3df37ccbaaa981b47cb41" -dependencies = [ - "windows-metadata", - "windows-tokens", -] - -[[package]] -name = "windows-implement" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba01f98f509cb5dc05f4e5fc95e535f78260f15fea8fe1a8abdd08f774f1cee7" -dependencies = [ - "syn", - "windows-tokens", -] - -[[package]] -name = "windows-metadata" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ee5e275231f07c6e240d14f34e1b635bf1faa1c76c57cfd59a5cdb9848e4278" - -[[package]] -name = "windows-sys" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea04155a16a59f9eab786fe12a4a450e75cdb175f9e0d80da1e17db09f55b8d2" -dependencies = [ - "windows_aarch64_msvc 0.36.1", - "windows_i686_gnu 0.36.1", - "windows_i686_msvc 0.36.1", - "windows_x86_64_gnu 0.36.1", - "windows_x86_64_msvc 0.36.1", -] - -[[package]] -name = "windows-sys" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" -dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc 0.42.0", - "windows_i686_gnu 0.42.0", - "windows_i686_msvc 0.42.0", - "windows_x86_64_gnu 0.42.0", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc 0.42.0", -] - -[[package]] -name = "windows-tokens" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f838de2fe15fe6bac988e74b798f26499a8b21a9d97edec321e79b28d1d7f597" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41d2aa71f6f0cbe00ae5167d90ef3cfe66527d6f613ca78ac8024c3ccab9a19e" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8e92753b1c443191654ec532f14c199742964a061be25d77d7a96f09db20bf5" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9bb8c3fd39ade2d67e9874ac4f3db21f0d710bee00fe7cab16949ec184eeaa47" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2623277cb2d1c216ba3b578c0f3cf9cdebeddb6e66b1b218bb33596ea7769c3a" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec7711666096bd4096ffa835238905bb33fb87267910e154b18b44eaabb340f2" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd0f252f5a35cac83d6311b2e795981f5ee6e67eb1f9a7f64eb4500fbc4dcdb4" - -[[package]] -name = "windows_i686_gnu" -version = "0.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a711c68811799e017b6038e0922cb27a5e2f43a2ddb609fe0b6f3eeda9de615" - -[[package]] -name = "windows_i686_gnu" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "180e6ccf01daf4c426b846dfc66db1fc518f074baa793aa7d9b9aaeffad6a3b6" - -[[package]] -name = "windows_i686_gnu" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3925fd0b0b804730d44d4b6278c50f9699703ec49bcd628020f46f4ba07d9e1" - -[[package]] -name = "windows_i686_gnu" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "763fc57100a5f7042e3057e7e8d9bdd7860d330070251a73d003563a3bb49e1b" - -[[package]] -name = "windows_i686_gnu" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbeae19f6716841636c28d695375df17562ca208b2b7d0dc47635a50ae6c5de7" - -[[package]] -name = "windows_i686_msvc" -version = "0.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "146c11bb1a02615db74680b32a68e2d61f553cc24c4eb5b4ca10311740e44172" - -[[package]] -name = "windows_i686_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2e7917148b2812d1eeafaeb22a97e4813dfa60a3f8f78ebe204bcc88f12f024" - -[[package]] -name = "windows_i686_msvc" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce907ac74fe331b524c1298683efbf598bb031bc84d5e274db2083696d07c57c" - -[[package]] -name = "windows_i686_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bc7cbfe58828921e10a9f446fcaaf649204dcfe6c1ddd712c5eebae6bda1106" - -[[package]] -name = "windows_i686_msvc" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84c12f65daa39dd2babe6e442988fc329d6243fdce47d7d2d155b8d874862246" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c912b12f7454c6620635bbff3450962753834be2a594819bd5e945af18ec64bc" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dcd171b8776c41b97521e5da127a2d86ad280114807d0b2ab1e462bc764d9e1" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2babfba0828f2e6b32457d5341427dcbb577ceef556273229959ac23a10af33d" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6868c165637d653ae1e8dc4d82c25d4f97dd6605eaa8d784b5c6e0ab2a252b65" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf7b1b21b5362cbc318f686150e5bcea75ecedc74dd157d874d754a2ca44b0ed" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09d525d2ba30eeb3297665bd434a54297e4170c7f1a44cad4ef58095b4cd2028" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "504a2476202769977a040c6364301a3f65d0cc9e3fb08600b2bda150a0488316" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c811ca4a8c853ef420abd8592ba53ddbbac90410fab6903b3e79972a631f7680" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4dd6dc7df2d84cf7b33822ed5b86318fb1781948e9663bacd047fc9dd52259d" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e4d40883ae9cae962787ca76ba76390ffa29214667a111db9e0a1ad8377e809" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f40009d85759725a34da6d89a94e63d7bdc50a862acf0dbc7c8e488f1edcb6f5" - -[[package]] -name = "winres" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b68db261ef59e9e52806f688020631e987592bd83619edccda9c47d42cde4f6c" -dependencies = [ - "toml", -] - -[[package]] -name = "wry" -version = "0.21.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff5c1352b4266fdf92c63479d2f58ab4cd29dc4e78fbc1b62011ed1227926945" -dependencies = [ - "base64", - "block", - "cocoa", - "core-graphics", - "crossbeam-channel", - "gdk", - "gio", - "glib", - "gtk", - "html5ever", - "http", - "kuchiki", - "libc", - "log", - "objc", - "objc_id", - "once_cell", - "serde", - "serde_json", - "sha2", - "tao", - "thiserror", - "url", - "webkit2gtk", - "webkit2gtk-sys", - "webview2-com", - "windows 0.39.0", - "windows-implement", -] - -[[package]] -name = "x11" -version = "2.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7ae97874a928d821b061fce3d1fc52f08071dd53c89a6102bc06efcac3b2908" -dependencies = [ - "libc", - "pkg-config", -] - -[[package]] -name = "x11-dl" -version = "2.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c83627bc137605acc00bb399c7b908ef460b621fc37c953db2b09f88c449ea6" -dependencies = [ - "lazy_static", - "libc", - "pkg-config", -] - -[[package]] -name = "xattr" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d1526bbe5aaeb5eb06885f4d987bcdfa5e23187055de9b83fe00156a821fabc" -dependencies = [ - "libc", -] - -[[package]] -name = "xml-rs" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2d7d3948613f75c98fd9328cfdcc45acc4d360655289d0a7d4ec931392200a3" - -[[package]] -name = "zbus" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a25ae891bd547674b368906552115143031c16c23a0f2f4b2f5f5436ab2e6a9f" -dependencies = [ - "async-broadcast", - "async-channel", - "async-executor", - "async-io", - "async-lock", - "async-recursion", - "async-task", - "async-trait", - "byteorder", - "derivative", - "dirs", - "enumflags2", - "event-listener", - "futures-core", - "futures-sink", - "futures-util", - "hex", - "nix", - "once_cell", - "ordered-stream", - "rand 0.8.5", - "serde", - "serde_repr", - "sha1", - "static_assertions", - "tracing", - "uds_windows", - "winapi", - "zbus_macros", - "zbus_names", - "zvariant", -] - -[[package]] -name = "zbus_macros" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8aa37701ce7b3a43632d2b0ad9d4aef602b46be6bdd7fba3b7c5007f9f6eb2c2" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "regex", - "syn", -] - -[[package]] -name = "zbus_names" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41a408fd8a352695690f53906dc7fd036be924ec51ea5e05666ff42685ed0af5" -dependencies = [ - "serde", - "static_assertions", - "zvariant", -] - -[[package]] -name = "zvariant" -version = "3.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c817f416f05fcbc833902f1e6064b72b1778573978cfeac54731451ccc9e207" -dependencies = [ - "byteorder", - "enumflags2", - "libc", - "serde", - "static_assertions", - "zvariant_derive", -] - -[[package]] -name = "zvariant_derive" -version = "3.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdd24fffd02794a76eb10109de463444064c88f5adb9e9d1a78488adc332bfef" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] diff --git a/plugins/single-instance/examples/vanilla/src-tauri/build.rs b/plugins/single-instance/examples/vanilla/src-tauri/build.rs index 795b9b7c..b055ec37 100644 --- a/plugins/single-instance/examples/vanilla/src-tauri/build.rs +++ b/plugins/single-instance/examples/vanilla/src-tauri/build.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + fn main() { tauri_build::build() } diff --git a/plugins/single-instance/examples/vanilla/src-tauri/src/main.rs b/plugins/single-instance/examples/vanilla/src-tauri/src/main.rs index a6260a7f..0b93460d 100644 --- a/plugins/single-instance/examples/vanilla/src-tauri/src/main.rs +++ b/plugins/single-instance/examples/vanilla/src-tauri/src/main.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + #![cfg_attr( all(not(debug_assertions), target_os = "windows"), windows_subsystem = "windows" diff --git a/plugins/single-instance/examples/vanilla/src-tauri/tauri.conf.json b/plugins/single-instance/examples/vanilla/src-tauri/tauri.conf.json index de4bdb81..a0593744 100644 --- a/plugins/single-instance/examples/vanilla/src-tauri/tauri.conf.json +++ b/plugins/single-instance/examples/vanilla/src-tauri/tauri.conf.json @@ -40,12 +40,6 @@ "timestampUrl": "" } }, - "updater": { - "active": false - }, - "allowlist": { - "all": true - }, "windows": [ { "title": "app", diff --git a/plugins/single-instance/src/lib.rs b/plugins/single-instance/src/lib.rs index a2ff71af..6b20956e 100644 --- a/plugins/single-instance/src/lib.rs +++ b/plugins/single-instance/src/lib.rs @@ -1,3 +1,9 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +#![cfg(not(any(target_os = "android", target_os = "ios")))] + use tauri::{plugin::TauriPlugin, AppHandle, Manager, Runtime}; #[cfg(target_os = "windows")] diff --git a/plugins/single-instance/src/platform_impl/linux.rs b/plugins/single-instance/src/platform_impl/linux.rs index 42557e5a..3ad8585f 100644 --- a/plugins/single-instance/src/platform_impl/linux.rs +++ b/plugins/single-instance/src/platform_impl/linux.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + #![cfg(target_os = "linux")] use std::sync::Arc; diff --git a/plugins/single-instance/src/platform_impl/macos.rs b/plugins/single-instance/src/platform_impl/macos.rs index 1b408c66..170ff0e0 100644 --- a/plugins/single-instance/src/platform_impl/macos.rs +++ b/plugins/single-instance/src/platform_impl/macos.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + #![cfg(target_os = "macos")] use crate::SingleInstanceCallback; diff --git a/plugins/single-instance/src/platform_impl/windows.rs b/plugins/single-instance/src/platform_impl/windows.rs index 69036f58..31c4f229 100644 --- a/plugins/single-instance/src/platform_impl/windows.rs +++ b/plugins/single-instance/src/platform_impl/windows.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + #![cfg(target_os = "windows")] use crate::SingleInstanceCallback; diff --git a/plugins/sql/CHANGELOG.md b/plugins/sql/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/sql/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/sql/Cargo.toml b/plugins/sql/Cargo.toml index 91a839ac..c08a48ff 100644 --- a/plugins/sql/Cargo.toml +++ b/plugins/sql/Cargo.toml @@ -1,26 +1,27 @@ [package] name = "tauri-plugin-sql" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Interface with SQL databases." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +[package.metadata.docs.rs] +features = [ "sqlite" ] [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } futures-core = "0.3" -sqlx = { version = "0.6", features = ["runtime-tokio-rustls", "json", "time"] } +sqlx = { version = "0.6", features = [ "runtime-tokio-rustls", "json", "time" ] } time = "0.3" -tokio = { version = "1", features = ["sync"] } +tokio = { version = "1", features = [ "sync" ] } [features] -sqlite = ["sqlx/sqlite"] -mysql = ["sqlx/mysql"] -postgres = ["sqlx/postgres"] \ No newline at end of file +sqlite = [ "sqlx/sqlite" ] +mysql = [ "sqlx/mysql" ] +postgres = [ "sqlx/postgres" ] diff --git a/plugins/sql/README.md b/plugins/sql/README.md index 387c5db1..3901405e 100644 --- a/plugins/sql/README.md +++ b/plugins/sql/README.md @@ -4,7 +4,7 @@ Interface with SQL databases through [sqlx](https://github.com/launchbadge/sqlx) ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,9 +18,11 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies.tauri-plugin-sql] +features = ["sqlite"] # or "postgres", or "mysql" +version = "2.0.0-alpha" +# alternatively with Git git = "https://github.com/tauri-apps/plugins-workspace" branch = "v2" -features = ["sqlite"] # or "postgres", or "mysql" ``` You can install the JavaScript Guest bindings using your preferred JavaScript package manager: @@ -28,6 +30,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-sql +# or +npm add @tauri-apps/plugin-sql +# or +yarn add @tauri-apps/plugin-sql + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-sql#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-sql#v2 @@ -53,7 +62,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import Database from "tauri-plugin-sql-api"; +import Database from "@tauri-apps/plugin-sql"; // sqlite. The path is relative to `tauri::api::path::BaseDirectory::App`. const db = await Database.load("sqlite:test.db"); diff --git a/plugins/sql/guest-js/index.ts b/plugins/sql/guest-js/index.ts index a574e72e..24f35ec9 100644 --- a/plugins/sql/guest-js/index.ts +++ b/plugins/sql/guest-js/index.ts @@ -1,4 +1,12 @@ -import { invoke } from "@tauri-apps/api/tauri"; +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} export interface QueryResult { /** The number of rows affected by the query. */ @@ -42,7 +50,7 @@ export default class Database { * ``` */ static async load(path: string): Promise { - const _path = await invoke("plugin:sql|load", { + const _path = await window.__TAURI_INVOKE__("plugin:sql|load", { db: path, }); @@ -83,14 +91,13 @@ export default class Database { * ``` */ async execute(query: string, bindValues?: unknown[]): Promise { - const [rowsAffected, lastInsertId] = await invoke<[number, number]>( - "plugin:sql|execute", - { - db: this.path, - query, - values: bindValues ?? [], - } - ); + const [rowsAffected, lastInsertId] = await window.__TAURI_INVOKE__< + [number, number] + >("plugin:sql|execute", { + db: this.path, + query, + values: bindValues ?? [], + }); return { lastInsertId, @@ -111,7 +118,7 @@ export default class Database { * ``` */ async select(query: string, bindValues?: unknown[]): Promise { - const result = await invoke("plugin:sql|select", { + const result = await window.__TAURI_INVOKE__("plugin:sql|select", { db: this.path, query, values: bindValues ?? [], @@ -132,7 +139,7 @@ export default class Database { * @param db - Optionally state the name of a database if you are managing more than one. Otherwise, all database pools will be in scope. */ async close(db?: string): Promise { - const success = await invoke("plugin:sql|close", { + const success = await window.__TAURI_INVOKE__("plugin:sql|close", { db, }); return success; diff --git a/plugins/sql/package.json b/plugins/sql/package.json index a5607cd6..faea80a8 100644 --- a/plugins/sql/package.json +++ b/plugins/sql/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-sql-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-sql", + "version": "2.0.0-alpha.0", "description": "Interface with SQL databases", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/sql/src/api-iife.js b/plugins/sql/src/api-iife.js new file mode 100644 index 00000000..e43792cd --- /dev/null +++ b/plugins/sql/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_SQL__=function(){"use strict";class _{constructor(_){this.path=_}static async load(t){const e=await window.__TAURI_INVOKE__("plugin:sql|load",{db:t});return new _(e)}static get(t){return new _(t)}async execute(_,t){const[e,n]=await window.__TAURI_INVOKE__("plugin:sql|execute",{db:this.path,query:_,values:null!=t?t:[]});return{lastInsertId:n,rowsAffected:e}}async select(_,t){return await window.__TAURI_INVOKE__("plugin:sql|select",{db:this.path,query:_,values:null!=t?t:[]})}async close(_){return await window.__TAURI_INVOKE__("plugin:sql|close",{db:_})}}return _}();Object.defineProperty(window.__TAURI__,"sql",{value:__TAURI_SQL__})} diff --git a/plugins/sql/src/decode/mod.rs b/plugins/sql/src/decode/mod.rs index 415c99b8..50fb3c78 100644 --- a/plugins/sql/src/decode/mod.rs +++ b/plugins/sql/src/decode/mod.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + #[cfg(feature = "mysql")] mod mysql; #[cfg(feature = "postgres")] diff --git a/plugins/sql/src/decode/mysql.rs b/plugins/sql/src/decode/mysql.rs index e68bd1ac..6ca7e403 100644 --- a/plugins/sql/src/decode/mysql.rs +++ b/plugins/sql/src/decode/mysql.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use serde_json::Value as JsonValue; use sqlx::{mysql::MySqlValueRef, TypeInfo, Value, ValueRef}; use time::{Date, OffsetDateTime, PrimitiveDateTime, Time}; diff --git a/plugins/sql/src/decode/postgres.rs b/plugins/sql/src/decode/postgres.rs index 39c9acfd..bd77aff0 100644 --- a/plugins/sql/src/decode/postgres.rs +++ b/plugins/sql/src/decode/postgres.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use serde_json::Value as JsonValue; use sqlx::{postgres::PgValueRef, TypeInfo, Value, ValueRef}; use time::{Date, OffsetDateTime, PrimitiveDateTime, Time}; diff --git a/plugins/sql/src/decode/sqlite.rs b/plugins/sql/src/decode/sqlite.rs index 65d378cb..1f0808ae 100644 --- a/plugins/sql/src/decode/sqlite.rs +++ b/plugins/sql/src/decode/sqlite.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use serde_json::Value as JsonValue; use sqlx::{sqlite::SqliteValueRef, TypeInfo, Value, ValueRef}; use time::{Date, PrimitiveDateTime, Time}; diff --git a/plugins/sql/src/lib.rs b/plugins/sql/src/lib.rs index 378240b3..4bc87324 100644 --- a/plugins/sql/src/lib.rs +++ b/plugins/sql/src/lib.rs @@ -1,4 +1,4 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT @@ -7,7 +7,9 @@ all(feature = "sqlite", feature = "postgres"), all(feature = "mysql", feature = "postgres") ))] -compile_error!("Only one database driver can be enabled. Use `default-features = false` and set the feature flag for the driver of your choice."); +compile_error!( + "Only one database driver can be enabled. Set the feature flag for the driver of your choice." +); #[cfg(not(any(feature = "sqlite", feature = "mysql", feature = "postgres")))] compile_error!( diff --git a/plugins/sql/src/plugin.rs b/plugins/sql/src/plugin.rs index 6d682bda..8d524345 100644 --- a/plugins/sql/src/plugin.rs +++ b/plugins/sql/src/plugin.rs @@ -1,4 +1,4 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT @@ -280,6 +280,7 @@ impl Builder { pub fn build(mut self) -> TauriPlugin> { PluginBuilder::>::new("sql") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![load, execute, select, close]) .setup(|app, api| { let config = api.config().clone().unwrap_or_default(); diff --git a/plugins/sql/tsconfig.json b/plugins/sql/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/sql/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/sql/tsconfig.json b/plugins/sql/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/sql/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/store/CHANGELOG.md b/plugins/store/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/store/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/store/Cargo.toml b/plugins/store/Cargo.toml index 626dbebc..a2ec5226 100644 --- a/plugins/store/Cargo.toml +++ b/plugins/store/Cargo.toml @@ -1,17 +1,15 @@ [package] name = "tauri-plugin-store" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Simple, persistent key-value store." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true \ No newline at end of file +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } diff --git a/plugins/store/README.md b/plugins/store/README.md index 4f6d1fa0..90b0b7ef 100644 --- a/plugins/store/README.md +++ b/plugins/store/README.md @@ -4,7 +4,7 @@ Simple, persistent key-value store. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-store = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-store = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-store +# or +npm add @tauri-apps/plugin-store +# or +yarn add @tauri-apps/plugin-store + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-store#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-store#v2 @@ -51,7 +60,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { Store } from "tauri-plugin-store-api"; +import { Store } from "@tauri-apps/plugin-store"; const store = new Store(".settings.dat"); diff --git a/plugins/store/guest-js/index.ts b/plugins/store/guest-js/index.ts index cc6058d8..4df455f8 100644 --- a/plugins/store/guest-js/index.ts +++ b/plugins/store/guest-js/index.ts @@ -1,10 +1,15 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT -import { invoke } from "@tauri-apps/api/tauri"; import { listen, UnlistenFn } from "@tauri-apps/api/event"; +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} + interface ChangePayload { path: string; key: string; @@ -28,7 +33,7 @@ export class Store { * @returns */ async set(key: string, value: unknown): Promise { - return await invoke("plugin:store|set", { + return await window.__TAURI_INVOKE__("plugin:store|set", { path: this.path, key, value, @@ -42,7 +47,7 @@ export class Store { * @returns */ async get(key: string): Promise { - return await invoke("plugin:store|get", { + return await window.__TAURI_INVOKE__("plugin:store|get", { path: this.path, key, }); @@ -55,7 +60,7 @@ export class Store { * @returns */ async has(key: string): Promise { - return await invoke("plugin:store|has", { + return await window.__TAURI_INVOKE__("plugin:store|has", { path: this.path, key, }); @@ -68,7 +73,7 @@ export class Store { * @returns */ async delete(key: string): Promise { - return await invoke("plugin:store|delete", { + return await window.__TAURI_INVOKE__("plugin:store|delete", { path: this.path, key, }); @@ -81,7 +86,7 @@ export class Store { * @returns */ async clear(): Promise { - return await invoke("plugin:store|clear", { + return await window.__TAURI_INVOKE__("plugin:store|clear", { path: this.path, }); } @@ -93,7 +98,7 @@ export class Store { * @returns */ async reset(): Promise { - return await invoke("plugin:store|reset", { + return await window.__TAURI_INVOKE__("plugin:store|reset", { path: this.path, }); } @@ -104,7 +109,7 @@ export class Store { * @returns */ async keys(): Promise { - return await invoke("plugin:store|keys", { + return await window.__TAURI_INVOKE__("plugin:store|keys", { path: this.path, }); } @@ -115,7 +120,7 @@ export class Store { * @returns */ async values(): Promise { - return await invoke("plugin:store|values", { + return await window.__TAURI_INVOKE__("plugin:store|values", { path: this.path, }); } @@ -126,7 +131,7 @@ export class Store { * @returns */ async entries(): Promise> { - return await invoke("plugin:store|entries", { + return await window.__TAURI_INVOKE__("plugin:store|entries", { path: this.path, }); } @@ -137,7 +142,7 @@ export class Store { * @returns */ async length(): Promise { - return await invoke("plugin:store|length", { + return await window.__TAURI_INVOKE__("plugin:store|length", { path: this.path, }); } @@ -151,7 +156,7 @@ export class Store { * @returns */ async load(): Promise { - return await invoke("plugin:store|load", { + return await window.__TAURI_INVOKE__("plugin:store|load", { path: this.path, }); } @@ -164,7 +169,7 @@ export class Store { * @returns */ async save(): Promise { - return await invoke("plugin:store|save", { + return await window.__TAURI_INVOKE__("plugin:store|save", { path: this.path, }); } @@ -174,6 +179,8 @@ export class Store { * @param key * @param cb * @returns A promise resolving to a function to unlisten to the event. + * + * @since 2.0.0 */ async onKeyChange( key: string, @@ -190,6 +197,8 @@ export class Store { * Listen to changes on the store. * @param cb * @returns A promise resolving to a function to unlisten to the event. + * + * @since 2.0.0 */ async onChange( cb: (key: string, value: T | null) => void diff --git a/plugins/store/package.json b/plugins/store/package.json index 02e5d230..9bfaabe1 100644 --- a/plugins/store/package.json +++ b/plugins/store/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-store-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-store", + "version": "2.0.0-alpha.0", "description": "Simple, persistent key-value store.", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/store/src/api-iife.js b/plugins/store/src/api-iife.js new file mode 100644 index 00000000..df38427d --- /dev/null +++ b/plugins/store/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_STORE__=function(e){"use strict";var t=Object.defineProperty,n=(e,n)=>{for(var a in n)t(e,a,{get:n[a],enumerable:!0})},a=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},r=(e,t,n)=>(a(e,t,"read from private field"),n?n.call(e):t.get(e)),i=(e,t,n,r)=>(a(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n);function s(e,t=!1){let n=window.crypto.getRandomValues(new Uint32Array(1))[0],a=`_${n}`;return Object.defineProperty(window,a,{value:n=>(t&&Reflect.deleteProperty(window,a),e?.(n)),writable:!1,configurable:!0}),n}n({},{Channel:()=>o,PluginListener:()=>l,addPluginListener:()=>u,convertFileSrc:()=>h,invoke:()=>c,transformCallback:()=>s});var _,o=class{constructor(){this.__TAURI_CHANNEL_MARKER__=!0,((e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)})(this,_,(()=>{})),this.id=s((e=>{r(this,_).call(this,e)}))}set onmessage(e){i(this,_,e)}get onmessage(){return r(this,_)}toJSON(){return`__CHANNEL__:${this.id}`}};_=new WeakMap;var l=class{constructor(e,t,n){this.plugin=e,this.event=t,this.channelId=n}async unregister(){return c(`plugin:${this.plugin}|remove_listener`,{event:this.event,channelId:this.channelId})}};async function u(e,t,n){let a=new o;return a.onmessage=n,c(`plugin:${e}|register_listener`,{event:t,handler:a}).then((()=>new l(e,t,a.id)))}async function c(e,t={}){return new Promise(((n,a)=>{let r=s((e=>{n(e),Reflect.deleteProperty(window,`_${i}`)}),!0),i=s((e=>{a(e),Reflect.deleteProperty(window,`_${r}`)}),!0);window.__TAURI_IPC__({cmd:e,callback:r,error:i,...t})}))}function h(e,t="asset"){let n=encodeURIComponent(e);return navigator.userAgent.includes("Windows")?`https://${t}.localhost/${n}`:`${t}://localhost/${n}`}async function d(e,t){await c("plugin:event|unlisten",{event:e,eventId:t})}async function p(e,t,n){return c("plugin:event|listen",{event:e,windowLabel:t,handler:s(n)}).then((t=>async()=>d(e,t)))}n({},{TauriEvent:()=>y,emit:()=>E,listen:()=>I,once:()=>g});var w,y=((w=y||{}).WINDOW_RESIZED="tauri://resize",w.WINDOW_MOVED="tauri://move",w.WINDOW_CLOSE_REQUESTED="tauri://close-requested",w.WINDOW_CREATED="tauri://window-created",w.WINDOW_DESTROYED="tauri://destroyed",w.WINDOW_FOCUS="tauri://focus",w.WINDOW_BLUR="tauri://blur",w.WINDOW_SCALE_FACTOR_CHANGED="tauri://scale-change",w.WINDOW_THEME_CHANGED="tauri://theme-changed",w.WINDOW_FILE_DROP="tauri://file-drop",w.WINDOW_FILE_DROP_HOVER="tauri://file-drop-hover",w.WINDOW_FILE_DROP_CANCELLED="tauri://file-drop-cancelled",w.MENU="tauri://menu",w);async function I(e,t){return p(e,null,t)}async function g(e,t){return async function(e,t,n){return p(e,t,(t=>{n(t),d(e,t.id).catch((()=>{}))}))}(e,null,t)}async function E(e,t){return async function(e,t,n){await c("plugin:event|emit",{event:e,windowLabel:t,payload:n})}(e,void 0,t)}return e.Store=class{constructor(e){this.path=e}async set(e,t){return await window.__TAURI_INVOKE__("plugin:store|set",{path:this.path,key:e,value:t})}async get(e){return await window.__TAURI_INVOKE__("plugin:store|get",{path:this.path,key:e})}async has(e){return await window.__TAURI_INVOKE__("plugin:store|has",{path:this.path,key:e})}async delete(e){return await window.__TAURI_INVOKE__("plugin:store|delete",{path:this.path,key:e})}async clear(){return await window.__TAURI_INVOKE__("plugin:store|clear",{path:this.path})}async reset(){return await window.__TAURI_INVOKE__("plugin:store|reset",{path:this.path})}async keys(){return await window.__TAURI_INVOKE__("plugin:store|keys",{path:this.path})}async values(){return await window.__TAURI_INVOKE__("plugin:store|values",{path:this.path})}async entries(){return await window.__TAURI_INVOKE__("plugin:store|entries",{path:this.path})}async length(){return await window.__TAURI_INVOKE__("plugin:store|length",{path:this.path})}async load(){return await window.__TAURI_INVOKE__("plugin:store|load",{path:this.path})}async save(){return await window.__TAURI_INVOKE__("plugin:store|save",{path:this.path})}async onKeyChange(e,t){return await I("store://change",(n=>{n.payload.path===this.path&&n.payload.key===e&&t(n.payload.value)}))}async onChange(e){return await I("store://change",(t=>{t.payload.path===this.path&&e(t.payload.key,t.payload.value)}))}},e}({});Object.defineProperty(window.__TAURI__,"store",{value:__TAURI_STORE__})} diff --git a/plugins/store/src/error.rs b/plugins/store/src/error.rs index 03d29182..0a04bb09 100644 --- a/plugins/store/src/error.rs +++ b/plugins/store/src/error.rs @@ -1,4 +1,4 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT diff --git a/plugins/store/src/lib.rs b/plugins/store/src/lib.rs index a7b66b2e..1ce2885e 100644 --- a/plugins/store/src/lib.rs +++ b/plugins/store/src/lib.rs @@ -1,4 +1,4 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT @@ -46,7 +46,7 @@ pub fn with_store) -> Result>( if collection.frozen { return Err(Error::NotFound(path.to_path_buf())); } - let mut store = StoreBuilder::new(app, path.to_path_buf()).build(); + let mut store = StoreBuilder::new(path).build(app); // ignore loading errors, just use the default if let Err(err) = store.load() { warn!( @@ -205,15 +205,14 @@ impl Builder { /// # Examples /// /// ``` - /// # fn main() -> Result<(), Box> { - /// use tauri_plugin_store::{StoreBuilder,PluginBuilder}; + /// use tauri_plugin_store::{StoreBuilder, Builder}; /// - /// let store = StoreBuilder::new("store.bin".parse()?).build(); - /// - /// let builder = PluginBuilder::default().store(store); - /// - /// # Ok(()) - /// # } + /// tauri::Builder::default() + /// .setup(|app| { + /// let store = StoreBuilder::new("store.bin").build(app.handle()); + /// let builder = Builder::default().store(store); + /// Ok(()) + /// }); /// ``` pub fn store(mut self, store: Store) -> Self { self.stores.insert(store.path.clone(), store); @@ -225,15 +224,14 @@ impl Builder { /// # Examples /// /// ``` - /// # fn main() -> Result<(), Box> { - /// use tauri_plugin_store::{StoreBuilder,PluginBuilder}; - /// - /// let store = StoreBuilder::new("store.bin".parse()?).build(); - /// - /// let builder = PluginBuilder::default().stores([store]); + /// use tauri_plugin_store::{StoreBuilder, Builder}; /// - /// # Ok(()) - /// # } + /// tauri::Builder::default() + /// .setup(|app| { + /// let store = StoreBuilder::new("store.bin").build(app.handle()); + /// let builder = Builder::default().stores([store]); + /// Ok(()) + /// }); /// ``` pub fn stores>>(mut self, stores: T) -> Self { self.stores = stores @@ -250,15 +248,14 @@ impl Builder { /// # Examples /// /// ``` - /// # fn main() -> Result<(), Box> { - /// use tauri_plugin_store::{StoreBuilder,PluginBuilder}; + /// use tauri_plugin_store::{StoreBuilder, Builder}; /// - /// let store = StoreBuilder::new("store.bin".parse()?).build(); - /// - /// let builder = PluginBuilder::default().freeze(); - /// - /// # Ok(()) - /// # } + /// tauri::Builder::default() + /// .setup(|app| { + /// let store = StoreBuilder::new("store.bin").build(app.handle()); + /// app.handle().plugin(Builder::default().freeze().build()); + /// Ok(()) + /// }); /// ``` pub fn freeze(mut self) -> Self { self.frozen = true; @@ -270,19 +267,18 @@ impl Builder { /// # Examples /// /// ``` - /// # fn main() -> Result<(), Box> { - /// use tauri_plugin_store::{StoreBuilder,PluginBuilder}; - /// use tauri::Wry; - /// - /// let store = StoreBuilder::new("store.bin".parse()?).build(); - /// - /// let plugin = PluginBuilder::default().build::(); + /// use tauri_plugin_store::{StoreBuilder, Builder}; /// - /// # Ok(()) - /// # } + /// tauri::Builder::default() + /// .setup(|app| { + /// let store = StoreBuilder::new("store.bin").build(app.handle()); + /// app.handle().plugin(Builder::default().build()); + /// Ok(()) + /// }); /// ``` pub fn build(mut self) -> TauriPlugin { plugin::Builder::new("store") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![ set, get, has, delete, clear, reset, keys, values, length, entries, load, save ]) diff --git a/plugins/store/src/store.rs b/plugins/store/src/store.rs index 004b05b9..41e9ff54 100644 --- a/plugins/store/src/store.rs +++ b/plugins/store/src/store.rs @@ -1,4 +1,4 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT @@ -8,7 +8,7 @@ use std::{ collections::HashMap, fs::{create_dir_all, read, File}, io::Write, - path::PathBuf, + path::{Path, PathBuf}, }; use tauri::{AppHandle, Manager, Runtime}; @@ -30,8 +30,7 @@ fn default_deserialize( } /// Builds a [`Store`] -pub struct StoreBuilder { - app: AppHandle, +pub struct StoreBuilder { path: PathBuf, defaults: Option>, cache: HashMap, @@ -39,7 +38,7 @@ pub struct StoreBuilder { deserialize: DeserializeFn, } -impl StoreBuilder { +impl StoreBuilder { /// Creates a new [`StoreBuilder`]. /// /// # Examples @@ -47,15 +46,14 @@ impl StoreBuilder { /// # fn main() -> Result<(), Box> { /// use tauri_plugin_store::StoreBuilder; /// - /// let builder = StoreBuilder::new("store.bin".parse()?); + /// let builder = StoreBuilder::new("store.bin"); /// /// # Ok(()) /// # } /// ``` - pub fn new(app: AppHandle, path: PathBuf) -> Self { + pub fn new>(path: P) -> Self { Self { - app, - path, + path: path.as_ref().to_path_buf(), defaults: None, cache: Default::default(), serialize: default_serialize, @@ -75,7 +73,7 @@ impl StoreBuilder { /// /// defaults.insert("foo".to_string(), "bar".into()); /// - /// let builder = StoreBuilder::new("store.bin".parse()?) + /// let builder = StoreBuilder::new("store.bin") /// .defaults(defaults); /// /// # Ok(()) @@ -93,7 +91,7 @@ impl StoreBuilder { /// # fn main() -> Result<(), Box> { /// use tauri_plugin_store::StoreBuilder; /// - /// let builder = StoreBuilder::new("store.bin".parse()?) + /// let builder = StoreBuilder::new("store.bin") /// .default("foo".to_string(), "bar".into()); /// /// # Ok(()) @@ -113,7 +111,7 @@ impl StoreBuilder { /// # fn main() -> Result<(), Box> { /// use tauri_plugin_store::StoreBuilder; /// - /// let builder = StoreBuilder::new("store.json".parse()?) + /// let builder = StoreBuilder::new("store.json") /// .serialize(|cache| serde_json::to_vec(&cache).map_err(Into::into)); /// /// # Ok(()) @@ -130,7 +128,7 @@ impl StoreBuilder { /// # fn main() -> Result<(), Box> { /// use tauri_plugin_store::StoreBuilder; /// - /// let builder = StoreBuilder::new("store.json".parse()?) + /// let builder = StoreBuilder::new("store.json") /// .deserialize(|bytes| serde_json::from_slice(&bytes).map_err(Into::into)); /// /// # Ok(()) @@ -144,16 +142,15 @@ impl StoreBuilder { /// /// # Examples /// ``` - /// # fn main() -> Result<(), Box> { - /// use tauri_plugin_store::StoreBuilder; - /// - /// let store = StoreBuilder::new("store.bin".parse()?).build(); - /// - /// # Ok(()) - /// # } - pub fn build(self) -> Store { + /// tauri::Builder::default() + /// .setup(|app| { + /// let store = tauri_plugin_store::StoreBuilder::new("store.json").build(app.handle()); + /// Ok(()) + /// }); + /// ``` + pub fn build(self, app: AppHandle) -> Store { Store { - app: self.app, + app, path: self.path, defaults: self.defaults, cache: self.cache, diff --git a/plugins/store/tsconfig.json b/plugins/store/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/store/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/store/tsconfig.json b/plugins/store/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/store/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/stronghold/CHANGELOG.md b/plugins/stronghold/CHANGELOG.md new file mode 100644 index 00000000..ae13dabe --- /dev/null +++ b/plugins/stronghold/CHANGELOG.md @@ -0,0 +1,9 @@ +# Changelog + +## \[2.0.0-alpha.1] + +- [`b3d7d11`](https://github.com/tauri-apps/plugins-workspace/commit/b3d7d11ae32e0970184f53be26e2c5530f78cdf0)([#416](https://github.com/tauri-apps/plugins-workspace/pull/416)) Added `Stronghold.load` and removed its constructor. + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/stronghold/Cargo.toml b/plugins/stronghold/Cargo.toml index fb3ac3b8..8b6084f5 100644 --- a/plugins/stronghold/Cargo.toml +++ b/plugins/stronghold/Cargo.toml @@ -1,25 +1,23 @@ [package] name = "tauri-plugin-stronghold" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Store secrets and keys using the IOTA Stronghold encrypted database." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } iota_stronghold = "1" -iota-crypto = "0.17" +iota-crypto = "0.20" hex = "0.4" -zeroize = { version = "1", features = ["zeroize_derive"] } +zeroize = { version = "1", features = [ "zeroize_derive" ] } [dev-dependencies] rand = "0.8" -rusty-fork = "0.3" \ No newline at end of file +rusty-fork = "0.3" diff --git a/plugins/stronghold/README.md b/plugins/stronghold/README.md index da84b0d7..7254b857 100644 --- a/plugins/stronghold/README.md +++ b/plugins/stronghold/README.md @@ -4,7 +4,7 @@ Store secrets and keys using the [IOTA Stronghold](https://github.com/iotaledger ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-stronghold = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-stronghold = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-stronghold +# or +npm add @tauri-apps/plugin-stronghold +# or +yarn add @tauri-apps/plugin-stronghold + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-stronghold#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-stronghold#v2 @@ -55,7 +64,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { Stronghold, Location } from "tauri-plugin-stronghold-api"; +import { Stronghold, Location } from "@tauri-apps/plugin-stronghold"; // TODO ``` diff --git a/plugins/stronghold/guest-js/index.ts b/plugins/stronghold/guest-js/index.ts index 3339f87f..1b28f4f1 100644 --- a/plugins/stronghold/guest-js/index.ts +++ b/plugins/stronghold/guest-js/index.ts @@ -1,4 +1,12 @@ -import { invoke } from "@tauri-apps/api/tauri"; +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} type BytesDto = string | number[]; export type ClientPath = @@ -127,16 +135,18 @@ class ProcedureExecutor { outputLocation: Location, sizeBytes?: number ): Promise { - return await invoke("plugin:stronghold|execute_procedure", { - ...this.procedureArgs, - procedure: { - type: "SLIP10Generate", - payload: { - output: outputLocation, - sizeBytes, + return await window + .__TAURI_INVOKE__("plugin:stronghold|execute_procedure", { + ...this.procedureArgs, + procedure: { + type: "SLIP10Generate", + payload: { + output: outputLocation, + sizeBytes, + }, }, - }, - }).then((n) => Uint8Array.from(n)); + }) + .then((n) => Uint8Array.from(n)); } /** @@ -154,20 +164,22 @@ class ProcedureExecutor { sourceLocation: Location, outputLocation: Location ): Promise { - return await invoke("plugin:stronghold|execute_procedure", { - ...this.procedureArgs, - procedure: { - type: "SLIP10Derive", - payload: { - chain, - input: { - type: source, - payload: sourceLocation, + return await window + .__TAURI_INVOKE__("plugin:stronghold|execute_procedure", { + ...this.procedureArgs, + procedure: { + type: "SLIP10Derive", + payload: { + chain, + input: { + type: source, + payload: sourceLocation, + }, + output: outputLocation, }, - output: outputLocation, }, - }, - }).then((n) => Uint8Array.from(n)); + }) + .then((n) => Uint8Array.from(n)); } /** @@ -183,17 +195,19 @@ class ProcedureExecutor { outputLocation: Location, passphrase?: string ): Promise { - return await invoke("plugin:stronghold|execute_procedure", { - ...this.procedureArgs, - procedure: { - type: "BIP39Recover", - payload: { - mnemonic, - passphrase, - output: outputLocation, + return await window + .__TAURI_INVOKE__("plugin:stronghold|execute_procedure", { + ...this.procedureArgs, + procedure: { + type: "BIP39Recover", + payload: { + mnemonic, + passphrase, + output: outputLocation, + }, }, - }, - }).then((n) => Uint8Array.from(n)); + }) + .then((n) => Uint8Array.from(n)); } /** @@ -207,34 +221,40 @@ class ProcedureExecutor { outputLocation: Location, passphrase?: string ): Promise { - return await invoke("plugin:stronghold|execute_procedure", { - ...this.procedureArgs, - procedure: { - type: "BIP39Generate", - payload: { - output: outputLocation, - passphrase, + return await window + .__TAURI_INVOKE__("plugin:stronghold|execute_procedure", { + ...this.procedureArgs, + procedure: { + type: "BIP39Generate", + payload: { + output: outputLocation, + passphrase, + }, }, - }, - }).then((n) => Uint8Array.from(n)); + }) + .then((n) => Uint8Array.from(n)); } /** * Gets the Ed25519 public key of a SLIP10 private key. * @param privateKeyLocation The location of the private key. Must be the `outputLocation` of a previous call to `deriveSLIP10`. * @returns A promise resolving to the public key hex string. + * + * @since 2.0.0 */ async getEd25519PublicKey(privateKeyLocation: Location): Promise { - return await invoke("plugin:stronghold|execute_procedure", { - ...this.procedureArgs, - procedure: { - type: "PublicKey", - payload: { - type: "Ed25519", - privateKey: privateKeyLocation, + return await window + .__TAURI_INVOKE__("plugin:stronghold|execute_procedure", { + ...this.procedureArgs, + procedure: { + type: "PublicKey", + payload: { + type: "Ed25519", + privateKey: privateKeyLocation, + }, }, - }, - }).then((n) => Uint8Array.from(n)); + }) + .then((n) => Uint8Array.from(n)); } /** @@ -242,21 +262,25 @@ class ProcedureExecutor { * @param privateKeyLocation The location of the record where the private key is stored. Must be the `outputLocation` of a previous call to `deriveSLIP10`. * @param msg The message to sign. * @returns A promise resolving to the signature hex string. + * + * @since 2.0.0 */ async signEd25519( privateKeyLocation: Location, msg: string ): Promise { - return await invoke("plugin:stronghold|execute_procedure", { - ...this.procedureArgs, - procedure: { - type: "Ed25519Sign", - payload: { - privateKey: privateKeyLocation, - msg, + return await window + .__TAURI_INVOKE__("plugin:stronghold|execute_procedure", { + ...this.procedureArgs, + procedure: { + type: "Ed25519Sign", + payload: { + privateKey: privateKeyLocation, + msg, + }, }, - }, - }).then((n) => Uint8Array.from(n)); + }) + .then((n) => Uint8Array.from(n)); } } @@ -294,11 +318,13 @@ export class Store { } async get(key: StoreKey): Promise { - return await invoke("plugin:stronghold|get_store_record", { - snapshotPath: this.path, - client: this.client, - key: toBytesDto(key), - }).then((v) => Uint8Array.from(v)); + return await window + .__TAURI_INVOKE__("plugin:stronghold|get_store_record", { + snapshotPath: this.path, + client: this.client, + key: toBytesDto(key), + }) + .then((v) => Uint8Array.from(v)); } async insert( @@ -306,24 +332,29 @@ export class Store { value: number[], lifetime?: Duration ): Promise { - return await invoke("plugin:stronghold|save_store_record", { - snapshotPath: this.path, - client: this.client, - key: toBytesDto(key), - value, - lifetime, - }); - } - - async remove(key: StoreKey): Promise { - return await invoke( - "plugin:stronghold|remove_store_record", + return await window.__TAURI_INVOKE__( + "plugin:stronghold|save_store_record", { snapshotPath: this.path, client: this.client, key: toBytesDto(key), + value, + lifetime, } - ).then((v) => (v != null ? Uint8Array.from(v) : null)); + ); + } + + async remove(key: StoreKey): Promise { + return await window + .__TAURI_INVOKE__( + "plugin:stronghold|remove_store_record", + { + snapshotPath: this.path, + client: this.client, + key: toBytesDto(key), + } + ) + .then((v) => (v != null ? Uint8Array.from(v) : null)); } } @@ -358,7 +389,7 @@ export class Vault extends ProcedureExecutor { * @returns */ async insert(recordPath: RecordPath, secret: number[]): Promise { - return await invoke("plugin:stronghold|save_secret", { + return await window.__TAURI_INVOKE__("plugin:stronghold|save_secret", { snapshotPath: this.path, client: this.client, vault: this.name, @@ -374,7 +405,7 @@ export class Vault extends ProcedureExecutor { * @returns */ async remove(location: Location): Promise { - return await invoke("plugin:stronghold|remove_secret", { + return await window.__TAURI_INVOKE__("plugin:stronghold|remove_secret", { snapshotPath: this.path, client: this.client, vault: this.name, @@ -395,44 +426,49 @@ export class Stronghold { * @param path * @param password */ - constructor(path: string, password: string) { + private constructor(path: string) { this.path = path; - void this.reload(password); } /** - * Force a reload of the snapshot. The password must match. + * Load the snapshot if it exists (password must match), or start a fresh stronghold instance otherwise. * @param password * @returns */ - private async reload(password: string): Promise { - return await invoke("plugin:stronghold|initialize", { - snapshotPath: this.path, - password, - }); + static async load(path: string, password: string): Promise { + return await window + .__TAURI_INVOKE__("plugin:stronghold|initialize", { + snapshotPath: path, + password, + }) + .then(() => new Stronghold(path)); } /** * Remove this instance from the cache. */ async unload(): Promise { - return await invoke("plugin:stronghold|destroy", { + return await window.__TAURI_INVOKE__("plugin:stronghold|destroy", { snapshotPath: this.path, }); } async loadClient(client: ClientPath): Promise { - return await invoke("plugin:stronghold|load_client", { - snapshotPath: this.path, - client: toBytesDto(client), - }).then(() => new Client(this.path, client)); + return await window + .__TAURI_INVOKE__("plugin:stronghold|load_client", { + snapshotPath: this.path, + client: toBytesDto(client), + }) + .then(() => new Client(this.path, client)); } async createClient(client: ClientPath): Promise { - return await invoke("plugin:stronghold|create_client", { - snapshotPath: this.path, - client: toBytesDto(client), - }).then(() => new Client(this.path, client)); + return await window + .__TAURI_INVOKE__("plugin:stronghold|create_client", { + snapshotPath: this.path, + client: toBytesDto(client), + }) + .then(() => new Client(this.path, client)); } /** @@ -440,7 +476,7 @@ export class Stronghold { * @returns */ async save(): Promise { - return await invoke("plugin:stronghold|save", { + return await window.__TAURI_INVOKE__("plugin:stronghold|save", { snapshotPath: this.path, }); } diff --git a/plugins/stronghold/package.json b/plugins/stronghold/package.json index 254a3925..fcb1364e 100644 --- a/plugins/stronghold/package.json +++ b/plugins/stronghold/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-stronghold-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-stronghold", + "version": "2.0.0-alpha.1", "description": "Store secrets and keys using the IOTA Stronghold encrypted database.", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/stronghold/src/api-iife.js b/plugins/stronghold/src/api-iife.js new file mode 100644 index 00000000..b8cf0127 --- /dev/null +++ b/plugins/stronghold/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_STRONGHOLD__=function(t){"use strict";function e(t){return"string"==typeof t?t:Array.from(t instanceof ArrayBuffer?new Uint8Array(t):t)}class r{constructor(t,e){this.type=t,this.payload=e}static generic(t,n){return new r("Generic",{vault:e(t),record:e(n)})}static counter(t,n){return new r("Counter",{vault:e(t),counter:n})}}class n{constructor(t){this.procedureArgs=t}async generateSLIP10Seed(t,e){return await window.__TAURI_INVOKE__("plugin:stronghold|execute_procedure",{...this.procedureArgs,procedure:{type:"SLIP10Generate",payload:{output:t,sizeBytes:e}}}).then((t=>Uint8Array.from(t)))}async deriveSLIP10(t,e,r,n){return await window.__TAURI_INVOKE__("plugin:stronghold|execute_procedure",{...this.procedureArgs,procedure:{type:"SLIP10Derive",payload:{chain:t,input:{type:e,payload:r},output:n}}}).then((t=>Uint8Array.from(t)))}async recoverBIP39(t,e,r){return await window.__TAURI_INVOKE__("plugin:stronghold|execute_procedure",{...this.procedureArgs,procedure:{type:"BIP39Recover",payload:{mnemonic:t,passphrase:r,output:e}}}).then((t=>Uint8Array.from(t)))}async generateBIP39(t,e){return await window.__TAURI_INVOKE__("plugin:stronghold|execute_procedure",{...this.procedureArgs,procedure:{type:"BIP39Generate",payload:{output:t,passphrase:e}}}).then((t=>Uint8Array.from(t)))}async getEd25519PublicKey(t){return await window.__TAURI_INVOKE__("plugin:stronghold|execute_procedure",{...this.procedureArgs,procedure:{type:"PublicKey",payload:{type:"Ed25519",privateKey:t}}}).then((t=>Uint8Array.from(t)))}async signEd25519(t,e){return await window.__TAURI_INVOKE__("plugin:stronghold|execute_procedure",{...this.procedureArgs,procedure:{type:"Ed25519Sign",payload:{privateKey:t,msg:e}}}).then((t=>Uint8Array.from(t)))}}class a{constructor(t,r){this.path=t,this.name=e(r)}getVault(t){return new s(this.path,this.name,e(t))}getStore(){return new i(this.path,this.name)}}class i{constructor(t,e){this.path=t,this.client=e}async get(t){return await window.__TAURI_INVOKE__("plugin:stronghold|get_store_record",{snapshotPath:this.path,client:this.client,key:e(t)}).then((t=>Uint8Array.from(t)))}async insert(t,r,n){return await window.__TAURI_INVOKE__("plugin:stronghold|save_store_record",{snapshotPath:this.path,client:this.client,key:e(t),value:r,lifetime:n})}async remove(t){return await window.__TAURI_INVOKE__("plugin:stronghold|remove_store_record",{snapshotPath:this.path,client:this.client,key:e(t)}).then((t=>null!=t?Uint8Array.from(t):null))}}class s extends n{constructor(t,r,n){super({snapshotPath:t,client:r,vault:n}),this.path=t,this.client=e(r),this.name=e(n)}async insert(t,r){return await window.__TAURI_INVOKE__("plugin:stronghold|save_secret",{snapshotPath:this.path,client:this.client,vault:this.name,recordPath:e(t),secret:r})}async remove(t){return await window.__TAURI_INVOKE__("plugin:stronghold|remove_secret",{snapshotPath:this.path,client:this.client,vault:this.name,location:t})}}class o{constructor(t){this.path=t}static async load(t,e){return await window.__TAURI_INVOKE__("plugin:stronghold|initialize",{snapshotPath:t,password:e}).then((()=>new o(t)))}async unload(){return await window.__TAURI_INVOKE__("plugin:stronghold|destroy",{snapshotPath:this.path})}async loadClient(t){return await window.__TAURI_INVOKE__("plugin:stronghold|load_client",{snapshotPath:this.path,client:e(t)}).then((()=>new a(this.path,t)))}async createClient(t){return await window.__TAURI_INVOKE__("plugin:stronghold|create_client",{snapshotPath:this.path,client:e(t)}).then((()=>new a(this.path,t)))}async save(){return await window.__TAURI_INVOKE__("plugin:stronghold|save",{snapshotPath:this.path})}}return t.Client=a,t.Location=r,t.Store=i,t.Stronghold=o,t.Vault=s,t}({});Object.defineProperty(window.__TAURI__,"stronghold",{value:__TAURI_STRONGHOLD__})} diff --git a/plugins/stronghold/src/lib.rs b/plugins/stronghold/src/lib.rs index b35f61bd..37322cc6 100644 --- a/plugins/stronghold/src/lib.rs +++ b/plugins/stronghold/src/lib.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::{ collections::HashMap, fmt, @@ -409,6 +413,7 @@ impl Builder { let password_hash_function = self.password_hash_function; PluginBuilder::new("stronghold") + .js_init_script(include_str!("api-iife.js").to_string()) .setup(move |app, _api| { app.manage(StrongholdCollection::default()); app.manage(PasswordHashFunction(password_hash_function)); diff --git a/plugins/stronghold/src/stronghold.rs b/plugins/stronghold/src/stronghold.rs index 8e065c44..7da521bd 100644 --- a/plugins/stronghold/src/stronghold.rs +++ b/plugins/stronghold/src/stronghold.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::{convert::TryFrom, ops::Deref, path::Path}; use iota_stronghold::{KeyProvider, SnapshotPath}; diff --git a/plugins/stronghold/tsconfig.json b/plugins/stronghold/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/stronghold/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/stronghold/tsconfig.json b/plugins/stronghold/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/stronghold/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/updater/CHANGELOG.md b/plugins/updater/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/updater/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/updater/Cargo.toml b/plugins/updater/Cargo.toml new file mode 100644 index 00000000..7342e8d8 --- /dev/null +++ b/plugins/updater/Cargo.toml @@ -0,0 +1,40 @@ +[package] +name = "tauri-plugin-updater" +version = "2.0.0-alpha.0" +description = "In-app updates for Tauri applications." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } + +[dependencies] +tauri = { workspace = true } +serde = { workspace = true } +serde_json = { workspace = true } +thiserror = { workspace = true } +tokio = "1" +reqwest = { version = "0.11", default-features = false, features = [ "json", "stream" ] } +url = "2" +http = "0.2" +dirs-next = "2" +minisign-verify = "0.2" +time = { version = "0.3", features = [ "parsing", "formatting" ] } +base64 = "0.21" +percent-encoding = "2" +semver = { version = "1", features = [ "serde" ] } +futures-util = "0.3" +tempfile = "3" +flate2 = "1" +tar = "0.4" +ignore = "0.4" + +[target."cfg(target_os = \"windows\")".dependencies] +zip = { version = "0.6", default-features = false } + +[dev-dependencies] +mockito = "0.31" +tokio-test = "0.4.2" + +[features] +native-tls = [ "reqwest/native-tls" ] +native-tls-vendored = [ "reqwest/native-tls-vendored" ] +rustls-tls = [ "reqwest/rustls-tls" ] diff --git a/plugins/updater/LICENSE.spdx b/plugins/updater/LICENSE.spdx new file mode 100644 index 00000000..cdd0df5a --- /dev/null +++ b/plugins/updater/LICENSE.spdx @@ -0,0 +1,20 @@ +SPDXVersion: SPDX-2.1 +DataLicense: CC0-1.0 +PackageName: tauri +DataFormat: SPDXRef-1 +PackageSupplier: Organization: The Tauri Programme in the Commons Conservancy +PackageHomePage: https://tauri.app +PackageLicenseDeclared: Apache-2.0 +PackageLicenseDeclared: MIT +PackageCopyrightText: 2019-2022, The Tauri Programme in the Commons Conservancy +PackageSummary: Tauri is a rust project that enables developers to make secure +and small desktop applications using a web frontend. + +PackageComment: The package includes the following libraries; see +Relationship information. + +Created: 2019-05-20T09:00:00Z +PackageDownloadLocation: git://github.com/tauri-apps/tauri +PackageDownloadLocation: git+https://github.com/tauri-apps/tauri.git +PackageDownloadLocation: git+ssh://github.com/tauri-apps/tauri.git +Creator: Person: Daniel Thompson-Yvetot \ No newline at end of file diff --git a/plugins/updater/LICENSE_APACHE-2.0 b/plugins/updater/LICENSE_APACHE-2.0 new file mode 100644 index 00000000..4947287f --- /dev/null +++ b/plugins/updater/LICENSE_APACHE-2.0 @@ -0,0 +1,177 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS \ No newline at end of file diff --git a/plugins/updater/LICENSE_MIT b/plugins/updater/LICENSE_MIT new file mode 100644 index 00000000..4d754725 --- /dev/null +++ b/plugins/updater/LICENSE_MIT @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2017 - Present Tauri Apps Contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/plugins/updater/README.md b/plugins/updater/README.md new file mode 100644 index 00000000..eb6f3642 --- /dev/null +++ b/plugins/updater/README.md @@ -0,0 +1,87 @@ +# Updater + +In-app updates for Tauri applications. + +- Supported platforms: Windows, Linux and macOS. + +## Install + +_This plugin requires a Rust version of at least **1.65**_ + +There are three general methods of installation that we can recommend. + +1. Use crates.io and npm (easiest, and requires you to trust that our publishing pipeline worked) +2. Pull sources directly from Github using git tags / revision hashes (most secure) +3. Git submodule install this repo in your tauri project and then use file protocol to ingest the source (most secure, but inconvenient to use) + +Install the Core plugin by adding the following to your `Cargo.toml` file: + +`src-tauri/Cargo.toml` + +```toml +# you can add the dependencies on the `[dependencies]` section if you do not target mobile +[target."cfg(not(any(target_os = \"android\", target_os = \"ios\")))".dependencies] +tauri-plugin-updater = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-updater = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +``` + +You can install the JavaScript Guest bindings using your preferred JavaScript package manager: + +> Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. + +```sh +pnpm add @tauri-apps/plugin-updater +# or +npm add @tauri-apps/plugin-updater +# or +yarn add @tauri-apps/plugin-updater + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-updater#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-updater#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-updater#v2 +``` + +## Usage + +First you need to register the core plugin with Tauri: + +`src-tauri/src/main.rs` + +```rust +fn main() { + tauri::Builder::default() + .setup(|app| { + #[cfg(desktop)] + app.handle().plugin(tauri_plugin_updater::Builder::new().build())?; + Ok(()) + }) + .run(tauri::generate_context!()) + .expect("error while running tauri application"); +} +``` + +Afterwards all the plugin's APIs are available through the JavaScript guest bindings: + +```javascript +import { check } from "@tauri-apps/plugin-updater"; +import { relaunch } from "@tauri-apps/plugin-process"; +const update = await check(); +if (update.response.available) { + await update.downloadAndInstall(); + await relaunch(); +} +``` + +## Contributing + +PRs accepted. Please make sure to read the Contributing Guide before making a pull request. + +## License + +Code: (c) 2015 - Present - The Tauri Programme within The Commons Conservancy. + +MIT or MIT/Apache 2.0 where applicable. diff --git a/plugins/updater/build.rs b/plugins/updater/build.rs new file mode 100644 index 00000000..0b339c43 --- /dev/null +++ b/plugins/updater/build.rs @@ -0,0 +1,18 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +fn main() { + let target_os = std::env::var("CARGO_CFG_TARGET_OS").unwrap(); + let mobile = target_os == "ios" || target_os == "android"; + alias("desktop", !mobile); + alias("mobile", mobile); +} + +// creates a cfg alias if `has_feature` is true. +// `alias` must be a snake case string. +fn alias(alias: &str, has_feature: bool) { + if has_feature { + println!("cargo:rustc-cfg={alias}"); + } +} diff --git a/plugins/updater/guest-js/index.ts b/plugins/updater/guest-js/index.ts new file mode 100644 index 00000000..0124caf8 --- /dev/null +++ b/plugins/updater/guest-js/index.ts @@ -0,0 +1,62 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +import { invoke, Channel } from "@tauri-apps/api/tauri"; + +interface CheckOptions { + /** + * Request headers + */ + headers?: Record; + /** + * Timeout in seconds + */ + timeout?: number; + /** + * Target identifier for the running application. This is sent to the backend. + */ + target?: string; +} + +interface UpdateResponse { + available: boolean; + currentVersion: string; + latestVersion: string; + date?: string; + body?: string; +} + +type DownloadEvent = + | { event: "Started"; data: { contentLength?: number } } + | { event: "Progress"; data: { chunkLength: number } } + | { event: "Finished" }; + +class Update { + response: UpdateResponse; + + constructor(response: UpdateResponse) { + this.response = response; + } + + async downloadAndInstall( + onEvent?: (progress: DownloadEvent) => void + ): Promise { + const channel = new Channel(); + if (onEvent != null) { + channel.onmessage = onEvent; + } + return invoke("plugin:updater|download_and_install", { + onEvent: channel, + }); + } +} + +async function check(options?: CheckOptions): Promise { + return invoke("plugin:updater|check", { ...options }).then( + (response) => new Update(response) + ); +} + +export type { CheckOptions, UpdateResponse, DownloadEvent }; +export { check, Update }; diff --git a/plugins/updater/package.json b/plugins/updater/package.json new file mode 100644 index 00000000..1117938d --- /dev/null +++ b/plugins/updater/package.json @@ -0,0 +1,32 @@ +{ + "name": "@tauri-apps/plugin-updater", + "version": "2.0.0-alpha.0", + "license": "MIT or APACHE-2.0", + "authors": [ + "Tauri Programme within The Commons Conservancy" + ], + "type": "module", + "browser": "dist-js/index.min.js", + "module": "dist-js/index.mjs", + "types": "dist-js/index.d.ts", + "exports": { + "import": "./dist-js/index.mjs", + "types": "./dist-js/index.d.ts", + "browser": "./dist-js/index.min.js" + }, + "scripts": { + "build": "rollup -c" + }, + "files": [ + "dist-js", + "!dist-js/**/*.map", + "README.md", + "LICENSE" + ], + "devDependencies": { + "tslib": "^2.5.0" + }, + "dependencies": { + "@tauri-apps/api": "2.0.0-alpha.4" + } +} diff --git a/plugins/updater/rollup.config.mjs b/plugins/updater/rollup.config.mjs new file mode 100644 index 00000000..6555e98b --- /dev/null +++ b/plugins/updater/rollup.config.mjs @@ -0,0 +1,11 @@ +import { readFileSync } from "fs"; + +import { createConfig } from "../../shared/rollup.config.mjs"; + +export default createConfig({ + input: "guest-js/index.ts", + pkg: JSON.parse( + readFileSync(new URL("./package.json", import.meta.url), "utf8") + ), + external: [/^@tauri-apps\/api/], +}); diff --git a/plugins/updater/src/api-iife.js b/plugins/updater/src/api-iife.js new file mode 100644 index 00000000..98b55689 --- /dev/null +++ b/plugins/updater/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_UPDATER__=function(e){"use strict";var n=Object.defineProperty,t=(e,n,t)=>{if(!n.has(e))throw TypeError("Cannot "+t)},r=(e,n,r)=>(t(e,n,"read from private field"),r?r.call(e):n.get(e)),i=(e,n,r,i)=>(t(e,n,"write to private field"),i?i.call(e,r):n.set(e,r),r);function a(e,n=!1){let t=window.crypto.getRandomValues(new Uint32Array(1))[0],r=`_${t}`;return Object.defineProperty(window,r,{value:t=>(n&&Reflect.deleteProperty(window,r),e?.(t)),writable:!1,configurable:!0}),t}((e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})})({},{Channel:()=>s,PluginListener:()=>l,addPluginListener:()=>c,convertFileSrc:()=>u,invoke:()=>d,transformCallback:()=>a});var o,s=class{constructor(){this.__TAURI_CHANNEL_MARKER__=!0,((e,n,t)=>{if(n.has(e))throw TypeError("Cannot add the same private member more than once");n instanceof WeakSet?n.add(e):n.set(e,t)})(this,o,(()=>{})),this.id=a((e=>{r(this,o).call(this,e)}))}set onmessage(e){i(this,o,e)}get onmessage(){return r(this,o)}toJSON(){return`__CHANNEL__:${this.id}`}};o=new WeakMap;var l=class{constructor(e,n,t){this.plugin=e,this.event=n,this.channelId=t}async unregister(){return d(`plugin:${this.plugin}|remove_listener`,{event:this.event,channelId:this.channelId})}};async function c(e,n,t){let r=new s;return r.onmessage=t,d(`plugin:${e}|register_listener`,{event:n,handler:r}).then((()=>new l(e,n,r.id)))}async function d(e,n={}){return new Promise(((t,r)=>{let i=a((e=>{t(e),Reflect.deleteProperty(window,`_${o}`)}),!0),o=a((e=>{r(e),Reflect.deleteProperty(window,`_${i}`)}),!0);window.__TAURI_IPC__({cmd:e,callback:i,error:o,...n})}))}function u(e,n="asset"){let t=encodeURIComponent(e);return navigator.userAgent.includes("Windows")?`https://${n}.localhost/${t}`:`${n}://localhost/${t}`}class _{constructor(e){this.response=e}async downloadAndInstall(e){const n=new s;return null!=e&&(n.onmessage=e),d("plugin:updater|download_and_install",{onEvent:n})}}return e.Update=_,e.check=async function(e){return d("plugin:updater|check",{...e}).then((e=>new _(e)))},e}({});Object.defineProperty(window.__TAURI__,"updater",{value:__TAURI_UPDATER__})} diff --git a/plugins/updater/src/commands.rs b/plugins/updater/src/commands.rs new file mode 100644 index 00000000..75d78288 --- /dev/null +++ b/plugins/updater/src/commands.rs @@ -0,0 +1,106 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use crate::{PendingUpdate, Result, UpdaterExt}; + +use http::header; +use serde::{Deserialize, Deserializer, Serialize}; +use tauri::{api::ipc::Channel, AppHandle, Runtime, State}; + +use std::{collections::HashMap, time::Duration}; + +#[derive(Serialize)] +#[serde(rename_all = "camelCase")] +pub(crate) struct Metadata { + available: bool, + current_version: String, + latest_version: String, + date: Option, + body: Option, +} + +#[derive(Debug, Default)] +pub(crate) struct HeaderMap(header::HeaderMap); + +impl<'de> Deserialize<'de> for HeaderMap { + fn deserialize(deserializer: D) -> std::result::Result + where + D: Deserializer<'de>, + { + let map = HashMap::::deserialize(deserializer)?; + let mut headers = header::HeaderMap::default(); + for (key, value) in map { + if let (Ok(key), Ok(value)) = ( + header::HeaderName::from_bytes(key.as_bytes()), + header::HeaderValue::from_str(&value), + ) { + headers.insert(key, value); + } else { + return Err(serde::de::Error::custom(format!( + "invalid header `{key}` `{value}`" + ))); + } + } + Ok(Self(headers)) + } +} + +#[tauri::command] +pub(crate) async fn check( + app: AppHandle, + pending: State<'_, PendingUpdate>, + headers: Option, + timeout: Option, + target: Option, +) -> Result { + let mut builder = app.updater(); + if let Some(headers) = headers { + for (k, v) in headers.0.iter() { + builder = builder.header(k, v)?; + } + } + if let Some(timeout) = timeout { + builder = builder.timeout(Duration::from_secs(timeout)); + } + if let Some(target) = target { + builder = builder.target(target); + } + + let response = builder.check().await?; + + let metadata = Metadata { + available: response.is_update_available(), + current_version: response.current_version().to_string(), + latest_version: response.latest_version().to_string(), + date: response.date().map(|d| d.to_string()), + body: response.body().cloned(), + }; + + pending.0.lock().await.replace(response); + + Ok(metadata) +} + +#[derive(Serialize)] +#[serde(rename_all = "camelCase")] +pub(crate) struct DownloadProgress { + chunk_length: usize, + content_length: Option, +} + +#[tauri::command] +pub(crate) async fn download_and_install( + _app: AppHandle, + pending: State<'_, PendingUpdate>, + on_event: Channel, +) -> Result<()> { + if let Some(pending) = &*pending.0.lock().await { + pending + .download_and_install(move |event| { + on_event.send(&event).unwrap(); + }) + .await?; + } + Ok(()) +} diff --git a/plugins/updater/src/config.rs b/plugins/updater/src/config.rs new file mode 100644 index 00000000..9361ea00 --- /dev/null +++ b/plugins/updater/src/config.rs @@ -0,0 +1,46 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use serde::{Deserialize, Deserializer}; +use url::Url; + +/// Updater configuration. +#[derive(Debug, Clone, Deserialize)] +pub struct Config { + #[serde(default)] + pub endpoints: Vec, + /// Additional arguments given to the NSIS or WiX installer. + #[serde(default, alias = "installer-args")] + pub installer_args: Vec, +} + +/// A URL to an updater server. +/// +/// The URL must use the `https` scheme on production. +#[derive(Debug, PartialEq, Eq, Clone)] +pub struct UpdaterEndpoint(pub Url); + +impl std::fmt::Display for UpdaterEndpoint { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + write!(f, "{}", self.0) + } +} + +impl<'de> Deserialize<'de> for UpdaterEndpoint { + fn deserialize(deserializer: D) -> Result + where + D: Deserializer<'de>, + { + let url = Url::deserialize(deserializer)?; + #[cfg(all(not(debug_assertions), not(feature = "schema")))] + { + if url.scheme() != "https" { + return Err(serde::de::Error::custom( + "The configured updater endpoint must use the `https` protocol.", + )); + } + } + Ok(Self(url)) + } +} diff --git a/plugins/updater/src/error.rs b/plugins/updater/src/error.rs new file mode 100644 index 00000000..20f2eb42 --- /dev/null +++ b/plugins/updater/src/error.rs @@ -0,0 +1,100 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use http::StatusCode; +use serde::{Serialize, Serializer}; + +/// All errors that can occur while running the updater. +#[derive(Debug, thiserror::Error)] +#[non_exhaustive] +pub enum Error { + /// IO Errors. + #[error("`{0}`")] + Io(#[from] std::io::Error), + /// Semver Errors. + #[error("Unable to compare version: {0}")] + Semver(#[from] semver::Error), + /// JSON (Serde) Errors. + #[error("JSON error: {0}")] + SerdeJson(#[from] serde_json::Error), + /// Minisign is used for signature validation. + #[error("Verify signature error: {0}")] + Minisign(#[from] minisign_verify::Error), + /// Error with Minisign base64 decoding. + #[error("Signature decoding error: {0}")] + Base64(#[from] base64::DecodeError), + /// UTF8 Errors in signature. + #[error("The signature {0} could not be decoded, please check if it is a valid base64 string. The signature must be the contents of the `.sig` file generated by the Tauri bundler, as a string.")] + SignatureUtf8(String), + /// Tauri utils, mainly extract and file move. + #[error("Tauri API error: {0}")] + TauriApi(#[from] tauri::api::Error), + /// Network error. + #[error("Download request failed with status: {0}")] + DownloadFailed(StatusCode), + /// Network error. + #[error("Network error: {0}")] + Network(#[from] reqwest::Error), + /// Failed to serialize header value as string. + #[error(transparent)] + Utf8(#[from] std::string::FromUtf8Error), + /// Could not fetch a valid response from the server. + #[error("Could not fetch a valid release JSON from the remote")] + ReleaseNotFound, + /// Error building updater. + #[error("Unable to prepare the updater: {0}")] + Builder(String), + /// Error building updater. + #[error("Unable to extract the new version: {0}")] + Extract(String), + /// Updater cannot be executed on this Linux package. Currently the updater is enabled only on AppImages. + #[error( + "Cannot run updater on this Linux package. Currently only an AppImage can be updated." + )] + UnsupportedLinuxPackage, + /// Operating system is not supported. + #[error("unsupported OS, expected one of `linux`, `darwin` or `windows`.")] + UnsupportedOs, + /// Unsupported app architecture. + #[error( + "Unsupported application architecture, expected one of `x86`, `x86_64`, `arm` or `aarch64`." + )] + UnsupportedArch, + /// The platform was not found on the updater JSON response. + #[error("the platform `{0}` was not found on the response `platforms` object")] + TargetNotFound(String), + /// Triggered when there is NO error and the two versions are equals. + /// On client side, it's important to catch this error. + #[error("No updates available")] + UpToDate, + /// The updater responded with an invalid signature type. + #[error("the updater response field `{0}` type is invalid, expected {1} but found {2}")] + InvalidResponseType(&'static str, &'static str, serde_json::Value), + /// HTTP error. + #[error(transparent)] + Http(#[from] http::Error), + /// Temp dir is not on same mount mount. This prevents our updater to rename the AppImage to a temp file. + #[cfg(target_os = "linux")] + #[error("temp directory is not on the same mount point as the AppImage")] + TempDirNotOnSameMountPoint, + /// The path StripPrefixError error. + #[error("Path Error: {0}")] + PathPrefix(#[from] std::path::StripPrefixError), + /// Ignore error. + #[error("failed to walkdir: {0}")] + Ignore(#[from] ignore::Error), + /// Zip error. + #[cfg(windows)] + #[error(transparent)] + ZipError(#[from] zip::result::ZipError), +} + +impl Serialize for Error { + fn serialize(&self, serializer: S) -> std::result::Result + where + S: Serializer, + { + serializer.serialize_str(self.to_string().as_ref()) + } +} diff --git a/plugins/updater/src/lib.rs b/plugins/updater/src/lib.rs new file mode 100644 index 00000000..3b511ca4 --- /dev/null +++ b/plugins/updater/src/lib.rs @@ -0,0 +1,101 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use tauri::{ + plugin::{Builder as PluginBuilder, TauriPlugin}, + Manager, Runtime, +}; + +use tokio::sync::Mutex; + +mod commands; +mod config; +mod error; +mod updater; + +pub use config::Config; +pub use error::Error; +pub use updater::*; +pub type Result = std::result::Result; + +struct UpdaterState { + target: Option, + config: Config, +} + +struct PendingUpdate(Mutex>>); + +#[derive(Default)] +pub struct Builder { + target: Option, + installer_args: Option>, +} + +/// Extension trait to use the updater on [`tauri::App`], [`tauri::AppHandle`] and [`tauri::Window`]. +pub trait UpdaterExt { + /// Gets the updater builder to manually check if an update is available. + /// + /// # Examples + /// + /// ```no_run + /// use tauri_plugin_updater::UpdaterExt; + /// tauri::Builder::default() + /// .setup(|app| { + /// let handle = app.handle(); + /// tauri::async_runtime::spawn(async move { + /// let response = handle.updater().check().await; + /// }); + /// Ok(()) + /// }); + /// ``` + fn updater(&self) -> updater::UpdateBuilder; +} + +impl> UpdaterExt for T { + fn updater(&self) -> updater::UpdateBuilder { + updater::builder(self.app_handle()) + } +} + +impl Builder { + pub fn new() -> Self { + Self::default() + } + + pub fn target(mut self, target: impl Into) -> Self { + self.target.replace(target.into()); + self + } + + pub fn installer_args(mut self, args: I) -> Self + where + I: IntoIterator, + S: Into, + { + self.installer_args + .replace(args.into_iter().map(Into::into).collect()); + self + } + + pub fn build(self) -> TauriPlugin { + let target = self.target; + let installer_args = self.installer_args; + PluginBuilder::::new("updater") + .js_init_script(include_str!("api-iife.js").to_string()) + .setup(move |app, api| { + let mut config = api.config().clone(); + if let Some(installer_args) = installer_args { + config.installer_args = installer_args; + } + app.manage(UpdaterState { target, config }); + app.manage(PendingUpdate::(Default::default())); + Ok(()) + }) + .invoke_handler(tauri::generate_handler![ + commands::check, + commands::download_and_install + ]) + .build() + } +} diff --git a/plugins/updater/src/updater/core.rs b/plugins/updater/src/updater/core.rs new file mode 100644 index 00000000..fd917497 --- /dev/null +++ b/plugins/updater/src/updater/core.rs @@ -0,0 +1,1678 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +#[cfg(desktop)] +use super::{ + extract::{ArchiveFormat, Extract}, + move_file::Move, +}; +use crate::{Error, Result}; +use base64::Engine; +use futures_util::StreamExt; +use http::{ + header::{HeaderName, HeaderValue}, + HeaderMap, Method, StatusCode, +}; +use minisign_verify::{PublicKey, Signature}; +use reqwest::ClientBuilder; +use semver::Version; +use serde::{de::Error as DeError, Deserialize, Deserializer, Serialize}; +use tauri::utils::{platform::current_exe, Env}; +use tauri::{AppHandle, Manager, Runtime}; +use time::OffsetDateTime; +use url::Url; + +#[cfg(desktop)] +use std::io::Seek; +use std::{ + collections::HashMap, + env, + fmt::{self}, + io::{Cursor, Read}, + path::{Path, PathBuf}, + str::{from_utf8, FromStr}, + time::Duration, +}; + +#[cfg(any(target_os = "linux", windows))] +use std::ffi::OsStr; + +#[cfg(all(desktop, not(target_os = "windows")))] +use super::extract::Compression; + +#[cfg(target_os = "windows")] +use std::{ + fs::read_dir, + process::{exit, Command}, +}; + +type ShouldInstall = dyn FnOnce(&Version, &RemoteRelease) -> bool + Send; + +#[derive(Debug, Deserialize, Serialize)] +#[serde(untagged)] +pub enum RemoteReleaseInner { + Dynamic(ReleaseManifestPlatform), + Static { + platforms: HashMap, + }, +} + +/// Information about a release returned by the remote update server. +/// +/// This type can have one of two shapes: Server Format (Dynamic Format) and Static Format. +#[derive(Debug)] +pub struct RemoteRelease { + /// Version to install. + version: Version, + /// Release notes. + notes: Option, + /// Release date. + pub_date: Option, + /// Release data. + data: RemoteReleaseInner, +} + +impl<'de> Deserialize<'de> for RemoteRelease { + fn deserialize(deserializer: D) -> std::result::Result + where + D: Deserializer<'de>, + { + #[derive(Deserialize)] + struct InnerRemoteRelease { + #[serde(alias = "name", deserialize_with = "parse_version")] + version: Version, + notes: Option, + pub_date: Option, + platforms: Option>, + // dynamic platform response + url: Option, + signature: Option, + #[cfg(target_os = "windows")] + #[serde(default)] + with_elevated_task: bool, + } + + let release = InnerRemoteRelease::deserialize(deserializer)?; + + let pub_date = if let Some(date) = release.pub_date { + Some( + OffsetDateTime::parse(&date, &time::format_description::well_known::Rfc3339) + .map_err(|e| DeError::custom(format!("invalid value for `pub_date`: {e}")))?, + ) + } else { + None + }; + + Ok(RemoteRelease { + version: release.version, + notes: release.notes, + pub_date, + data: if let Some(platforms) = release.platforms { + RemoteReleaseInner::Static { platforms } + } else { + RemoteReleaseInner::Dynamic(ReleaseManifestPlatform { + url: release.url.ok_or_else(|| { + DeError::custom("the `url` field was not set on the updater response") + })?, + signature: release.signature.ok_or_else(|| { + DeError::custom("the `signature` field was not set on the updater response") + })?, + #[cfg(target_os = "windows")] + with_elevated_task: release.with_elevated_task, + }) + }, + }) + } +} + +#[derive(Debug, Deserialize, Serialize)] +pub struct ReleaseManifestPlatform { + /// Download URL for the platform + pub url: Url, + /// Signature for the platform + pub signature: String, + #[cfg(target_os = "windows")] + #[serde(default)] + /// Optional: Windows only try to use elevated task + pub with_elevated_task: bool, +} + +fn parse_version<'de, D>(deserializer: D) -> std::result::Result +where + D: serde::Deserializer<'de>, +{ + let str = String::deserialize(deserializer)?; + + Version::from_str(str.trim_start_matches('v')).map_err(serde::de::Error::custom) +} + +impl RemoteRelease { + /// The release version. + pub fn version(&self) -> &Version { + &self.version + } + + /// The release notes. + pub fn notes(&self) -> Option<&String> { + self.notes.as_ref() + } + + /// The release date. + pub fn pub_date(&self) -> Option<&OffsetDateTime> { + self.pub_date.as_ref() + } + + /// The release's download URL for the given target. + pub fn download_url(&self, target: &str) -> Result<&Url> { + match self.data { + RemoteReleaseInner::Dynamic(ref platform) => Ok(&platform.url), + RemoteReleaseInner::Static { ref platforms } => platforms + .get(target) + .map_or(Err(Error::TargetNotFound(target.to_string())), |p| { + Ok(&p.url) + }), + } + } + + /// The release's signature for the given target. + pub fn signature(&self, target: &str) -> Result<&String> { + match self.data { + RemoteReleaseInner::Dynamic(ref platform) => Ok(&platform.signature), + RemoteReleaseInner::Static { ref platforms } => platforms + .get(target) + .map_or(Err(Error::TargetNotFound(target.to_string())), |platform| { + Ok(&platform.signature) + }), + } + } + + #[cfg(target_os = "windows")] + /// Optional: Windows only try to use elevated task + pub fn with_elevated_task(&self, target: &str) -> Result { + match self.data { + RemoteReleaseInner::Dynamic(ref platform) => Ok(platform.with_elevated_task), + RemoteReleaseInner::Static { ref platforms } => platforms + .get(target) + .map_or(Err(Error::TargetNotFound(target.to_string())), |platform| { + Ok(platform.with_elevated_task) + }), + } + } +} + +pub struct UpdateBuilder { + /// Application handle. + pub app: AppHandle, + /// Current version we are running to compare with announced version + pub current_version: Version, + /// The URLs to checks updates. We suggest at least one fallback on a different domain. + pub urls: Vec, + /// The platform the updater will check and install the update. Default is from `get_updater_target` + pub target: Option, + /// The current executable path. Default is automatically extracted. + pub executable_path: Option, + should_install: Option>, + timeout: Option, + headers: HeaderMap, +} + +impl fmt::Debug for UpdateBuilder { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + f.debug_struct("UpdateBuilder") + .field("app", &self.app) + .field("current_version", &self.current_version) + .field("urls", &self.urls) + .field("target", &self.target) + .field("executable_path", &self.executable_path) + .field("timeout", &self.timeout) + .field("headers", &self.headers) + .finish() + } +} + +// Create new updater instance and return an Update +impl UpdateBuilder { + pub fn new(app: AppHandle) -> Self { + UpdateBuilder { + app, + urls: Vec::new(), + target: None, + executable_path: None, + // safe to unwrap: CARGO_PKG_VERSION is also a valid semver value + current_version: env!("CARGO_PKG_VERSION").parse().unwrap(), + should_install: None, + timeout: None, + headers: Default::default(), + } + } + + #[allow(dead_code)] + pub fn url(mut self, url: String) -> Self { + self.urls.push( + percent_encoding::percent_decode(url.as_bytes()) + .decode_utf8_lossy() + .to_string(), + ); + self + } + + /// Add multiple URLS at once inside a Vec for future reference + pub fn urls(mut self, urls: &[String]) -> Self { + let mut formatted_vec: Vec = Vec::new(); + for url in urls { + formatted_vec.push( + percent_encoding::percent_decode(url.as_bytes()) + .decode_utf8_lossy() + .to_string(), + ); + } + self.urls = formatted_vec; + self + } + + /// Set the current app version, used to compare against the latest available version. + /// The `cargo_crate_version!` macro can be used to pull the version from your `Cargo.toml` + pub fn current_version(mut self, ver: Version) -> Self { + self.current_version = ver; + self + } + + /// Set the target name. Represents the string that is looked up on the updater API or response JSON. + pub fn target(mut self, target: impl Into) -> Self { + self.target.replace(target.into()); + self + } + + /// Set the executable path + #[allow(dead_code)] + pub fn executable_path>(mut self, executable_path: A) -> Self { + self.executable_path = Some(PathBuf::from(executable_path.as_ref())); + self + } + + pub fn should_install bool + Send + 'static>( + mut self, + f: F, + ) -> Self { + self.should_install.replace(Box::new(f)); + self + } + + pub fn timeout(mut self, timeout: Duration) -> Self { + self.timeout.replace(timeout); + self + } + + /// Add a `Header` to the request. + pub fn header(mut self, key: K, value: V) -> Result + where + HeaderName: TryFrom, + >::Error: Into, + HeaderValue: TryFrom, + >::Error: Into, + { + let key: std::result::Result = key.try_into().map_err(Into::into); + let value: std::result::Result = + value.try_into().map_err(Into::into); + self.headers.insert(key?, value?); + Ok(self) + } + + pub async fn build(mut self) -> Result> { + let mut remote_release: Option = None; + + // make sure we have at least one url + if self.urls.is_empty() { + return Err(Error::Builder( + "Unable to check update, `url` is required.".into(), + )); + }; + + // If no executable path provided, we use current_exe from tauri_utils + let executable_path = self.executable_path.unwrap_or(current_exe()?); + + let arch = get_updater_arch().ok_or(Error::UnsupportedArch)?; + // `target` is the `{{target}}` variable we replace in the endpoint + // `json_target` is the value we search if the updater server returns a JSON with the `platforms` object + let (target, json_target) = if let Some(target) = self.target { + (target.clone(), target) + } else { + let target = get_updater_target().ok_or(Error::UnsupportedOs)?; + (target.to_string(), format!("{target}-{arch}")) + }; + + // Get the extract_path from the provided executable_path + let extract_path = extract_path_from_executable(&self.app.state::(), &executable_path); + + // Set SSL certs for linux if they aren't available. + // We do not require to recheck in the download_and_install as we use + // ENV variables, we can expect them to be set for the second call. + #[cfg(target_os = "linux")] + { + if env::var_os("SSL_CERT_FILE").is_none() { + env::set_var("SSL_CERT_FILE", "/etc/ssl/certs/ca-certificates.crt"); + } + if env::var_os("SSL_CERT_DIR").is_none() { + env::set_var("SSL_CERT_DIR", "/etc/ssl/certs"); + } + } + + // we want JSON only + let mut headers = self.headers; + headers.insert("Accept", HeaderValue::from_str("application/json").unwrap()); + + // Allow fallback if more than 1 urls is provided + let mut last_error: Option = None; + for url in &self.urls { + // replace {{current_version}}, {{target}} and {{arch}} in the provided URL + // this is useful if we need to query example + // https://releases.myapp.com/update/{{target}}/{{arch}}/{{current_version}} + // will be translated into -> + // https://releases.myapp.com/update/darwin/aarch64/1.0.0 + // The main objective is if the update URL is defined via the Cargo.toml + // the URL will be generated dynamically + let fixed_link = url + .replace("{{current_version}}", &self.current_version.to_string()) + .replace("{{target}}", &target) + .replace("{{arch}}", arch); + + let client = ClientBuilder::new().build()?; + let mut request = client + .request(Method::GET, &fixed_link) + .headers(headers.clone()); + if let Some(timeout) = self.timeout { + request = request.timeout(timeout); + } + + // If we got a success, we stop the loop + // and we set our remote_release variable + if let Ok(res) = request.send().await { + let status = res.status(); + // got status code 2XX + if status.is_success() { + // if we got 204 + if status == StatusCode::NO_CONTENT { + // return with `UpToDate` error + // we should catch on the client + return Err(Error::UpToDate); + }; + let data = res.bytes().await?; + // Convert the remote Result<()>to our local struct + let built_release = serde_json::from_slice(&data).map_err(Into::into); + // make sure all went well and the remote data is compatible + // with what we need locally + match built_release { + Ok(release) => { + last_error = None; + remote_release = Some(release); + break; + } + Err(err) => last_error = Some(err), + } + } // if status code is not 2XX we keep loopin' our urls + } + } + + // Last error is cleaned on success -- shouldn't be triggered if + // we have a successful call + if let Some(error) = last_error { + return Err(error); + } + + // Extracted remote metadata + let final_release = remote_release.ok_or(Error::ReleaseNotFound)?; + + // is the announced version greater than our current one? + let should_update = if let Some(comparator) = self.should_install.take() { + comparator(&self.current_version, &final_release) + } else { + final_release.version() > &self.current_version + }; + + headers.remove("Accept"); + + // create our new updater + Ok(Update { + app: self.app, + target, + extract_path, + should_update, + version: final_release.version().to_string(), + date: final_release.pub_date().cloned(), + current_version: self.current_version, + download_url: final_release.download_url(&json_target)?.to_owned(), + body: final_release.notes().cloned(), + signature: final_release.signature(&json_target)?.to_owned(), + #[cfg(target_os = "windows")] + with_elevated_task: final_release.with_elevated_task(&json_target)?, + timeout: self.timeout, + headers, + }) + } +} + +pub fn builder(app: AppHandle) -> UpdateBuilder { + UpdateBuilder::new(app) +} + +#[derive(Debug)] +pub struct Update { + /// Application handle. + pub app: AppHandle, + /// Update description + pub body: Option, + /// Should we update or not + pub should_update: bool, + /// Version announced + pub version: String, + /// Running version + pub current_version: Version, + /// Update publish date + pub date: Option, + /// Target + #[allow(dead_code)] + target: String, + /// Extract path + extract_path: PathBuf, + /// Download URL announced + download_url: Url, + /// Signature announced + signature: String, + #[cfg(target_os = "windows")] + /// Optional: Windows only try to use elevated task + /// Default to false + with_elevated_task: bool, + /// Request timeout + timeout: Option, + /// Request headers + headers: HeaderMap, +} + +impl Clone for Update { + fn clone(&self) -> Self { + Self { + app: self.app.clone(), + body: self.body.clone(), + should_update: self.should_update, + version: self.version.clone(), + current_version: self.current_version.clone(), + date: self.date, + target: self.target.clone(), + extract_path: self.extract_path.clone(), + download_url: self.download_url.clone(), + signature: self.signature.clone(), + #[cfg(target_os = "windows")] + with_elevated_task: self.with_elevated_task, + timeout: self.timeout, + headers: self.headers.clone(), + } + } +} + +#[derive(Debug, Serialize)] +#[serde(tag = "event", content = "data")] +pub enum DownloadEvent { + #[serde(rename_all = "camelCase")] + Started { + content_length: Option, + }, + #[serde(rename_all = "camelCase")] + Progress { + chunk_length: usize, + }, + Finished, +} + +impl Update { + // Download and install our update + // @todo(lemarier): Split into download and install (two step) but need to be thread safe + pub(crate) async fn download_and_install( + &self, + pub_key: String, + on_event: F, + ) -> Result<()> { + // make sure we can install the update on linux + // We fail here because later we can add more linux support + // actually if we use APPIMAGE, our extract path should already + // be set with our APPIMAGE env variable, we don't need to do + // anything with it yet + #[cfg(target_os = "linux")] + if self.app.state::().appimage.is_none() { + return Err(Error::UnsupportedLinuxPackage); + } + + // set our headers + let mut headers = self.headers.clone(); + headers.insert( + "Accept", + HeaderValue::from_str("application/octet-stream").unwrap(), + ); + headers.insert( + "User-Agent", + HeaderValue::from_str("tauri/updater").unwrap(), + ); + + let client = ClientBuilder::new().build()?; + // Create our request + let mut req = client + .request(Method::GET, self.download_url.clone()) + .headers(headers); + if let Some(timeout) = self.timeout { + req = req.timeout(timeout); + } + + let response = req.send().await?; + + // make sure it's success + if !response.status().is_success() { + return Err(Error::DownloadFailed(response.status())); + } + + let content_length: Option = response + .headers() + .get("Content-Length") + .and_then(|value| value.to_str().ok()) + .and_then(|value| value.parse().ok()); + + on_event(DownloadEvent::Started { content_length }); + + let mut buffer = Vec::new(); + + let mut stream = response.bytes_stream(); + while let Some(chunk) = stream.next().await { + let chunk = chunk?; + let bytes = chunk.as_ref().to_vec(); + on_event(DownloadEvent::Progress { + chunk_length: bytes.len(), + }); + buffer.extend(bytes); + } + + on_event(DownloadEvent::Finished); + + // create memory buffer from our archive (Seek + Read) + let mut archive_buffer = Cursor::new(buffer); + + // We need an announced signature by the server + // if there is no signature, bail out. + verify_signature(&mut archive_buffer, &self.signature, &pub_key)?; + + // TODO: implement updater in mobile + #[cfg(desktop)] + { + // we copy the files depending of the operating system + // we run the setup, appimage re-install or overwrite the + // macos .app + #[cfg(target_os = "windows")] + copy_files_and_run( + archive_buffer, + &self.extract_path, + self.with_elevated_task, + &self.app.config(), + &self.app.state::().config, + )?; + #[cfg(not(target_os = "windows"))] + copy_files_and_run(archive_buffer, &self.extract_path)?; + } + + // We are done! + Ok(()) + } +} + +// Linux (AppImage) + +// ### Expected structure: +// ├── [AppName]_[version]_amd64.AppImage.tar.gz # GZ generated by tauri-bundler +// │ └──[AppName]_[version]_amd64.AppImage # Application AppImage +// └── ... + +// We should have an AppImage already installed to be able to copy and install +// the extract_path is the current AppImage path +// tmp_dir is where our new AppImage is found +#[cfg(target_os = "linux")] +fn copy_files_and_run(archive_buffer: R, extract_path: &Path) -> Result<()> { + use std::os::unix::fs::{MetadataExt, PermissionsExt}; + + let extract_path_metadata = extract_path.metadata()?; + + let tmp_dir_locations = vec![ + Box::new(|| Some(env::temp_dir())) as Box Option>, + Box::new(dirs_next::cache_dir), + Box::new(|| Some(extract_path.parent().unwrap().to_path_buf())), + ]; + + for tmp_dir_location in tmp_dir_locations { + if let Some(tmp_dir_location) = tmp_dir_location() { + let tmp_dir = tempfile::Builder::new() + .prefix("tauri_current_app") + .tempdir_in(tmp_dir_location)?; + let tmp_dir_metadata = tmp_dir.path().metadata()?; + + if extract_path_metadata.dev() == tmp_dir_metadata.dev() { + let mut perms = tmp_dir_metadata.permissions(); + perms.set_mode(0o700); + std::fs::set_permissions(tmp_dir.path(), perms)?; + + let tmp_app_image = &tmp_dir.path().join("current_app.AppImage"); + + // create a backup of our current app image + Move::from_source(extract_path).to_dest(tmp_app_image)?; + + // extract the buffer to the tmp_dir + // we extract our signed archive into our final directory without any temp file + let mut extractor = + Extract::from_cursor(archive_buffer, ArchiveFormat::Tar(Some(Compression::Gz))); + + return extractor + .with_files(|entry| { + let path = entry.path()?; + if path.extension() == Some(OsStr::new("AppImage")) { + // if something went wrong during the extraction, we should restore previous app + if let Err(err) = entry.extract(extract_path) { + Move::from_source(tmp_app_image).to_dest(extract_path)?; + return Err(err); + } + // early finish we have everything we need here + return Ok(true); + } + Ok(false) + }) + .map_err(Into::into); + } + } + } + + Err(Error::TempDirNotOnSameMountPoint) +} + +// Windows +// +// ### Expected structure: +// ├── [AppName]_[version]_x64.msi.zip # ZIP generated by tauri-bundler +// │ └──[AppName]_[version]_x64.msi # Application MSI +// ├── [AppName]_[version]_x64-setup.exe.zip # ZIP generated by tauri-bundler +// │ └──[AppName]_[version]_x64-setup.exe # NSIS installer +// └── ... +// +// ## MSI +// Update server can provide a MSI for Windows. (Generated with tauri-bundler from *Wix*) +// To replace current version of the application. In later version we'll offer +// incremental update to push specific binaries. +// +// ## EXE +// Update server can provide a custom EXE (installer) who can run any task. +#[cfg(target_os = "windows")] +#[allow(clippy::unnecessary_wraps)] +fn copy_files_and_run( + archive_buffer: R, + _extract_path: &Path, + with_elevated_task: bool, + config: &tauri::Config, + updater_config: &crate::Config, +) -> Result<()> { + // FIXME: We need to create a memory buffer with the MSI and then run it. + // (instead of extracting the MSI to a temp path) + // + // The tricky part is the MSI need to be exposed and spawned so the memory allocation + // shouldn't drop but we should be able to pass the reference so we can drop it once the installation + // is done, otherwise we have a huge memory leak. + + let tmp_dir = tempfile::Builder::new().tempdir()?.into_path(); + + // extract the buffer to the tmp_dir + // we extract our signed archive into our final directory without any temp file + let mut extractor = Extract::from_cursor(archive_buffer, ArchiveFormat::Zip); + + // extract the msi + extractor.extract_into(&tmp_dir)?; + + let paths = read_dir(&tmp_dir)?; + + for path in paths { + let found_path = path?.path(); + // we support 2 type of files exe & msi for now + // If it's an `exe` we expect an installer not a runtime. + if found_path.extension() == Some(OsStr::new("exe")) { + // Run the EXE + let mut installer = Command::new(found_path); + if tauri::utils::config::WindowsUpdateInstallMode::Quiet + == config.tauri.bundle.updater.windows.install_mode + { + installer.arg("/S"); + } + installer.args(&updater_config.installer_args); + + installer.spawn().expect("installer failed to start"); + + exit(0); + } else if found_path.extension() == Some(OsStr::new("msi")) { + if with_elevated_task { + if let Some(bin_name) = current_exe() + .ok() + .and_then(|pb| pb.file_name().map(|s| s.to_os_string())) + .and_then(|s| s.into_string().ok()) + { + let product_name = bin_name.replace(".exe", ""); + + // Check if there is a task that enables the updater to skip the UAC prompt + let update_task_name = format!("Update {product_name} - Skip UAC"); + if let Ok(output) = Command::new("schtasks") + .arg("/QUERY") + .arg("/TN") + .arg(update_task_name.clone()) + .output() + { + if output.status.success() { + // Rename the MSI to the match file name the Skip UAC task is expecting it to be + let temp_msi = tmp_dir.with_file_name(bin_name).with_extension("msi"); + Move::from_source(&found_path) + .to_dest(&temp_msi) + .expect("Unable to move update MSI"); + let exit_status = Command::new("schtasks") + .arg("/RUN") + .arg("/TN") + .arg(update_task_name) + .status() + .expect("failed to start updater task"); + + if exit_status.success() { + // Successfully launched task that skips the UAC prompt + exit(0); + } + } + // Failed to run update task. Following UAC Path + } + } + } + + // we need to wrap the current exe path in quotes for Start-Process + let mut current_exe_arg = std::ffi::OsString::new(); + current_exe_arg.push("\""); + current_exe_arg.push(current_exe()?); + current_exe_arg.push("\""); + + let mut msi_path_arg = std::ffi::OsString::new(); + msi_path_arg.push("\"\"\""); + msi_path_arg.push(&found_path); + msi_path_arg.push("\"\"\""); + + let mut msiexec_args = config + .tauri + .bundle + .updater + .windows + .install_mode + .clone() + .msiexec_args() + .iter() + .map(|p| p.to_string()) + .collect::>(); + msiexec_args.extend(updater_config.installer_args.clone()); + + // run the installer and relaunch the application + let system_root = std::env::var("SYSTEMROOT"); + let powershell_path = system_root.as_ref().map_or_else( + |_| "powershell.exe".to_string(), + |p| format!("{p}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe"), + ); + let powershell_install_res = Command::new(powershell_path) + .args(["-NoProfile", "-windowstyle", "hidden"]) + .args([ + "Start-Process", + "-Wait", + "-FilePath", + "$env:SYSTEMROOT\\System32\\msiexec.exe", + "-ArgumentList", + ]) + .arg("/i,") + .arg(msi_path_arg) + .arg(format!(", {}, /promptrestart;", msiexec_args.join(", "))) + .arg("Start-Process") + .arg(current_exe_arg) + .spawn(); + if powershell_install_res.is_err() { + // fallback to running msiexec directly - relaunch won't be available + // we use this here in case powershell fails in an older machine somehow + let msiexec_path = system_root.as_ref().map_or_else( + |_| "msiexec.exe".to_string(), + |p| format!("{p}\\System32\\msiexec.exe"), + ); + let _ = Command::new(msiexec_path) + .arg("/i") + .arg(found_path) + .args(msiexec_args) + .arg("/promptrestart") + .spawn(); + } + + exit(0); + } + } + + Ok(()) +} + +// MacOS +// ### Expected structure: +// ├── [AppName]_[version]_x64.app.tar.gz # GZ generated by tauri-bundler +// │ └──[AppName].app # Main application +// │ └── Contents # Application contents... +// │ └── ... +// └── ... +#[cfg(target_os = "macos")] +fn copy_files_and_run(archive_buffer: R, extract_path: &Path) -> Result<()> { + let mut extracted_files: Vec = Vec::new(); + + // extract the buffer to the tmp_dir + // we extract our signed archive into our final directory without any temp file + let mut extractor = + Extract::from_cursor(archive_buffer, ArchiveFormat::Tar(Some(Compression::Gz))); + // the first file in the tar.gz will always be + // /Contents + let tmp_dir = tempfile::Builder::new() + .prefix("tauri_current_app") + .tempdir()?; + + // create backup of our current app + Move::from_source(extract_path).to_dest(tmp_dir.path())?; + + // extract all the files + extractor.with_files(|entry| { + let path = entry.path()?; + // skip the first folder (should be the app name) + let collected_path: PathBuf = path.iter().skip(1).collect(); + let extraction_path = extract_path.join(collected_path); + + // if something went wrong during the extraction, we should restore previous app + if let Err(err) = entry.extract(&extraction_path) { + for file in &extracted_files { + // delete all the files we extracted + if file.is_dir() { + std::fs::remove_dir(file)?; + } else { + std::fs::remove_file(file)?; + } + } + Move::from_source(tmp_dir.path()).to_dest(extract_path)?; + return Err(err); + } + + extracted_files.push(extraction_path); + + Ok(false) + })?; + + let _ = std::process::Command::new("touch") + .arg(extract_path) + .status(); + + Ok(()) +} + +pub(crate) fn get_updater_target() -> Option<&'static str> { + if cfg!(target_os = "linux") { + Some("linux") + } else if cfg!(target_os = "macos") { + Some("darwin") + } else if cfg!(target_os = "windows") { + Some("windows") + } else { + None + } +} + +pub(crate) fn get_updater_arch() -> Option<&'static str> { + if cfg!(target_arch = "x86") { + Some("i686") + } else if cfg!(target_arch = "x86_64") { + Some("x86_64") + } else if cfg!(target_arch = "arm") { + Some("armv7") + } else if cfg!(target_arch = "aarch64") { + Some("aarch64") + } else { + None + } +} + +/// Get the extract_path from the provided executable_path +#[allow(unused_variables)] +pub fn extract_path_from_executable(env: &Env, executable_path: &Path) -> PathBuf { + // Return the path of the current executable by default + // Example C:\Program Files\My App\ + let extract_path = executable_path + .parent() + .map(PathBuf::from) + .expect("Can't determine extract path"); + + // MacOS example binary is in /Applications/TestApp.app/Contents/MacOS/myApp + // We need to get /Applications/.app + // todo(lemarier): Need a better way here + // Maybe we could search for <*.app> to get the right path + #[cfg(target_os = "macos")] + if extract_path + .display() + .to_string() + .contains("Contents/MacOS") + { + return extract_path + .parent() + .map(PathBuf::from) + .expect("Unable to find the extract path") + .parent() + .map(PathBuf::from) + .expect("Unable to find the extract path"); + } + + // We should use APPIMAGE exposed env variable + // This is where our APPIMAGE should sit and should be replaced + #[cfg(target_os = "linux")] + if let Some(app_image_path) = &env.appimage { + return PathBuf::from(app_image_path); + } + + extract_path +} + +// Convert base64 to string and prevent failing +fn base64_to_string(base64_string: &str) -> Result { + let decoded_string = &base64::engine::general_purpose::STANDARD.decode(base64_string)?; + let result = from_utf8(decoded_string) + .map_err(|_| Error::SignatureUtf8(base64_string.into()))? + .to_string(); + Ok(result) +} + +// Validate signature +// need to be public because its been used +// by our tests in the bundler +// +// NOTE: The buffer position is not reset. +pub fn verify_signature( + archive_reader: &mut R, + release_signature: &str, + pub_key: &str, +) -> Result +where + R: Read, +{ + // we need to convert the pub key + let pub_key_decoded = base64_to_string(pub_key)?; + let public_key = PublicKey::decode(&pub_key_decoded)?; + let signature_base64_decoded = base64_to_string(release_signature)?; + let signature = Signature::decode(&signature_base64_decoded)?; + + // read all bytes until EOF in the buffer + let mut data = Vec::new(); + archive_reader.read_to_end(&mut data)?; + + // Validate signature or bail out + public_key.verify(&data, &signature, true)?; + Ok(true) +} + +/*#[cfg(test)] +mod test { + use super::*; + #[cfg(target_os = "macos")] + use std::fs::File; + + macro_rules! block { + ($e:expr) => { + tokio_test::block_on($e) + }; + } + + fn generate_sample_raw_json() -> String { + r#"{ + "version": "v2.0.0", + "notes": "Test version !", + "pub_date": "2020-06-22T19:25:57Z", + "platforms": { + "darwin-aarch64": { + "signature": "dW50cnVzdGVkIGNvbW1lbnQ6IHNpZ25hdHVyZSBmcm9tIHRhdXJpIHNlY3JldCBrZXkKUldUTE5QWWxkQnlZOVJZVGdpKzJmRWZ0SkRvWS9TdFpqTU9xcm1mUmJSSG5OWVlwSklrWkN1SFpWbmh4SDlBcTU3SXpjbm0xMmRjRkphbkpVeGhGcTdrdzlrWGpGVWZQSWdzPQp0cnVzdGVkIGNvbW1lbnQ6IHRpbWVzdGFtcDoxNTkyOTE1MDU3CWZpbGU6L1VzZXJzL3J1bm5lci9ydW5uZXJzLzIuMjYzLjAvd29yay90YXVyaS90YXVyaS90YXVyaS9leGFtcGxlcy9jb21tdW5pY2F0aW9uL3NyYy10YXVyaS90YXJnZXQvZGVidWcvYnVuZGxlL29zeC9hcHAuYXBwLnRhci5negp4ZHFlUkJTVnpGUXdDdEhydTE5TGgvRlVPeVhjTnM5RHdmaGx3c0ZPWjZXWnFwVDRNWEFSbUJTZ1ZkU1IwckJGdmlwSzJPd00zZEZFN2hJOFUvL1FDZz09Cg==", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v1.0.0/app.app.tar.gz" + }, + "darwin-x86_64": { + "signature": "dW50cnVzdGVkIGNvbW1lbnQ6IHNpZ25hdHVyZSBmcm9tIHRhdXJpIHNlY3JldCBrZXkKUldUTE5QWWxkQnlZOVJZVGdpKzJmRWZ0SkRvWS9TdFpqTU9xcm1mUmJSSG5OWVlwSklrWkN1SFpWbmh4SDlBcTU3SXpjbm0xMmRjRkphbkpVeGhGcTdrdzlrWGpGVWZQSWdzPQp0cnVzdGVkIGNvbW1lbnQ6IHRpbWVzdGFtcDoxNTkyOTE1MDU3CWZpbGU6L1VzZXJzL3J1bm5lci9ydW5uZXJzLzIuMjYzLjAvd29yay90YXVyaS90YXVyaS90YXVyaS9leGFtcGxlcy9jb21tdW5pY2F0aW9uL3NyYy10YXVyaS90YXJnZXQvZGVidWcvYnVuZGxlL29zeC9hcHAuYXBwLnRhci5negp4ZHFlUkJTVnpGUXdDdEhydTE5TGgvRlVPeVhjTnM5RHdmaGx3c0ZPWjZXWnFwVDRNWEFSbUJTZ1ZkU1IwckJGdmlwSzJPd00zZEZFN2hJOFUvL1FDZz09Cg==", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v1.0.0/app.app.tar.gz" + }, + "linux-x86_64": { + "signature": "dW50cnVzdGVkIGNvbW1lbnQ6IHNpZ25hdHVyZSBmcm9tIHRhdXJpIHNlY3JldCBrZXkKUldUTE5QWWxkQnlZOWZSM29hTFNmUEdXMHRoOC81WDFFVVFRaXdWOUdXUUdwT0NlMldqdXkyaWVieXpoUmdZeXBJaXRqSm1YVmczNXdRL1Brc0tHb1NOTzhrL1hadFcxdmdnPQp0cnVzdGVkIGNvbW1lbnQ6IHRpbWVzdGFtcDoxNTkyOTE3MzQzCWZpbGU6L2hvbWUvcnVubmVyL3dvcmsvdGF1cmkvdGF1cmkvdGF1cmkvZXhhbXBsZXMvY29tbXVuaWNhdGlvbi9zcmMtdGF1cmkvdGFyZ2V0L2RlYnVnL2J1bmRsZS9hcHBpbWFnZS9hcHAuQXBwSW1hZ2UudGFyLmd6CmRUTUM2bWxnbEtTbUhOZGtERUtaZnpUMG5qbVo5TGhtZWE1SFNWMk5OOENaVEZHcnAvVW0zc1A2ajJEbWZUbU0yalRHT0FYYjJNVTVHOHdTQlYwQkF3PT0K", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v1.0.0/app.AppImage.tar.gz" + }, + "windows-x86_64": { + "signature": "dW50cnVzdGVkIGNvbW1lbnQ6IHNpZ25hdHVyZSBmcm9tIHRhdXJpIHNlY3JldCBrZXkKUldUTE5QWWxkQnlZOVJHMWlvTzRUSlQzTHJOMm5waWpic0p0VVI2R0hUNGxhQVMxdzBPRndlbGpXQXJJakpTN0toRURtVzBkcm15R0VaNTJuS1lZRWdzMzZsWlNKUVAzZGdJPQp0cnVzdGVkIGNvbW1lbnQ6IHRpbWVzdGFtcDoxNTkyOTE1NTIzCWZpbGU6RDpcYVx0YXVyaVx0YXVyaVx0YXVyaVxleGFtcGxlc1xjb21tdW5pY2F0aW9uXHNyYy10YXVyaVx0YXJnZXRcZGVidWdcYXBwLng2NC5tc2kuemlwCitXa1lQc3A2MCs1KzEwZnVhOGxyZ2dGMlZqbjBaVUplWEltYUdyZ255eUF6eVF1dldWZzFObStaVEQ3QU1RS1lzcjhDVU4wWFovQ1p1QjJXbW1YZUJ3PT0K", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v1.0.0/app.x64.msi.zip" + } + } + }"#.into() + } + + fn generate_sample_platform_json( + version: &str, + public_signature: &str, + download_url: &str, + ) -> String { + format!( + r#" + {{ + "name": "v{version}", + "notes": "This is the latest version! Once updated you shouldn't see this prompt.", + "pub_date": "2020-06-25T14:14:19Z", + "signature": "{public_signature}", + "url": "{download_url}" + }} + "# + ) + } + + fn generate_sample_with_elevated_task_platform_json( + version: &str, + public_signature: &str, + download_url: &str, + with_elevated_task: bool, + ) -> String { + format!( + r#" + {{ + "name": "v{version}", + "notes": "This is the latest version! Once updated you shouldn't see this prompt.", + "pub_date": "2020-06-25T14:14:19Z", + "signature": "{public_signature}", + "url": "{download_url}", + "with_elevated_task": {with_elevated_task} + }} + "# + ) + } + + #[test] + fn simple_http_updater() { + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_raw_json()) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("0.0.0".parse().unwrap()) + .url(mockito::server_url()) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(updater.should_update); + } + + #[test] + fn simple_http_updater_raw_json() { + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_raw_json()) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("0.0.0".parse().unwrap()) + .url(mockito::server_url()) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(updater.should_update); + } + + #[test] + fn simple_http_updater_raw_json_windows_x86_64() { + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_raw_json()) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("0.0.0".parse().unwrap()) + .target("windows-x86_64") + .url(mockito::server_url()) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(updater.should_update); + assert_eq!(updater.version, "2.0.0"); + assert_eq!(updater.signature, "dW50cnVzdGVkIGNvbW1lbnQ6IHNpZ25hdHVyZSBmcm9tIHRhdXJpIHNlY3JldCBrZXkKUldUTE5QWWxkQnlZOVJHMWlvTzRUSlQzTHJOMm5waWpic0p0VVI2R0hUNGxhQVMxdzBPRndlbGpXQXJJakpTN0toRURtVzBkcm15R0VaNTJuS1lZRWdzMzZsWlNKUVAzZGdJPQp0cnVzdGVkIGNvbW1lbnQ6IHRpbWVzdGFtcDoxNTkyOTE1NTIzCWZpbGU6RDpcYVx0YXVyaVx0YXVyaVx0YXVyaVxleGFtcGxlc1xjb21tdW5pY2F0aW9uXHNyYy10YXVyaVx0YXJnZXRcZGVidWdcYXBwLng2NC5tc2kuemlwCitXa1lQc3A2MCs1KzEwZnVhOGxyZ2dGMlZqbjBaVUplWEltYUdyZ255eUF6eVF1dldWZzFObStaVEQ3QU1RS1lzcjhDVU4wWFovQ1p1QjJXbW1YZUJ3PT0K"); + assert_eq!( + updater.download_url.to_string(), + "https://github.com/tauri-apps/updater-test/releases/download/v1.0.0/app.x64.msi.zip" + ); + } + + #[test] + fn simple_http_updater_raw_json_uptodate() { + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_raw_json()) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("10.0.0".parse().unwrap()) + .url(mockito::server_url()) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(!updater.should_update); + } + + #[test] + fn simple_http_updater_without_version() { + let _m = mockito::mock("GET", "/darwin-aarch64/1.0.0") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_platform_json( + "2.0.0", + "SampleTauriKey", + "https://tauri.app", + )) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("1.0.0".parse().unwrap()) + .url(format!( + "{}/darwin-aarch64/{{{{current_version}}}}", + mockito::server_url() + )) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(updater.should_update); + } + + #[test] + fn simple_http_updater_percent_decode() { + let _m = mockito::mock("GET", "/darwin-aarch64/1.0.0") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_platform_json( + "2.0.0", + "SampleTauriKey", + "https://tauri.app", + )) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("1.0.0".parse().unwrap()) + .url( + url::Url::parse(&format!( + "{}/darwin-aarch64/{{{{current_version}}}}", + mockito::server_url() + )) + .unwrap() + .to_string() + ) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(updater.should_update); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("1.0.0".parse().unwrap()) + .urls(&[url::Url::parse(&format!( + "{}/darwin-aarch64/{{{{current_version}}}}", + mockito::server_url() + )) + .unwrap() + .to_string()]) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(updater.should_update); + } + + #[test] + fn simple_http_updater_with_elevated_task() { + let _m = mockito::mock("GET", "/windows-x86_64/1.0.0") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_with_elevated_task_platform_json( + "2.0.0", + "SampleTauriKey", + "https://tauri.app", + true, + )) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("1.0.0".parse().unwrap()) + .url(format!( + "{}/windows-x86_64/{{{{current_version}}}}", + mockito::server_url() + )) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(updater.should_update); + } + + #[test] + fn http_updater_uptodate() { + let _m = mockito::mock("GET", "/darwin-aarch64/10.0.0") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_platform_json( + "2.0.0", + "SampleTauriKey", + "https://tauri.app", + )) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .current_version("10.0.0".parse().unwrap()) + .url(format!( + "{}/darwin-aarch64/{{{{current_version}}}}", + mockito::server_url() + )) + .build()); + + let updater = check_update.expect("Can't check update"); + + assert!(!updater.should_update); + } + + #[test] + fn http_updater_fallback_urls() { + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_raw_json()) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .url("http://badurl.www.tld/1".into()) + .url(mockito::server_url()) + .current_version("0.0.1".parse().unwrap()) + .build()); + + let updater = check_update.expect("Can't check remote update"); + + assert!(updater.should_update); + } + + #[test] + fn http_updater_fallback_urls_with_array() { + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_raw_json()) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .urls(&["http://badurl.www.tld/1".into(), mockito::server_url(),]) + .current_version("0.0.1".parse().unwrap()) + .build()); + + let updater = check_update.expect("Can't check remote update"); + + assert!(updater.should_update); + } + + #[test] + fn http_updater_invalid_remote_data() { + let invalid_signature = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", + "signature": true + }"#; + let invalid_version = r#"{ + "version": 5, + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", + "signature": "x" + }"#; + let invalid_name = r#"{ + "name": false, + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", + "signature": "x" + }"#; + let invalid_date = r#"{ + "version": "1.0.0", + "notes": "Blablaa", + "pub_date": 345645646, + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", + "signature": "x" + }"#; + let invalid_notes = r#"{ + "version": "v0.0.3", + "notes": ["bla", "bla"], + "pub_date": "2020-02-20T15:41:00Z", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", + "signature": "x" + }"#; + let invalid_url = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "url": ["https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz"], + "signature": "x" + }"#; + let invalid_platform_signature = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "platforms": { + "test-target": { + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", + "signature": { + "test-target": "x" + } + } + } + }"#; + let invalid_platform_url = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "platforms": { + "test-target": { + "url": { + "first": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz" + } + "signature": "x" + } + } + }"#; + + let test_cases = [ + ( + invalid_signature, + Box::new(|e| matches!(e, Error::InvalidResponseType("signature", "string", _))) + as Box bool>, + ), + ( + invalid_version, + Box::new(|e| matches!(e, Error::InvalidResponseType("version", "string", _))) + as Box bool>, + ), + ( + invalid_name, + Box::new(|e| matches!(e, Error::InvalidResponseType("name", "string", _))) + as Box bool>, + ), + ( + invalid_date, + Box::new(|e| matches!(e, Error::InvalidResponseType("pub_date", "string", _))) + as Box bool>, + ), + ( + invalid_notes, + Box::new(|e| matches!(e, Error::InvalidResponseType("notes", "string", _))) + as Box bool>, + ), + ( + invalid_url, + Box::new(|e| matches!(e, Error::InvalidResponseType("url", "string", _))) + as Box bool>, + ), + ( + invalid_platform_signature, + Box::new(|e| matches!(e, Error::InvalidResponseType("signature", "string", _))) + as Box bool>, + ), + ( + invalid_platform_url, + Box::new(|e| matches!(e, Error::InvalidResponseType("url", "string", _))) + as Box bool>, + ), + ]; + + for (response, validator) in test_cases { + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(response) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .url(mockito::server_url()) + .current_version("0.0.1".parse().unwrap()) + .target("test-target") + .build()); + if let Err(e) = check_update { + validator(e); + } else { + panic!("unexpected Ok response"); + } + } + } + + #[test] + fn http_updater_missing_remote_data() { + let missing_signature = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz" + }"#; + let missing_version = r#"{ + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", + "signature": "x" + }"#; + let missing_url = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "signature": "x" + }"#; + let missing_target = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "platforms": { + "unknown-target": { + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz", + "signature": "x" + } + } + }"#; + let missing_platform_signature = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "platforms": { + "test-target": { + "url": "https://github.com/tauri-apps/updater-test/releases/download/v0.0.1/update3.tar.gz" + } + } + }"#; + let missing_platform_url = r#"{ + "version": "v0.0.3", + "notes": "Blablaa", + "pub_date": "2020-02-20T15:41:00Z", + "platforms": { + "test-target": { + "signature": "x" + } + } + }"#; + + fn missing_field_error(field: &str) -> String { + format!("the `{field}` field was not set on the updater response") + } + + let test_cases = [ + (missing_signature, missing_field_error("signature")), + (missing_version, "missing field `version`".to_string()), + (missing_url, missing_field_error("url")), + ( + missing_target, + Error::TargetNotFound("test-target".into()).to_string(), + ), + ( + missing_platform_signature, + "missing field `signature`".to_string(), + ), + (missing_platform_url, "missing field `url`".to_string()), + ]; + + for (response, error) in test_cases { + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(response) + .create(); + + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .url(mockito::server_url()) + .current_version("0.0.1".parse().unwrap()) + .target("test-target") + .build()); + if let Err(e) = check_update { + println!("ERROR: {e}, expected: {error}"); + assert!(e.to_string().contains(&error)); + } else { + panic!("unexpected Ok response"); + } + } + } + + // run complete process on mac only for now as we don't have + // server (api) that we can use to test + #[test] + #[cfg(target_os = "macos")] + fn http_updater_complete_process() { + #[cfg(target_os = "macos")] + let archive_file = "archive.macos.tar.gz"; + #[cfg(target_os = "linux")] + let archive_file = "archive.linux.tar.gz"; + #[cfg(target_os = "windows")] + let archive_file = "archive.windows.zip"; + + let good_archive_url = format!("{}/{archive_file}", mockito::server_url()); + + let mut signature_file = File::open(format!( + "./test/updater/fixture/archives/{archive_file}.sig" + )) + .expect("Unable to open signature"); + let mut signature = String::new(); + signature_file + .read_to_string(&mut signature) + .expect("Unable to read signature as string"); + + let mut pubkey_file = File::open("./test/updater/fixture/good_signature/update.key.pub") + .expect("Unable to open pubkey"); + let mut pubkey = String::new(); + pubkey_file + .read_to_string(&mut pubkey) + .expect("Unable to read signature as string"); + + // add sample file + let _m = mockito::mock("GET", format!("/{archive_file}").as_str()) + .with_status(200) + .with_header("content-type", "application/octet-stream") + .with_body_from_file(format!("./test/updater/fixture/archives/{archive_file}")) + .create(); + + // sample mock for update file + let _m = mockito::mock("GET", "/") + .with_status(200) + .with_header("content-type", "application/json") + .with_body(generate_sample_platform_json( + "2.0.1", + signature.as_ref(), + good_archive_url.as_ref(), + )) + .create(); + + // Build a tmpdir so we can test our extraction inside + // We dont want to overwrite our current executable or the directory + // Otherwise tests are failing... + let executable_path = current_exe().expect("Can't extract executable path"); + let parent_path = executable_path + .parent() + .expect("Can't find the parent path"); + + let tmp_dir = tempfile::Builder::new() + .prefix("tauri_updater_test") + .tempdir_in(parent_path); + + assert!(tmp_dir.is_ok()); + let tmp_dir_unwrap = tmp_dir.expect("Can't find tmp_dir"); + let tmp_dir_path = tmp_dir_unwrap.path(); + + #[cfg(target_os = "linux")] + let my_executable = &tmp_dir_path.join("updater-example_0.1.0_amd64.AppImage"); + #[cfg(target_os = "macos")] + let my_executable = &tmp_dir_path.join("my_app"); + #[cfg(target_os = "windows")] + let my_executable = &tmp_dir_path.join("my_app.exe"); + + // configure the updater + let app = crate::test::mock_app(); + let check_update = block!(builder(app.handle()) + .url(mockito::server_url()) + // It should represent the executable path, that's why we add my_app.exe in our + // test path -- in production you shouldn't have to provide it + .executable_path(my_executable) + // make sure we force an update + .current_version("1.0.0".parse().unwrap()) + .build()); + + #[cfg(target_os = "linux")] + { + env::set_var("APPIMAGE", my_executable); + } + + // unwrap our results + let updater = check_update.expect("Can't check remote update"); + + // make sure we need to update + assert!(updater.should_update); + // make sure we can read announced version + assert_eq!(updater.version, "2.0.1"); + + // download, install and validate signature + let install_process = block!(updater.download_and_install(pubkey, |_, _| (), || ())); + assert!(install_process.is_ok()); + + // make sure the extraction went well (it should have skipped the main app.app folder) + // as we can't extract in /Applications directly + #[cfg(target_os = "macos")] + let bin_file = tmp_dir_path.join("Contents").join("MacOS").join("app"); + #[cfg(target_os = "linux")] + // linux should extract at same place as the executable path + let bin_file = my_executable; + #[cfg(target_os = "windows")] + let bin_file = tmp_dir_path.join("with").join("long").join("path.json"); + + assert!(bin_file.exists()); + } +} +*/ diff --git a/plugins/updater/src/updater/extract.rs b/plugins/updater/src/updater/extract.rs new file mode 100644 index 00000000..4d0feca6 --- /dev/null +++ b/plugins/updater/src/updater/extract.rs @@ -0,0 +1,344 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use std::{ + borrow::Cow, + fs, + io::{self, Read, Seek}, + path::{self, Path}, +}; + +use crate::{Error, Result}; + +/// The archive reader. +#[derive(Debug)] +pub enum ArchiveReader { + /// A plain reader. + Plain(R), + /// A GZ- compressed reader (decoder). + GzCompressed(Box>), +} + +impl Read for ArchiveReader { + fn read(&mut self, buf: &mut [u8]) -> std::io::Result { + match self { + Self::Plain(r) => r.read(buf), + Self::GzCompressed(decoder) => decoder.read(buf), + } + } +} + +impl ArchiveReader { + #[allow(dead_code)] + fn get_mut(&mut self) -> &mut R { + match self { + Self::Plain(r) => r, + Self::GzCompressed(decoder) => decoder.get_mut(), + } + } +} + +/// The supported archive formats. +#[derive(Debug, Clone, Copy, PartialEq, Eq)] +#[non_exhaustive] +pub enum ArchiveFormat { + /// Tar archive. + Tar(Option), + /// Zip archive. + #[cfg(windows)] + Zip, +} + +impl ArchiveFormat { + fn compression(self) -> Option { + match self { + Self::Tar(c) => c, + #[allow(unreachable_patterns)] + _ => None, + } + } +} + +/// The supported compression types. +#[derive(Debug, Clone, Copy, PartialEq, Eq)] +#[non_exhaustive] +pub enum Compression { + /// Gz compression (e.g. `.tar.gz` archives) + Gz, +} + +/// The zip entry. +#[cfg(windows)] +pub struct ZipEntry { + path: std::path::PathBuf, + is_dir: bool, + file_contents: Vec, +} + +/// A read-only view into an entry of an archive. +#[non_exhaustive] +pub enum Entry<'a, R: Read> { + /// An entry of a tar archive. + #[non_exhaustive] + Tar(Box>), + /// An entry of a zip archive. + #[non_exhaustive] + #[cfg(windows)] + Zip(ZipEntry), +} + +impl<'a, R: Read> Entry<'a, R> { + /// The entry path. + pub fn path(&self) -> Result> { + match self { + Self::Tar(e) => e.path().map_err(Into::into), + #[cfg(windows)] + Self::Zip(e) => Ok(Cow::Borrowed(&e.path)), + } + } + + /// Extract this entry into `into_path`. + /// If it's a directory, the target will be created, if it's a file, it'll be extracted at this location. + /// Note: You need to include the complete path, with file name and extension. + pub fn extract(self, into_path: &path::Path) -> Result<()> { + match self { + Self::Tar(mut entry) => { + // determine if it's a file or a directory + if entry.header().entry_type() == tar::EntryType::Directory { + // this is a directory, lets create it + match fs::create_dir_all(into_path) { + Ok(_) => (), + Err(e) => { + if e.kind() != io::ErrorKind::AlreadyExists { + return Err(e.into()); + } + } + } + } else { + let mut out_file = fs::File::create(into_path)?; + io::copy(&mut entry, &mut out_file)?; + + // make sure we set permissions + if let Ok(mode) = entry.header().mode() { + set_perms(into_path, Some(&mut out_file), mode, true)?; + } + } + } + #[cfg(windows)] + Self::Zip(entry) => { + if entry.is_dir { + // this is a directory, lets create it + match fs::create_dir_all(into_path) { + Ok(_) => (), + Err(e) => { + if e.kind() != io::ErrorKind::AlreadyExists { + return Err(e.into()); + } + } + } + } else { + let mut out_file = fs::File::create(into_path)?; + io::copy( + &mut std::io::Cursor::new(entry.file_contents), + &mut out_file, + )?; + } + } + } + + Ok(()) + } +} + +/// The extract manager to retrieve files from archives. +pub struct Extract<'a, R: Read + Seek> { + reader: ArchiveReader, + archive_format: ArchiveFormat, + tar_archive: Option>>, +} + +impl<'a, R: std::fmt::Debug + Read + Seek> std::fmt::Debug for Extract<'a, R> { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + f.debug_struct("Extract") + .field("reader", &self.reader) + .field("archive_format", &self.archive_format) + .finish() + } +} + +impl<'a, R: Read + Seek> Extract<'a, R> { + /// Create archive from reader. + pub fn from_cursor(mut reader: R, archive_format: ArchiveFormat) -> Extract<'a, R> { + if reader.rewind().is_err() { + #[cfg(debug_assertions)] + eprintln!("Could not seek to start of the file"); + } + let compression = archive_format.compression(); + Extract { + reader: match compression { + Some(Compression::Gz) => { + ArchiveReader::GzCompressed(Box::new(flate2::read::GzDecoder::new(reader))) + } + _ => ArchiveReader::Plain(reader), + }, + archive_format, + tar_archive: None, + } + } + + /// Reads the archive content. + pub fn with_files< + E: Into, + F: FnMut(Entry<'_, &mut ArchiveReader>) -> std::result::Result, + >( + &'a mut self, + mut f: F, + ) -> Result<()> { + match self.archive_format { + ArchiveFormat::Tar(_) => { + let archive = tar::Archive::new(&mut self.reader); + self.tar_archive.replace(archive); + for entry in self.tar_archive.as_mut().unwrap().entries()? { + let entry = entry?; + if entry.path().is_ok() { + let stop = f(Entry::Tar(Box::new(entry))).map_err(Into::into)?; + if stop { + break; + } + } + } + } + + #[cfg(windows)] + ArchiveFormat::Zip => { + let mut archive = zip::ZipArchive::new(self.reader.get_mut())?; + let file_names = archive + .file_names() + .map(|f| f.to_string()) + .collect::>(); + for path in file_names { + let mut zip_file = archive.by_name(&path)?; + let is_dir = zip_file.is_dir(); + let mut file_contents = Vec::new(); + zip_file.read_to_end(&mut file_contents)?; + let stop = f(Entry::Zip(ZipEntry { + path: path.into(), + is_dir, + file_contents, + })) + .map_err(Into::into)?; + if stop { + break; + } + } + } + } + + Ok(()) + } + + /// Extract an entire source archive into a specified path. If the source is a single compressed + /// file and not an archive, it will be extracted into a file with the same name inside of + /// `into_dir`. + #[allow(dead_code)] + pub fn extract_into(&mut self, into_dir: &path::Path) -> Result<()> { + match self.archive_format { + ArchiveFormat::Tar(_) => { + let mut archive = tar::Archive::new(&mut self.reader); + archive.unpack(into_dir)?; + } + + #[cfg(windows)] + ArchiveFormat::Zip => { + let mut archive = zip::ZipArchive::new(self.reader.get_mut())?; + for i in 0..archive.len() { + let mut file = archive.by_index(i)?; + // Decode the file name from raw bytes instead of using file.name() directly. + // file.name() uses String::from_utf8_lossy() which may return messy characters + // such as: τê▒Σ║ñµÿô.app/, that does not work as expected. + // Here we require the file name must be a valid UTF-8. + let file_name = String::from_utf8(file.name_raw().to_vec())?; + let out_path = into_dir.join(file_name); + if file.is_dir() { + fs::create_dir_all(&out_path)?; + } else { + if let Some(out_path_parent) = out_path.parent() { + fs::create_dir_all(out_path_parent)?; + } + let mut out_file = fs::File::create(&out_path)?; + io::copy(&mut file, &mut out_file)?; + } + // Get and Set permissions + #[cfg(unix)] + { + use std::os::unix::fs::PermissionsExt; + if let Some(mode) = file.unix_mode() { + fs::set_permissions(&out_path, fs::Permissions::from_mode(mode))?; + } + } + } + } + } + Ok(()) + } +} + +fn set_perms( + dst: &Path, + f: Option<&mut std::fs::File>, + mode: u32, + preserve: bool, +) -> io::Result<()> { + _set_perms(dst, f, mode, preserve).map_err(|_| { + io::Error::new( + io::ErrorKind::Other, + format!( + "failed to set permissions to {mode:o} \ + for `{}`", + dst.display() + ), + ) + }) +} + +#[cfg(unix)] +fn _set_perms( + dst: &Path, + f: Option<&mut std::fs::File>, + mode: u32, + preserve: bool, +) -> io::Result<()> { + use std::os::unix::prelude::*; + + let mode = if preserve { mode } else { mode & 0o777 }; + let perm = fs::Permissions::from_mode(mode as _); + match f { + Some(f) => f.set_permissions(perm), + None => fs::set_permissions(dst, perm), + } +} + +#[cfg(windows)] +fn _set_perms( + dst: &Path, + f: Option<&mut std::fs::File>, + mode: u32, + _preserve: bool, +) -> io::Result<()> { + if mode & 0o200 == 0o200 { + return Ok(()); + } + match f { + Some(f) => { + let mut perm = f.metadata()?.permissions(); + perm.set_readonly(true); + f.set_permissions(perm) + } + None => { + let mut perm = fs::metadata(dst)?.permissions(); + perm.set_readonly(true); + fs::set_permissions(dst, perm) + } + } +} diff --git a/plugins/updater/src/updater/mod.rs b/plugins/updater/src/updater/mod.rs new file mode 100644 index 00000000..913148c9 --- /dev/null +++ b/plugins/updater/src/updater/mod.rs @@ -0,0 +1,308 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +//! The Tauri updater. +//! +//! The updater is focused on making Tauri's application updates **as safe and transparent as updates to a website**. +//! +//! For a full guide on setting up the updater, see . +//! +//! Check [`UpdateBuilder`] to see how to trigger and customize the updater at runtime. +//! ``` + +mod core; +mod extract; +mod move_file; + +use std::time::Duration; + +use http::header::{HeaderName, HeaderValue}; +use semver::Version; +use time::OffsetDateTime; + +pub use self::core::{DownloadEvent, RemoteRelease}; + +use tauri::{AppHandle, Manager, Runtime}; + +use crate::{Result, UpdaterState}; + +/// Gets the target string used on the updater. +pub fn target() -> Option { + if let (Some(target), Some(arch)) = (core::get_updater_target(), core::get_updater_arch()) { + Some(format!("{target}-{arch}")) + } else { + None + } +} + +#[derive(Clone, serde::Serialize)] +struct StatusEvent { + status: String, + error: Option, +} + +#[derive(Clone, serde::Serialize)] +#[serde(rename_all = "camelCase")] +struct DownloadProgressEvent { + chunk_length: usize, + content_length: Option, +} + +#[derive(Clone, serde::Serialize)] +struct UpdateManifest { + version: String, + date: Option, + body: String, +} + +/// An update check builder. +#[derive(Debug)] +pub struct UpdateBuilder { + inner: core::UpdateBuilder, +} + +impl UpdateBuilder { + /// Sets the current platform's target name for the updater. + /// + /// The target is injected in the endpoint URL by replacing `{{target}}`. + /// Note that this does not affect the `{{arch}}` variable. + /// + /// If the updater response JSON includes the `platforms` field, + /// that object must contain a value for the target key. + /// + /// By default Tauri uses `$OS_NAME` as the replacement for `{{target}}` + /// and `$OS_NAME-$ARCH` as the key in the `platforms` object, + /// where `$OS_NAME` is the current operating system name "linux", "windows" or "darwin") + /// and `$ARCH` is one of the supported architectures ("i686", "x86_64", "armv7" or "aarch64"). + /// + /// See [`Builder::updater_target`](crate::Builder#method.updater_target) for a way to set the target globally. + /// + /// # Examples + /// + /// ## Use a macOS Universal binary target name + /// + /// In this example, we set the updater target only on macOS. + /// On other platforms, we set the default target. + /// Note that `{{target}}` will be replaced with `darwin-universal`, + /// but `{{arch}}` is still the running platform's architecture. + /// + /// ```no_run + /// use tauri_plugin_updater::{target as updater_target, UpdaterExt}; + /// tauri::Builder::default() + /// .setup(|app| { + /// let handle = app.handle(); + /// tauri::async_runtime::spawn(async move { + /// let builder = handle.updater().target(if cfg!(target_os = "macos") { + /// "darwin-universal".to_string() + /// } else { + /// updater_target().unwrap() + /// }); + /// match builder.check().await { + /// Ok(update) => {} + /// Err(error) => {} + /// } + /// }); + /// Ok(()) + /// }); + /// ``` + /// + /// ## Append debug information to the target + /// + /// This allows you to provide updates for both debug and release applications. + /// + /// ```no_run + /// use tauri_plugin_updater::{UpdaterExt, target as updater_target}; + /// tauri::Builder::default() + /// .setup(|app| { + /// let handle = app.handle(); + /// tauri::async_runtime::spawn(async move { + /// let kind = if cfg!(debug_assertions) { "debug" } else { "release" }; + /// let builder = handle.updater().target(format!("{}-{kind}", updater_target().unwrap())); + /// match builder.check().await { + /// Ok(update) => {} + /// Err(error) => {} + /// } + /// }); + /// Ok(()) + /// }); + /// ``` + /// + /// ## Use the platform's target triple + /// + /// ```no_run + /// use tauri_plugin_updater::UpdaterExt; + /// tauri::Builder::default() + /// .setup(|app| { + /// let handle = app.handle(); + /// tauri::async_runtime::spawn(async move { + /// let builder = handle.updater().target(tauri::utils::platform::target_triple().unwrap()); + /// match builder.check().await { + /// Ok(update) => {} + /// Err(error) => {} + /// } + /// }); + /// Ok(()) + /// }); + /// ``` + pub fn target(mut self, target: impl Into) -> Self { + self.inner = self.inner.target(target); + self + } + + /// Sets a closure that is invoked to compare the current version and the latest version returned by the updater server. + /// The first argument is the current version, and the second one is the latest version. + /// + /// The closure must return `true` if the update should be installed. + /// + /// # Examples + /// + /// - Always install the version returned by the server: + /// + /// ```no_run + /// use tauri_plugin_updater::UpdaterExt; + /// tauri::Builder::default() + /// .setup(|app| { + /// app.handle().updater().should_install(|_current, _latest| true); + /// Ok(()) + /// }); + /// ``` + pub fn should_install bool + Send + 'static>( + mut self, + f: F, + ) -> Self { + self.inner = self.inner.should_install(f); + self + } + + /// Sets the timeout for the requests to the updater endpoints. + pub fn timeout(mut self, timeout: Duration) -> Self { + self.inner = self.inner.timeout(timeout); + self + } + + /// Add a `Header` to the request. + pub fn header(mut self, key: K, value: V) -> Result + where + HeaderName: TryFrom, + >::Error: Into, + HeaderValue: TryFrom, + >::Error: Into, + { + self.inner = self.inner.header(key, value)?; + Ok(self) + } + + /// Check if an update is available. + /// + /// # Examples + /// + /// ```no_run + /// use tauri_plugin_updater::{UpdaterExt, DownloadEvent}; + /// tauri::Builder::default() + /// .setup(|app| { + /// let handle = app.handle(); + /// tauri::async_runtime::spawn(async move { + /// match handle.updater().check().await { + /// Ok(update) => { + /// if update.is_update_available() { + /// update.download_and_install(|event| { + /// match event { + /// DownloadEvent::Started { content_length } => println!("started! size: {:?}", content_length), + /// DownloadEvent::Progress { chunk_length } => println!("Downloaded {chunk_length} bytes"), + /// DownloadEvent::Finished => println!("download finished"), + /// } + /// }).await.unwrap(); + /// } + /// } + /// Err(e) => { + /// println!("failed to get update: {}", e); + /// } + /// } + /// }); + /// Ok(()) + /// }); + /// ``` + pub async fn check(self) -> Result> { + self.inner + .build() + .await + .map(|update| UpdateResponse { update }) + } +} + +/// The response of an updater check. +pub struct UpdateResponse { + update: core::Update, +} + +impl Clone for UpdateResponse { + fn clone(&self) -> Self { + Self { + update: self.update.clone(), + } + } +} + +impl UpdateResponse { + /// Whether the updater found a newer release or not. + pub fn is_update_available(&self) -> bool { + self.update.should_update + } + + /// The current version of the application as read by the updater. + pub fn current_version(&self) -> &Version { + &self.update.current_version + } + + /// The latest version of the application found by the updater. + pub fn latest_version(&self) -> &str { + &self.update.version + } + + /// The update date. + pub fn date(&self) -> Option<&OffsetDateTime> { + self.update.date.as_ref() + } + + /// The update description. + pub fn body(&self) -> Option<&String> { + self.update.body.as_ref() + } + + /// Downloads and installs the update. + pub async fn download_and_install(&self, on_event: F) -> Result<()> { + // Launch updater download process + // macOS we display the `Ready to restart dialog` asking to restart + // Windows is closing the current App and launch the downloaded MSI when ready (the process stop here) + // Linux we replace the AppImage by launching a new install, it start a new AppImage instance, so we're closing the previous. (the process stop here) + self.update + .download_and_install( + self.update.app.config().tauri.bundle.updater.pubkey.clone(), + on_event, + ) + .await + } +} + +/// Initializes the [`UpdateBuilder`] using the app configuration. +pub fn builder(handle: AppHandle) -> UpdateBuilder { + let package_info = handle.package_info().clone(); + + // prepare our endpoints + let endpoints = handle + .state::() + .config + .endpoints + .iter() + .map(|e| e.to_string()) + .collect::>(); + + let mut builder = self::core::builder(handle.clone()) + .urls(&endpoints[..]) + .current_version(package_info.version); + if let Some(target) = &handle.state::().target { + builder = builder.target(target); + } + UpdateBuilder { inner: builder } +} diff --git a/plugins/updater/src/updater/move_file.rs b/plugins/updater/src/updater/move_file.rs new file mode 100644 index 00000000..a6ec158e --- /dev/null +++ b/plugins/updater/src/updater/move_file.rs @@ -0,0 +1,118 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use ignore::WalkBuilder; +use std::{fs, path}; + +use crate::Result; + +/// Moves a file from the given path to the specified destination. +/// +/// `source` and `dest` must be on the same filesystem. +/// If `replace_using_temp` is specified, the destination file will be +/// replaced using the given temporary path. +/// +/// * Errors: +/// * Io - copying / renaming +#[derive(Debug)] +pub struct Move<'a> { + source: &'a path::Path, + temp: Option<&'a path::Path>, +} +impl<'a> Move<'a> { + /// Specify source file + pub fn from_source(source: &'a path::Path) -> Move<'a> { + Self { source, temp: None } + } + + /// If specified and the destination file already exists, the "destination" + /// file will be moved to the given temporary location before the "source" + /// file is moved to the "destination" file. + /// + /// In the event of an `io` error while renaming "source" to "destination", + /// the temporary file will be moved back to "destination". + /// + /// The `temp` dir must be explicitly provided since `rename` operations require + /// files to live on the same filesystem. + #[allow(dead_code)] + pub fn replace_using_temp(&mut self, temp: &'a path::Path) -> &mut Self { + self.temp = Some(temp); + self + } + + /// Move source file to specified destination (replace whole directory) + pub fn to_dest(&self, dest: &path::Path) -> Result<()> { + match self.temp { + None => { + fs::rename(self.source, dest)?; + } + Some(temp) => { + if dest.exists() { + fs::rename(dest, temp)?; + if let Err(e) = fs::rename(self.source, dest) { + fs::rename(temp, dest)?; + return Err(e.into()); + } + } else { + fs::rename(self.source, dest)?; + } + } + }; + Ok(()) + } + + /// Walk in the source and copy all files and create directories if needed by + /// replacing existing elements. (equivalent to a cp -R) + #[allow(dead_code)] + pub fn walk_to_dest(&self, dest: &path::Path) -> Result<()> { + match self.temp { + None => { + // got no temp -- no need to backup + walkdir_and_copy(self.source, dest)?; + } + Some(temp) => { + if dest.exists() { + // we got temp and our dest exist, lets make a backup + // of current files + walkdir_and_copy(dest, temp)?; + + if let Err(e) = walkdir_and_copy(self.source, dest) { + // if we got something wrong we reset the dest with our backup + fs::rename(temp, dest)?; + return Err(e); + } + } else { + // got temp but dest didnt exist + walkdir_and_copy(self.source, dest)?; + } + } + }; + Ok(()) + } +} +// Walk into the source and create directories, and copy files +// Overwriting existing items but keeping untouched the files in the dest +// not provided in the source. +fn walkdir_and_copy(source: &path::Path, dest: &path::Path) -> Result<()> { + let walkdir = WalkBuilder::new(source).hidden(false).build(); + + for entry in walkdir { + // Check if it's a file + + let element = entry?; + let metadata = element.metadata()?; + let destination = dest.join(element.path().strip_prefix(source)?); + + // we make sure it's a directory and destination doesnt exist + if metadata.is_dir() && !&destination.exists() { + fs::create_dir_all(&destination)?; + } + + // we make sure it's a file + if metadata.is_file() { + fs::copy(element.path(), destination)?; + } + } + Ok(()) +} diff --git a/plugins/updater/tests/app-updater/.gitignore b/plugins/updater/tests/app-updater/.gitignore new file mode 100644 index 00000000..e69de29b diff --git a/plugins/updater/tests/app-updater/Cargo.toml b/plugins/updater/tests/app-updater/Cargo.toml new file mode 100644 index 00000000..e3f94814 --- /dev/null +++ b/plugins/updater/tests/app-updater/Cargo.toml @@ -0,0 +1,19 @@ +[package] +name = "app-updater" +version = "0.1.0" +edition = { workspace = true } + +[build-dependencies] +tauri-build = { workspace = true } + +[dependencies] +tauri = { workspace = true } +serde = { workspace = true } +serde_json = { workspace = true } +tauri-plugin-updater = { path = "../.." } +tiny_http = "0.11" +time = { version = "0.3", features = ["formatting"] } + +[features] +default = ["custom-protocol"] +custom-protocol = ["tauri/custom-protocol"] diff --git a/plugins/dialog/examples/tauri-app/src-tauri/src/main.rs b/plugins/updater/tests/app-updater/build.rs similarity index 50% rename from plugins/dialog/examples/tauri-app/src-tauri/src/main.rs rename to plugins/updater/tests/app-updater/build.rs index 004cbf3b..5ebf8d2f 100644 --- a/plugins/dialog/examples/tauri-app/src-tauri/src/main.rs +++ b/plugins/updater/tests/app-updater/build.rs @@ -1,7 +1,7 @@ -// Copyright 2019-2022 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT fn main() { - app::run(); + tauri_build::build() } diff --git a/plugins/dialog/examples/tauri-app/src-tauri/icons/128x128.png b/plugins/updater/tests/app-updater/icons/128x128.png similarity index 100% rename from plugins/dialog/examples/tauri-app/src-tauri/icons/128x128.png rename to plugins/updater/tests/app-updater/icons/128x128.png diff --git a/plugins/dialog/examples/tauri-app/src-tauri/icons/128x128@2x.png b/plugins/updater/tests/app-updater/icons/128x128@2x.png similarity index 100% rename from plugins/dialog/examples/tauri-app/src-tauri/icons/128x128@2x.png rename to plugins/updater/tests/app-updater/icons/128x128@2x.png diff --git a/plugins/dialog/examples/tauri-app/src-tauri/icons/32x32.png b/plugins/updater/tests/app-updater/icons/32x32.png similarity index 100% rename from plugins/dialog/examples/tauri-app/src-tauri/icons/32x32.png rename to plugins/updater/tests/app-updater/icons/32x32.png diff --git a/plugins/dialog/examples/tauri-app/src-tauri/icons/icon.icns b/plugins/updater/tests/app-updater/icons/icon.icns similarity index 98% rename from plugins/dialog/examples/tauri-app/src-tauri/icons/icon.icns rename to plugins/updater/tests/app-updater/icons/icon.icns index 29d6685a..5594104c 100644 Binary files a/plugins/dialog/examples/tauri-app/src-tauri/icons/icon.icns and b/plugins/updater/tests/app-updater/icons/icon.icns differ diff --git a/plugins/dialog/examples/tauri-app/src-tauri/icons/icon.ico b/plugins/updater/tests/app-updater/icons/icon.ico similarity index 100% rename from plugins/dialog/examples/tauri-app/src-tauri/icons/icon.ico rename to plugins/updater/tests/app-updater/icons/icon.ico diff --git a/plugins/dialog/examples/tauri-app/src-tauri/icons/icon.png b/plugins/updater/tests/app-updater/icons/icon.png similarity index 100% rename from plugins/dialog/examples/tauri-app/src-tauri/icons/icon.png rename to plugins/updater/tests/app-updater/icons/icon.png diff --git a/plugins/updater/tests/app-updater/src/main.rs b/plugins/updater/tests/app-updater/src/main.rs new file mode 100644 index 00000000..5b5a868a --- /dev/null +++ b/plugins/updater/tests/app-updater/src/main.rs @@ -0,0 +1,55 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")] + +use tauri_plugin_updater::UpdaterExt; + +fn main() { + #[allow(unused_mut)] + let mut context = tauri::generate_context!(); + + let mut updater = tauri_plugin_updater::Builder::new(); + if std::env::var("TARGET").unwrap_or_default() == "nsis" { + // /D sets the default installation directory ($INSTDIR), + // overriding InstallDir and InstallDirRegKey. + // It must be the last parameter used in the command line and must not contain any quotes, even if the path contains spaces. + // Only absolute paths are supported. + // NOTE: we only need this because this is an integration test and we don't want to install the app in the programs folder + updater = updater.installer_args(vec![format!( + "/D={}", + tauri::utils::platform::current_exe() + .unwrap() + .parent() + .unwrap() + .display() + )]); + } + + tauri::Builder::default() + .plugin(updater.build()) + .setup(|app| { + let handle = app.handle(); + tauri::async_runtime::spawn(async move { + match handle.updater().check().await { + Ok(update) => { + if update.is_update_available() { + if let Err(e) = update.download_and_install(|_event| {}).await { + println!("{e}"); + std::process::exit(1); + } + } + std::process::exit(0); + } + Err(e) => { + println!("{e}"); + std::process::exit(1); + } + } + }); + Ok(()) + }) + .run(context) + .expect("error while running tauri application"); +} diff --git a/plugins/updater/tests/app-updater/tauri.conf.json b/plugins/updater/tests/app-updater/tauri.conf.json new file mode 100644 index 00000000..27442c2d --- /dev/null +++ b/plugins/updater/tests/app-updater/tauri.conf.json @@ -0,0 +1,39 @@ +{ + "$schema": "../../../../node_modules/.pnpm/@tauri-apps+cli@2.0.0-alpha.8/node_modules/@tauri-apps/cli/schema.json", + "build": { + "distDir": [], + "devPath": [] + }, + "tauri": { + "bundle": { + "active": true, + "targets": "all", + "identifier": "com.tauri.updater", + "icon": [ + "icons/32x32.png", + "icons/128x128.png", + "icons/128x128@2x.png", + "icons/icon.icns", + "icons/icon.ico" + ], + "category": "DeveloperTool", + "windows": { + "wix": { + "skipWebviewInstall": true + } + }, + "updater": { + "active": true, + "pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDE5QzMxNjYwNTM5OEUwNTgKUldSWTRKaFRZQmJER1h4d1ZMYVA3dnluSjdpN2RmMldJR09hUFFlZDY0SlFqckkvRUJhZDJVZXAK", + "windows": { + "installMode": "quiet" + } + } + } + }, + "plugins": { + "updater": { + "endpoints": ["http://localhost:3007"] + } + } +} diff --git a/plugins/updater/tests/app-updater/tests/update.rs b/plugins/updater/tests/app-updater/tests/update.rs new file mode 100644 index 00000000..6cc2033b --- /dev/null +++ b/plugins/updater/tests/app-updater/tests/update.rs @@ -0,0 +1,298 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +#![allow(dead_code, unused_imports)] + +use std::{ + collections::HashMap, + fs::File, + path::{Path, PathBuf}, + process::Command, +}; + +use serde::Serialize; + +const UPDATER_PRIVATE_KEY: &str = "dW50cnVzdGVkIGNvbW1lbnQ6IHJzaWduIGVuY3J5cHRlZCBzZWNyZXQga2V5ClJXUlRZMEl5YTBGV3JiTy9lRDZVd3NkL0RoQ1htZmExNDd3RmJaNmRMT1ZGVjczWTBKZ0FBQkFBQUFBQUFBQUFBQUlBQUFBQWdMekUzVkE4K0tWQ1hjeGt1Vkx2QnRUR3pzQjVuV0ZpM2czWXNkRm9hVUxrVnB6TUN3K1NheHJMREhQbUVWVFZRK3NIL1VsMDBHNW5ET1EzQno0UStSb21nRW4vZlpTaXIwZFh5ZmRlL1lSN0dKcHdyOUVPclVvdzFhVkxDVnZrbHM2T1o4Tk1NWEU9Cg=="; + +#[derive(Serialize)] +struct PackageConfig { + version: &'static str, +} + +#[derive(Serialize)] +struct Config { + package: PackageConfig, +} + +#[derive(Serialize)] +struct PlatformUpdate { + signature: String, + url: &'static str, + with_elevated_task: bool, +} + +#[derive(Serialize)] +struct Update { + version: &'static str, + date: String, + platforms: HashMap, +} + +fn get_cli_bin_path(cli_dir: &Path, debug: bool) -> Option { + let mut cli_bin_path = cli_dir.join(format!( + "target/{}/cargo-tauri", + if debug { "debug" } else { "release" } + )); + if cfg!(windows) { + cli_bin_path.set_extension("exe"); + } + if cli_bin_path.exists() { + Some(cli_bin_path) + } else { + None + } +} + +fn build_app(cwd: &Path, config: &Config, bundle_updater: bool, target: BundleTarget) { + let mut command = Command::new("cargo"); + command + .args(["tauri", "build", "--debug", "--verbose"]) + .arg("--config") + .arg(serde_json::to_string(config).unwrap()) + .current_dir(cwd); + + #[cfg(target_os = "linux")] + command.args(["--bundles", target.name()]); + #[cfg(target_os = "macos")] + command.args(["--bundles", target.name()]); + + if bundle_updater { + #[cfg(windows)] + command.args(["--bundles", "msi", "nsis"]); + + command + .env("TAURI_PRIVATE_KEY", UPDATER_PRIVATE_KEY) + .env("TAURI_KEY_PASSWORD", "") + .args(["--bundles", "updater"]); + } else { + #[cfg(windows)] + command.args(["--bundles", target.name()]); + } + + let status = command + .status() + .expect("failed to run Tauri CLI to bundle app"); + + if !status.code().map(|c| c == 0).unwrap_or(true) { + panic!("failed to bundle app {:?}", status.code()); + } +} + +#[derive(Copy, Clone)] +enum BundleTarget { + AppImage, + + App, + + Msi, + Nsis, +} + +impl BundleTarget { + fn name(self) -> &'static str { + match self { + Self::AppImage => "appimage", + Self::App => "app", + Self::Msi => "msi", + Self::Nsis => "nsis", + } + } +} + +impl Default for BundleTarget { + fn default() -> Self { + #[cfg(any(target_os = "macos", target_os = "ios"))] + return Self::App; + #[cfg(target_os = "linux")] + return Self::App; + #[cfg(windows)] + return Self::Nsis; + } +} + +#[cfg(target_os = "linux")] +fn bundle_paths(root_dir: &Path, version: &str) -> Vec<(BundleTarget, PathBuf)> { + vec![( + BundleTarget::AppImage, + root_dir.join(format!( + "target/debug/bundle/appimage/app-updater_{version}_amd64.AppImage" + )), + )] +} + +#[cfg(target_os = "macos")] +fn bundle_paths(root_dir: &Path, _version: &str) -> Vec<(BundleTarget, PathBuf)> { + vec![( + BundleTarget::App, + root_dir.join("target/debug/bundle/macos/app-updater.app"), + )] +} + +#[cfg(target_os = "ios")] +fn bundle_paths(root_dir: &Path, _version: &str) -> Vec<(BundleTarget, PathBuf)> { + vec![( + BundleTarget::App, + root_dir.join("target/debug/bundle/ios/app-updater.ipa"), + )] +} + +#[cfg(target_os = "android")] +fn bundle_path(root_dir: &Path, _version: &str) -> PathBuf { + root_dir.join("target/debug/bundle/android/app-updater.apk") +} + +#[cfg(windows)] +fn bundle_paths(root_dir: &Path, version: &str) -> Vec<(BundleTarget, PathBuf)> { + vec![ + ( + BundleTarget::Nsis, + root_dir.join(format!( + "target/debug/bundle/nsis/app-updater_{version}_x64-setup.exe" + )), + ), + ( + BundleTarget::Msi, + root_dir.join(format!( + "target/debug/bundle/msi/app-updater_{version}_x64_en-US.msi" + )), + ), + ] +} + +#[test] +#[ignore] +fn update_app() { + let target = + tauri_plugin_updater::target().expect("running updater test in an unsupported platform"); + let manifest_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")); + let root_dir = manifest_dir.join("../../../.."); + + let mut config = Config { + package: PackageConfig { version: "1.0.0" }, + }; + + // bundle app update + build_app(&manifest_dir, &config, true, Default::default()); + + let updater_zip_ext = if cfg!(windows) { "zip" } else { "tar.gz" }; + + for (bundle_target, out_bundle_path) in bundle_paths(&root_dir, "1.0.0") { + let bundle_updater_ext = out_bundle_path + .extension() + .unwrap() + .to_str() + .unwrap() + .replace("exe", "nsis"); + let signature_path = + out_bundle_path.with_extension(format!("{bundle_updater_ext}.{updater_zip_ext}.sig")); + let signature = std::fs::read_to_string(&signature_path).unwrap_or_else(|_| { + panic!("failed to read signature file {}", signature_path.display()) + }); + let out_updater_path = + out_bundle_path.with_extension(format!("{}.{}", bundle_updater_ext, updater_zip_ext)); + let updater_path = root_dir.join(format!( + "target/debug/{}", + out_updater_path.file_name().unwrap().to_str().unwrap() + )); + std::fs::rename(&out_updater_path, &updater_path).expect("failed to rename bundle"); + + let target = target.clone(); + std::thread::spawn(move || { + // start the updater server + let server = + tiny_http::Server::http("localhost:3007").expect("failed to start updater server"); + + loop { + if let Ok(request) = server.recv() { + match request.url() { + "/" => { + let mut platforms = HashMap::new(); + + platforms.insert( + target.clone(), + PlatformUpdate { + signature: signature.clone(), + url: "http://localhost:3007/download", + with_elevated_task: false, + }, + ); + let body = serde_json::to_vec(&Update { + version: "1.0.0", + date: time::OffsetDateTime::now_utc() + .format(&time::format_description::well_known::Rfc3339) + .unwrap(), + platforms, + }) + .unwrap(); + let len = body.len(); + let response = tiny_http::Response::new( + tiny_http::StatusCode(200), + Vec::new(), + std::io::Cursor::new(body), + Some(len), + None, + ); + let _ = request.respond(response); + } + "/download" => { + let _ = request.respond(tiny_http::Response::from_file( + File::open(&updater_path).unwrap_or_else(|_| { + panic!( + "failed to open updater bundle {}", + updater_path.display() + ) + }), + )); + // close server + return; + } + _ => (), + } + } + } + }); + + config.package.version = "0.1.0"; + + // bundle initial app version + build_app(&manifest_dir, &config, false, bundle_target); + + let mut binary_cmd = if cfg!(windows) { + Command::new(root_dir.join("target/debug/app-updater.exe")) + } else if cfg!(target_os = "macos") { + Command::new( + bundle_paths(&root_dir, "0.1.0") + .first() + .unwrap() + .1 + .join("Contents/MacOS/app-updater"), + ) + } else if std::env::var("CI").map(|v| v == "true").unwrap_or_default() { + let mut c = Command::new("xvfb-run"); + c.arg("--auto-servernum") + .arg(&bundle_paths(&root_dir, "0.1.0").first().unwrap().1); + c + } else { + Command::new(&bundle_paths(&root_dir, "0.1.0").first().unwrap().1) + }; + + binary_cmd.env("TARGET", bundle_target.name()); + + let status = binary_cmd.status().expect("failed to run app"); + + if !status.success() { + panic!("failed to run app"); + } + } +} diff --git a/plugins/updater/tsconfig.json b/plugins/updater/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/updater/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/upload/CHANGELOG.md b/plugins/upload/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/upload/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/upload/Cargo.toml b/plugins/upload/Cargo.toml index 49abc6d4..0f4da100 100644 --- a/plugins/upload/Cargo.toml +++ b/plugins/upload/Cargo.toml @@ -1,22 +1,25 @@ [package] name = "tauri-plugin-upload" -version = "0.0.0" +version = "2.0.0-alpha.0" description = "Upload files from disk to a remote server over HTTP." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } tokio = { version = "1", features = [ "fs" ] } tokio-util = { version = "0.7", features = [ "codec" ] } -reqwest = { version = "0.11", features = [ "json", "stream" ] } +reqwest = { version = "0.11", default-features = false, features = [ "json", "stream" ] } futures-util = "0.3" -read-progress-stream = "1.0.0" \ No newline at end of file +read-progress-stream = "1.0.0" + +[features] +native-tls = [ "reqwest/native-tls" ] +native-tls-vendored = [ "reqwest/native-tls-vendored" ] +rustls-tls = [ "reqwest/rustls-tls" ] diff --git a/plugins/upload/README.md b/plugins/upload/README.md index 08401560..31d13238 100644 --- a/plugins/upload/README.md +++ b/plugins/upload/README.md @@ -1,10 +1,11 @@ ![plugin-upload](banner.png) Upload files from disk to a remote server over HTTP. +Download files from a remote HTTP server to disk. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +19,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-upload = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-upload = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +29,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-upload +# or +npm add @tauri-apps/plugin-upload +# or +yarn add @tauri-apps/plugin-upload + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-upload#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-upload#v2 @@ -51,14 +61,25 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { upload } from 'tauri-plugin-upload-api' +import { upload } from "@tauri-apps/plugin-upload"; upload( - 'https://example.com/file-upload' - './path/to/my/file.txt' - (progress, total) => console.log(`Downloaded ${progress} of ${total} bytes`) // a callback that will be called with the upload progress - { 'ContentType': 'text/plain' } // optional headers to send with the request -) + "https://example.com/file-upload", + "./path/to/my/file.txt", + (progress, total) => console.log(`Uploaded ${progress} of ${total} bytes`), // a callback that will be called with the upload progress + { "Content-Type": "text/plain" } // optional headers to send with the request +); +``` + +```javascript +import { download } from "tauri-plugin-upload-api"; + +download( + "https://example.com/file-download-link", + "./path/to/save/my/file.txt", + (progress, total) => console.log(`Downloaded ${progress} of ${total} bytes`), // a callback that will be called with the download progress + { "Content-Type": "text/plain" } // optional headers to send with the request +); ``` ## Contributing diff --git a/plugins/upload/guest-js/index.ts b/plugins/upload/guest-js/index.ts index 26bc93b4..29c25a98 100644 --- a/plugins/upload/guest-js/index.ts +++ b/plugins/upload/guest-js/index.ts @@ -1,31 +1,15 @@ -import { invoke } from "@tauri-apps/api/tauri"; -import { appWindow } from "@tauri-apps/api/window"; +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +import { invoke, Channel } from "@tauri-apps/api/tauri"; interface ProgressPayload { - id: number; progress: number; total: number; } -type ProgressHandler = (progress: number, total: number) => void; -const handlers: Map = new Map(); -let listening = false; - -async function listenToEventIfNeeded(event: string): Promise { - if (listening) { - return await Promise.resolve(); - } - return await appWindow - .listen(event, ({ payload }) => { - const handler = handlers.get(payload.id); - if (handler != null) { - handler(payload.progress, payload.total); - } - }) - .then(() => { - listening = true; - }); -} +type ProgressHandler = (progress: ProgressPayload) => void; async function upload( url: string, @@ -37,17 +21,17 @@ async function upload( window.crypto.getRandomValues(ids); const id = ids[0]; + const onProgress = new Channel(); if (progressHandler != null) { - handlers.set(id, progressHandler); + onProgress.onmessage = progressHandler; } - await listenToEventIfNeeded("upload://progress"); - await invoke("plugin:upload|upload", { id, url, filePath, headers: headers ?? {}, + onProgress, }); } @@ -65,19 +49,18 @@ async function download( window.crypto.getRandomValues(ids); const id = ids[0]; + const onProgress = new Channel(); if (progressHandler != null) { - handlers.set(id, progressHandler); + onProgress.onmessage = progressHandler; } - await listenToEventIfNeeded("download://progress"); - await invoke("plugin:upload|download", { id, url, filePath, headers: headers ?? {}, + onProgress, }); } -export default upload; export { download, upload }; diff --git a/plugins/upload/package.json b/plugins/upload/package.json index acd01d42..67ecc76d 100644 --- a/plugins/upload/package.json +++ b/plugins/upload/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-upload-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-upload", + "version": "2.0.0-alpha.0", "description": "Upload files from disk to a remote server over HTTP.", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/upload/src/api-iife.js b/plugins/upload/src/api-iife.js new file mode 100644 index 00000000..210ee0d9 --- /dev/null +++ b/plugins/upload/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_UPLOAD__=function(e){"use strict";var n=Object.defineProperty,t=(e,n,t)=>{if(!n.has(e))throw TypeError("Cannot "+t)},r=(e,n,r)=>(t(e,n,"read from private field"),r?r.call(e):n.get(e)),o=(e,n,r,o)=>(t(e,n,"write to private field"),o?o.call(e,r):n.set(e,r),r);function a(e,n=!1){let t=window.crypto.getRandomValues(new Uint32Array(1))[0],r=`_${t}`;return Object.defineProperty(window,r,{value:t=>(n&&Reflect.deleteProperty(window,r),e?.(t)),writable:!1,configurable:!0}),t}((e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})})({},{Channel:()=>s,PluginListener:()=>l,addPluginListener:()=>d,convertFileSrc:()=>u,invoke:()=>c,transformCallback:()=>a});var i,s=class{constructor(){this.__TAURI_CHANNEL_MARKER__=!0,((e,n,t)=>{if(n.has(e))throw TypeError("Cannot add the same private member more than once");n instanceof WeakSet?n.add(e):n.set(e,t)})(this,i,(()=>{})),this.id=a((e=>{r(this,i).call(this,e)}))}set onmessage(e){o(this,i,e)}get onmessage(){return r(this,i)}toJSON(){return`__CHANNEL__:${this.id}`}};i=new WeakMap;var l=class{constructor(e,n,t){this.plugin=e,this.event=n,this.channelId=t}async unregister(){return c(`plugin:${this.plugin}|remove_listener`,{event:this.event,channelId:this.channelId})}};async function d(e,n,t){let r=new s;return r.onmessage=t,c(`plugin:${e}|register_listener`,{event:n,handler:r}).then((()=>new l(e,n,r.id)))}async function c(e,n={}){return new Promise(((t,r)=>{let o=a((e=>{t(e),Reflect.deleteProperty(window,`_${i}`)}),!0),i=a((e=>{r(e),Reflect.deleteProperty(window,`_${o}`)}),!0);window.__TAURI_IPC__({cmd:e,callback:o,error:i,...n})}))}function u(e,n="asset"){let t=encodeURIComponent(e);return navigator.userAgent.includes("Windows")?`https://${n}.localhost/${t}`:`${n}://localhost/${t}`}return e.download=async function(e,n,t,r){const o=new Uint32Array(1);window.crypto.getRandomValues(o);const a=o[0],i=new s;null!=t&&(i.onmessage=t),await c("plugin:upload|download",{id:a,url:e,filePath:n,headers:null!=r?r:{},onProgress:i})},e.upload=async function(e,n,t,r){const o=new Uint32Array(1);window.crypto.getRandomValues(o);const a=o[0],i=new s;null!=t&&(i.onmessage=t),await c("plugin:upload|upload",{id:a,url:e,filePath:n,headers:null!=r?r:{},onProgress:i})},e}({});Object.defineProperty(window.__TAURI__,"upload",{value:__TAURI_UPLOAD__})} diff --git a/plugins/upload/src/lib.rs b/plugins/upload/src/lib.rs index c4a0d8c7..698549af 100644 --- a/plugins/upload/src/lib.rs +++ b/plugins/upload/src/lib.rs @@ -1,20 +1,21 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT use futures_util::TryStreamExt; use serde::{ser::Serializer, Serialize}; use tauri::{ + api::ipc::Channel, command, plugin::{Builder as PluginBuilder, TauriPlugin}, - Runtime, Window, + Runtime, }; use tokio::{fs::File, io::AsyncWriteExt}; use tokio_util::codec::{BytesCodec, FramedRead}; use read_progress_stream::ReadProgressStream; -use std::{collections::HashMap, sync::Mutex}; +use std::collections::HashMap; type Result = std::result::Result; @@ -39,19 +40,17 @@ impl Serialize for Error { #[derive(Clone, Serialize)] struct ProgressPayload { - id: u32, progress: u64, total: u64, } #[command] async fn download( - window: Window, - id: u32, url: &str, file_path: &str, headers: HashMap, -) -> Result { + on_progress: Channel, +) -> Result<()> { let client = reqwest::Client::new(); let mut request = client.get(url); @@ -69,33 +68,28 @@ async fn download( while let Some(chunk) = stream.try_next().await? { file.write_all(&chunk).await?; - let _ = window.emit( - "download://progress", - ProgressPayload { - id, - progress: chunk.len() as u64, - total, - }, - ); + let _ = on_progress.send(&ProgressPayload { + progress: chunk.len() as u64, + total, + }); } - Ok(id) + Ok(()) } #[command] async fn upload( - window: Window, - id: u32, url: &str, file_path: &str, headers: HashMap, + on_progress: Channel, ) -> Result { // Read the file let file = File::open(file_path).await?; // Create the request and attach the file to the body let client = reqwest::Client::new(); - let mut request = client.post(url).body(file_to_body(id, window, file)); + let mut request = client.post(url).body(file_to_body(on_progress, file)); // Loop trought the headers keys and values // and add them to the request object. @@ -108,26 +102,20 @@ async fn upload( response.json().await.map_err(Into::into) } -fn file_to_body(id: u32, window: Window, file: File) -> reqwest::Body { +fn file_to_body(channel: Channel, file: File) -> reqwest::Body { let stream = FramedRead::new(file, BytesCodec::new()).map_ok(|r| r.freeze()); - let window = Mutex::new(window); + reqwest::Body::wrap_stream(ReadProgressStream::new( stream, Box::new(move |progress, total| { - let _ = window.lock().unwrap().emit( - "upload://progress", - ProgressPayload { - id, - progress, - total, - }, - ); + let _ = channel.send(&ProgressPayload { progress, total }); }), )) } pub fn init() -> TauriPlugin { PluginBuilder::new("upload") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![download, upload]) .build() } diff --git a/plugins/upload/tsconfig.json b/plugins/upload/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/upload/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/upload/tsconfig.json b/plugins/upload/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/upload/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/websocket/CHANGELOG.md b/plugins/websocket/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/websocket/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/websocket/Cargo.toml b/plugins/websocket/Cargo.toml index 37eafb5d..a9c00ba1 100644 --- a/plugins/websocket/Cargo.toml +++ b/plugins/websocket/Cargo.toml @@ -1,21 +1,25 @@ [package] name = "tauri-plugin-websocket" -version = "0.0.0" -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true -exclude = ["/examples"] - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +version = "2.0.0-alpha.0" +description = "Expose a WebSocket server to your Tauri frontend." +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } +exclude = [ "/examples" ] [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } rand = "0.8" futures-util = "0.3" -tokio = { version = "1", features = ["net", "sync"] } -tokio-tungstenite = { version = "0.18", features = ["native-tls"] } +tokio = { version = "1", features = [ "net", "sync" ] } +tokio-tungstenite = { version = "0.19" } + +[features] +native-tls = [ "tokio-tungstenite/native-tls" ] +native-tls-vendored = [ "tokio-tungstenite/native-tls-vendored" ] +rustls-tls-webpki-roots = [ "tokio-tungstenite/rustls-tls-webpki-roots" ] diff --git a/plugins/websocket/README.md b/plugins/websocket/README.md index 4557b851..56943465 100644 --- a/plugins/websocket/README.md +++ b/plugins/websocket/README.md @@ -1,10 +1,10 @@ ![plugin-websocket](banner.png) - +Expose a WebSocket server to your Tauri frontend. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-websocket = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-websocket = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-websocket +# or +npm add @tauri-apps/plugin-websocket +# or +yarn add @tauri-apps/plugin-websocket + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-websocket#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-websocket#v2 @@ -51,7 +60,7 @@ fn main() { Afterwards all the plugin's APIs are available through the JavaScript guest bindings: ```javascript -import { WebSocket } from "tauri-plugin-websocket-api"; +import { WebSocket } from "@tauri-apps/plugin-websocket"; const ws = await WebSocket.connect("wss://example.com"); diff --git a/plugins/websocket/examples/svelte-app/package.json b/plugins/websocket/examples/svelte-app/package.json index d5885cd6..67d63a59 100644 --- a/plugins/websocket/examples/svelte-app/package.json +++ b/plugins/websocket/examples/svelte-app/package.json @@ -13,7 +13,7 @@ "devDependencies": { "@sveltejs/adapter-auto": "^2.0.0", "@sveltejs/kit": "^1.15.5", - "@tauri-apps/cli": "^1.2.3", + "@tauri-apps/cli": "2.0.0-alpha.9", "svelte": "^3.58.0", "svelte-check": "^3.2.0", "tslib": "^2.5.0", @@ -21,8 +21,7 @@ "vite": "^4.2.1" }, "dependencies": { - "@tauri-apps/cli": "^2.0.0-alpha.8", - "tauri-plugin-websocket-api": "link:../../" + "@tauri-apps/plugin-websocket": "link:../../" }, "type": "module" } diff --git a/plugins/websocket/examples/svelte-app/src-tauri/Cargo.lock b/plugins/websocket/examples/svelte-app/src-tauri/Cargo.lock deleted file mode 100644 index efab7176..00000000 --- a/plugins/websocket/examples/svelte-app/src-tauri/Cargo.lock +++ /dev/null @@ -1,3363 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "aho-corasick" -version = "0.7.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e37cfd5e7657ada45f742d6e99ca5788580b5c529dc78faf11ece6dc702656f" -dependencies = [ - "memchr", -] - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "anyhow" -version = "1.0.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "595d3cfa7a60d4555cb5067b99f07142a08ea778de5cf993f7b75c7d8fabc486" - -[[package]] -name = "app" -version = "0.1.0" -dependencies = [ - "futures-util", - "serde", - "serde_json", - "tauri", - "tauri-build", - "tauri-plugin-websocket", - "tokio", - "tokio-tungstenite", -] - -[[package]] -name = "atk" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c3d816ce6f0e2909a96830d6911c2aff044370b1ef92d7f267b43bae5addedd" -dependencies = [ - "atk-sys", - "bitflags", - "glib", - "libc", -] - -[[package]] -name = "atk-sys" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58aeb089fb698e06db8089971c7ee317ab9644bade33383f63631437b03aafb6" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps 6.0.1", -] - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "base64" -version = "0.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fd" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "block" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a" - -[[package]] -name = "block-buffer" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bf7fe51849ea569fd452f37822f606a5cabb684dc918707a0193fd4664ff324" -dependencies = [ - "generic-array", -] - -[[package]] -name = "brotli" -version = "3.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a0b1dbcc8ae29329621f8d4f0d835787c1c38bb1401979b49d13b0b305ff68" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59ad2d4653bf5ca36ae797b1f4bb4dbddb60ce49ca4aed8a2ce4829f60425b80" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bstr" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90682c8d613ad3373e66de8c6411e0ae2ab2571e879d2efbf73558cc66f21279" -dependencies = [ - "memchr", -] - -[[package]] -name = "bytemuck" -version = "1.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aaa3a8d9a1ca92e282c96a32d6511b695d7d994d1d102ba85d279f9b2756947f" - -[[package]] -name = "byteorder" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" - -[[package]] -name = "bytes" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b700ce4376041dcd0a327fd0097c41095743c4c8af8887265942faf1100bd040" - -[[package]] -name = "cairo-rs" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b869e97a87170f96762f9f178eae8c461147e722ba21dd8814105bf5716bf14a" -dependencies = [ - "bitflags", - "cairo-sys-rs", - "glib", - "libc", - "thiserror", -] - -[[package]] -name = "cairo-sys-rs" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c55d429bef56ac9172d25fecb85dc8068307d17acd74b377866b7a1ef25d3c8" -dependencies = [ - "glib-sys", - "libc", - "system-deps 6.0.1", -] - -[[package]] -name = "cargo_toml" -version = "0.13.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497049e9477329f8f6a559972ee42e117487d01d1e8c2cc9f836ea6fa23a9e1a" -dependencies = [ - "serde", - "toml", -] - -[[package]] -name = "cc" -version = "1.0.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e70cc2f62c6ce1868963827bd677764c62d07c3d9a3e1fb1177ee1a9ab199eb2" - -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - -[[package]] -name = "cfb" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74f89d248799e3f15f91b70917f65381062a01bb8e222700ea0e5a7ff9785f9c" -dependencies = [ - "byteorder", - "uuid 0.8.2", -] - -[[package]] -name = "cfg-expr" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3431df59f28accaf4cb4eed4a9acc66bea3f3c3753aa6cdc2f024174ef232af7" -dependencies = [ - "smallvec", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "cocoa" -version = "0.24.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f63902e9223530efb4e26ccd0cf55ec30d592d3b42e21a28defc42a9586e832" -dependencies = [ - "bitflags", - "block", - "cocoa-foundation", - "core-foundation", - "core-graphics", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "cocoa-foundation" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ade49b65d560ca58c403a479bb396592b155c0185eada742ee323d1d68d6318" -dependencies = [ - "bitflags", - "block", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", - "objc", -] - -[[package]] -name = "color_quant" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" - -[[package]] -name = "combine" -version = "4.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "core-foundation" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a89e2ae426ea83155dccf10c0fa6b1463ef6d5fcb44cee0b224a408fa640a62" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea221b5284a47e40033bf9b66f35f984ec0ea2931eb03505246cd27a963f981b" - -[[package]] -name = "core-graphics" -version = "0.22.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "269f35f69b542b80e736a20a89a05215c0ce80c2c03c514abb2e318b78379d86" -dependencies = [ - "bitflags", - "core-foundation", - "core-graphics-types", - "foreign-types", - "libc", -] - -[[package]] -name = "core-graphics-types" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a68b68b3446082644c91ac778bf50cd4104bfb002b5a6a7c44cca5a2c70788b" -dependencies = [ - "bitflags", - "core-foundation", - "foreign-types", - "libc", -] - -[[package]] -name = "cpufeatures" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95059428f66df56b63431fdb4e1947ed2190586af5c5a8a8b71122bdf5a7f469" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81156fece84ab6a9f2afdb109ce3ae577e42b1228441eded99bd77f627953b1a" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ed27e177f16d65f0f0c22a213e17c696ace5dd64b14258b52f9417ccb52db4" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d82cfc11ce7f2c3faef78d8a684447b40d503d9681acebed6cb728d45940c4db" -dependencies = [ - "cfg-if", - "lazy_static", -] - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "cssparser" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "754b69d351cdc2d8ee09ae203db831e005560fc6030da058f86ad60c92a9cb0a" -dependencies = [ - "cssparser-macros", - "dtoa-short", - "itoa 0.4.7", - "matches", - "phf 0.8.0", - "proc-macro2", - "quote", - "smallvec", - "syn", -] - -[[package]] -name = "cssparser-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfae75de57f2b2e85e8768c3ea840fd159c8f33e2b6522c7835b7abac81be16e" -dependencies = [ - "quote", - "syn", -] - -[[package]] -name = "ctor" -version = "0.1.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccc0a48a9b826acdf4028595adc9db92caea352f7af011a3034acd172a52a0aa" -dependencies = [ - "quote", - "syn", -] - -[[package]] -name = "cty" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b365fabc795046672053e29c954733ec3b05e4be654ab130fe8f1f94d7051f35" - -[[package]] -name = "darling" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0d720b8683f8dd83c65155f0530560cba68cd2bf395f6513a483caee57ff7f4" -dependencies = [ - "darling_core", - "darling_macro", -] - -[[package]] -name = "darling_core" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a340f241d2ceed1deb47ae36c4144b2707ec7dd0b649f894cb39bb595986324" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn", -] - -[[package]] -name = "darling_macro" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72c41b3b7352feb3211a0d743dc5700a4e3b60f51bd2b368892d1e0f9a95f44b" -dependencies = [ - "darling_core", - "quote", - "syn", -] - -[[package]] -name = "derivative" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "derive_more" -version = "0.99.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40eebddd2156ce1bb37b20bbe5151340a31828b1f2d22ba4141f3531710e38df" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version", - "syn", -] - -[[package]] -name = "digest" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dirs-next" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" -dependencies = [ - "cfg-if", - "dirs-sys-next", -] - -[[package]] -name = "dirs-sys-next" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dispatch" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" - -[[package]] -name = "dtoa" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56899898ce76aaf4a0f24d914c97ea6ed976d42fec6ad33fcbb0a1103e07b2b0" - -[[package]] -name = "dtoa-short" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde03329ae10e79ede66c9ce4dc930aa8599043b0743008548680f25b91502d6" -dependencies = [ - "dtoa", -] - -[[package]] -name = "embed_plist" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53dd2e43a7d32952a6054141ee0d75183958620e84e5eab045de362dff13dc99" - -[[package]] -name = "fastrand" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b394ed3d285a429378d3b384b9eb1285267e7df4b166df24b7a6939a04dc392e" -dependencies = [ - "instant", -] - -[[package]] -name = "field-offset" -version = "0.3.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e1c54951450cbd39f3dbcf1005ac413b49487dabf18a720ad2383eccfeffb92" -dependencies = [ - "memoffset", - "rustc_version", -] - -[[package]] -name = "filetime" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d34cfa13a63ae058bfa601fe9e313bbdb3746427c1459185464ce0fcf62e1e8" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "winapi", -] - -[[package]] -name = "flate2" -version = "1.0.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd3aec53de10fe96d7d8c565eb17f2c687bb5518a2ec453b5b1252964526abe0" -dependencies = [ - "cfg-if", - "crc32fast", - "libc", - "miniz_oxide 0.4.4", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5fc25a87fa4fd2094bffb06925852034d90a17f0d1e05197d4956d3555752191" -dependencies = [ - "matches", - "percent-encoding", -] - -[[package]] -name = "futf" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c9c1ce3fa9336301af935ab852c437817d14cd33690446569392e65170aac3b" -dependencies = [ - "mac", - "new_debug_unreachable", -] - -[[package]] -name = "futures" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1adc00f486adfc9ce99f77d717836f0c5aa84965eb0b4f051f4e83f7cab53f8b" -dependencies = [ - "futures-channel", - "futures-core", - "futures-executor", - "futures-io", - "futures-sink", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-channel" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74ed2411805f6e4e3d9bc904c95d5d423b89b3b25dc0250aa74729de20629ff9" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af51b1b4a7fdff033703db39de8802c673eb91855f2e0d47dcf3bf2c0ef01f99" - -[[package]] -name = "futures-executor" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d0d535a57b87e1ae31437b892713aee90cd2d7b0ee48727cd11fc72ef54761c" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-io" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b0e06c393068f3a6ef246c75cdca793d6a46347e75286933e5e75fd2fd11582" - -[[package]] -name = "futures-lite" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7694489acd39452c77daa48516b894c153f192c3578d5a839b62c58099fcbf48" -dependencies = [ - "fastrand", - "futures-core", - "futures-io", - "memchr", - "parking", - "pin-project-lite", - "waker-fn", -] - -[[package]] -name = "futures-macro" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c54913bae956fb8df7f4dc6fc90362aa72e69148e3f39041fbe8742d21e0ac57" -dependencies = [ - "autocfg", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "futures-sink" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0f30aaa67363d119812743aa5f33c201a7a66329f97d1a887022971feea4b53" - -[[package]] -name = "futures-task" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbe54a98670017f3be909561f6ad13e810d9a51f3f061b902062ca3da80799f2" - -[[package]] -name = "futures-util" -version = "0.3.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67eb846bfd58e44a8481a00049e82c43e0ccb5d61f8dc071057cb19249dd4d78" -dependencies = [ - "autocfg", - "futures-channel", - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "proc-macro-hack", - "proc-macro-nested", - "slab", -] - -[[package]] -name = "fxhash" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c" -dependencies = [ - "byteorder", -] - -[[package]] -name = "gdk" -version = "0.15.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614258e81ec35ed8770e64a0838f3a47f95b398bc51e724d3b3fa09c1ee0f8d5" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk-pixbuf", - "gdk-sys", - "gio", - "glib", - "libc", - "pango", -] - -[[package]] -name = "gdk-pixbuf" -version = "0.15.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73aa2f5de1b45710da90a55863276667dc3a3264aaf6a2aeace62bb015244d49" -dependencies = [ - "bitflags", - "gdk-pixbuf-sys", - "gio", - "glib", - "libc", -] - -[[package]] -name = "gdk-pixbuf-sys" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "413424d9818621fa3cfc8a3a915cdb89a7c3c507d56761b4ec83a9a98e587171" -dependencies = [ - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps 6.0.1", -] - -[[package]] -name = "gdk-sys" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32e7a08c1e8f06f4177fb7e51a777b8c1689f743a7bc11ea91d44d2226073a88" -dependencies = [ - "cairo-sys-rs", - "gdk-pixbuf-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "pango-sys", - "pkg-config", - "system-deps 6.0.1", -] - -[[package]] -name = "gdkx11-sys" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4b7f8c7a84b407aa9b143877e267e848ff34106578b64d1e0a24bf550716178" -dependencies = [ - "gdk-sys", - "glib-sys", - "libc", - "system-deps 6.0.1", - "x11", -] - -[[package]] -name = "generator" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1d9279ca822891c1a4dae06d185612cf8fc6acfe5dff37781b41297811b12ee" -dependencies = [ - "cc", - "libc", - "log", - "rustversion", - "winapi", -] - -[[package]] -name = "generic-array" -version = "0.14.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "501466ecc8a30d1d3b7fc9229b122b2ce8ed6e9d9223f1138d4babb253e51817" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fcd999463524c52659517fe2cea98493cfe485d10565e7b0fb07dbba7ad2753" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.10.2+wasi-snapshot-preview1", -] - -[[package]] -name = "gio" -version = "0.15.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59105fa464928adf56b159c8d980cc11fbfbe414befb904caac5163d383049bf" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-io", - "gio-sys", - "glib", - "libc", - "once_cell", - "thiserror", -] - -[[package]] -name = "gio-sys" -version = "0.15.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f0bc4cfc9ebcdd05cc5057bc51b99c32f8f9bf246274f6a556ffd27279f8fe3" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps 6.0.1", - "winapi", -] - -[[package]] -name = "glib" -version = "0.15.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41dcfbdb6cc6c02aee163339465d8a40d6f3f64c3a43f729a4195f0e153338b7" -dependencies = [ - "bitflags", - "futures-channel", - "futures-core", - "futures-executor", - "futures-task", - "glib-macros", - "glib-sys", - "gobject-sys", - "libc", - "once_cell", - "smallvec", - "thiserror", -] - -[[package]] -name = "glib-macros" -version = "0.15.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e58b262ff65ef771003873cea8c10e0fe854f1c508d48d62a4111a1ff163f7d1" -dependencies = [ - "anyhow", - "heck 0.4.0", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "glib-sys" -version = "0.15.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa1d4e1a63d8574541e5b92931e4e669ddc87ffa85d58e84e631dba13ad2e10c" -dependencies = [ - "libc", - "system-deps 6.0.1", -] - -[[package]] -name = "glob" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b919933a397b79c37e33b77bb2aa3dc8eb6e165ad809e58ff75bc7db2e34574" - -[[package]] -name = "globset" -version = "0.4.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10463d9ff00a2a068db14231982f5132edebad0d7660cd956a1c30292dbcbfbd" -dependencies = [ - "aho-corasick", - "bstr", - "fnv", - "log", - "regex", -] - -[[package]] -name = "gobject-sys" -version = "0.15.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df6859463843c20cf3837e3a9069b6ab2051aeeadf4c899d33344f4aea83189a" -dependencies = [ - "glib-sys", - "libc", - "system-deps 6.0.1", -] - -[[package]] -name = "gtk" -version = "0.15.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7978eaec05bea63947c801d29a21372f2ed39aec0bf56bf7725d3599094675e" -dependencies = [ - "atk", - "bitflags", - "cairo-rs", - "field-offset", - "futures-channel", - "gdk", - "gdk-pixbuf", - "gio", - "glib", - "gtk-sys", - "gtk3-macros", - "libc", - "once_cell", - "pango", - "pkg-config", -] - -[[package]] -name = "gtk-sys" -version = "0.15.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5bc2f0587cba247f60246a0ca11fe25fb733eabc3de12d1965fc07efab87c84" -dependencies = [ - "atk-sys", - "cairo-sys-rs", - "gdk-pixbuf-sys", - "gdk-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "pango-sys", - "system-deps 6.0.1", -] - -[[package]] -name = "gtk3-macros" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c891188af69e77a1e8a0b1746fbd03b9b396e7d34d518c5331b15950259f541" -dependencies = [ - "anyhow", - "proc-macro-crate", - "proc-macro-error", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" - -[[package]] -name = "heck" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "heck" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2540771e65fc8cb83cd6e8a237f70c319bd5c29f78ed1084ba5d50eeac86f7f9" - -[[package]] -name = "hermit-abi" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" -dependencies = [ - "libc", -] - -[[package]] -name = "html5ever" -version = "0.25.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aafcf38a1a36118242d29b92e1b08ef84e67e4a5ed06e0a80be20e6a32bfed6b" -dependencies = [ - "log", - "mac", - "markup5ever", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "http" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75f43d41e26995c17e71ee126451dd3941010b0514a81a9d11f3b341debc2399" -dependencies = [ - "bytes", - "fnv", - "itoa 1.0.1", -] - -[[package]] -name = "http-range" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eee9694f83d9b7c09682fdb32213682939507884e5bcf227be9aff5d644b90dc" - -[[package]] -name = "httparse" -version = "1.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acd94fdbe1d4ff688b67b04eee2e17bd50995534a61539e45adfefb45e5e5503" - -[[package]] -name = "ico" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "031530fe562d8c8d71c0635013d6d155bbfe8ba0aa4b4d2d24ce8af6b71047bd" -dependencies = [ - "byteorder", - "png", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418a0a6fab821475f634efe3ccc45c013f742efe03d853e8d3355d5cb850ecf8" -dependencies = [ - "matches", - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "713f1b139373f96a2e0ce3ac931cd01ee973c3c5dd7c40c0c2efe96ad2b6751d" -dependencies = [ - "crossbeam-utils", - "globset", - "lazy_static", - "log", - "memchr", - "regex", - "same-file", - "thread_local", - "walkdir", - "winapi-util", -] - -[[package]] -name = "image" -version = "0.24.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69b7ea949b537b0fd0af141fff8c77690f2ce96f4f41f042ccb6c69c6c965945" -dependencies = [ - "bytemuck", - "byteorder", - "color_quant", - "num-rational", - "num-traits", -] - -[[package]] -name = "indexmap" -version = "1.9.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399" -dependencies = [ - "autocfg", - "hashbrown", -] - -[[package]] -name = "infer" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20b2b533137b9cad970793453d4f921c2e91312a6d88b1085c07bc15fc51bb3b" -dependencies = [ - "cfb", -] - -[[package]] -name = "instant" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bee0328b1209d157ef001c94dd85b4f8f64139adb0eac2659f4b08382b2f474d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "itoa" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd25036021b0de88a0aff6b850051563c6516d0bf53f8638938edbb9de732736" - -[[package]] -name = "itoa" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1aab8fc367588b89dcee83ab0fd66b72b50b72fa1904d7095045ace2b0c81c35" - -[[package]] -name = "javascriptcore-rs" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf053e7843f2812ff03ef5afe34bb9c06ffee120385caad4f6b9967fcd37d41c" -dependencies = [ - "bitflags", - "glib", - "javascriptcore-rs-sys", -] - -[[package]] -name = "javascriptcore-rs-sys" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "905fbb87419c5cde6e3269537e4ea7d46431f3008c5d057e915ef3f115e7793c" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps 5.0.0", -] - -[[package]] -name = "jni" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24967112a1e4301ca5342ea339763613a37592b8a6ce6cf2e4494537c7a42faf" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - -[[package]] -name = "jni" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6df18c2e3db7e453d3c6ac5b3e9d5182664d28788126d39b91f2d1e22b017ec" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - -[[package]] -name = "jni-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" - -[[package]] -name = "json-patch" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f995a3c8f2bc3dd52a18a583e90f9ec109c047fa1603a853e46bcda14d2e279d" -dependencies = [ - "serde", - "serde_json", - "treediff", -] - -[[package]] -name = "kuchiki" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ea8e9c6e031377cff82ee3001dc8026cdf431ed4e2e6b51f98ab8c73484a358" -dependencies = [ - "cssparser", - "html5ever", - "matches", - "selectors", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.139" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "201de327520df007757c1f0adce6e827fe8562fbc28bfd9c15571c66ca1f5f79" - -[[package]] -name = "line-wrap" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f30344350a2a51da54c1d53be93fade8a237e545dbcc4bdbe635413f2117cab9" -dependencies = [ - "safemem", -] - -[[package]] -name = "lock_api" -version = "0.4.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88943dd7ef4a2e5a4bfa2753aaab3013e34ce2533d1996fb18ef591e315e2b3b" -dependencies = [ - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51b9bbe6c47d51fc3e1a9b945965946b4c44142ab8792c50835a980d362c2710" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "loom" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2111607c723d7857e0d8299d5ce7a0bf4b844d3e44f8de136b13da513eaf8fc4" -dependencies = [ - "cfg-if", - "generator", - "scoped-tls", - "serde", - "serde_json", -] - -[[package]] -name = "mac" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4" - -[[package]] -name = "malloc_buf" -version = "0.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb" -dependencies = [ - "libc", -] - -[[package]] -name = "markup5ever" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a24f40fb03852d1cdd84330cddcaf98e9ec08a7b7768e952fad3b4cf048ec8fd" -dependencies = [ - "log", - "phf 0.8.0", - "phf_codegen", - "string_cache", - "string_cache_codegen", - "tendril", -] - -[[package]] -name = "matches" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ffc5c5338469d4d3ea17d269fa8ea3512ad247247c30bd2df69e68309ed0a08" - -[[package]] -name = "memchr" -version = "2.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b16bd47d9e329435e309c58469fe0791c2d0d1ba96ec0954152a5ae2b04387dc" - -[[package]] -name = "memoffset" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59accc507f1338036a0477ef61afdae33cde60840f4dfe481319ce3ad116ddf9" -dependencies = [ - "autocfg", -] - -[[package]] -name = "miniz_oxide" -version = "0.4.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a92518e98c078586bc6c934028adcca4c92a53d6a958196de835170a01d84e4b" -dependencies = [ - "adler", - "autocfg", -] - -[[package]] -name = "miniz_oxide" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5d732bc30207a6423068df043e3d02e0735b155ad7ce1a6f76fe2baa5b158de" -dependencies = [ - "libc", - "log", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.42.0", -] - -[[package]] -name = "native-tls" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8d96b2e1c8da3957d58100b09f102c6d9cfdfced01b7ec5a8974044bb09dbd4" -dependencies = [ - "lazy_static", - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "ndk" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2032c77e030ddee34a6787a64166008da93f6a352b629261d0fee232b8742dd4" -dependencies = [ - "bitflags", - "jni-sys", - "ndk-sys", - "num_enum", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5a6ae77c8ee183dcbbba6150e2e6b9f3f4196a7666c02a715a95692ec1fa97" -dependencies = [ - "jni-sys", -] - -[[package]] -name = "new_debug_unreachable" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" - -[[package]] -name = "nodrop" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72ef4a56884ca558e5ddb05a1d1e7e1bfd9a68d9ed024c21704cc98872dae1bb" - -[[package]] -name = "num-integer" -version = "0.1.44" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2cc698a63b549a70bc047073d2949cce27cd1c7b0a4a862d08a8031bc2801db" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a64b1ec5cda2586e284722486d802acf1f7dbdc623e2bfc57e65ca1cd099290" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05499f3756671c15885fee9034446956fff3f243d6077b91e5767df161f766b3" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee2c8fd66061a707503d515639b8af10fd3807a5b5ee6959f7ff1bd303634bd5" -dependencies = [ - "derivative", - "num_enum_derive", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "474fd1d096da3ad17084694eebed40ba09c4a36c5255cd772bd8b98859cc562e" -dependencies = [ - "proc-macro-crate", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "objc" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1" -dependencies = [ - "malloc_buf", - "objc_exception", -] - -[[package]] -name = "objc_exception" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad970fb455818ad6cba4c122ad012fae53ae8b4795f86378bce65e4f6bab2ca4" -dependencies = [ - "cc", -] - -[[package]] -name = "objc_id" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b" -dependencies = [ - "objc", -] - -[[package]] -name = "once_cell" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f61fba1741ea2b3d6a1e3178721804bb716a68a6aeba1149b5d52e3d464ea66" - -[[package]] -name = "openssl" -version = "0.10.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "549430950c79ae24e6d02e0b7404534ecf311d94cc9f861e9e4020187d13d885" -dependencies = [ - "bitflags", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-sys", -] - -[[package]] -name = "openssl-probe" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28988d872ab76095a6e6ac88d99b54fd267702734fd7ffe610ca27f533ddb95a" - -[[package]] -name = "openssl-sys" -version = "0.9.65" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a7907e3bfa08bb85105209cdfcb6c63d109f8f6c1ed6ca318fff5c1853fbc1d" -dependencies = [ - "autocfg", - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "pango" -version = "0.15.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79211eff430c29cc38c69e0ab54bc78fa1568121ca9737707eee7f92a8417a94" -dependencies = [ - "bitflags", - "glib", - "libc", - "once_cell", - "pango-sys", -] - -[[package]] -name = "pango-sys" -version = "0.15.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7022c2fb88cd2d9d55e1a708a8c53a3ae8678234c4a54bf623400aeb7f31fac2" -dependencies = [ - "glib-sys", - "gobject-sys", - "libc", - "system-deps 6.0.1", -] - -[[package]] -name = "parking" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "427c3892f9e783d91cc128285287e70a59e206ca452770ece88a76f7a3eddd72" - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1ef8814b5c993410bb3adfad7a5ed269563e4a2f90c41f5d85be7fb47133bf" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-sys 0.42.0", -] - -[[package]] -name = "paste" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d01a5bd0424d00070b0098dd17ebca6f961a959dead1dbcbbbc1d1cd8d3deeba" - -[[package]] -name = "percent-encoding" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4fd5641d01c8f18a23da7b6fe29298ff4b55afcccdf78973b24cf3175fee32e" - -[[package]] -name = "pest" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10f4872ae94d7b90ae48754df22fd42ad52ce740b8f370b03da4835417403e53" -dependencies = [ - "ucd-trie", -] - -[[package]] -name = "phf" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dfb61232e34fcb633f43d12c58f83c1df82962dcdfa565a4e866ffc17dafe12" -dependencies = [ - "phf_macros 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", -] - -[[package]] -name = "phf" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9fc3db1018c4b59d7d582a739436478b6035138b6aecbce989fc91c3e98409f" -dependencies = [ - "phf_macros 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", -] - -[[package]] -name = "phf_codegen" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbffee61585b0411840d3ece935cce9cb6321f01c45477d30066498cd5e1a815" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", -] - -[[package]] -name = "phf_generator" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17367f0cc86f2d25802b2c26ee58a7b23faeccf78a396094c13dced0d0182526" -dependencies = [ - "phf_shared 0.8.0", - "rand 0.7.3", -] - -[[package]] -name = "phf_generator" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d5285893bb5eb82e6aaf5d59ee909a06a16737a8970984dd7746ba9283498d6" -dependencies = [ - "phf_shared 0.10.0", - "rand 0.8.4", -] - -[[package]] -name = "phf_macros" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f6fde18ff429ffc8fe78e2bf7f8b7a5a5a6e2a8b58bc5a9ac69198bbda9189c" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "phf_macros" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58fdf3184dd560f160dd73922bea2d5cd6e8f064bf4b13110abd81b03697b4e0" -dependencies = [ - "phf_generator 0.10.0", - "phf_shared 0.10.0", - "proc-macro-hack", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "phf_shared" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c00cf8b9eafe68dde5e9eaa2cef8ee84a9336a47d566ec55ca16589633b65af7" -dependencies = [ - "siphasher", -] - -[[package]] -name = "phf_shared" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6796ad771acdc0123d2a88dc428b5e38ef24456743ddb1744ed628f9815c096" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d31d11c69a6b52a174b42bdc0c30e5e11670f90788b2c471c31c1d17d449443" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" - -[[package]] -name = "plist" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd39bc6cdc9355ad1dc5eeedefee696bb35c34caf21768741e81826c0bbd7225" -dependencies = [ - "base64", - "indexmap", - "line-wrap", - "serde", - "time", - "xml-rs", -] - -[[package]] -name = "png" -version = "0.17.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d708eaf860a19b19ce538740d2b4bdeeb8337fa53f7738455e706623ad5c638" -dependencies = [ - "bitflags", - "crc32fast", - "flate2", - "miniz_oxide 0.6.2", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac74c624d6b2d21f425f752262f42188365d7b8ff1aff74c82e45136510a4857" - -[[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.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41fdbd1df62156fbc5945f4762632564d7d038153091c3fcf1067f6aef7cff92" -dependencies = [ - "thiserror", - "toml", -] - -[[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", - "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-macro-hack" -version = "0.5.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbf0c48bc1d91375ae5c3cd81e3722dff1abcf81a30960240640d223f59fe0e5" - -[[package]] -name = "proc-macro-nested" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc881b2c22681370c6a780e47af9840ef841837bc98118431d4e1868bd0c1086" - -[[package]] -name = "proc-macro2" -version = "1.0.49" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57a8eca9f9c4ffde41714334dee777596264c7825420f521abc92b5b5deb63a5" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quote" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d0b9745dc2debf507c8422de05d7226cc1f0644216dfdfead988f9b1ab32a7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc 0.2.0", - "rand_pcg", -] - -[[package]] -name = "rand" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e7573632e6454cf6b99d7aac4ccca54be06da05aca2ef7423d22d27d4d4bcd8" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.3", - "rand_hc 0.3.1", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.3", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d34f1408f55294453790c48b2f1ebbb1c5b4b7563eb1f418bcfcfdbb06ebb4e7" -dependencies = [ - "getrandom 0.2.3", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_hc" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d51e9f596de227fda2ea6c84607f5558e196eeaf43c986b724ba4fb8fdf497e7" -dependencies = [ - "rand_core 0.6.3", -] - -[[package]] -name = "rand_pcg" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16abd0c1b639e9eb4d7c50c0b8100b0d0f849be2349829c740fe8e6eb4816429" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "raw-window-handle" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b800beb9b6e7d2df1fe337c9e3d04e3af22a124460fb4c30fcc22c9117cefb41" -dependencies = [ - "cty", -] - -[[package]] -name = "redox_syscall" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ab49abadf3f9e1c4bc499e8845e152ad87d2ad2d30371841171169e9d75feee" -dependencies = [ - "bitflags", -] - -[[package]] -name = "redox_users" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "528532f3d801c87aec9def2add9ca802fe569e44a544afe633765267840abe64" -dependencies = [ - "getrandom 0.2.3", - "redox_syscall", -] - -[[package]] -name = "regex" -version = "1.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d07a8629359eb56f1e2fb1652bb04212c072a87ba68546a04065d525673ac461" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b" - -[[package]] -name = "remove_dir_all" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7" -dependencies = [ - "winapi", -] - -[[package]] -name = "rustc_version" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" -dependencies = [ - "semver 0.11.0", -] - -[[package]] -name = "rustversion" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61b3909d758bb75c79f23d4736fac9433868679d3ad2ea7a61e3c25cfda9a088" - -[[package]] -name = "ryu" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "71d301d4193d031abdd79ff7e3dd721168a9572ef3fe51a1517aba235bd8f86e" - -[[package]] -name = "safemem" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef703b7cb59335eae2eb93ceb664c0eb7ea6bf567079d843e09420219668e072" - -[[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.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f05ba609c234e60bee0d547fe94a4c7e9da733d1c962cf6e59efa4cd9c8bc75" -dependencies = [ - "lazy_static", - "winapi", -] - -[[package]] -name = "scoped-tls" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea6a9290e3c9cf0f18145ef7ffa62d68ee0bf5fcd651017e586dc7fd5da448c2" - -[[package]] -name = "scopeguard" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "security-framework" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23a2ac85147a3a11d77ecf1bc7166ec0b92febfa4461c37944e180f319ece467" -dependencies = [ - "bitflags", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e4effb91b4b8b6fb7732e670b6cee160278ff8e6bf485c7805d9e319d76e284" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "selectors" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df320f1889ac4ba6bc0cdc9c9af7af4bd64bb927bccdf32d81140dc1f9be12fe" -dependencies = [ - "bitflags", - "cssparser", - "derive_more", - "fxhash", - "log", - "matches", - "phf 0.8.0", - "phf_codegen", - "precomputed-hash", - "servo_arc", - "smallvec", - "thin-slice", -] - -[[package]] -name = "semver" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" -dependencies = [ - "semver-parser", -] - -[[package]] -name = "semver" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "568a8e6258aa33c13358f81fd834adb854c6f7c9468520910a9b1e8fac068012" -dependencies = [ - "serde", -] - -[[package]] -name = "semver-parser" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" -dependencies = [ - "pest", -] - -[[package]] -name = "serde" -version = "1.0.152" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb7d1f0d3021d347a83e556fc4683dea2ea09d87bccdf88ff5c12545d89d5efb" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.152" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af487d118eecd09402d70a5d72551860e788df87b464af30e5ea6a38c75c541e" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.66" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "336b10da19a12ad094b59d870ebde26a45402e5b470add4b5fd03c5048a32127" -dependencies = [ - "itoa 0.4.7", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98d0516900518c29efa217c298fa1f4e6c6ffc85ae29fd7f4ee48f176e1a9ed5" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_with" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec1e6ec4d8950e5b1e894eac0d360742f3b1407a6078a604a731c4b3f49cefbc" -dependencies = [ - "rustversion", - "serde", - "serde_with_macros", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12e47be9471c72889ebafb5e14d5ff930d89ae7a67bbdb5f8abb564f845a927e" -dependencies = [ - "darling", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serialize-to-javascript" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9823f2d3b6a81d98228151fdeaf848206a7855a7a042bbf9bf870449a66cafb" -dependencies = [ - "serde", - "serde_json", - "serialize-to-javascript-impl", -] - -[[package]] -name = "serialize-to-javascript-impl" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74064874e9f6a15f04c1f3cb627902d0e6b410abbf36668afa873c61889f1763" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "servo_arc" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d98238b800e0d1576d8b6e3de32827c2d74bee68bb97748dcf5071fb53965432" -dependencies = [ - "nodrop", - "stable_deref_trait", -] - -[[package]] -name = "sha1" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f04293dc80c3993519f2d7f6f511707ee7094fe0c6d3406feb330cdb3540eba3" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "sha2" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99c3bd8169c58782adad9290a9af5939994036b76187f7b4f0e6de91dbbfc0ec" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "siphasher" -version = "0.3.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "729a25c17d72b06c68cb47955d44fda88ad2d3e7d77e025663fdd69b93dd71a1" - -[[package]] -name = "slab" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f173ac3d1a7e3b28003f40de0b5ce7fe2710f9b9dc3fc38664cebee46b3b6527" - -[[package]] -name = "smallvec" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe0f37c9e8f3c5a4a66ad655a93c74daac4ad00c441533bf5c6e7990bb42604e" - -[[package]] -name = "socket2" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "soup2" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2b4d76501d8ba387cf0fefbe055c3e0a59891d09f0f995ae4e4b16f6b60f3c0" -dependencies = [ - "bitflags", - "gio", - "glib", - "libc", - "once_cell", - "soup2-sys", -] - -[[package]] -name = "soup2-sys" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "009ef427103fcb17f802871647a7fa6c60cbb654b4c4e4c0ac60a31c5f6dc9cf" -dependencies = [ - "bitflags", - "gio-sys", - "glib-sys", - "gobject-sys", - "libc", - "system-deps 5.0.0", -] - -[[package]] -name = "stable_deref_trait" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" - -[[package]] -name = "state" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cf4f5369e6d3044b5e365c9690f451516ac8f0954084622b49ea3fde2f6de5" -dependencies = [ - "loom", -] - -[[package]] -name = "string_cache" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ddb1139b5353f96e429e1a5e19fbaf663bddedaa06d1dbd49f82e352601209a" -dependencies = [ - "lazy_static", - "new_debug_unreachable", - "phf_shared 0.8.0", - "precomputed-hash", - "serde", -] - -[[package]] -name = "string_cache_codegen" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f24c8e5e19d22a726626f1a5e16fe15b132dcf21d10177fa5a45ce7962996b97" -dependencies = [ - "phf_generator 0.8.0", - "phf_shared 0.8.0", - "proc-macro2", - "quote", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "syn" -version = "1.0.107" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f4064b5b16e03ae50984a5a8ed5d4f8803e6bc1fd170a3cda91a1be4b18e3f5" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-deps" -version = "5.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18db855554db7bd0e73e06cf7ba3df39f97812cb11d3f75e71c39bf45171797e" -dependencies = [ - "cfg-expr", - "heck 0.3.3", - "pkg-config", - "toml", - "version-compare 0.0.11", -] - -[[package]] -name = "system-deps" -version = "6.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad3a97fdef3daf935d929b3e97e5a6a680cd4622e40c2941ca0875d6566416f8" -dependencies = [ - "cfg-expr", - "heck 0.4.0", - "pkg-config", - "toml", - "version-compare 0.1.0", -] - -[[package]] -name = "tao" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6fd7725dc1e593e9ecabd9fe49c112a204c8c8694db4182e78b2a5af490b1ae" -dependencies = [ - "bitflags", - "cairo-rs", - "cc", - "cocoa", - "core-foundation", - "core-graphics", - "crossbeam-channel", - "dispatch", - "gdk", - "gdk-pixbuf", - "gdk-sys", - "gdkx11-sys", - "gio", - "glib", - "glib-sys", - "gtk", - "image", - "instant", - "jni 0.19.0", - "lazy_static", - "libc", - "log", - "ndk", - "ndk-context", - "ndk-sys", - "objc", - "once_cell", - "parking_lot", - "paste", - "png", - "raw-window-handle", - "scopeguard", - "serde", - "unicode-segmentation", - "uuid 1.2.2", - "windows 0.37.0", - "windows-implement 0.37.0", - "x11-dl", -] - -[[package]] -name = "tar" -version = "0.4.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b55807c0344e1e6c04d7c965f5289c39a8d94ae23ed5c0b57aabac549f871c6" -dependencies = [ - "filetime", - "libc", - "xattr", -] - -[[package]] -name = "tauri" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b63a5d3a76d114e252eeebda97e2affba0943b6e1fa7e49a88ebb520aefcb21b" -dependencies = [ - "anyhow", - "cocoa", - "dirs-next", - "embed_plist", - "flate2", - "futures", - "futures-lite", - "glib", - "glob", - "gtk", - "heck 0.4.0", - "http", - "ignore", - "objc", - "once_cell", - "percent-encoding", - "rand 0.8.4", - "raw-window-handle", - "semver 1.0.4", - "serde", - "serde_json", - "serde_repr", - "serialize-to-javascript", - "state", - "tar", - "tauri-macros", - "tauri-runtime", - "tauri-runtime-wry", - "tauri-utils", - "tempfile", - "thiserror", - "tokio", - "url", - "uuid 1.2.2", - "webkit2gtk", - "webview2-com", - "windows 0.37.0", -] - -[[package]] -name = "tauri-build" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8807c85d656b2b93927c19fe5a5f1f1f348f96c2de8b90763b3c2d561511f9b4" -dependencies = [ - "anyhow", - "cargo_toml", - "heck 0.4.0", - "json-patch", - "semver 1.0.4", - "serde_json", - "tauri-utils", - "winres", -] - -[[package]] -name = "tauri-codegen" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14388d484b6b1b5dc0f6a7d6cc6433b3b230bec85eaa576adcdf3f9fafa49251" -dependencies = [ - "base64", - "brotli", - "ico", - "json-patch", - "plist", - "png", - "proc-macro2", - "quote", - "semver 1.0.4", - "serde", - "serde_json", - "sha2", - "tauri-utils", - "thiserror", - "time", - "uuid 1.2.2", - "walkdir", -] - -[[package]] -name = "tauri-macros" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "069319e5ecbe653a799b94b0690d9f9bf5d00f7b1d3989aa331c524d4e354075" -dependencies = [ - "heck 0.4.0", - "proc-macro2", - "quote", - "syn", - "tauri-codegen", - "tauri-utils", -] - -[[package]] -name = "tauri-plugin-websocket" -version = "0.1.0" -dependencies = [ - "futures-util", - "log", - "rand 0.8.4", - "serde", - "serde_json", - "tauri", - "thiserror", - "tokio", - "tokio-tungstenite", -] - -[[package]] -name = "tauri-runtime" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4cff3b4d9469727fa2107c4b3d2eda110df1ba45103fb420178e536362fae4" -dependencies = [ - "gtk", - "http", - "http-range", - "infer", - "raw-window-handle", - "serde", - "serde_json", - "tauri-utils", - "thiserror", - "uuid 1.2.2", - "webview2-com", - "windows 0.37.0", -] - -[[package]] -name = "tauri-runtime-wry" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fa8c4edaf01d8b556e7172c844b1b4dd3399adcd1a606bd520fc3e65f698546" -dependencies = [ - "cocoa", - "gtk", - "percent-encoding", - "rand 0.8.4", - "raw-window-handle", - "tauri-runtime", - "tauri-utils", - "uuid 1.2.2", - "webkit2gtk", - "webview2-com", - "windows 0.37.0", - "wry", -] - -[[package]] -name = "tauri-utils" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5abbc109a6eb45127956ffcc26ef0e875d160150ac16cfa45d26a6b2871686f1" -dependencies = [ - "brotli", - "ctor", - "glob", - "heck 0.4.0", - "html5ever", - "infer", - "json-patch", - "kuchiki", - "memchr", - "phf 0.10.0", - "proc-macro2", - "quote", - "semver 1.0.4", - "serde", - "serde_json", - "serde_with", - "thiserror", - "url", - "walkdir", - "windows 0.39.0", -] - -[[package]] -name = "tempfile" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dac1c663cfc93810f88aed9b8941d48cabf856a1b111c29a40439018d870eb22" -dependencies = [ - "cfg-if", - "libc", - "rand 0.8.4", - "redox_syscall", - "remove_dir_all", - "winapi", -] - -[[package]] -name = "tendril" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9ef557cb397a4f0a5a3a628f06515f78563f2209e64d47055d9dc6052bf5e33" -dependencies = [ - "futf", - "mac", - "utf-8", -] - -[[package]] -name = "thin-slice" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaa81235c7058867fa8c0e7314f33dcce9c215f535d1913822a2b3f5e289f3c" - -[[package]] -name = "thiserror" -version = "1.0.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "854babe52e4df1653706b98fcfc05843010039b406875930a70e4d9644e5c417" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa32fd3f627f367fe16f893e2597ae3c05020f8bba2666a4e6ea73d377e5714b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "thread_local" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8018d24e04c95ac8790716a5987d0fec4f8b27249ffa0f7d33f1369bdfb88cbd" -dependencies = [ - "once_cell", -] - -[[package]] -name = "time" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a561bf4617eebd33bca6434b988f39ed798e527f51a1e797d0ee4f61c0a38376" -dependencies = [ - "itoa 1.0.1", - "serde", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd" - -[[package]] -name = "time-macros" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d967f99f534ca7e495c575c62638eebc2898a8c84c119b89e250477bc4ba16b2" -dependencies = [ - "time-core", -] - -[[package]] -name = "tinyvec" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "848a1e1181b9f6753b5e96a092749e29b11d19ede67dfbbd6c7dc7e0f49b5338" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c" - -[[package]] -name = "tokio" -version = "1.27.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0de47a4eecbe11f498978a9b29d792f0d2692d1dd003650c24c76510e3bc001" -dependencies = [ - "autocfg", - "bytes", - "libc", - "mio", - "num_cpus", - "pin-project-lite", - "socket2", - "windows-sys 0.45.0", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7d995660bd2b7f8c1568414c1126076c13fbb725c40112dc0120b78eb9b717b" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-tungstenite" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54319c93411147bced34cb5609a80e0a8e44c5999c93903a81cd866630ec0bfd" -dependencies = [ - "futures-util", - "log", - "native-tls", - "tokio", - "tokio-native-tls", - "tungstenite", -] - -[[package]] -name = "toml" -version = "0.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a31142970826733df8241ef35dc040ef98c679ab14d7c3e54d827099b3acecaa" -dependencies = [ - "serde", -] - -[[package]] -name = "treediff" -version = "3.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "761e8d5ad7ce14bb82b7e61ccc0ca961005a275a060b9644a2431aa11553c2ff" -dependencies = [ - "serde_json", -] - -[[package]] -name = "tungstenite" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30ee6ab729cd4cf0fd55218530c4522ed30b7b6081752839b68fcec8d0960788" -dependencies = [ - "base64", - "byteorder", - "bytes", - "http", - "httparse", - "log", - "native-tls", - "rand 0.8.4", - "sha1", - "thiserror", - "url", - "utf-8", -] - -[[package]] -name = "typenum" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" - -[[package]] -name = "ucd-trie" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56dee185309b50d1f11bfedef0fe6d036842e3fb77413abef29f8f8d1c5d4c1c" - -[[package]] -name = "unicode-bidi" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eeb8be209bb1c96b7c177c7420d26e04eccacb0eeae6b980e35fcb74678107e0" -dependencies = [ - "matches", -] - -[[package]] -name = "unicode-ident" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84a22b9f218b40614adcb3f4ff08b703773ad44fa9423e4e0d346d5db86e4ebc" - -[[package]] -name = "unicode-normalization" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d54590932941a9e9266f0832deed84ebe1bf2e4c9e4a3554d393d18f5e854bf9" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fdbf052a0783de01e944a6ce7a8cb939e295b1e7be835a1112c3b9a7f047a5a" - -[[package]] -name = "url" -version = "2.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507c383b2d33b5fc35d1861e77e6b383d158b2da5e14fe51b83dfedf6fd578c" -dependencies = [ - "form_urlencoded", - "idna", - "matches", - "percent-encoding", - "serde", -] - -[[package]] -name = "utf-8" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" - -[[package]] -name = "uuid" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7" - -[[package]] -name = "uuid" -version = "1.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "422ee0de9031b5b948b97a8fc04e3aa35230001a722ddd27943e0be31564ce4c" -dependencies = [ - "getrandom 0.2.3", -] - -[[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.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c18c859eead79d8b95d09e4678566e8d70105c4e7b251f707a03df32442661b" - -[[package]] -name = "version-compare" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe88247b92c1df6b6de80ddc290f3976dbdf2f5f5d3fd049a9fb598c6dd5ca73" - -[[package]] -name = "version_check" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5fecdca9a5291cc2b8dcf7dc02453fee791a280f3743cb0905f8822ae463b3fe" - -[[package]] -name = "waker-fn" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d5b2c62b4012a3e1eca5a7e077d13b3bf498c4073e33ccd58626607748ceeca" - -[[package]] -name = "walkdir" -version = "2.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "808cf2735cd4b6866113f648b791c6adc5714537bc222d9347bb203386ffda56" -dependencies = [ - "same-file", - "winapi", - "winapi-util", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.10.2+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd6fbd9a79829dd1ad0cc20627bf1ed606756a7f77edff7b66b7064f9cb327c6" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "webkit2gtk" -version = "0.18.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8f859735e4a452aeb28c6c56a852967a8a76c8eb1cc32dbf931ad28a13d6370" -dependencies = [ - "bitflags", - "cairo-rs", - "gdk", - "gdk-sys", - "gio", - "gio-sys", - "glib", - "glib-sys", - "gobject-sys", - "gtk", - "gtk-sys", - "javascriptcore-rs", - "libc", - "once_cell", - "soup2", - "webkit2gtk-sys", -] - -[[package]] -name = "webkit2gtk-sys" -version = "0.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d76ca6ecc47aeba01ec61e480139dda143796abcae6f83bcddf50d6b5b1dcf3" -dependencies = [ - "atk-sys", - "bitflags", - "cairo-sys-rs", - "gdk-pixbuf-sys", - "gdk-sys", - "gio-sys", - "glib-sys", - "gobject-sys", - "gtk-sys", - "javascriptcore-rs-sys", - "libc", - "pango-sys", - "pkg-config", - "soup2-sys", - "system-deps 6.0.1", -] - -[[package]] -name = "webview2-com" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a489a9420acabb3c2ed0434b6f71f6b56b9485ec32665a28dec1ee186d716e0f" -dependencies = [ - "webview2-com-macros", - "webview2-com-sys", - "windows 0.37.0", - "windows-implement 0.37.0", -] - -[[package]] -name = "webview2-com-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaebe196c01691db62e9e4ca52c5ef1e4fd837dcae27dae3ada599b5a8fd05ac" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "webview2-com-sys" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0258c53ee9adc0a4f8ba1c8c317588f7a58c7048a55b621d469ba75ab3709ca1" -dependencies = [ - "regex", - "serde", - "serde_json", - "thiserror", - "windows 0.37.0", - "windows-bindgen", -] - -[[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.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" -dependencies = [ - "winapi", -] - -[[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 = "windows" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57b543186b344cc61c85b5aab0d2e3adf4e0f99bc076eff9aa5927bcc0b8a647" -dependencies = [ - "windows-implement 0.37.0", - "windows_aarch64_msvc 0.37.0", - "windows_i686_gnu 0.37.0", - "windows_i686_msvc 0.37.0", - "windows_x86_64_gnu 0.37.0", - "windows_x86_64_msvc 0.37.0", -] - -[[package]] -name = "windows" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1c4bd0a50ac6020f65184721f758dba47bb9fbc2133df715ec74a237b26794a" -dependencies = [ - "windows-implement 0.39.0", - "windows_aarch64_msvc 0.39.0", - "windows_i686_gnu 0.39.0", - "windows_i686_msvc 0.39.0", - "windows_x86_64_gnu 0.39.0", - "windows_x86_64_msvc 0.39.0", -] - -[[package]] -name = "windows-bindgen" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bed7be31ade0af08fec9b5343e9edcc005d22b1f11859b8a59b24797f5858e8" -dependencies = [ - "windows-metadata", - "windows-tokens 0.37.0", -] - -[[package]] -name = "windows-implement" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67a1062e555f7d9d66fd1130ed4f7c6ec41a47529ee0850cd0e926d95b26bb14" -dependencies = [ - "syn", - "windows-tokens 0.37.0", -] - -[[package]] -name = "windows-implement" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba01f98f509cb5dc05f4e5fc95e535f78260f15fea8fe1a8abdd08f774f1cee7" -dependencies = [ - "syn", - "windows-tokens 0.39.0", -] - -[[package]] -name = "windows-metadata" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f33f2b90a6664e369c41ab5ff262d06f048fc9685d9bf8a0e99a47750bb0463" - -[[package]] -name = "windows-sys" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" -dependencies = [ - "windows_aarch64_gnullvm", - "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", - "windows_x86_64_msvc 0.42.2", -] - -[[package]] -name = "windows-sys" -version = "0.45.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" -dependencies = [ - "windows-targets", -] - -[[package]] -name = "windows-targets" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" -dependencies = [ - "windows_aarch64_gnullvm", - "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", - "windows_x86_64_msvc 0.42.2", -] - -[[package]] -name = "windows-tokens" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3263d25f1170419995b78ff10c06b949e8a986c35c208dc24333c64753a87169" - -[[package]] -name = "windows-tokens" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f838de2fe15fe6bac988e74b798f26499a8b21a9d97edec321e79b28d1d7f597" - -[[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_msvc" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2623277cb2d1c216ba3b578c0f3cf9cdebeddb6e66b1b218bb33596ea7769c3a" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec7711666096bd4096ffa835238905bb33fb87267910e154b18b44eaabb340f2" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" - -[[package]] -name = "windows_i686_gnu" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3925fd0b0b804730d44d4b6278c50f9699703ec49bcd628020f46f4ba07d9e1" - -[[package]] -name = "windows_i686_gnu" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "763fc57100a5f7042e3057e7e8d9bdd7860d330070251a73d003563a3bb49e1b" - -[[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_msvc" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce907ac74fe331b524c1298683efbf598bb031bc84d5e274db2083696d07c57c" - -[[package]] -name = "windows_i686_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7bc7cbfe58828921e10a9f446fcaaf649204dcfe6c1ddd712c5eebae6bda1106" - -[[package]] -name = "windows_i686_msvc" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2babfba0828f2e6b32457d5341427dcbb577ceef556273229959ac23a10af33d" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6868c165637d653ae1e8dc4d82c25d4f97dd6605eaa8d784b5c6e0ab2a252b65" - -[[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_gnullvm" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.37.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4dd6dc7df2d84cf7b33822ed5b86318fb1781948e9663bacd047fc9dd52259d" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.39.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e4d40883ae9cae962787ca76ba76390ffa29214667a111db9e0a1ad8377e809" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" - -[[package]] -name = "winres" -version = "0.1.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff4fb510bbfe5b8992ff15f77a2e6fe6cf062878f0eda00c0f44963a807ca5dc" -dependencies = [ - "toml", -] - -[[package]] -name = "wry" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce19dddbd3ce01dc8f14eb6d4c8f914123bf8379aaa838f6da4f981ff7104a3f" -dependencies = [ - "block", - "cocoa", - "core-graphics", - "gdk", - "gio", - "glib", - "gtk", - "http", - "jni 0.18.0", - "libc", - "log", - "objc", - "objc_id", - "once_cell", - "serde", - "serde_json", - "tao", - "thiserror", - "url", - "webkit2gtk", - "webkit2gtk-sys", - "webview2-com", - "windows 0.37.0", - "windows-implement 0.37.0", -] - -[[package]] -name = "x11" -version = "2.19.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6dd0565fa8bfba8c5efe02725b14dff114c866724eff2cfd44d76cea74bcd87a" -dependencies = [ - "libc", - "pkg-config", -] - -[[package]] -name = "x11-dl" -version = "2.20.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1536d6965a5d4e573c7ef73a2c15ebcd0b2de3347bdf526c34c297c00ac40f0" -dependencies = [ - "lazy_static", - "libc", - "pkg-config", -] - -[[package]] -name = "xattr" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "244c3741f4240ef46274860397c7c74e50eb23624996930e484c16679633a54c" -dependencies = [ - "libc", -] - -[[package]] -name = "xml-rs" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2d7d3948613f75c98fd9328cfdcc45acc4d360655289d0a7d4ec931392200a3" diff --git a/plugins/websocket/examples/svelte-app/src-tauri/Cargo.toml b/plugins/websocket/examples/svelte-app/src-tauri/Cargo.toml index 307d58ef..b746e808 100644 --- a/plugins/websocket/examples/svelte-app/src-tauri/Cargo.toml +++ b/plugins/websocket/examples/svelte-app/src-tauri/Cargo.toml @@ -13,7 +13,7 @@ tauri = { version = "2.0.0-alpha.8", features = [] } tokio = { version = "1", features = ["net"] } futures-util = "0.3" tauri-plugin-websocket = { path = "../../../" } -tokio-tungstenite = "0.18" +tokio-tungstenite = "0.19" [build-dependencies] tauri-build = { version = "2.0.0-alpha.4", features = [] } diff --git a/plugins/websocket/examples/svelte-app/src-tauri/build.rs b/plugins/websocket/examples/svelte-app/src-tauri/build.rs index 795b9b7c..b055ec37 100644 --- a/plugins/websocket/examples/svelte-app/src-tauri/build.rs +++ b/plugins/websocket/examples/svelte-app/src-tauri/build.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + fn main() { tauri_build::build() } diff --git a/plugins/websocket/examples/svelte-app/src-tauri/src/main.rs b/plugins/websocket/examples/svelte-app/src-tauri/src/main.rs index d71d3109..8858da82 100644 --- a/plugins/websocket/examples/svelte-app/src-tauri/src/main.rs +++ b/plugins/websocket/examples/svelte-app/src-tauri/src/main.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + #![cfg_attr( all(not(debug_assertions), target_os = "windows"), windows_subsystem = "windows" diff --git a/plugins/websocket/examples/svelte-app/src-tauri/tauri.conf.json b/plugins/websocket/examples/svelte-app/src-tauri/tauri.conf.json index 1f14e4f3..3321f62d 100644 --- a/plugins/websocket/examples/svelte-app/src-tauri/tauri.conf.json +++ b/plugins/websocket/examples/svelte-app/src-tauri/tauri.conf.json @@ -33,9 +33,6 @@ "exceptionDomain": "" } }, - "allowlist": { - "all": false - }, "windows": [ { "title": "Tauri App", diff --git a/plugins/websocket/examples/svelte-app/src/app.d.ts b/plugins/websocket/examples/svelte-app/src/app.d.ts index 1cea0dcf..caf34f1d 100644 --- a/plugins/websocket/examples/svelte-app/src/app.d.ts +++ b/plugins/websocket/examples/svelte-app/src/app.d.ts @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + // See https://kit.svelte.dev/docs/types#app // for information about these interfaces // and what to do when importing types diff --git a/plugins/websocket/examples/svelte-app/src/routes/+page.svelte b/plugins/websocket/examples/svelte-app/src/routes/+page.svelte index 26e53cb0..d41d6389 100644 --- a/plugins/websocket/examples/svelte-app/src/routes/+page.svelte +++ b/plugins/websocket/examples/svelte-app/src/routes/+page.svelte @@ -1,35 +1,44 @@
- - - + + +
{@html response}
diff --git a/plugins/websocket/examples/svelte-app/svelte.config.js b/plugins/websocket/examples/svelte-app/svelte.config.js index 998c3647..af7cb8a9 100644 --- a/plugins/websocket/examples/svelte-app/svelte.config.js +++ b/plugins/websocket/examples/svelte-app/svelte.config.js @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import adapter from "@sveltejs/adapter-auto"; import { vitePreprocess } from "@sveltejs/kit/vite"; diff --git a/plugins/websocket/examples/svelte-app/vite.config.ts b/plugins/websocket/examples/svelte-app/vite.config.ts index efc8757f..2b08f961 100644 --- a/plugins/websocket/examples/svelte-app/vite.config.ts +++ b/plugins/websocket/examples/svelte-app/vite.config.ts @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import { sveltekit } from "@sveltejs/kit/vite"; import type { UserConfig } from "vite"; diff --git a/plugins/websocket/guest-js/index.ts b/plugins/websocket/guest-js/index.ts index 9dc5b4d8..5fd967b4 100644 --- a/plugins/websocket/guest-js/index.ts +++ b/plugins/websocket/guest-js/index.ts @@ -1,4 +1,15 @@ -import { invoke, transformCallback } from "@tauri-apps/api/tauri"; +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + __TAURI__: { + transformCallback: (cb: (payload: T) => void) => number; + }; + } +} export interface MessageKind { type: T; @@ -32,11 +43,13 @@ export default class WebSocket { listeners.forEach((l) => l(message)); }; - return await invoke("plugin:websocket|connect", { - url, - callbackFunction: transformCallback(handler), - options, - }).then((id) => new WebSocket(id, listeners)); + return await window + .__TAURI_INVOKE__("plugin:websocket|connect", { + url, + callbackFunction: window.__TAURI__.transformCallback(handler), + options, + }) + .then((id) => new WebSocket(id, listeners)); } addListener(cb: (arg: Message) => void): void { @@ -56,7 +69,7 @@ export default class WebSocket { "invalid `message` type, expected a `{ type: string, data: any }` object, a string or a numeric array" ); } - return await invoke("plugin:websocket|send", { + return await window.__TAURI_INVOKE__("plugin:websocket|send", { id: this.id, message: m, }); diff --git a/plugins/websocket/package.json b/plugins/websocket/package.json index dab28b37..7cc1628b 100644 --- a/plugins/websocket/package.json +++ b/plugins/websocket/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-websocket-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-websocket", + "version": "2.0.0-alpha.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/websocket/src/api-iife.js b/plugins/websocket/src/api-iife.js new file mode 100644 index 00000000..cea3c830 --- /dev/null +++ b/plugins/websocket/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_WEBSOCKET__=function(){"use strict";class e{constructor(e,t){this.id=e,this.listeners=t}static async connect(t,n){const i=[];return await window.__TAURI_INVOKE__("plugin:websocket|connect",{url:t,callbackFunction:window.__TAURI__.transformCallback((e=>{i.forEach((t=>t(e)))})),options:n}).then((t=>new e(t,i)))}addListener(e){this.listeners.push(e)}async send(e){let t;if("string"==typeof e)t={type:"Text",data:e};else if("object"==typeof e&&"type"in e)t=e;else{if(!Array.isArray(e))throw new Error("invalid `message` type, expected a `{ type: string, data: any }` object, a string or a numeric array");t={type:"Binary",data:e}}return await window.__TAURI_INVOKE__("plugin:websocket|send",{id:this.id,message:t})}async disconnect(){return await this.send({type:"Close",data:{code:1e3,reason:"Disconnected by client"}})}}return e}();Object.defineProperty(window.__TAURI__,"websocket",{value:__TAURI_WEBSOCKET__})} diff --git a/plugins/websocket/src/lib.rs b/plugins/websocket/src/lib.rs index b61f2537..a3b94136 100644 --- a/plugins/websocket/src/lib.rs +++ b/plugins/websocket/src/lib.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use futures_util::{stream::SplitSink, SinkExt, StreamExt}; use serde::{ser::Serializer, Deserialize, Serialize}; use tauri::{ @@ -86,7 +90,7 @@ async fn connect( config: Option, ) -> Result { let id = rand::random(); - let (ws_stream, _) = connect_async_with_config(url, config.map(Into::into)).await?; + let (ws_stream, _) = connect_async_with_config(url, config.map(Into::into), false).await?; tauri::async_runtime::spawn(async move { let (write, read) = ws_stream.split(); @@ -161,6 +165,7 @@ async fn send( pub fn init() -> TauriPlugin { PluginBuilder::new("websocket") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![connect, send]) .setup(|app, _api| { app.manage(ConnectionManager::default()); diff --git a/plugins/websocket/tsconfig.json b/plugins/websocket/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/websocket/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/websocket/tsconfig.json b/plugins/websocket/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/websocket/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/window-state/CHANGELOG.md b/plugins/window-state/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/window-state/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/window-state/Cargo.toml b/plugins/window-state/Cargo.toml index 19693f36..b1f6c802 100644 --- a/plugins/window-state/Cargo.toml +++ b/plugins/window-state/Cargo.toml @@ -1,19 +1,17 @@ [package] name = "tauri-plugin-window-state" -version = "0.1.0" +version = "2.0.0-alpha.0" description = "Save window positions and sizes and restore them when the app is reopened." -authors.workspace = true -license.workspace = true -edition.workspace = true -rust-version.workspace = true - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +authors = { workspace = true } +license = { workspace = true } +edition = { workspace = true } +rust-version = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } bincode = "1.3" bitflags = "2" diff --git a/plugins/window-state/README.md b/plugins/window-state/README.md index 710270a3..ea03f8e2 100644 --- a/plugins/window-state/README.md +++ b/plugins/window-state/README.md @@ -4,7 +4,7 @@ Save window positions and sizes and restore them when the app is reopened. ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,6 +18,8 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] +tauri-plugin-window-state = "2.0.0-alpha" +# alternatively with Git: tauri-plugin-window-state = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` @@ -26,6 +28,13 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh +pnpm add @tauri-apps/plugin-window-state +# or +npm add @tauri-apps/plugin-window-state +# or +yarn add @tauri-apps/plugin-window-state + +# alternatively with Git: pnpm add https://github.com/tauri-apps/tauri-plugin-window-state#v2 # or npm add https://github.com/tauri-apps/tauri-plugin-window-state#v2 @@ -62,7 +71,7 @@ app.save_window_state(StateFlags::all()); // will save the state of all open win or through Javascript ```javascript -import { saveWindowState, StateFlags } from "tauri-plugin-window-state-api"; +import { saveWindowState, StateFlags } from "@tauri-apps/plugin-window-state"; saveWindowState(StateFlags.ALL); ``` @@ -79,7 +88,10 @@ window.restore_state(StateFlags::all()); // will restore the windows state from or through Javascript ```javascript -import { restoreStateCurrent, StateFlags } from "tauri-plugin-window-state-api"; +import { + restoreStateCurrent, + StateFlags, +} from "@tauri-apps/plugin-window-state"; restoreStateCurrent(StateFlags.ALL); ``` diff --git a/plugins/window-state/guest-js/index.ts b/plugins/window-state/guest-js/index.ts index 11ead0f4..31d88f9a 100644 --- a/plugins/window-state/guest-js/index.ts +++ b/plugins/window-state/guest-js/index.ts @@ -1,5 +1,25 @@ -import { invoke } from "@tauri-apps/api/tauri"; -import { WindowLabel, getCurrent } from "@tauri-apps/api/window"; +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} + +interface WindowDef { + label: string; +} + +declare global { + interface Window { + __TAURI_METADATA__: { + __windows: WindowDef[]; + __currentWindow: WindowDef; + }; + } +} export enum StateFlags { SIZE = 1 << 0, @@ -14,22 +34,27 @@ export enum StateFlags { /** * Save the state of all open windows to disk. */ -async function saveWindowState(flags: StateFlags) { - invoke("plugin:window-state|save_window_state", { flags }); +async function saveWindowState(flags: StateFlags): Promise { + return window.__TAURI_INVOKE__("plugin:window-state|save_window_state", { + flags, + }); } /** * Restore the state for the specified window from disk. */ -async function restoreState(label: WindowLabel, flags: StateFlags) { - invoke("plugin:window-state|restore_state", { label, flags }); +async function restoreState(label: string, flags: StateFlags): Promise { + return window.__TAURI_INVOKE__("plugin:window-state|restore_state", { + label, + flags, + }); } /** * Restore the state for the current window from disk. */ -async function restoreStateCurrent(flags: StateFlags) { - restoreState(getCurrent().label, flags); +async function restoreStateCurrent(flags: StateFlags): Promise { + return restoreState(window.__TAURI_METADATA__.__currentWindow.label, flags); } export { restoreState, restoreStateCurrent, saveWindowState }; diff --git a/plugins/window-state/package.json b/plugins/window-state/package.json index f7938586..060ae802 100644 --- a/plugins/window-state/package.json +++ b/plugins/window-state/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-window-state-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-window-state", + "version": "2.0.0-alpha.0", "description": "Save window positions and sizes and restore them when the app is reopened.", "license": "MIT or APACHE-2.0", "authors": [ @@ -28,6 +28,6 @@ "tslib": "^2.5.0" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/plugins/window-state/src/api-iife.js b/plugins/window-state/src/api-iife.js new file mode 100644 index 00000000..3ded95ac --- /dev/null +++ b/plugins/window-state/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_WINDOWSTATE__=function(t){"use strict";var _;async function e(t,_){return window.__TAURI_INVOKE__("plugin:window-state|restore_state",{label:t,flags:_})}return t.StateFlags=void 0,(_=t.StateFlags||(t.StateFlags={}))[_.SIZE=1]="SIZE",_[_.POSITION=2]="POSITION",_[_.MAXIMIZED=4]="MAXIMIZED",_[_.VISIBLE=8]="VISIBLE",_[_.DECORATIONS=16]="DECORATIONS",_[_.FULLSCREEN=32]="FULLSCREEN",_[_.ALL=63]="ALL",t.restoreState=e,t.restoreStateCurrent=async function(t){return e(window.__TAURI_METADATA__.__currentWindow.label,t)},t.saveWindowState=async function(t){return window.__TAURI_INVOKE__("plugin:window-state|save_window_state",{flags:t})},t}({});Object.defineProperty(window.__TAURI__,"windowState",{value:__TAURI_WINDOWSTATE__})} diff --git a/plugins/window-state/src/cmd.rs b/plugins/window-state/src/cmd.rs index 65690db4..17486505 100644 --- a/plugins/window-state/src/cmd.rs +++ b/plugins/window-state/src/cmd.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use crate::{AppHandleExt, StateFlags, WindowExt}; use tauri::{command, AppHandle, Manager, Runtime}; diff --git a/plugins/window-state/src/lib.rs b/plugins/window-state/src/lib.rs index 3eaf4c52..fa88be3b 100644 --- a/plugins/window-state/src/lib.rs +++ b/plugins/window-state/src/lib.rs @@ -1,7 +1,9 @@ -// Copyright 2021 Tauri Programme within The Commons Conservancy +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy // SPDX-License-Identifier: Apache-2.0 // SPDX-License-Identifier: MIT +#![cfg(not(any(target_os = "android", target_os = "ios")))] + use bitflags::bitflags; use serde::{Deserialize, Serialize}; use tauri::{ @@ -53,7 +55,7 @@ impl Default for StateFlags { } } -#[derive(Debug, Default, Deserialize, Serialize, PartialEq)] +#[derive(Debug, Deserialize, Serialize, PartialEq)] struct WindowState { width: f64, height: f64, @@ -65,6 +67,21 @@ struct WindowState { fullscreen: bool, } +impl Default for WindowState { + fn default() -> Self { + Self { + width: Default::default(), + height: Default::default(), + x: Default::default(), + y: Default::default(), + maximized: Default::default(), + visible: true, + decorated: true, + fullscreen: Default::default(), + } + } +} + struct WindowStateCache(Arc>>); pub trait AppHandleExt { /// Saves all open windows state to disk @@ -175,7 +192,7 @@ impl WindowExt for Window { } if flags.contains(StateFlags::DECORATIONS) { - metadata.visible = self.is_visible()?; + metadata.decorated = self.is_decorated()?; } if flags.contains(StateFlags::FULLSCREEN) { @@ -280,6 +297,7 @@ impl Builder { pub fn build(self) -> TauriPlugin { let flags = self.state_flags; PluginBuilder::new("window-state") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![ cmd::save_window_state, cmd::restore_state diff --git a/plugins/window-state/tsconfig.json b/plugins/window-state/tsconfig.json deleted file mode 120000 index 7cd38da8..00000000 --- a/plugins/window-state/tsconfig.json +++ /dev/null @@ -1 +0,0 @@ -../../shared/tsconfig.json \ No newline at end of file diff --git a/plugins/window-state/tsconfig.json b/plugins/window-state/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/window-state/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/plugins/window/CHANGELOG.md b/plugins/window/CHANGELOG.md new file mode 100644 index 00000000..a70b10ec --- /dev/null +++ b/plugins/window/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## \[2.0.0-alpha.0] + +- [`717ae67`](https://github.com/tauri-apps/plugins-workspace/commit/717ae670978feb4492fac1f295998b93f2b9347f)([#371](https://github.com/tauri-apps/plugins-workspace/pull/371)) First v2 alpha release! diff --git a/plugins/window/Cargo.toml b/plugins/window/Cargo.toml new file mode 100644 index 00000000..7e52814d --- /dev/null +++ b/plugins/window/Cargo.toml @@ -0,0 +1,17 @@ +[package] +name = "tauri-plugin-window" +version = "2.0.0-alpha.0" +description = "Interact with the Tauri window." +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } + +[dependencies] +tauri = { workspace = true } +serde = { workspace = true } +thiserror = { workspace = true } + +[features] +icon-png = [ "tauri/icon-png" ] +icon-ico = [ "tauri/icon-ico" ] +devtools = [ ] diff --git a/plugins/window/LICENSE.spdx b/plugins/window/LICENSE.spdx new file mode 100644 index 00000000..cdd0df5a --- /dev/null +++ b/plugins/window/LICENSE.spdx @@ -0,0 +1,20 @@ +SPDXVersion: SPDX-2.1 +DataLicense: CC0-1.0 +PackageName: tauri +DataFormat: SPDXRef-1 +PackageSupplier: Organization: The Tauri Programme in the Commons Conservancy +PackageHomePage: https://tauri.app +PackageLicenseDeclared: Apache-2.0 +PackageLicenseDeclared: MIT +PackageCopyrightText: 2019-2022, The Tauri Programme in the Commons Conservancy +PackageSummary: Tauri is a rust project that enables developers to make secure +and small desktop applications using a web frontend. + +PackageComment: The package includes the following libraries; see +Relationship information. + +Created: 2019-05-20T09:00:00Z +PackageDownloadLocation: git://github.com/tauri-apps/tauri +PackageDownloadLocation: git+https://github.com/tauri-apps/tauri.git +PackageDownloadLocation: git+ssh://github.com/tauri-apps/tauri.git +Creator: Person: Daniel Thompson-Yvetot \ No newline at end of file diff --git a/plugins/window/LICENSE_APACHE-2.0 b/plugins/window/LICENSE_APACHE-2.0 new file mode 100644 index 00000000..4947287f --- /dev/null +++ b/plugins/window/LICENSE_APACHE-2.0 @@ -0,0 +1,177 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS \ No newline at end of file diff --git a/plugins/window/LICENSE_MIT b/plugins/window/LICENSE_MIT new file mode 100644 index 00000000..4d754725 --- /dev/null +++ b/plugins/window/LICENSE_MIT @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2017 - Present Tauri Apps Contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/plugins/window/README.md b/plugins/window/README.md new file mode 100644 index 00000000..14e7c8a8 --- /dev/null +++ b/plugins/window/README.md @@ -0,0 +1,87 @@ +# Window + +Interact with the Tauri window. + +## Install + +_This plugin requires a Rust version of at least **1.65**_ + +There are three general methods of installation that we can recommend. + +1. Use crates.io and npm (easiest, and requires you to trust that our publishing pipeline worked) +2. Pull sources directly from Github using git tags / revision hashes (most secure) +3. Git submodule install this repo in your tauri project and then use file protocol to ingest the source (most secure, but inconvenient to use) + +Install the Core plugin by adding the following to your `Cargo.toml` file: + +`src-tauri/Cargo.toml` + +```toml +[dependencies] +tauri-plugin-window = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-window = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +``` + +You can install the JavaScript Guest bindings using your preferred JavaScript package manager: + +> Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. + +```sh +pnpm add @tauri-apps/plugin-window +# or +npm add @tauri-apps/plugin-window +# or +yarn add @tauri-apps/plugin-window + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-window#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-window#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-window#v2 +``` + +## Usage + +First you need to register the core plugin with Tauri: + +`src-tauri/src/main.rs` + +```rust +fn main() { + tauri::Builder::default() + .plugin(tauri_plugin_window::init()) + .run(tauri::generate_context!()) + .expect("error while running tauri application"); +} +``` + +Afterwards all the plugin's APIs are available through the JavaScript guest bindings: + +```javascript +import { appWindow, WebviewWindow } from "@tauri-apps/plugin-window"; + +// manipulating this window +await appWindow.setResizable(false); + +// Creating new windows: +// loading embedded asset: +const webview = new WebviewWindow("theUniqueLabel", { + url: "path/to/page.html", +}); +// alternatively, load a remote URL: +const webview = new WebviewWindow("theUniqueLabel", { + url: "https://github.com/tauri-apps/tauri", +}); +``` + +## Contributing + +PRs accepted. Please make sure to read the Contributing Guide before making a pull request. + +## License + +Code: (c) 2015 - Present - The Tauri Programme within The Commons Conservancy. + +MIT or MIT/Apache 2.0 where applicable. diff --git a/plugins/window/build.rs b/plugins/window/build.rs new file mode 100644 index 00000000..0b339c43 --- /dev/null +++ b/plugins/window/build.rs @@ -0,0 +1,18 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +fn main() { + let target_os = std::env::var("CARGO_CFG_TARGET_OS").unwrap(); + let mobile = target_os == "ios" || target_os == "android"; + alias("desktop", !mobile); + alias("mobile", mobile); +} + +// creates a cfg alias if `has_feature` is true. +// `alias` must be a snake case string. +fn alias(alias: &str, has_feature: bool) { + if has_feature { + println!("cargo:rustc-cfg={alias}"); + } +} diff --git a/plugins/window/guest-js/event.ts b/plugins/window/guest-js/event.ts new file mode 100644 index 00000000..9ff16f1d --- /dev/null +++ b/plugins/window/guest-js/event.ts @@ -0,0 +1,107 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + __TAURI__: { + transformCallback: (cb: (payload: T) => void) => number; + }; + } +} + +export interface Event { + /** Event name */ + event: string; + /** The label of the window that emitted this event. */ + windowLabel: string; + /** Event identifier used to unlisten */ + id: number; + /** Event payload */ + payload: T; +} + +export type EventCallback = (event: Event) => void; + +export type UnlistenFn = () => void; + +/** + * Unregister the event listener associated with the given name and id. + * + * @ignore + * @param event The event name + * @param eventId Event identifier + * @returns + */ +async function _unlisten(event: string, eventId: number): Promise { + await window.__TAURI_INVOKE__("plugin:event|unlisten", { + event, + eventId, + }); +} + +/** + * Emits an event to the backend. + * + * @param event Event name. Must include only alphanumeric characters, `-`, `/`, `:` and `_`. + * @param [windowLabel] The label of the window to which the event is sent, if null/undefined the event will be sent to all windows + * @param [payload] Event payload + * @returns + */ +async function emit( + event: string, + windowLabel?: string, + payload?: unknown +): Promise { + await window.__TAURI_INVOKE__("plugin:event|emit", { + event, + windowLabel, + payload, + }); +} + +/** + * Listen to an event from the backend. + * + * @param event Event name. Must include only alphanumeric characters, `-`, `/`, `:` and `_`. + * @param handler Event handler callback. + * @return A promise resolving to a function to unlisten to the event. + */ +async function listen( + event: string, + windowLabel: string | null, + handler: EventCallback +): Promise { + return window + .__TAURI_INVOKE__("plugin:event|listen", { + event, + windowLabel, + handler: window.__TAURI__.transformCallback(handler), + }) + .then((eventId) => { + return async () => _unlisten(event, eventId); + }); +} + +/** + * Listen to an one-off event from the backend. + * + * @param event Event name. Must include only alphanumeric characters, `-`, `/`, `:` and `_`. + * @param handler Event handler callback. + * @returns A promise resolving to a function to unlisten to the event. + */ +async function once( + event: string, + windowLabel: string | null, + handler: EventCallback +): Promise { + return listen(event, windowLabel, (eventData) => { + handler(eventData); + _unlisten(event, eventData.id).catch(() => { + // do nothing + }); + }); +} + +export { emit, listen, once }; diff --git a/plugins/window/guest-js/index.ts b/plugins/window/guest-js/index.ts new file mode 100644 index 00000000..f1ae5e0d --- /dev/null +++ b/plugins/window/guest-js/index.ts @@ -0,0 +1,1985 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +/** + * Provides APIs to create windows, communicate with other windows and manipulate the current window. + * + * ## Window events + * + * Events can be listened to using `appWindow.listen`: + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * appWindow.listen("my-window-event", ({ event, payload }) => { }); + * ``` + * + * @module + */ + +import type { + Event, + EventName, + EventCallback, + UnlistenFn, +} from "@tauri-apps/api/event"; +import { TauriEvent } from "@tauri-apps/api/event"; +// TODO: use from @tauri-apps/api v2 +import { emit, listen, once } from "./event"; + +declare global { + interface Window { + __TAURI_INVOKE__: (cmd: string, args?: unknown) => Promise; + } +} + +type Theme = "light" | "dark"; +type TitleBarStyle = "visible" | "transparent" | "overlay"; + +/** + * Allows you to retrieve information about a given monitor. + * + * @since 2.0.0 + */ +interface Monitor { + /** Human-readable name of the monitor */ + name: string | null; + /** The monitor's resolution. */ + size: PhysicalSize; + /** the Top-left corner position of the monitor relative to the larger full screen area. */ + position: PhysicalPosition; + /** The scale factor that can be used to map physical pixels to logical pixels. */ + scaleFactor: number; +} + +/** + * The payload for the `scaleChange` event. + * + * @since 2.0.0 + */ +interface ScaleFactorChanged { + /** The new window scale factor. */ + scaleFactor: number; + /** The new window size */ + size: PhysicalSize; +} + +/** The file drop event types. */ +type FileDropEvent = + | { type: "hover"; paths: string[] } + | { type: "drop"; paths: string[] } + | { type: "cancel" }; + +/** + * A size represented in logical pixels. + * + * @since 2.0.0 + */ +class LogicalSize { + type = "Logical"; + width: number; + height: number; + + constructor(width: number, height: number) { + this.width = width; + this.height = height; + } +} + +/** + * A size represented in physical pixels. + * + * @since 2.0.0 + */ +class PhysicalSize { + type = "Physical"; + width: number; + height: number; + + constructor(width: number, height: number) { + this.width = width; + this.height = height; + } + + /** + * Converts the physical size to a logical one. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const factor = await appWindow.scaleFactor(); + * const size = await appWindow.innerSize(); + * const logical = size.toLogical(factor); + * ``` + * */ + toLogical(scaleFactor: number): LogicalSize { + return new LogicalSize(this.width / scaleFactor, this.height / scaleFactor); + } +} + +/** + * A position represented in logical pixels. + * + * @since 2.0.0 + */ +class LogicalPosition { + type = "Logical"; + x: number; + y: number; + + constructor(x: number, y: number) { + this.x = x; + this.y = y; + } +} + +/** + * A position represented in physical pixels. + * + * @since 2.0.0 + */ +class PhysicalPosition { + type = "Physical"; + x: number; + y: number; + + constructor(x: number, y: number) { + this.x = x; + this.y = y; + } + + /** + * Converts the physical position to a logical one. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const factor = await appWindow.scaleFactor(); + * const position = await appWindow.innerPosition(); + * const logical = position.toLogical(factor); + * ``` + * */ + toLogical(scaleFactor: number): LogicalPosition { + return new LogicalPosition(this.x / scaleFactor, this.y / scaleFactor); + } +} + +/** @ignore */ +interface WindowDef { + label: string; +} + +/** @ignore */ +declare global { + interface Window { + __TAURI_METADATA__: { + __windows: WindowDef[]; + __currentWindow: WindowDef; + }; + } +} + +/** + * Attention type to request on a window. + * + * @since 2.0.0 + */ +enum UserAttentionType { + /** + * #### Platform-specific + * - **macOS:** Bounces the dock icon until the application is in focus. + * - **Windows:** Flashes both the window and the taskbar button until the application is in focus. + */ + Critical = 1, + /** + * #### Platform-specific + * - **macOS:** Bounces the dock icon once. + * - **Windows:** Flashes the taskbar button until the application is in focus. + */ + Informational, +} + +export type CursorIcon = + | "default" + | "crosshair" + | "hand" + | "arrow" + | "move" + | "text" + | "wait" + | "help" + | "progress" + // something cannot be done + | "notAllowed" + | "contextMenu" + | "cell" + | "verticalText" + | "alias" + | "copy" + | "noDrop" + // something can be grabbed + | "grab" + /// something is grabbed + | "grabbing" + | "allScroll" + | "zoomIn" + | "zoomOut" + // edge is to be moved + | "eResize" + | "nResize" + | "neResize" + | "nwResize" + | "sResize" + | "seResize" + | "swResize" + | "wResize" + | "ewResize" + | "nsResize" + | "neswResize" + | "nwseResize" + | "colResize" + | "rowResize"; + +/** + * Get an instance of `WebviewWindow` for the current webview window. + * + * @since 2.0.0 + */ +function getCurrent(): WebviewWindow { + return new WebviewWindow(window.__TAURI_METADATA__.__currentWindow.label, { + // @ts-expect-error `skip` is not defined in the public API but it is handled by the constructor + skip: true, + }); +} + +/** + * Gets a list of instances of `WebviewWindow` for all available webview windows. + * + * @since 2.0.0 + */ +function getAll(): WebviewWindow[] { + return window.__TAURI_METADATA__.__windows.map( + (w) => + new WebviewWindow(w.label, { + // @ts-expect-error `skip` is not defined in the public API but it is handled by the constructor + skip: true, + }) + ); +} + +/** @ignore */ +// events that are emitted right here instead of by the created webview +const localTauriEvents = ["tauri://created", "tauri://error"]; +/** @ignore */ +export type WindowLabel = string; +/** + * A webview window handle allows emitting and listening to events from the backend that are tied to the window. + * + * @ignore + * @since 2.0.0 + */ +class WebviewWindowHandle { + /** The window label. It is a unique identifier for the window, can be used to reference it later. */ + label: WindowLabel; + /** Local event listeners. */ + // eslint-disable-next-line @typescript-eslint/no-explicit-any + listeners: Record>>; + + constructor(label: WindowLabel) { + this.label = label; + // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment + this.listeners = Object.create(null); + } + + /** + * Listen to an event emitted by the backend that is tied to the webview window. + * + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const unlisten = await appWindow.listen('state-changed', (event) => { + * console.log(`Got error: ${payload}`); + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @param event Event name. Must include only alphanumeric characters, `-`, `/`, `:` and `_`. + * @param handler Event handler. + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async listen( + event: EventName, + handler: EventCallback + ): Promise { + if (this._handleTauriEvent(event, handler)) { + return Promise.resolve(() => { + // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access, security/detect-object-injection + const listeners = this.listeners[event]; + listeners.splice(listeners.indexOf(handler), 1); + }); + } + return listen(event, this.label, handler); + } + + /** + * Listen to an one-off event emitted by the backend that is tied to the webview window. + * + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const unlisten = await appWindow.once('initialized', (event) => { + * console.log(`Window initialized!`); + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @param event Event name. Must include only alphanumeric characters, `-`, `/`, `:` and `_`. + * @param handler Event handler. + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async once(event: string, handler: EventCallback): Promise { + if (this._handleTauriEvent(event, handler)) { + return Promise.resolve(() => { + // eslint-disable-next-line security/detect-object-injection + const listeners = this.listeners[event]; + listeners.splice(listeners.indexOf(handler), 1); + }); + } + return once(event, this.label, handler); + } + + /** + * Emits an event to the backend, tied to the webview window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.emit('window-loaded', { loggedIn: true, token: 'authToken' }); + * ``` + * + * @param event Event name. Must include only alphanumeric characters, `-`, `/`, `:` and `_`. + * @param payload Event payload. + */ + async emit(event: string, payload?: unknown): Promise { + if (localTauriEvents.includes(event)) { + // eslint-disable-next-line + for (const handler of this.listeners[event] || []) { + handler({ event, id: -1, windowLabel: this.label, payload }); + } + return Promise.resolve(); + } + return emit(event, this.label, payload); + } + + /** @ignore */ + _handleTauriEvent(event: string, handler: EventCallback): boolean { + if (localTauriEvents.includes(event)) { + if (!(event in this.listeners)) { + // eslint-disable-next-line + this.listeners[event] = [handler]; + } else { + // eslint-disable-next-line + this.listeners[event].push(handler); + } + return true; + } + return false; + } +} + +/** + * Manage the current window object. + * + * @ignore + * @since 2.0.0 + */ +class WindowManager extends WebviewWindowHandle { + // Getters + /** + * The scale factor that can be used to map physical pixels to logical pixels. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const factor = await appWindow.scaleFactor(); + * ``` + * + * @returns The window's monitor scale factor. + * + * @since 2.0.0 + * */ + async scaleFactor(): Promise { + return window.__TAURI_INVOKE__("plugin:window|scale_factor", { + label: this.label, + }); + } + + /** + * The position of the top-left hand corner of the window's client area relative to the top-left hand corner of the desktop. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const position = await appWindow.innerPosition(); + * ``` + * + * @returns The window's inner position. + * + * @since 2.0.0 + * */ + async innerPosition(): Promise { + return window + .__TAURI_INVOKE__<{ x: number; y: number }>( + "plugin:window|inner_position", + { + label: this.label, + } + ) + .then(({ x, y }) => new PhysicalPosition(x, y)); + } + + /** + * The position of the top-left hand corner of the window relative to the top-left hand corner of the desktop. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const position = await appWindow.outerPosition(); + * ``` + * + * @returns The window's outer position. + * + * @since 2.0.0 + * */ + async outerPosition(): Promise { + return window + .__TAURI_INVOKE__<{ x: number; y: number }>( + "plugin:window|outer_position", + { + label: this.label, + } + ) + .then(({ x, y }) => new PhysicalPosition(x, y)); + } + + /** + * The physical size of the window's client area. + * The client area is the content of the window, excluding the title bar and borders. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const size = await appWindow.innerSize(); + * ``` + * + * @returns The window's inner size. + * + * @since 2.0.0 + */ + async innerSize(): Promise { + return window + .__TAURI_INVOKE__<{ width: number; height: number }>( + "plugin:window|inner_size", + { + label: this.label, + } + ) + .then(({ width, height }) => new PhysicalSize(width, height)); + } + + /** + * The physical size of the entire window. + * These dimensions include the title bar and borders. If you don't want that (and you usually don't), use inner_size instead. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const size = await appWindow.outerSize(); + * ``` + * + * @returns The window's outer size. + * + * @since 2.0.0 + */ + async outerSize(): Promise { + return window + .__TAURI_INVOKE__<{ width: number; height: number }>( + "plugin:window|outer_size", + { + label: this.label, + } + ) + .then(({ width, height }) => new PhysicalSize(width, height)); + } + + /** + * Gets the window's current fullscreen state. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const fullscreen = await appWindow.isFullscreen(); + * ``` + * + * @returns Whether the window is in fullscreen mode or not. + * + * @since 2.0.0 + * */ + async isFullscreen(): Promise { + return window.__TAURI_INVOKE__("plugin:window|is_fullscreen", { + label: this.label, + }); + } + + /** + * Gets the window's current minimized state. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const minimized = await appWindow.isMinimized(); + * ``` + * + * @since 2.0.0 + * */ + async isMinimized(): Promise { + return window.__TAURI_INVOKE__("plugin:window|is_minimized", { + label: this.label, + }); + } + + /** + * Gets the window's current maximized state. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const maximized = await appWindow.isMaximized(); + * ``` + * + * @returns Whether the window is maximized or not. + * + * @since 2.0.0 + * */ + async isMaximized(): Promise { + return window.__TAURI_INVOKE__("plugin:window|is_maximized", { + label: this.label, + }); + } + + /** + * Gets the window's current decorated state. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const decorated = await appWindow.isDecorated(); + * ``` + * + * @returns Whether the window is decorated or not. + * + * @since 2.0.0 + * */ + async isDecorated(): Promise { + return window.__TAURI_INVOKE__("plugin:window|is_decorated", { + label: this.label, + }); + } + + /** + * Gets the window's current resizable state. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const resizable = await appWindow.isResizable(); + * ``` + * + * @returns Whether the window is resizable or not. + * + * @since 2.0.0 + * */ + async isResizable(): Promise { + return window.__TAURI_INVOKE__("plugin:window|is_resizable", { + label: this.label, + }); + } + + /** + * Gets the window's current visible state. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const visible = await appWindow.isVisible(); + * ``` + * + * @returns Whether the window is visible or not. + * + * @since 2.0.0 + * */ + async isVisible(): Promise { + return window.__TAURI_INVOKE__("plugin:window|is_visible", { + label: this.label, + }); + } + + /** + * Gets the window's current title. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const title = await appWindow.title(); + * ``` + * + * @since 2.0.0 + * */ + async title(): Promise { + return window.__TAURI_INVOKE__("plugin:window|title", { + label: this.label, + }); + } + + /** + * Gets the window's current theme. + * + * #### Platform-specific + * + * - **macOS:** Theme was introduced on macOS 10.14. Returns `light` on macOS 10.13 and below. + * + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * const theme = await appWindow.theme(); + * ``` + * + * @returns The window theme. + * + * @since 2.0.0 + * */ + async theme(): Promise { + return window.__TAURI_INVOKE__("plugin:window|theme", { + label: this.label, + }); + } + + // Setters + + /** + * Centers the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.center(); + * ``` + * + * @param resizable + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async center(): Promise { + return window.__TAURI_INVOKE__("plugin:window|center", { + label: this.label, + }); + } + + /** + * Requests user attention to the window, this has no effect if the application + * is already focused. How requesting for user attention manifests is platform dependent, + * see `UserAttentionType` for details. + * + * Providing `null` will unset the request for user attention. Unsetting the request for + * user attention might not be done automatically by the WM when the window receives input. + * + * #### Platform-specific + * + * - **macOS:** `null` has no effect. + * - **Linux:** Urgency levels have the same effect. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.requestUserAttention(); + * ``` + * + * @param resizable + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async requestUserAttention( + requestType: UserAttentionType | null + ): Promise { + let requestType_ = null; + if (requestType) { + if (requestType === UserAttentionType.Critical) { + requestType_ = { type: "Critical" }; + } else { + requestType_ = { type: "Informational" }; + } + } + + return window.__TAURI_INVOKE__("plugin:window|request_user_attention", { + label: this.label, + value: requestType_, + }); + } + + /** + * Updates the window resizable flag. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setResizable(false); + * ``` + * + * @param resizable + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setResizable(resizable: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_resizable", { + label: this.label, + value: resizable, + }); + } + + /** + * Sets the window title. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setTitle('Tauri'); + * ``` + * + * @param title The new title + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setTitle(title: string): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_title", { + label: this.label, + value: title, + }); + } + + /** + * Maximizes the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.maximize(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async maximize(): Promise { + return window.__TAURI_INVOKE__("plugin:window|maximize", { + label: this.label, + }); + } + + /** + * Unmaximizes the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.unmaximize(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async unmaximize(): Promise { + return window.__TAURI_INVOKE__("plugin:window|unmaximize", { + label: this.label, + }); + } + + /** + * Toggles the window maximized state. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.toggleMaximize(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async toggleMaximize(): Promise { + return window.__TAURI_INVOKE__("plugin:window|toggle_maximize", { + label: this.label, + }); + } + + /** + * Minimizes the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.minimize(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async minimize(): Promise { + return window.__TAURI_INVOKE__("plugin:window|minimize", { + label: this.label, + }); + } + + /** + * Unminimizes the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.unminimize(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async unminimize(): Promise { + return window.__TAURI_INVOKE__("plugin:window|unminimize", { + label: this.label, + }); + } + + /** + * Sets the window visibility to true. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.show(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async show(): Promise { + return window.__TAURI_INVOKE__("plugin:window|show", { + label: this.label, + }); + } + + /** + * Sets the window visibility to false. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.hide(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async hide(): Promise { + return window.__TAURI_INVOKE__("plugin:window|hide", { + label: this.label, + }); + } + + /** + * Closes the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.close(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async close(): Promise { + return window.__TAURI_INVOKE__("plugin:window|close", { + label: this.label, + }); + } + + /** + * Whether the window should have borders and bars. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setDecorations(false); + * ``` + * + * @param decorations Whether the window should have borders and bars. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setDecorations(decorations: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_decorations", { + label: this.label, + value: decorations, + }); + } + + /** + * Whether or not the window should have shadow. + * + * #### Platform-specific + * + * - **Windows:** + * - `false` has no effect on decorated window, shadows are always ON. + * - `true` will make ndecorated window have a 1px white border, + * and on Windows 11, it will have a rounded corners. + * - **Linux:** Unsupported. + * + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setShadow(false); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setShadow(enable: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_shadow", { + label: this.label, + value: enable, + }); + } + + /** + * Whether the window should always be on top of other windows. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setAlwaysOnTop(true); + * ``` + * + * @param alwaysOnTop Whether the window should always be on top of other windows or not. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setAlwaysOnTop(alwaysOnTop: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_always_on_top", { + label: this.label, + value: alwaysOnTop, + }); + } + + /** + * Prevents the window contents from being captured by other apps. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setContentProtected(true); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setContentProtected(protected_: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_content_protected", { + label: this.label, + value: protected_, + }); + } + + /** + * Resizes the window with a new inner size. + * @example + * ```typescript + * import { appWindow, LogicalSize } from '@tauri-apps/window'; + * await appWindow.setSize(new LogicalSize(600, 500)); + * ``` + * + * @param size The logical or physical inner size. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setSize(size: LogicalSize | PhysicalSize): Promise { + if (!size || (size.type !== "Logical" && size.type !== "Physical")) { + throw new Error( + "the `size` argument must be either a LogicalSize or a PhysicalSize instance" + ); + } + + return window.__TAURI_INVOKE__("plugin:window|set_size", { + label: this.label, + value: { + type: size.type, + data: { + width: size.width, + height: size.height, + }, + }, + }); + } + + /** + * Sets the window minimum inner size. If the `size` argument is not provided, the constraint is unset. + * @example + * ```typescript + * import { appWindow, PhysicalSize } from '@tauri-apps/window'; + * await appWindow.setMinSize(new PhysicalSize(600, 500)); + * ``` + * + * @param size The logical or physical inner size, or `null` to unset the constraint. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setMinSize( + size: LogicalSize | PhysicalSize | null | undefined + ): Promise { + if (size && size.type !== "Logical" && size.type !== "Physical") { + throw new Error( + "the `size` argument must be either a LogicalSize or a PhysicalSize instance" + ); + } + + return window.__TAURI_INVOKE__("plugin:window|set_min_size", { + label: this.label, + value: size + ? { + type: size.type, + data: { + width: size.width, + height: size.height, + }, + } + : null, + }); + } + + /** + * Sets the window maximum inner size. If the `size` argument is undefined, the constraint is unset. + * @example + * ```typescript + * import { appWindow, LogicalSize } from '@tauri-apps/window'; + * await appWindow.setMaxSize(new LogicalSize(600, 500)); + * ``` + * + * @param size The logical or physical inner size, or `null` to unset the constraint. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setMaxSize( + size: LogicalSize | PhysicalSize | null | undefined + ): Promise { + if (size && size.type !== "Logical" && size.type !== "Physical") { + throw new Error( + "the `size` argument must be either a LogicalSize or a PhysicalSize instance" + ); + } + + return window.__TAURI_INVOKE__("plugin:window|set_max_size", { + label: this.label, + value: size + ? { + type: size.type, + data: { + width: size.width, + height: size.height, + }, + } + : null, + }); + } + + /** + * Sets the window outer position. + * @example + * ```typescript + * import { appWindow, LogicalPosition } from '@tauri-apps/window'; + * await appWindow.setPosition(new LogicalPosition(600, 500)); + * ``` + * + * @param position The new position, in logical or physical pixels. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setPosition( + position: LogicalPosition | PhysicalPosition + ): Promise { + if ( + !position || + (position.type !== "Logical" && position.type !== "Physical") + ) { + throw new Error( + "the `position` argument must be either a LogicalPosition or a PhysicalPosition instance" + ); + } + + return window.__TAURI_INVOKE__("plugin:window|set_position", { + label: this.label, + value: { + type: position.type, + data: { + x: position.x, + y: position.y, + }, + }, + }); + } + + /** + * Sets the window fullscreen state. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setFullscreen(true); + * ``` + * + * @param fullscreen Whether the window should go to fullscreen or not. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setFullscreen(fullscreen: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_fullscreen", { + label: this.label, + value: fullscreen, + }); + } + + /** + * Bring the window to front and focus. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setFocus(); + * ``` + * + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setFocus(): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_focus", { + label: this.label, + }); + } + + /** + * Sets the window icon. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setIcon('/tauri/awesome.png'); + * ``` + * + * Note that you need the `icon-ico` or `icon-png` Cargo features to use this API. + * To enable it, change your Cargo.toml file: + * ```toml + * [dependencies] + * tauri = { version = "...", features = ["...", "icon-png"] } + * ``` + * + * @param icon Icon bytes or path to the icon file. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setIcon(icon: string | Uint8Array): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_icon", { + label: this.label, + value: typeof icon === "string" ? icon : Array.from(icon), + }); + } + + /** + * Whether the window icon should be hidden from the taskbar or not. + * + * #### Platform-specific + * + * - **macOS:** Unsupported. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setSkipTaskbar(true); + * ``` + * + * @param skip true to hide window icon, false to show it. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setSkipTaskbar(skip: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_skip_taskbar", { + label: this.label, + value: skip, + }); + } + + /** + * Grabs the cursor, preventing it from leaving the window. + * + * There's no guarantee that the cursor will be hidden. You should + * hide it by yourself if you want so. + * + * #### Platform-specific + * + * - **Linux:** Unsupported. + * - **macOS:** This locks the cursor in a fixed location, which looks visually awkward. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setCursorGrab(true); + * ``` + * + * @param grab `true` to grab the cursor icon, `false` to release it. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setCursorGrab(grab: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_cursor_grab", { + label: this.label, + value: grab, + }); + } + + /** + * Modifies the cursor's visibility. + * + * #### Platform-specific + * + * - **Windows:** The cursor is only hidden within the confines of the window. + * - **macOS:** The cursor is hidden as long as the window has input focus, even if the cursor is + * outside of the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setCursorVisible(false); + * ``` + * + * @param visible If `false`, this will hide the cursor. If `true`, this will show the cursor. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setCursorVisible(visible: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_cursor_visible", { + label: this.label, + value: visible, + }); + } + + /** + * Modifies the cursor icon of the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setCursorIcon('help'); + * ``` + * + * @param icon The new cursor icon. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setCursorIcon(icon: CursorIcon): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_cursor_icon", { + label: this.label, + value: icon, + }); + } + + /** + * Changes the position of the cursor in window coordinates. + * @example + * ```typescript + * import { appWindow, LogicalPosition } from '@tauri-apps/window'; + * await appWindow.setCursorPosition(new LogicalPosition(600, 300)); + * ``` + * + * @param position The new cursor position. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setCursorPosition( + position: LogicalPosition | PhysicalPosition + ): Promise { + if ( + !position || + (position.type !== "Logical" && position.type !== "Physical") + ) { + throw new Error( + "the `position` argument must be either a LogicalPosition or a PhysicalPosition instance" + ); + } + + return window.__TAURI_INVOKE__("plugin:window|set_cursor_position", { + label: this.label, + value: { + type: position.type, + data: { + x: position.x, + y: position.y, + }, + }, + }); + } + + /** + * Changes the cursor events behavior. + * + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.setIgnoreCursorEvents(true); + * ``` + * + * @param ignore `true` to ignore the cursor events; `false` to process them as usual. + * @returns A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async setIgnoreCursorEvents(ignore: boolean): Promise { + return window.__TAURI_INVOKE__("plugin:window|set_ignore_cursor_events", { + label: this.label, + value: ignore, + }); + } + + /** + * Starts dragging the window. + * @example + * ```typescript + * import { appWindow } from '@tauri-apps/window'; + * await appWindow.startDragging(); + * ``` + * + * @return A promise indicating the success or failure of the operation. + * + * @since 2.0.0 + */ + async startDragging(): Promise { + return window.__TAURI_INVOKE__("plugin:window|start_dragging", { + label: this.label, + }); + } + + // Listeners + + /** + * Listen to window resize. + * + * @example + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * const unlisten = await appWindow.onResized(({ payload: size }) => { + * console.log('Window resized', size); + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async onResized(handler: EventCallback): Promise { + return this.listen(TauriEvent.WINDOW_RESIZED, (e) => { + e.payload = mapPhysicalSize(e.payload); + handler(e); + }); + } + + /** + * Listen to window move. + * + * @example + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * const unlisten = await appWindow.onMoved(({ payload: position }) => { + * console.log('Window moved', position); + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async onMoved(handler: EventCallback): Promise { + return this.listen(TauriEvent.WINDOW_MOVED, (e) => { + e.payload = mapPhysicalPosition(e.payload); + handler(e); + }); + } + + /** + * Listen to window close requested. Emitted when the user requests to closes the window. + * + * @example + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * import { confirm } from '@tauri-apps/api/dialog'; + * const unlisten = await appWindow.onCloseRequested(async (event) => { + * const confirmed = await confirm('Are you sure?'); + * if (!confirmed) { + * // user did not confirm closing the window; let's prevent it + * event.preventDefault(); + * } + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + /* eslint-disable @typescript-eslint/promise-function-async */ + async onCloseRequested( + handler: (event: CloseRequestedEvent) => void | Promise + ): Promise { + return this.listen(TauriEvent.WINDOW_CLOSE_REQUESTED, (event) => { + const evt = new CloseRequestedEvent(event); + void Promise.resolve(handler(evt)).then(() => { + if (!evt.isPreventDefault()) { + return this.close(); + } + }); + }); + } + /* eslint-enable */ + + /** + * Listen to window focus change. + * + * @example + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * const unlisten = await appWindow.onFocusChanged(({ payload: focused }) => { + * console.log('Focus changed, window is focused? ' + focused); + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async onFocusChanged(handler: EventCallback): Promise { + const unlistenFocus = await this.listen( + TauriEvent.WINDOW_FOCUS, + (event) => { + handler({ ...event, payload: true }); + } + ); + const unlistenBlur = await this.listen( + TauriEvent.WINDOW_BLUR, + (event) => { + handler({ ...event, payload: false }); + } + ); + return () => { + unlistenFocus(); + unlistenBlur(); + }; + } + + /** + * Listen to window scale change. Emitted when the window's scale factor has changed. + * The following user actions can cause DPI changes: + * - Changing the display's resolution. + * - Changing the display's scale factor (e.g. in Control Panel on Windows). + * - Moving the window to a display with a different scale factor. + * + * @example + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * const unlisten = await appWindow.onScaleChanged(({ payload }) => { + * console.log('Scale changed', payload.scaleFactor, payload.size); + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async onScaleChanged( + handler: EventCallback + ): Promise { + return this.listen( + TauriEvent.WINDOW_SCALE_FACTOR_CHANGED, + handler + ); + } + + /** + * Listen to the window menu item click. The payload is the item id. + * + * @example + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * const unlisten = await appWindow.onMenuClicked(({ payload: menuId }) => { + * console.log('Menu clicked: ' + menuId); + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async onMenuClicked(handler: EventCallback): Promise { + return this.listen(TauriEvent.MENU, handler); + } + + /** + * Listen to a file drop event. + * The listener is triggered when the user hovers the selected files on the window, + * drops the files or cancels the operation. + * + * @example + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * const unlisten = await appWindow.onFileDropEvent((event) => { + * if (event.payload.type === 'hover') { + * console.log('User hovering', event.payload.paths); + * } else if (event.payload.type === 'drop') { + * console.log('User dropped', event.payload.paths); + * } else { + * console.log('File drop cancelled'); + * } + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async onFileDropEvent( + handler: EventCallback + ): Promise { + const unlistenFileDrop = await this.listen( + TauriEvent.WINDOW_FILE_DROP, + (event) => { + handler({ ...event, payload: { type: "drop", paths: event.payload } }); + } + ); + + const unlistenFileHover = await this.listen( + TauriEvent.WINDOW_FILE_DROP_HOVER, + (event) => { + handler({ ...event, payload: { type: "hover", paths: event.payload } }); + } + ); + + const unlistenCancel = await this.listen( + TauriEvent.WINDOW_FILE_DROP_CANCELLED, + (event) => { + handler({ ...event, payload: { type: "cancel" } }); + } + ); + + return () => { + unlistenFileDrop(); + unlistenFileHover(); + unlistenCancel(); + }; + } + + /** + * Listen to the system theme change. + * + * @example + * ```typescript + * import { appWindow } from "@tauri-apps/plugin-window"; + * const unlisten = await appWindow.onThemeChanged(({ payload: theme }) => { + * console.log('New theme: ' + theme); + * }); + * + * // you need to call unlisten if your handler goes out of scope e.g. the component is unmounted + * unlisten(); + * ``` + * + * @returns A promise resolving to a function to unlisten to the event. + * Note that removing the listener is required if your listener goes out of scope e.g. the component is unmounted. + * + * @since 2.0.0 + */ + async onThemeChanged(handler: EventCallback): Promise { + return this.listen(TauriEvent.WINDOW_THEME_CHANGED, handler); + } +} + +/** + * @since 2.0.0 + */ +class CloseRequestedEvent { + /** Event name */ + event: EventName; + /** The label of the window that emitted this event. */ + windowLabel: string; + /** Event identifier used to unlisten */ + id: number; + private _preventDefault = false; + + constructor(event: Event) { + this.event = event.event; + this.windowLabel = event.windowLabel; + this.id = event.id; + } + + preventDefault(): void { + this._preventDefault = true; + } + + isPreventDefault(): boolean { + return this._preventDefault; + } +} + +/** + * Create new webview windows and get a handle to existing ones. + * + * Windows are identified by a *label* a unique identifier that can be used to reference it later. + * It may only contain alphanumeric characters `a-zA-Z` plus the following special characters `-`, `/`, `:` and `_`. + * + * @example + * ```typescript + * // loading embedded asset: + * const webview = new WebviewWindow('theUniqueLabel', { + * url: 'path/to/page.html' + * }); + * // alternatively, load a remote URL: + * const webview = new WebviewWindow('theUniqueLabel', { + * url: 'https://github.com/tauri-apps/tauri' + * }); + * + * webview.once('tauri://created', function () { + * // webview window successfully created + * }); + * webview.once('tauri://error', function (e) { + * // an error happened creating the webview window + * }); + * + * // emit an event to the backend + * await webview.emit("some event", "data"); + * // listen to an event from the backend + * const unlisten = await webview.listen("event name", e => {}); + * unlisten(); + * ``` + * + * @since 2.0.0 + */ +class WebviewWindow extends WindowManager { + /** + * Creates a new WebviewWindow. + * @example + * ```typescript + * import { WebviewWindow } from '@tauri-apps/window'; + * const webview = new WebviewWindow('my-label', { + * url: 'https://github.com/tauri-apps/tauri' + * }); + * webview.once('tauri://created', function () { + * // webview window successfully created + * }); + * webview.once('tauri://error', function (e) { + * // an error happened creating the webview window + * }); + * ``` + * + * * @param label The unique webview window label. Must be alphanumeric: `a-zA-Z-/:_`. + * @returns The WebviewWindow instance to communicate with the webview. + * + * @since 2.0.0 + */ + constructor(label: WindowLabel, options: WindowOptions = {}) { + super(label); + // @ts-expect-error `skip` is not a public API so it is not defined in WindowOptions + if (!options?.skip) { + window + .__TAURI_INVOKE__("plugin:window|create", { + options: { + ...options, + label, + }, + }) + .then(async () => this.emit("tauri://created")) + .catch(async (e: string) => this.emit("tauri://error", e)); + } + } + + /** + * Gets the WebviewWindow for the webview associated with the given label. + * @example + * ```typescript + * import { WebviewWindow } from '@tauri-apps/window'; + * const mainWindow = WebviewWindow.getByLabel('main'); + * ``` + * + * @param label The webview window label. + * @returns The WebviewWindow instance to communicate with the webview or null if the webview doesn't exist. + * + * @since 2.0.0 + */ + static getByLabel(label: string): WebviewWindow | null { + if (getAll().some((w) => w.label === label)) { + // @ts-expect-error `skip` is not defined in the public API but it is handled by the constructor + return new WebviewWindow(label, { skip: true }); + } + return null; + } +} + +/** The WebviewWindow for the current window. */ +let appWindow: WebviewWindow; +if ("__TAURI_METADATA__" in window) { + appWindow = new WebviewWindow( + window.__TAURI_METADATA__.__currentWindow.label, + { + // @ts-expect-error `skip` is not defined in the public API but it is handled by the constructor + skip: true, + } + ); +} else { + console.warn( + `Could not find "window.__TAURI_METADATA__". The "appWindow" value will reference the "main" window label.\nNote that this is not an issue if running this frontend on a browser instead of a Tauri window.` + ); + appWindow = new WebviewWindow("main", { + // @ts-expect-error `skip` is not defined in the public API but it is handled by the constructor + skip: true, + }); +} + +/** + * Configuration for the window to create. + * + * @since 2.0.0 + */ +interface WindowOptions { + /** + * Remote URL or local file path to open. + * + * - URL such as `https://github.com/tauri-apps` is opened directly on a Tauri window. + * - data: URL such as `data:text/html,...` is only supported with the `window-data-url` Cargo feature for the `tauri` dependency. + * - local file path or route such as `/path/to/page.html` or `/users` is appended to the application URL (the devServer URL on development, or `tauri://localhost/` and `https://tauri.localhost/` on production). + */ + url?: string; + /** Show window in the center of the screen.. */ + center?: boolean; + /** The initial vertical position. Only applies if `y` is also set. */ + x?: number; + /** The initial horizontal position. Only applies if `x` is also set. */ + y?: number; + /** The initial width. */ + width?: number; + /** The initial height. */ + height?: number; + /** The minimum width. Only applies if `minHeight` is also set. */ + minWidth?: number; + /** The minimum height. Only applies if `minWidth` is also set. */ + minHeight?: number; + /** The maximum width. Only applies if `maxHeight` is also set. */ + maxWidth?: number; + /** The maximum height. Only applies if `maxWidth` is also set. */ + maxHeight?: number; + /** Whether the window is resizable or not. */ + resizable?: boolean; + /** Window title. */ + title?: string; + /** Whether the window is in fullscreen mode or not. */ + fullscreen?: boolean; + /** Whether the window will be initially focused or not. */ + focus?: boolean; + /** + * Whether the window is transparent or not. + * Note that on `macOS` this requires the `macos-private-api` feature flag, enabled under `tauri.conf.json > tauri > macOSPrivateApi`. + * WARNING: Using private APIs on `macOS` prevents your application from being accepted to the `App Store`. + */ + transparent?: boolean; + /** Whether the window should be maximized upon creation or not. */ + maximized?: boolean; + /** Whether the window should be immediately visible upon creation or not. */ + visible?: boolean; + /** Whether the window should have borders and bars or not. */ + decorations?: boolean; + /** Whether the window should always be on top of other windows or not. */ + alwaysOnTop?: boolean; + /** Prevents the window contents from being captured by other apps. */ + contentProtected?: boolean; + /** Whether or not the window icon should be added to the taskbar. */ + skipTaskbar?: boolean; + /** + * Whether or not the window has shadow. + * + * #### Platform-specific + * + * - **Windows:** + * - `false` has no effect on decorated window, shadows are always ON. + * - `true` will make ndecorated window have a 1px white border, + * and on Windows 11, it will have a rounded corners. + * - **Linux:** Unsupported. + * + * @since 2.0.0 + */ + shadow?: boolean; + /** + * Whether the file drop is enabled or not on the webview. By default it is enabled. + * + * Disabling it is required to use drag and drop on the frontend on Windows. + */ + fileDropEnabled?: boolean; + /** + * The initial window theme. Defaults to the system theme. + * + * Only implemented on Windows and macOS 10.14+. + */ + theme?: Theme; + /** + * The style of the macOS title bar. + */ + titleBarStyle?: TitleBarStyle; + /** + * If `true`, sets the window title to be hidden on macOS. + */ + hiddenTitle?: boolean; + /** + * Whether clicking an inactive window also clicks through to the webview on macOS. + */ + acceptFirstMouse?: boolean; + /** + * Defines the window [tabbing identifier](https://developer.apple.com/documentation/appkit/nswindow/1644704-tabbingidentifier) on macOS. + * + * Windows with the same tabbing identifier will be grouped together. + * If the tabbing identifier is not set, automatic tabbing will be disabled. + */ + tabbingIdentifier?: string; + /** + * The user agent for the webview. + */ + userAgent?: string; +} + +function mapMonitor(m: Monitor | null): Monitor | null { + return m === null + ? null + : { + name: m.name, + scaleFactor: m.scaleFactor, + position: mapPhysicalPosition(m.position), + size: mapPhysicalSize(m.size), + }; +} + +function mapPhysicalPosition(m: PhysicalPosition): PhysicalPosition { + return new PhysicalPosition(m.x, m.y); +} + +function mapPhysicalSize(m: PhysicalSize): PhysicalSize { + return new PhysicalSize(m.width, m.height); +} + +/** + * Returns the monitor on which the window currently resides. + * Returns `null` if current monitor can't be detected. + * @example + * ```typescript + * import { currentMonitor } from '@tauri-apps/window'; + * const monitor = currentMonitor(); + * ``` + * + * @since 2.0.0 + */ +async function currentMonitor(): Promise { + return window + .__TAURI_INVOKE__("plugin:window|current_monitor") + .then(mapMonitor); +} + +/** + * Returns the primary monitor of the system. + * Returns `null` if it can't identify any monitor as a primary one. + * @example + * ```typescript + * import { primaryMonitor } from '@tauri-apps/window'; + * const monitor = primaryMonitor(); + * ``` + * + * @since 2.0.0 + */ +async function primaryMonitor(): Promise { + return window + .__TAURI_INVOKE__("plugin:window|primary_monitor") + .then(mapMonitor); +} + +/** + * Returns the list of all the monitors available on the system. + * @example + * ```typescript + * import { availableMonitors } from '@tauri-apps/window'; + * const monitors = availableMonitors(); + * ``` + * + * @since 2.0.0 + */ +async function availableMonitors(): Promise { + return window + .__TAURI_INVOKE__("plugin:window|available_monitors") + .then((ms) => ms.map(mapMonitor) as Monitor[]); +} + +export { + WebviewWindow, + WebviewWindowHandle, + WindowManager, + CloseRequestedEvent, + getCurrent, + getAll, + appWindow, + LogicalSize, + PhysicalSize, + LogicalPosition, + PhysicalPosition, + UserAttentionType, + currentMonitor, + primaryMonitor, + availableMonitors, +}; + +export type { + Theme, + TitleBarStyle, + Monitor, + ScaleFactorChanged, + FileDropEvent, + WindowOptions, +}; diff --git a/plugins/window/package.json b/plugins/window/package.json new file mode 100644 index 00000000..1de59aeb --- /dev/null +++ b/plugins/window/package.json @@ -0,0 +1,32 @@ +{ + "name": "@tauri-apps/plugin-window", + "version": "2.0.0-alpha.0", + "license": "MIT or APACHE-2.0", + "authors": [ + "Tauri Programme within The Commons Conservancy" + ], + "type": "module", + "browser": "dist-js/index.min.js", + "module": "dist-js/index.mjs", + "types": "dist-js/index.d.ts", + "exports": { + "import": "./dist-js/index.mjs", + "types": "./dist-js/index.d.ts", + "browser": "./dist-js/index.min.js" + }, + "scripts": { + "build": "rollup -c" + }, + "files": [ + "dist-js", + "!dist-js/**/*.map", + "README.md", + "LICENSE" + ], + "devDependencies": { + "tslib": "^2.5.0" + }, + "dependencies": { + "@tauri-apps/api": "2.0.0-alpha.4" + } +} diff --git a/plugins/window/rollup.config.mjs b/plugins/window/rollup.config.mjs new file mode 100644 index 00000000..6555e98b --- /dev/null +++ b/plugins/window/rollup.config.mjs @@ -0,0 +1,11 @@ +import { readFileSync } from "fs"; + +import { createConfig } from "../../shared/rollup.config.mjs"; + +export default createConfig({ + input: "guest-js/index.ts", + pkg: JSON.parse( + readFileSync(new URL("./package.json", import.meta.url), "utf8") + ), + external: [/^@tauri-apps\/api/], +}); diff --git a/plugins/window/src/api-iife.js b/plugins/window/src/api-iife.js new file mode 100644 index 00000000..ffa35ae0 --- /dev/null +++ b/plugins/window/src/api-iife.js @@ -0,0 +1 @@ +if("__TAURI__"in window){var __TAURI_WINDOW__=function(e){"use strict";var n=Object.defineProperty,i=(e,i)=>{for(var t in i)n(e,t,{get:i[t],enumerable:!0})},t=(e,n,i)=>{if(!n.has(e))throw TypeError("Cannot "+i)},l=(e,n,i)=>(t(e,n,"read from private field"),i?i.call(e):n.get(e)),a=(e,n,i,l)=>(t(e,n,"write to private field"),l?l.call(e,i):n.set(e,i),i);function s(e,n=!1){let i=window.crypto.getRandomValues(new Uint32Array(1))[0],t=`_${i}`;return Object.defineProperty(window,t,{value:i=>(n&&Reflect.deleteProperty(window,t),e?.(i)),writable:!1,configurable:!0}),i}i({},{Channel:()=>o,PluginListener:()=>_,addPluginListener:()=>w,convertFileSrc:()=>c,invoke:()=>u,transformCallback:()=>s});var r,o=class{constructor(){this.__TAURI_CHANNEL_MARKER__=!0,((e,n,i)=>{if(n.has(e))throw TypeError("Cannot add the same private member more than once");n instanceof WeakSet?n.add(e):n.set(e,i)})(this,r,(()=>{})),this.id=s((e=>{l(this,r).call(this,e)}))}set onmessage(e){a(this,r,e)}get onmessage(){return l(this,r)}toJSON(){return`__CHANNEL__:${this.id}`}};r=new WeakMap;var _=class{constructor(e,n,i){this.plugin=e,this.event=n,this.channelId=i}async unregister(){return u(`plugin:${this.plugin}|remove_listener`,{event:this.event,channelId:this.channelId})}};async function w(e,n,i){let t=new o;return t.onmessage=i,u(`plugin:${e}|register_listener`,{event:n,handler:t}).then((()=>new _(e,n,t.id)))}async function u(e,n={}){return new Promise(((i,t)=>{let l=s((e=>{i(e),Reflect.deleteProperty(window,`_${a}`)}),!0),a=s((e=>{t(e),Reflect.deleteProperty(window,`_${l}`)}),!0);window.__TAURI_IPC__({cmd:e,callback:l,error:a,...n})}))}function c(e,n="asset"){let i=encodeURIComponent(e);return navigator.userAgent.includes("Windows")?`https://${n}.localhost/${i}`:`${n}://localhost/${i}`}async function d(e,n){await u("plugin:event|unlisten",{event:e,eventId:n})}async function h(e,n,i){return u("plugin:event|listen",{event:e,windowLabel:n,handler:s(i)}).then((n=>async()=>d(e,n)))}i({},{TauriEvent:()=>I,emit:()=>E,listen:()=>b,once:()=>g});var p,y,I=((p=I||{}).WINDOW_RESIZED="tauri://resize",p.WINDOW_MOVED="tauri://move",p.WINDOW_CLOSE_REQUESTED="tauri://close-requested",p.WINDOW_CREATED="tauri://window-created",p.WINDOW_DESTROYED="tauri://destroyed",p.WINDOW_FOCUS="tauri://focus",p.WINDOW_BLUR="tauri://blur",p.WINDOW_SCALE_FACTOR_CHANGED="tauri://scale-change",p.WINDOW_THEME_CHANGED="tauri://theme-changed",p.WINDOW_FILE_DROP="tauri://file-drop",p.WINDOW_FILE_DROP_HOVER="tauri://file-drop-hover",p.WINDOW_FILE_DROP_CANCELLED="tauri://file-drop-cancelled",p.MENU="tauri://menu",p);async function b(e,n){return h(e,null,n)}async function g(e,n){return async function(e,n,i){return h(e,n,(n=>{i(n),d(e,n.id).catch((()=>{}))}))}(e,null,n)}async function E(e,n){return async function(e,n,i){await u("plugin:event|emit",{event:e,windowLabel:n,payload:i})}(e,void 0,n)}async function A(e,n){await window.__TAURI_INVOKE__("plugin:event|unlisten",{event:e,eventId:n})}async function O(e,n,i){return window.__TAURI_INVOKE__("plugin:event|listen",{event:e,windowLabel:n,handler:window.__TAURI__.transformCallback(i)}).then((n=>async()=>A(e,n)))}class T{constructor(e,n){this.type="Logical",this.width=e,this.height=n}}class R{constructor(e,n){this.type="Physical",this.width=e,this.height=n}toLogical(e){return new T(this.width/e,this.height/e)}}class v{constructor(e,n){this.type="Logical",this.x=e,this.y=n}}class N{constructor(e,n){this.type="Physical",this.x=e,this.y=n}toLogical(e){return new v(this.x/e,this.y/e)}}function m(){return window.__TAURI_METADATA__.__windows.map((e=>new V(e.label,{skip:!0})))}e.UserAttentionType=void 0,(y=e.UserAttentionType||(e.UserAttentionType={}))[y.Critical=1]="Critical",y[y.Informational=2]="Informational";const U=["tauri://created","tauri://error"];class f{constructor(e){this.label=e,this.listeners=Object.create(null)}async listen(e,n){return this._handleTauriEvent(e,n)?Promise.resolve((()=>{const i=this.listeners[e];i.splice(i.indexOf(n),1)})):O(e,this.label,n)}async once(e,n){return this._handleTauriEvent(e,n)?Promise.resolve((()=>{const i=this.listeners[e];i.splice(i.indexOf(n),1)})):async function(e,n,i){return O(e,n,(n=>{i(n),A(e,n.id).catch((()=>{}))}))}(e,this.label,n)}async emit(e,n){if(U.includes(e)){for(const i of this.listeners[e]||[])i({event:e,id:-1,windowLabel:this.label,payload:n});return Promise.resolve()}return async function(e,n,i){await window.__TAURI_INVOKE__("plugin:event|emit",{event:e,windowLabel:n,payload:i})}(e,this.label,n)}_handleTauriEvent(e,n){return!!U.includes(e)&&(e in this.listeners?this.listeners[e].push(n):this.listeners[e]=[n],!0)}}class W extends f{async scaleFactor(){return window.__TAURI_INVOKE__("plugin:window|scale_factor",{label:this.label})}async innerPosition(){return window.__TAURI_INVOKE__("plugin:window|inner_position",{label:this.label}).then((({x:e,y:n})=>new N(e,n)))}async outerPosition(){return window.__TAURI_INVOKE__("plugin:window|outer_position",{label:this.label}).then((({x:e,y:n})=>new N(e,n)))}async innerSize(){return window.__TAURI_INVOKE__("plugin:window|inner_size",{label:this.label}).then((({width:e,height:n})=>new R(e,n)))}async outerSize(){return window.__TAURI_INVOKE__("plugin:window|outer_size",{label:this.label}).then((({width:e,height:n})=>new R(e,n)))}async isFullscreen(){return window.__TAURI_INVOKE__("plugin:window|is_fullscreen",{label:this.label})}async isMinimized(){return window.__TAURI_INVOKE__("plugin:window|is_minimized",{label:this.label})}async isMaximized(){return window.__TAURI_INVOKE__("plugin:window|is_maximized",{label:this.label})}async isDecorated(){return window.__TAURI_INVOKE__("plugin:window|is_decorated",{label:this.label})}async isResizable(){return window.__TAURI_INVOKE__("plugin:window|is_resizable",{label:this.label})}async isVisible(){return window.__TAURI_INVOKE__("plugin:window|is_visible",{label:this.label})}async title(){return window.__TAURI_INVOKE__("plugin:window|title",{label:this.label})}async theme(){return window.__TAURI_INVOKE__("plugin:window|theme",{label:this.label})}async center(){return window.__TAURI_INVOKE__("plugin:window|center",{label:this.label})}async requestUserAttention(n){let i=null;return n&&(i=n===e.UserAttentionType.Critical?{type:"Critical"}:{type:"Informational"}),window.__TAURI_INVOKE__("plugin:window|request_user_attention",{label:this.label,value:i})}async setResizable(e){return window.__TAURI_INVOKE__("plugin:window|set_resizable",{label:this.label,value:e})}async setTitle(e){return window.__TAURI_INVOKE__("plugin:window|set_title",{label:this.label,value:e})}async maximize(){return window.__TAURI_INVOKE__("plugin:window|maximize",{label:this.label})}async unmaximize(){return window.__TAURI_INVOKE__("plugin:window|unmaximize",{label:this.label})}async toggleMaximize(){return window.__TAURI_INVOKE__("plugin:window|toggle_maximize",{label:this.label})}async minimize(){return window.__TAURI_INVOKE__("plugin:window|minimize",{label:this.label})}async unminimize(){return window.__TAURI_INVOKE__("plugin:window|unminimize",{label:this.label})}async show(){return window.__TAURI_INVOKE__("plugin:window|show",{label:this.label})}async hide(){return window.__TAURI_INVOKE__("plugin:window|hide",{label:this.label})}async close(){return window.__TAURI_INVOKE__("plugin:window|close",{label:this.label})}async setDecorations(e){return window.__TAURI_INVOKE__("plugin:window|set_decorations",{label:this.label,value:e})}async setShadow(e){return window.__TAURI_INVOKE__("plugin:window|set_shadow",{label:this.label,value:e})}async setAlwaysOnTop(e){return window.__TAURI_INVOKE__("plugin:window|set_always_on_top",{label:this.label,value:e})}async setContentProtected(e){return window.__TAURI_INVOKE__("plugin:window|set_content_protected",{label:this.label,value:e})}async setSize(e){if(!e||"Logical"!==e.type&&"Physical"!==e.type)throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return window.__TAURI_INVOKE__("plugin:window|set_size",{label:this.label,value:{type:e.type,data:{width:e.width,height:e.height}}})}async setMinSize(e){if(e&&"Logical"!==e.type&&"Physical"!==e.type)throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return window.__TAURI_INVOKE__("plugin:window|set_min_size",{label:this.label,value:e?{type:e.type,data:{width:e.width,height:e.height}}:null})}async setMaxSize(e){if(e&&"Logical"!==e.type&&"Physical"!==e.type)throw new Error("the `size` argument must be either a LogicalSize or a PhysicalSize instance");return window.__TAURI_INVOKE__("plugin:window|set_max_size",{label:this.label,value:e?{type:e.type,data:{width:e.width,height:e.height}}:null})}async setPosition(e){if(!e||"Logical"!==e.type&&"Physical"!==e.type)throw new Error("the `position` argument must be either a LogicalPosition or a PhysicalPosition instance");return window.__TAURI_INVOKE__("plugin:window|set_position",{label:this.label,value:{type:e.type,data:{x:e.x,y:e.y}}})}async setFullscreen(e){return window.__TAURI_INVOKE__("plugin:window|set_fullscreen",{label:this.label,value:e})}async setFocus(){return window.__TAURI_INVOKE__("plugin:window|set_focus",{label:this.label})}async setIcon(e){return window.__TAURI_INVOKE__("plugin:window|set_icon",{label:this.label,value:"string"==typeof e?e:Array.from(e)})}async setSkipTaskbar(e){return window.__TAURI_INVOKE__("plugin:window|set_skip_taskbar",{label:this.label,value:e})}async setCursorGrab(e){return window.__TAURI_INVOKE__("plugin:window|set_cursor_grab",{label:this.label,value:e})}async setCursorVisible(e){return window.__TAURI_INVOKE__("plugin:window|set_cursor_visible",{label:this.label,value:e})}async setCursorIcon(e){return window.__TAURI_INVOKE__("plugin:window|set_cursor_icon",{label:this.label,value:e})}async setCursorPosition(e){if(!e||"Logical"!==e.type&&"Physical"!==e.type)throw new Error("the `position` argument must be either a LogicalPosition or a PhysicalPosition instance");return window.__TAURI_INVOKE__("plugin:window|set_cursor_position",{label:this.label,value:{type:e.type,data:{x:e.x,y:e.y}}})}async setIgnoreCursorEvents(e){return window.__TAURI_INVOKE__("plugin:window|set_ignore_cursor_events",{label:this.label,value:e})}async startDragging(){return window.__TAURI_INVOKE__("plugin:window|start_dragging",{label:this.label})}async onResized(e){return this.listen(I.WINDOW_RESIZED,(n=>{n.payload=C(n.payload),e(n)}))}async onMoved(e){return this.listen(I.WINDOW_MOVED,(n=>{n.payload=P(n.payload),e(n)}))}async onCloseRequested(e){return this.listen(I.WINDOW_CLOSE_REQUESTED,(n=>{const i=new D(n);Promise.resolve(e(i)).then((()=>{if(!i.isPreventDefault())return this.close()}))}))}async onFocusChanged(e){const n=await this.listen(I.WINDOW_FOCUS,(n=>{e({...n,payload:!0})})),i=await this.listen(I.WINDOW_BLUR,(n=>{e({...n,payload:!1})}));return()=>{n(),i()}}async onScaleChanged(e){return this.listen(I.WINDOW_SCALE_FACTOR_CHANGED,e)}async onMenuClicked(e){return this.listen(I.MENU,e)}async onFileDropEvent(e){const n=await this.listen(I.WINDOW_FILE_DROP,(n=>{e({...n,payload:{type:"drop",paths:n.payload}})})),i=await this.listen(I.WINDOW_FILE_DROP_HOVER,(n=>{e({...n,payload:{type:"hover",paths:n.payload}})})),t=await this.listen(I.WINDOW_FILE_DROP_CANCELLED,(n=>{e({...n,payload:{type:"cancel"}})}));return()=>{n(),i(),t()}}async onThemeChanged(e){return this.listen(I.WINDOW_THEME_CHANGED,e)}}class D{constructor(e){this._preventDefault=!1,this.event=e.event,this.windowLabel=e.windowLabel,this.id=e.id}preventDefault(){this._preventDefault=!0}isPreventDefault(){return this._preventDefault}}class V extends W{constructor(e,n={}){super(e),(null==n?void 0:n.skip)||window.__TAURI_INVOKE__("plugin:window|create",{options:{...n,label:e}}).then((async()=>this.emit("tauri://created"))).catch((async e=>this.emit("tauri://error",e)))}static getByLabel(e){return m().some((n=>n.label===e))?new V(e,{skip:!0}):null}}function K(e){return null===e?null:{name:e.name,scaleFactor:e.scaleFactor,position:P(e.position),size:C(e.size)}}function P(e){return new N(e.x,e.y)}function C(e){return new R(e.width,e.height)}return e.appWindow=void 0,"__TAURI_METADATA__"in window?e.appWindow=new V(window.__TAURI_METADATA__.__currentWindow.label,{skip:!0}):(console.warn('Could not find "window.__TAURI_METADATA__". The "appWindow" value will reference the "main" window label.\nNote that this is not an issue if running this frontend on a browser instead of a Tauri window.'),e.appWindow=new V("main",{skip:!0})),e.CloseRequestedEvent=D,e.LogicalPosition=v,e.LogicalSize=T,e.PhysicalPosition=N,e.PhysicalSize=R,e.WebviewWindow=V,e.WebviewWindowHandle=f,e.WindowManager=W,e.availableMonitors=async function(){return window.__TAURI_INVOKE__("plugin:window|available_monitors").then((e=>e.map(K)))},e.currentMonitor=async function(){return window.__TAURI_INVOKE__("plugin:window|current_monitor").then(K)},e.getAll=m,e.getCurrent=function(){return new V(window.__TAURI_METADATA__.__currentWindow.label,{skip:!0})},e.primaryMonitor=async function(){return window.__TAURI_INVOKE__("plugin:window|primary_monitor").then(K)},e}({});Object.defineProperty(window.__TAURI__,"window",{value:__TAURI_WINDOW__})} diff --git a/plugins/window/src/desktop_commands.rs b/plugins/window/src/desktop_commands.rs new file mode 100644 index 00000000..135e8d80 --- /dev/null +++ b/plugins/window/src/desktop_commands.rs @@ -0,0 +1,202 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use serde::{Deserialize, Serialize, Serializer}; +use tauri::{ + utils::config::WindowConfig, AppHandle, CursorIcon, Icon, Manager, Monitor, PhysicalPosition, + PhysicalSize, Position, Runtime, Size, Theme, UserAttentionType, Window, +}; + +#[derive(Debug, thiserror::Error)] +pub enum Error { + #[error("window not found")] + WindowNotFound, + #[error(transparent)] + Tauri(#[from] tauri::Error), +} + +impl Serialize for Error { + fn serialize(&self, serializer: S) -> std::result::Result + where + S: Serializer, + { + serializer.serialize_str(self.to_string().as_ref()) + } +} + +type Result = std::result::Result; + +#[derive(Deserialize)] +#[serde(untagged)] +pub enum IconDto { + #[cfg(any(feature = "icon-png", feature = "icon-ico"))] + File(std::path::PathBuf), + #[cfg(any(feature = "icon-png", feature = "icon-ico"))] + Raw(Vec), + Rgba { + rgba: Vec, + width: u32, + height: u32, + }, +} + +impl From for Icon { + fn from(icon: IconDto) -> Self { + match icon { + #[cfg(any(feature = "icon-png", feature = "icon-ico"))] + IconDto::File(path) => Self::File(path), + #[cfg(any(feature = "icon-png", feature = "icon-ico"))] + IconDto::Raw(raw) => Self::Raw(raw), + IconDto::Rgba { + rgba, + width, + height, + } => Self::Rgba { + rgba, + width, + height, + }, + } + } +} + +#[tauri::command] +pub async fn create(app: AppHandle, options: WindowConfig) -> Result<()> { + tauri::window::WindowBuilder::from_config(&app, options).build()?; + Ok(()) +} + +fn get_window(window: Window, label: Option) -> Result> { + match label { + Some(l) if !l.is_empty() => window.get_window(&l).ok_or(Error::WindowNotFound), + _ => Ok(window), + } +} + +macro_rules! getter { + ($cmd: ident, $ret: ty) => { + #[tauri::command] + pub async fn $cmd(window: Window, label: Option) -> Result<$ret> { + get_window(window, label)?.$cmd().map_err(Into::into) + } + }; +} + +macro_rules! setter { + ($cmd: ident) => { + #[tauri::command] + pub async fn $cmd(window: Window, label: Option) -> Result<()> { + get_window(window, label)?.$cmd().map_err(Into::into) + } + }; + + ($cmd: ident, $input: ty) => { + #[tauri::command] + pub async fn $cmd( + window: Window, + label: Option, + value: $input, + ) -> Result<()> { + get_window(window, label)?.$cmd(value).map_err(Into::into) + } + }; +} + +getter!(scale_factor, f64); +getter!(inner_position, PhysicalPosition); +getter!(outer_position, PhysicalPosition); +getter!(inner_size, PhysicalSize); +getter!(outer_size, PhysicalSize); +getter!(is_fullscreen, bool); +getter!(is_minimized, bool); +getter!(is_maximized, bool); +getter!(is_decorated, bool); +getter!(is_resizable, bool); +getter!(is_visible, bool); +getter!(title, String); +getter!(current_monitor, Option); +getter!(primary_monitor, Option); +getter!(available_monitors, Vec); +getter!(theme, Theme); + +setter!(center); +setter!(request_user_attention, Option); +setter!(set_resizable, bool); +setter!(set_title, &str); +setter!(maximize); +setter!(unmaximize); +setter!(minimize); +setter!(unminimize); +setter!(show); +setter!(hide); +setter!(close); +setter!(set_decorations, bool); +setter!(set_shadow, bool); +setter!(set_always_on_top, bool); +setter!(set_content_protected, bool); +setter!(set_size, Size); +setter!(set_min_size, Option); +setter!(set_max_size, Option); +setter!(set_position, Position); +setter!(set_fullscreen, bool); +setter!(set_focus); +setter!(set_skip_taskbar, bool); +setter!(set_cursor_grab, bool); +setter!(set_cursor_visible, bool); +setter!(set_cursor_icon, CursorIcon); +setter!(set_cursor_position, Position); +setter!(set_ignore_cursor_events, bool); +setter!(start_dragging); +setter!(print); + +#[tauri::command] +pub async fn set_icon( + window: Window, + label: Option, + value: IconDto, +) -> Result<()> { + get_window(window, label)? + .set_icon(value.into()) + .map_err(Into::into) +} + +#[tauri::command] +pub async fn toggle_maximize(window: Window, label: Option) -> Result<()> { + let window = get_window(window, label)?; + match window.is_maximized()? { + true => window.unmaximize()?, + false => window.maximize()?, + }; + Ok(()) +} + +#[tauri::command] +pub async fn internal_toggle_maximize( + window: Window, + label: Option, +) -> Result<()> { + let window = get_window(window, label)?; + if window.is_resizable()? { + match window.is_maximized()? { + true => window.unmaximize()?, + false => window.maximize()?, + }; + } + Ok(()) +} + +#[cfg(any(debug_assertions, feature = "devtools"))] +#[tauri::command] +pub async fn internal_toggle_devtools( + window: Window, + label: Option, +) -> Result<()> { + let window = get_window(window, label)?; + if window.is_devtools_open() { + window.close_devtools(); + } else { + window.open_devtools(); + } + Ok(()) +} diff --git a/plugins/window/src/lib.rs b/plugins/window/src/lib.rs new file mode 100644 index 00000000..1efeae15 --- /dev/null +++ b/plugins/window/src/lib.rs @@ -0,0 +1,97 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +use tauri::{ + plugin::{Builder, TauriPlugin}, + Runtime, +}; + +#[cfg(desktop)] +mod desktop_commands; + +pub fn init() -> TauriPlugin { + let mut init_script = String::new(); + // window.print works on Linux/Windows; need to use the API on macOS + #[cfg(any(target_os = "macos", target_os = "ios"))] + { + init_script.push_str(include_str!("./scripts/print.js")); + } + init_script.push_str(include_str!("./scripts/drag.js")); + #[cfg(any(debug_assertions, feature = "devtools"))] + init_script.push_str(include_str!("./scripts/toggle-devtools.js")); + + init_script.push_str(include_str!("api-iife.js")); + + Builder::new("window") + .js_init_script(init_script) + .invoke_handler(|invoke| { + #[cfg(desktop)] + { + let handler: Box) -> bool> = + Box::new(tauri::generate_handler![ + desktop_commands::create, + // getters + desktop_commands::scale_factor, + desktop_commands::inner_position, + desktop_commands::outer_position, + desktop_commands::inner_size, + desktop_commands::outer_size, + desktop_commands::is_fullscreen, + desktop_commands::is_minimized, + desktop_commands::is_maximized, + desktop_commands::is_decorated, + desktop_commands::is_resizable, + desktop_commands::is_visible, + desktop_commands::title, + desktop_commands::current_monitor, + desktop_commands::primary_monitor, + desktop_commands::available_monitors, + desktop_commands::theme, + // setters + desktop_commands::center, + desktop_commands::request_user_attention, + desktop_commands::set_resizable, + desktop_commands::set_title, + desktop_commands::maximize, + desktop_commands::unmaximize, + desktop_commands::minimize, + desktop_commands::unminimize, + desktop_commands::show, + desktop_commands::hide, + desktop_commands::close, + desktop_commands::set_decorations, + desktop_commands::set_shadow, + desktop_commands::set_always_on_top, + desktop_commands::set_content_protected, + desktop_commands::set_size, + desktop_commands::set_min_size, + desktop_commands::set_max_size, + desktop_commands::set_position, + desktop_commands::set_fullscreen, + desktop_commands::set_focus, + desktop_commands::set_skip_taskbar, + desktop_commands::set_cursor_grab, + desktop_commands::set_cursor_visible, + desktop_commands::set_cursor_icon, + desktop_commands::set_cursor_position, + desktop_commands::set_ignore_cursor_events, + desktop_commands::start_dragging, + desktop_commands::print, + desktop_commands::set_icon, + desktop_commands::toggle_maximize, + desktop_commands::internal_toggle_maximize, + #[cfg(any(debug_assertions, feature = "devtools"))] + desktop_commands::internal_toggle_devtools, + ]); + #[allow(clippy::needless_return)] + return handler(invoke); + } + #[cfg(mobile)] + { + invoke.resolver.reject("Window API not available on mobile"); + return true; + } + }) + .build() +} diff --git a/plugins/window/src/scripts/drag.js b/plugins/window/src/scripts/drag.js new file mode 100644 index 00000000..3b227bc6 --- /dev/null +++ b/plugins/window/src/scripts/drag.js @@ -0,0 +1,17 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +document.addEventListener("mousedown", (e) => { + if (e.target.hasAttribute("data-tauri-drag-region") && e.buttons === 1) { + // prevents text cursor + e.preventDefault(); + // fix #2549: double click on drag region edge causes content to maximize without window sizing change + // https://github.com/tauri-apps/tauri/issues/2549#issuecomment-1250036908 + e.stopImmediatePropagation(); + + // start dragging if the element has a `tauri-drag-region` data attribute and maximize on double-clicking it + const cmd = e.detail === 2 ? "internal_toggle_maximize" : "start_dragging"; + window.__TAURI_INVOKE__("plugin:window|" + cmd); + } +}); diff --git a/plugins/window/src/scripts/print.js b/plugins/window/src/scripts/print.js new file mode 100644 index 00000000..1e833766 --- /dev/null +++ b/plugins/window/src/scripts/print.js @@ -0,0 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +window.print = function () { + return window.__TAURI_INVOKE__("plugin:window|print"); +}; diff --git a/plugins/window/src/scripts/toggle-devtools.js b/plugins/window/src/scripts/toggle-devtools.js new file mode 100644 index 00000000..42c4bdba --- /dev/null +++ b/plugins/window/src/scripts/toggle-devtools.js @@ -0,0 +1,26 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + +(function () { + function toggleDevtoolsHotkey() { + const isHotkey = navigator.appVersion.includes("Mac") + ? (event) => event.metaKey && event.altKey && event.key === "I" + : (event) => event.ctrlKey && event.shiftKey && event.key === "I"; + + document.addEventListener("keydown", (event) => { + if (isHotkey(event)) { + window.__TAURI_INVOKE__("plugin:window|internal_toggle_devtools"); + } + }); + } + + if ( + document.readyState === "complete" || + document.readyState === "interactive" + ) { + toggleDevtoolsHotkey(); + } else { + window.addEventListener("DOMContentLoaded", toggleDevtoolsHotkey, true); + } +})(); diff --git a/plugins/window/tsconfig.json b/plugins/window/tsconfig.json new file mode 100644 index 00000000..5098169a --- /dev/null +++ b/plugins/window/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b6d93a34..34efef69 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,5 +1,9 @@ lockfileVersion: '6.0' +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + importers: .: @@ -19,6 +23,9 @@ importers: '@typescript-eslint/parser': specifier: ^5.58.0 version: 5.59.1(eslint@8.39.0)(typescript@5.0.4) + covector: + specifier: ^0.9.0 + version: 0.9.0 eslint: specifier: ^8.38.0 version: 8.39.0 @@ -26,14 +33,14 @@ importers: specifier: ^8.8.0 version: 8.8.0(eslint@8.39.0) eslint-config-standard-with-typescript: - specifier: ^34.0.1 - version: 34.0.1(@typescript-eslint/eslint-plugin@5.59.1)(eslint-plugin-import@2.27.5)(eslint-plugin-n@15.7.0)(eslint-plugin-promise@6.1.1)(eslint@8.39.0)(typescript@5.0.4) + specifier: ^35.0.0 + version: 35.0.0(@typescript-eslint/eslint-plugin@5.59.1)(eslint-plugin-import@2.27.5)(eslint-plugin-n@16.0.0)(eslint-plugin-promise@6.1.1)(eslint@8.39.0)(typescript@5.0.4) eslint-plugin-import: specifier: ^2.27.5 version: 2.27.5(@typescript-eslint/parser@5.59.1)(eslint@8.39.0) eslint-plugin-n: - specifier: ^15.7.0 - version: 15.7.0(eslint@8.39.0) + specifier: ^16.0.0 + version: 16.0.0(eslint@8.39.0) eslint-plugin-promise: specifier: ^6.1.1 version: 6.1.1(eslint@8.39.0) @@ -53,41 +60,53 @@ importers: examples/api: dependencies: '@tauri-apps/api': - specifier: 2.0.0-alpha.3 - version: 2.0.0-alpha.3 - '@tauri-apps/cli': - specifier: 2.0.0-alpha.8 - version: 2.0.0-alpha.8 - '@zerodevx/svelte-json-view': - specifier: 0.2.1 - version: 0.2.1 - tauri-plugin-barcode-scanner-api: + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 + '@tauri-apps/plugin-app': + specifier: 2.0.0-alpha.0 + version: link:../../plugins/app + '@tauri-apps/plugin-barcode-scanner': specifier: 0.0.0 version: link:../../plugins/barcode-scanner - tauri-plugin-cli-api: - specifier: 0.0.0 + '@tauri-apps/plugin-cli': + specifier: 2.0.0-alpha.0 version: link:../../plugins/cli - tauri-plugin-clipboard-api: - specifier: 0.0.0 - version: link:../../plugins/clipboard - tauri-plugin-dialog-api: - specifier: 0.0.0 + '@tauri-apps/plugin-clipboard-manager': + specifier: 2.0.0-alpha.0 + version: link:../../plugins/clipboard-manager + '@tauri-apps/plugin-dialog': + specifier: 2.0.0-alpha.0 version: link:../../plugins/dialog - tauri-plugin-fs-api: - specifier: 0.0.0 + '@tauri-apps/plugin-fs': + specifier: 2.0.0-alpha.0 version: link:../../plugins/fs - tauri-plugin-global-shortcut-api: - specifier: 0.0.0 + '@tauri-apps/plugin-global-shortcut': + specifier: 2.0.0-alpha.0 version: link:../../plugins/global-shortcut - tauri-plugin-http-api: - specifier: 0.0.0 + '@tauri-apps/plugin-http': + specifier: 2.0.0-alpha.0 version: link:../../plugins/http - tauri-plugin-notification-api: - specifier: 0.0.0 + '@tauri-apps/plugin-notification': + specifier: 2.0.0-alpha.0 version: link:../../plugins/notification - tauri-plugin-shell-api: - specifier: 0.0.0 + '@tauri-apps/plugin-os': + specifier: 2.0.0-alpha.0 + version: link:../../plugins/os + '@tauri-apps/plugin-process': + specifier: 2.0.0-alpha.0 + version: link:../../plugins/process + '@tauri-apps/plugin-shell': + specifier: 2.0.0-alpha.0 version: link:../../plugins/shell + '@tauri-apps/plugin-updater': + specifier: 2.0.0-alpha.0 + version: link:../../plugins/updater + '@tauri-apps/plugin-window': + specifier: 2.0.0-alpha.0 + version: link:../../plugins/window + '@zerodevx/svelte-json-view': + specifier: 0.2.1 + version: 0.2.1 devDependencies: '@iconify-json/codicon': specifier: ^1.1.10 @@ -98,6 +117,9 @@ importers: '@sveltejs/vite-plugin-svelte': specifier: ^1.0.1 version: 1.0.1(svelte@3.55.1)(vite@3.0.9) + '@tauri-apps/cli': + specifier: 2.0.0-alpha.9 + version: 2.0.0-alpha.9 internal-ip: specifier: ^7.0.0 version: 7.0.0 @@ -111,11 +133,21 @@ importers: specifier: ^3.0.9 version: 3.0.9 + plugins/app: + dependencies: + '@tauri-apps/api': + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 + devDependencies: + tslib: + specifier: ^2.5.0 + version: 2.5.0 + plugins/authenticator: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -124,8 +156,8 @@ importers: plugins/autostart: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -134,8 +166,8 @@ importers: plugins/barcode-scanner: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.4.1 @@ -144,18 +176,18 @@ importers: plugins/cli: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.4.1 version: 2.4.1 - plugins/clipboard: + plugins/clipboard-manager: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.4.1 @@ -164,60 +196,28 @@ importers: plugins/dialog: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.4.1 version: 2.4.1 - plugins/dialog/examples/tauri-app: - dependencies: - tauri-plugin-dialog-api: - specifier: link:../../ - version: link:../.. - devDependencies: - '@sveltejs/vite-plugin-svelte': - specifier: ^1.0.1 - version: 1.0.1(svelte@3.55.1)(vite@3.0.2) - '@tauri-apps/cli': - specifier: ^2.0.0-alpha.7 - version: 2.0.0-alpha.8 - internal-ip: - specifier: ^7.0.0 - version: 7.0.0 - svelte: - specifier: ^3.49.0 - version: 3.55.1 - vite: - specifier: ^3.0.2 - version: 3.0.2 - plugins/fs: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.4.1 version: 2.4.1 - plugins/fs-watch: - dependencies: - '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 - devDependencies: - tslib: - specifier: ^2.5.0 - version: 2.5.0 - plugins/global-shortcut: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.4.1 @@ -226,8 +226,8 @@ importers: plugins/http: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -236,8 +236,8 @@ importers: plugins/log: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -246,18 +246,38 @@ importers: plugins/notification: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.4.1 version: 2.4.1 + plugins/os: + dependencies: + '@tauri-apps/api': + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 + devDependencies: + tslib: + specifier: ^2.5.0 + version: 2.5.0 + plugins/positioner: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 + devDependencies: + tslib: + specifier: ^2.5.0 + version: 2.5.0 + + plugins/process: + dependencies: + '@tauri-apps/api': + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -266,24 +286,24 @@ importers: plugins/shell: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.4.1 version: 2.4.1 plugins/single-instance/examples/vanilla: - dependencies: + devDependencies: '@tauri-apps/cli': - specifier: ^2.0.0-alpha.8 - version: 2.0.0-alpha.8 + specifier: ^2.0.0-alpha.9 + version: 2.0.0-alpha.9 plugins/sql: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -292,8 +312,8 @@ importers: plugins/store: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -302,8 +322,18 @@ importers: plugins/stronghold: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 + devDependencies: + tslib: + specifier: ^2.5.0 + version: 2.5.0 + + plugins/updater: + dependencies: + '@tauri-apps/api': + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -312,8 +342,8 @@ importers: plugins/upload: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -322,8 +352,8 @@ importers: plugins/websocket: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -331,10 +361,7 @@ importers: plugins/websocket/examples/svelte-app: dependencies: - '@tauri-apps/cli': - specifier: ^2.0.0-alpha.8 - version: 2.0.0-alpha.8 - tauri-plugin-websocket-api: + '@tauri-apps/plugin-websocket': specifier: link:../../ version: link:../.. devDependencies: @@ -344,6 +371,9 @@ importers: '@sveltejs/kit': specifier: ^1.15.5 version: 1.15.8(svelte@3.58.0)(vite@4.3.3) + '@tauri-apps/cli': + specifier: 2.0.0-alpha.9 + version: 2.0.0-alpha.9 svelte: specifier: ^3.58.0 version: 3.58.0 @@ -360,11 +390,21 @@ importers: specifier: ^4.2.1 version: 4.3.3 + plugins/window: + dependencies: + '@tauri-apps/api': + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 + devDependencies: + tslib: + specifier: ^2.5.0 + version: 2.5.0 + plugins/window-state: dependencies: '@tauri-apps/api': - specifier: ^1.2.0 - version: 1.2.0 + specifier: 2.0.0-alpha.4 + version: 2.0.0-alpha.4 devDependencies: tslib: specifier: ^2.5.0 @@ -383,6 +423,130 @@ packages: resolution: {integrity: sha512-CQkeV+oJxUazwjlHD0/3ZD08QWKuGQkhnrKo3e6ly5pd48VUpXbb77q0xMU4+vc2CkJnDS02Eq/M9ugyX20XZA==} dev: true + /@covector/apply@0.8.0: + resolution: {integrity: sha512-t/yDcj9kzLl0NjmA86lET5ePGmGneHtcTlENdDEoWiJvLtjgtrCg9NcxMBHImEwIdUi1EsLQw9MgpWEZSMmtRg==} + dependencies: + '@covector/files': 0.6.1 + effection: 2.0.6 + lodash: 4.17.21 + semver: 7.3.8 + transitivePeerDependencies: + - encoding + dev: true + + /@covector/assemble@0.10.0: + resolution: {integrity: sha512-Ug8NMj/tEbRB3ZE7DhVL86AJiymi3T7AE6gBKVlWjSOQsAfj10bLRUUYXUrpFpt0uf1UGxldaqJshp9qemRKsA==} + dependencies: + '@covector/command': 0.6.1 + '@covector/files': 0.6.1 + effection: 2.0.6 + js-yaml: 4.1.0 + lodash: 4.17.21 + remark-frontmatter: 3.0.0 + remark-parse: 9.0.0 + remark-stringify: 9.0.1 + unified: 9.2.2 + transitivePeerDependencies: + - encoding + - supports-color + dev: true + + /@covector/changelog@0.8.0: + resolution: {integrity: sha512-INSuWMdGt96gkafwF+lK3o4113tqAuBNEP6VxjWGVUX4LRKRZlndwLua1Ckjc7TV5pMMfSTSUgBuc7AF/p2uzA==} + dependencies: + '@covector/files': 0.6.1 + effection: 2.0.6 + lodash: 4.17.21 + remark-parse: 9.0.0 + remark-stringify: 9.0.1 + unified: 9.2.2 + transitivePeerDependencies: + - encoding + - supports-color + dev: true + + /@covector/command@0.6.1: + resolution: {integrity: sha512-H44DLRVqRp/GarYqt1X1yo26+hBYqrrFqUstIb6b/+KRuuwN57VlHCvTlOnEK4Mn5bGZErFDrRiJ5yRCdMDYNw==} + dependencies: + '@effection/process': 2.1.2 + effection: 2.0.6 + strip-ansi: 6.0.1 + transitivePeerDependencies: + - encoding + dev: true + + /@covector/files@0.6.1: + resolution: {integrity: sha512-JQuh7LUqOvymOg/TYOfVZJJiXOrtCy2FD7/sNCAqabN6yOiVvY2kHQ134rqI20YnYtXghEbO7BZSPiyrCOiIYg==} + dependencies: + '@iarna/toml': 2.2.5 + '@tauri-apps/toml': 2.2.4 + globby: 11.1.0 + js-yaml: 4.1.0 + semver: 7.3.8 + dev: true + + /@effection/channel@2.0.4: + resolution: {integrity: sha512-JlopFnlubIGEKEwmoENsNqj2Tfxt0Xz6P8wFnmKVOajT9ggsFKgIaD3DwZ8ndJnHM+mw5BvKMaPGuuL7r3Pvuw==} + dependencies: + '@effection/core': 2.2.1 + '@effection/events': 2.0.4 + '@effection/stream': 2.0.4 + dev: true + + /@effection/core@2.2.1: + resolution: {integrity: sha512-uYItornfIcdEya1NrRbatPQyRc1DR+o1RNtpYkVyXMSf3bpShsPADdqPJmxTvGaa2CK6mLkZ+6onUNz06tsPWA==} + dependencies: + abort-controller: 3.0.0 + dev: true + + /@effection/events@2.0.4: + resolution: {integrity: sha512-7CsWy1h9JON+ZtIcQTcld4MWLs7JS09ncmiO1bLFQE3BaIEBjs98E89WtfGg66bXvlTYC0wTC7it03CcA/QEbA==} + dependencies: + '@effection/core': 2.2.1 + '@effection/stream': 2.0.4 + dev: true + + /@effection/fetch@2.0.5: + resolution: {integrity: sha512-NWrZYBgmNx686aslxf4J8CuquMIFVcG3LnONkGWQ41agDAX2lqQUOa5pAtUqj1hvEtb+l3lNawvpWbqFuNYYzA==} + dependencies: + '@effection/core': 2.2.1 + cross-fetch: 3.1.5 + transitivePeerDependencies: + - encoding + dev: true + + /@effection/main@2.1.1: + resolution: {integrity: sha512-NwQ4hN+Crja/8At8QCr2vXyTkd5kDdwnl1UqqspSm88y3YdVH/B8yvw89Y3j+E0teo3COY/zu5NcS/VnxkMnLQ==} + dependencies: + '@effection/core': 2.2.1 + chalk: 4.1.2 + stacktrace-parser: 0.1.10 + dev: true + + /@effection/process@2.1.2: + resolution: {integrity: sha512-hwanPqnyA1fyQNDFwoRo6fqrbX7akgLPv4fXYEOETElDjaXuLA88FHBPaDm52IJv2KI49beq9krdEaobWmFmlA==} + dependencies: + cross-spawn: 7.0.3 + ctrlc-windows: 2.1.0 + effection: 2.0.6 + shellwords: 0.1.1 + transitivePeerDependencies: + - encoding + dev: true + + /@effection/stream@2.0.4: + resolution: {integrity: sha512-XXDiUbX+2zBAFlV6r5HfwLzm1Ko1Had13HUNTJFR+fmtkb5uG9Y6eJuViphaYg0VBbsZTJfgTAZWzN4PsBT9Lg==} + dependencies: + '@effection/core': 2.2.1 + '@effection/subscription': 2.0.4 + dev: true + + /@effection/subscription@2.0.4: + resolution: {integrity: sha512-flr7bu4a9t3WuDAXodH2Y2LId8pPb3UEUtwYsUaGBWNxLJJ51t3uCdPybf57L5h4/bqxAwJosd3gyhAhKzxk0Q==} + dependencies: + '@effection/core': 2.2.1 + dev: true + /@esbuild/android-arm64@0.17.18: resolution: {integrity: sha512-/iq0aK0eeHgSC3z55ucMAHO05OIqmQehiGay8eP5l/5l+iEr4EIbh4/MI8xD9qRFjqzgkc0JkX0LculNC9mXBw==} engines: {node: '>=12'} @@ -647,6 +811,10 @@ packages: resolution: {integrity: sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==} dev: true + /@iarna/toml@2.2.5: + resolution: {integrity: sha512-trnsAYxU3xnS1gPHPyU961coFyLkh4gAD/0zQ5mymY4yOZ+CYvsPqUbOFSw0aDM4y0tV7tiFxL/1XfXPNC6IPg==} + dev: true + /@iconify-json/codicon@1.1.10: resolution: {integrity: sha512-xx3nX5k4UeDQnpX9D1T6L1RCEwyLtqu3Lqk9plYK+SoBSQ/kR73bPy9WbYyDVOw2MDw50JCSpZZYlBC718k7Sg==} dependencies: @@ -850,29 +1018,6 @@ packages: - supports-color dev: true - /@sveltejs/vite-plugin-svelte@1.0.1(svelte@3.55.1)(vite@3.0.2): - resolution: {integrity: sha512-PorCgUounn0VXcpeJu+hOweZODKmGuLHsLomwqSj+p26IwjjGffmYQfVHtiTWq+NqaUuuHWWG7vPge6UFw4Aeg==} - engines: {node: ^14.18.0 || >= 16} - peerDependencies: - diff-match-patch: ^1.0.5 - svelte: ^3.44.0 - vite: ^3.0.0 - peerDependenciesMeta: - diff-match-patch: - optional: true - dependencies: - '@rollup/pluginutils': 4.2.1 - debug: 4.3.4 - deepmerge: 4.3.1 - kleur: 4.1.5 - magic-string: 0.26.7 - svelte: 3.55.1 - svelte-hmr: 0.14.12(svelte@3.55.1) - vite: 3.0.2 - transitivePeerDependencies: - - supports-color - dev: true - /@sveltejs/vite-plugin-svelte@1.0.1(svelte@3.55.1)(vite@3.0.9): resolution: {integrity: sha512-PorCgUounn0VXcpeJu+hOweZODKmGuLHsLomwqSj+p26IwjjGffmYQfVHtiTWq+NqaUuuHWWG7vPge6UFw4Aeg==} engines: {node: ^14.18.0 || >= 16} @@ -915,102 +1060,111 @@ packages: - supports-color dev: true - /@tauri-apps/api@1.2.0: - resolution: {integrity: sha512-lsI54KI6HGf7VImuf/T9pnoejfgkNoXveP14pVV7XarrQ46rOejIVJLFqHI9sRReJMGdh2YuCoI3cc/yCWCsrw==} + /@tauri-apps/api@2.0.0-alpha.4: + resolution: {integrity: sha512-gWe5fFHbwFM+dmdDPtlDvVDVtoMneGRM+S8mECevWhKpXYxId0yxznE56YGAvPSJXC3vgsXw16mOmkTnEVKnaw==} engines: {node: '>= 14.6.0', npm: '>= 6.6.0', yarn: '>= 1.19.1'} dev: false - /@tauri-apps/api@2.0.0-alpha.3: - resolution: {integrity: sha512-F6seMDlcaxeCPy4gS0zJdp6Tet+0rd1qJi/fbKrOrhLM6Y5UtkiG1aSDnMPi+1udThSfadjhUwrLHINvfMCjzQ==} - engines: {node: '>= 14.6.0', npm: '>= 6.6.0', yarn: '>= 1.19.1'} - dev: false - - /@tauri-apps/cli-darwin-arm64@2.0.0-alpha.8: - resolution: {integrity: sha512-ZF9nkkYCDiAEKZFwjEbuqTcFVp+DBgem3edKjsZDYPQpWg0VcZOSYr0o3/RPC81T1/FAy1lq478mkcMe0efvEw==} + /@tauri-apps/cli-darwin-arm64@2.0.0-alpha.9: + resolution: {integrity: sha512-h7AQY4MbHyy7CLANfoegJyaypKQ3fYPlBA3mnhtF+zntrMxVTv+HO9sgn98jGnwlOak8y0NPPKJ6gZFu5GYiNg==} engines: {node: '>= 10'} cpu: [arm64] os: [darwin] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli-darwin-x64@2.0.0-alpha.8: - resolution: {integrity: sha512-N5V+tbP3qeAoXrrTZXvaLIeEWKCq11tqXoNFTkIZNGNC5yQdNpZSX0LqFqzmxVR1SHiOymebvcUlx+ADIpuXGw==} + /@tauri-apps/cli-darwin-x64@2.0.0-alpha.9: + resolution: {integrity: sha512-8RtvzZ4/1gZU8SvMaCygtjc9Q0bMnA0NuQKOMrehRfpvvy2gw/q8MMdw3WEawYGQHqEbr6YtNJmaR5wlsVk+IQ==} engines: {node: '>= 10'} cpu: [x64] os: [darwin] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli-linux-arm-gnueabihf@2.0.0-alpha.8: - resolution: {integrity: sha512-7LHfZA99ncMDUO/wCGMtrqmDHt1uEKZiNmuzPljWLUwVvbAn0pNWNygnvPNVLEOyav5NnZSGPqT1Zmn+L6Fpyg==} + /@tauri-apps/cli-linux-arm-gnueabihf@2.0.0-alpha.9: + resolution: {integrity: sha512-nHAgFEJ2DXXEx96FLPnqZ9vfFGw7Hr2ZaY+xy28llXWljCOguWi8wdHv4OMnq0hbOkegVGplYPc4RSQ5uUia2Q==} engines: {node: '>= 10'} cpu: [arm] os: [linux] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli-linux-arm64-gnu@2.0.0-alpha.8: - resolution: {integrity: sha512-imq2MdhWdREvL2sqbU26mzH9sgSvfNWP0uvCPvPxUhK157xqdtGw+Gqm00hwnhTuT5bOFlsUNfnG2U19k1qMpA==} + /@tauri-apps/cli-linux-arm64-gnu@2.0.0-alpha.9: + resolution: {integrity: sha512-ETmUoTp+UgHypPpsq3OYwbcmX8MqjCGIUAzDHoVFpYuj2oqHw0ZaCx2lQPTnqW5G5L9X9VXhMAcRB8OBZG5KFw==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli-linux-arm64-musl@2.0.0-alpha.8: - resolution: {integrity: sha512-7hXEyvCosBHIN6ahkbFOI5JoyWZAulc0sYd3hWh9V/MBfU+LlPiapsJi6fdde0zew5nnzwcCtfEKkoR737tAig==} + /@tauri-apps/cli-linux-arm64-musl@2.0.0-alpha.9: + resolution: {integrity: sha512-S55E2u4LsQajoxkpYqd2skPEVG5hp+Mkhhnixfi+87q87n9iIvIqcH+4ejDXAPUrWNMsRKIWVURV2ZzivqK5Kw==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli-linux-x64-gnu@2.0.0-alpha.8: - resolution: {integrity: sha512-S9T/trKpXcLc7hVIv7xFrRBlaivHD/HLUz0nYAkI2izNGFmbP3QpkqQDdwpWN/fxneodNgI2/mDFC3NULClj+A==} + /@tauri-apps/cli-linux-x64-gnu@2.0.0-alpha.9: + resolution: {integrity: sha512-/0J5sJDu+cSrj67L4Q4FVANe1ffpsz3LZMQRkbWmT2ggd2Mxg8LZBtg7y5ysMfJg8xjKvymi+1mS2yU1B7/k9Q==} engines: {node: '>= 10'} cpu: [x64] os: [linux] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli-linux-x64-musl@2.0.0-alpha.8: - resolution: {integrity: sha512-90mx6vSFNBbctaPaKhkH+um51gOoRJwLFOadOkklHS5Q6S6GjtSa1lmBEFyKUTAfFPtmiacuNYtoKx7nqm+z1Q==} + /@tauri-apps/cli-linux-x64-musl@2.0.0-alpha.9: + resolution: {integrity: sha512-zjtf5H3c4amlBjIdDiQ3pmiMV/cmcPxaiH4KgyRD6NZXY9+gDk5dkzj3WAWegiD1ycz3bv5INO/tDxjk5ZSYlw==} engines: {node: '>= 10'} cpu: [x64] os: [linux] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli-win32-ia32-msvc@2.0.0-alpha.8: - resolution: {integrity: sha512-VAMsLJYfp6iVI7oJ+uIkfe8DKPRMtWDiSEkfFqvDyFX0WMTQl23B0AzYyapVwZc+WkTkLuoMLpIWMQCgAoQWfQ==} + /@tauri-apps/cli-win32-ia32-msvc@2.0.0-alpha.9: + resolution: {integrity: sha512-Hn0xDaEEMeXRzWCtew2MIYDky8hF+BOos0PP4qyCX14LfChpgSIT0aMYC8xbSfj9N9pwznhNBxgOtCADaTPWcg==} engines: {node: '>= 10'} cpu: [ia32] os: [win32] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli-win32-x64-msvc@2.0.0-alpha.8: - resolution: {integrity: sha512-zvWd13hRfRM0AEJJZ4t4CeB/cyru8hvbB6c+sxYDS9GPRWfHSH5dIeKoHhnMwP5fEOPZLN7VaeEP6tC88trD6g==} + /@tauri-apps/cli-win32-x64-msvc@2.0.0-alpha.9: + resolution: {integrity: sha512-541nR7UoasX/fnEWhC14H4Ppj17Aa1fbCyFb9+zmWjupVkEGf/yQFvdWRHdmCkgOdGuxPahR5hbOPh+jvaklFw==} engines: {node: '>= 10'} cpu: [x64] os: [win32] requiresBuild: true + dev: true optional: true - /@tauri-apps/cli@2.0.0-alpha.8: - resolution: {integrity: sha512-cXt6pxh7oiV8Htz7eTPor7if4aN9f9emn10+5h2Y82YzST7I7wKXsrjuk0HIyzUiqiQjUgl3iT9gh791zgtI3w==} + /@tauri-apps/cli@2.0.0-alpha.9: + resolution: {integrity: sha512-roQNpFC3Ijni/c7TCkCpUg3gWKfxs1ftWSQJyCthqIPRM5J7I2vOfhcUXIZw9glrxDp5npyRW0xYyI7W/424uQ==} engines: {node: '>= 10'} hasBin: true optionalDependencies: - '@tauri-apps/cli-darwin-arm64': 2.0.0-alpha.8 - '@tauri-apps/cli-darwin-x64': 2.0.0-alpha.8 - '@tauri-apps/cli-linux-arm-gnueabihf': 2.0.0-alpha.8 - '@tauri-apps/cli-linux-arm64-gnu': 2.0.0-alpha.8 - '@tauri-apps/cli-linux-arm64-musl': 2.0.0-alpha.8 - '@tauri-apps/cli-linux-x64-gnu': 2.0.0-alpha.8 - '@tauri-apps/cli-linux-x64-musl': 2.0.0-alpha.8 - '@tauri-apps/cli-win32-ia32-msvc': 2.0.0-alpha.8 - '@tauri-apps/cli-win32-x64-msvc': 2.0.0-alpha.8 + '@tauri-apps/cli-darwin-arm64': 2.0.0-alpha.9 + '@tauri-apps/cli-darwin-x64': 2.0.0-alpha.9 + '@tauri-apps/cli-linux-arm-gnueabihf': 2.0.0-alpha.9 + '@tauri-apps/cli-linux-arm64-gnu': 2.0.0-alpha.9 + '@tauri-apps/cli-linux-arm64-musl': 2.0.0-alpha.9 + '@tauri-apps/cli-linux-x64-gnu': 2.0.0-alpha.9 + '@tauri-apps/cli-linux-x64-musl': 2.0.0-alpha.9 + '@tauri-apps/cli-win32-ia32-msvc': 2.0.0-alpha.9 + '@tauri-apps/cli-win32-x64-msvc': 2.0.0-alpha.9 + dev: true + + /@tauri-apps/toml@2.2.4: + resolution: {integrity: sha512-NJV/pdgJObDlDWi5+MTHZ2qyNvdL0dlHqQ72nzQYXWbW1LHMPXgCJYl0pLqL1XxxLtxtInYbtVCGVAcwhGxdkw==} + dev: true /@types/cookie@0.5.1: resolution: {integrity: sha512-COUnqfB2+ckwXXSFInsFdOAWQzCCx+a5hq2ruyj+Vjund94RJQd4LG2u9hnvJrTgunKAaax7ancBYlDrNYxA0g==} @@ -1028,6 +1182,12 @@ packages: resolution: {integrity: sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==} dev: true + /@types/mdast@3.0.11: + resolution: {integrity: sha512-Y/uImid8aAwrEA24/1tcRZwpxX3pIFTSilcNDKSPn+Y2iDywSEachzRuvgAYYLR3wpGXAsMbv5lvKLDZLeYPAw==} + dependencies: + '@types/unist': 2.0.6 + dev: true + /@types/pug@2.0.6: resolution: {integrity: sha512-SnHmG9wN1UVmagJOnyo/qkk0Z7gejYxOYYmaAwr5u2yFYfsupN3sg10kyzN8Hep/2zbHxCnsumxOoRIRMBwKCg==} dev: true @@ -1040,6 +1200,10 @@ packages: resolution: {integrity: sha512-21cFJr9z3g5dW8B0CVI9g2O9beqaThGQ6ZFBqHfwhzLDKUxaqTIy3vnfah/UPkfOiF2pLq+tGz+W8RyCskuslw==} dev: true + /@types/unist@2.0.6: + resolution: {integrity: sha512-PBjIUxZHOuj0R15/xuwJYjFi+KZdNFrehocChv4g5hu6aFroHue8m0lBP0POdK2nKzbw0cgV1mws8+V/JAcEkQ==} + dev: true + /@typescript-eslint/eslint-plugin@5.59.1(@typescript-eslint/parser@5.59.1)(eslint@8.39.0)(typescript@5.0.4): resolution: {integrity: sha512-AVi0uazY5quFB9hlp2Xv+ogpfpk77xzsgsIEWyVS7uK/c7MZ5tw7ZPbapa0SbfkqE0fsAMkz5UwtgMLVk2BQAg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -1308,6 +1472,13 @@ packages: resolution: {integrity: sha512-yaLojLYTi08vccUKRg/XSRCCPoyzCZqrG+W8mVhJEGiOfFKAmWqNH6b+/il1gG3V1UaEe7amj2mzmo1mo4q1iA==} dev: false + /abort-controller@3.0.0: + resolution: {integrity: sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==} + engines: {node: '>=6.5'} + dependencies: + event-target-shim: 5.0.1 + dev: true + /acorn-jsx@5.3.2(acorn@8.8.1): resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} peerDependencies: @@ -1331,6 +1502,13 @@ packages: uri-js: 4.4.1 dev: true + /ansi-escapes@4.3.2: + resolution: {integrity: sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==} + engines: {node: '>=8'} + dependencies: + type-fest: 0.21.3 + dev: true + /ansi-regex@5.0.1: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} engines: {node: '>=8'} @@ -1391,15 +1569,31 @@ packages: es-shim-unscopables: 1.0.0 dev: true + /bail@1.0.5: + resolution: {integrity: sha512-xFbRxM1tahm08yHBP16MMjVUAvDaBMD38zsM9EMAUN61omwLmKlOpB/Zku5QkjZ8TZ4vn53pj+t518cH0S03RQ==} + dev: true + /balanced-match@1.0.2: resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} dev: true + /base64-js@1.5.1: + resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} + dev: true + /binary-extensions@2.2.0: resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==} engines: {node: '>=8'} dev: true + /bl@4.1.0: + resolution: {integrity: sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==} + dependencies: + buffer: 5.7.1 + inherits: 2.0.4 + readable-stream: 3.6.2 + dev: true + /brace-expansion@1.1.11: resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} dependencies: @@ -1422,6 +1616,13 @@ packages: resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} dev: true + /buffer@5.7.1: + resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==} + dependencies: + base64-js: 1.5.1 + ieee754: 1.2.1 + dev: true + /builtin-modules@3.3.0: resolution: {integrity: sha512-zhaCDicdLuWN5UbN5IMnFqNMhNfo919sH85y2/ea+5Yg9TsTkeZxpL+JLbp6cgYFS4sRLp3YV4S6yDuqVWHYOw==} engines: {node: '>=6'} @@ -1430,7 +1631,7 @@ packages: /builtins@5.0.1: resolution: {integrity: sha512-qwVpFEHNfhYJIzNRBvd2C1kyo6jz3ZSMPyyuR47OPdiKWlbYnZNyDWuyR175qDnAJLiCo5fBBqPb3RiXgWlkOQ==} dependencies: - semver: 7.3.8 + semver: 7.5.1 dev: true /busboy@1.6.0: @@ -1465,6 +1666,22 @@ packages: supports-color: 7.2.0 dev: true + /character-entities-legacy@1.1.4: + resolution: {integrity: sha512-3Xnr+7ZFS1uxeiUDvV02wQ+QDbc55o97tIV5zHScSPJpcLm/r0DFPcoY3tYRp+VZukxuMeKgXYmsXQHO05zQeA==} + dev: true + + /character-entities@1.2.4: + resolution: {integrity: sha512-iBMyeEHxfVnIakwOuDXpVkc54HijNgCyQB2w0VfGQThle6NXn50zU6V/u+LDhxHcDUPojn6Kpga3PTAD8W1bQw==} + dev: true + + /character-reference-invalid@1.1.4: + resolution: {integrity: sha512-mKKUkUbhPpQlCOfIuZkvSEgktjPFIsZKRRbC6KWVEMvlzblj3i3asQv5ODsrwt0N3pHAEvjP8KTQPHkp0+6jOg==} + dev: true + + /chardet@0.7.0: + resolution: {integrity: sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==} + dev: true + /chokidar@3.5.3: resolution: {integrity: sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==} engines: {node: '>= 8.10.0'} @@ -1480,6 +1697,37 @@ packages: fsevents: 2.3.2 dev: true + /cli-cursor@3.1.0: + resolution: {integrity: sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw==} + engines: {node: '>=8'} + dependencies: + restore-cursor: 3.1.0 + dev: true + + /cli-spinners@2.9.0: + resolution: {integrity: sha512-4/aL9X3Wh0yiMQlE+eeRhWP6vclO3QRtw1JHKIT0FFUs5FjpFmESqtMvYZ0+lbzBw900b95mS0hohy+qn2VK/g==} + engines: {node: '>=6'} + dev: true + + /cli-width@3.0.0: + resolution: {integrity: sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw==} + engines: {node: '>= 10'} + dev: true + + /cliui@8.0.1: + resolution: {integrity: sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==} + engines: {node: '>=12'} + dependencies: + string-width: 4.2.3 + strip-ansi: 6.0.1 + wrap-ansi: 7.0.0 + dev: true + + /clone@1.0.4: + resolution: {integrity: sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==} + engines: {node: '>=0.8'} + dev: true + /color-convert@2.0.1: resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} engines: {node: '>=7.0.0'} @@ -1512,6 +1760,32 @@ packages: engines: {node: '>= 0.6'} dev: true + /covector@0.9.0: + resolution: {integrity: sha512-uGDdpb33ZOwThylB8GKWpygGrpbipt7YRGUtIKnS4EBLugXz7ZM+Aj3g+BXzvFJC87S0My1+y98ejcXAoQkwbQ==} + hasBin: true + dependencies: + '@covector/apply': 0.8.0 + '@covector/assemble': 0.10.0 + '@covector/changelog': 0.8.0 + '@covector/command': 0.6.1 + '@covector/files': 0.6.1 + effection: 2.0.6 + globby: 11.1.0 + inquirer: 8.2.5 + yargs: 17.7.2 + transitivePeerDependencies: + - encoding + - supports-color + dev: true + + /cross-fetch@3.1.5: + resolution: {integrity: sha512-lvb1SBsI0Z7GDwmuid+mU3kWVBwTVUbe7S0H52yaaAdQOXq2YktTCZdlAcNKFzE6QtRz0snpw9bNiPeOIkkQvw==} + dependencies: + node-fetch: 2.6.7 + transitivePeerDependencies: + - encoding + dev: true + /cross-spawn@7.0.3: resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==} engines: {node: '>= 8'} @@ -1529,6 +1803,10 @@ packages: source-map-js: 1.0.2 dev: true + /ctrlc-windows@2.1.0: + resolution: {integrity: sha512-OrX5KI+K+2NMN91QIhYZdW7VDO2YsSdTZW494pA7Nvw/wBdU2hz+MGP006bR978zOTrG6Q8EIeJvLJmLqc6MsQ==} + dev: true + /debug@3.2.7: resolution: {integrity: sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==} peerDependencies: @@ -1573,6 +1851,12 @@ packages: execa: 5.1.1 dev: true + /defaults@1.0.4: + resolution: {integrity: sha512-eFuaLoy/Rxalv2kr+lqMlUnrDWV+3j4pljOIJgLIhI058IQfWJ7vXhyEIHu+HtC738klGALYxOKDO0bQP3tg8A==} + dependencies: + clone: 1.0.4 + dev: true + /define-properties@1.1.4: resolution: {integrity: sha512-uckOqKcfaVvtBdsVkdPv3XjveQJsNQqmhXgRi8uhvWWuPYZCNlzT8qAyblUgNoXdHdjMTzAqeGjAoli8f+bzPA==} engines: {node: '>= 0.4'} @@ -1623,6 +1907,24 @@ packages: resolution: {integrity: sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==} dev: true + /effection@2.0.6: + resolution: {integrity: sha512-Bc8pXBrNQFumPLAmwj6mh7JeZFbLRoPYkqhU8WkVAuwHCQZh2xHE5zxaceL1nWR78ZuqFwwXlrTODDQLIkeQBw==} + dependencies: + '@effection/channel': 2.0.4 + '@effection/core': 2.2.1 + '@effection/events': 2.0.4 + '@effection/fetch': 2.0.5 + '@effection/main': 2.1.1 + '@effection/stream': 2.0.4 + '@effection/subscription': 2.0.4 + transitivePeerDependencies: + - encoding + dev: true + + /emoji-regex@8.0.0: + resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} + dev: true + /es-abstract@1.20.5: resolution: {integrity: sha512-7h8MM2EQhsCA7pU/Nv78qOXFpD8Rhqd12gYiSJVkrH9+e8VuA8JlPJK/hQjjlLv6pJvx/z1iRFKzYb0XT/RuAQ==} engines: {node: '>= 0.4'} @@ -1912,6 +2214,16 @@ packages: '@esbuild/win32-x64': 0.17.18 dev: true + /escalade@3.1.1: + resolution: {integrity: sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==} + engines: {node: '>=6'} + dev: true + + /escape-string-regexp@1.0.5: + resolution: {integrity: sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==} + engines: {node: '>=0.8.0'} + dev: true + /escape-string-regexp@4.0.0: resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} engines: {node: '>=10'} @@ -1926,10 +2238,10 @@ packages: eslint: 8.39.0 dev: true - /eslint-config-standard-with-typescript@34.0.1(@typescript-eslint/eslint-plugin@5.59.1)(eslint-plugin-import@2.27.5)(eslint-plugin-n@15.7.0)(eslint-plugin-promise@6.1.1)(eslint@8.39.0)(typescript@5.0.4): - resolution: {integrity: sha512-J7WvZeLtd0Vr9F+v4dZbqJCLD16cbIy4U+alJMq4MiXdpipdBM3U5NkXaGUjePc4sb1ZE01U9g6VuTBpHHz1fg==} + /eslint-config-standard-with-typescript@35.0.0(@typescript-eslint/eslint-plugin@5.59.1)(eslint-plugin-import@2.27.5)(eslint-plugin-n@16.0.0)(eslint-plugin-promise@6.1.1)(eslint@8.39.0)(typescript@5.0.4): + resolution: {integrity: sha512-Xa7DY9GgduZyp0qmXxBF0/dB+Vm4/DgWu1lGpNLJV2d46aCaUxTKDEnkzjUWX/1O9S0a+Dhnw7A4oI0JpYzwtw==} peerDependencies: - '@typescript-eslint/eslint-plugin': ^5.43.0 + '@typescript-eslint/eslint-plugin': ^5.50.0 eslint: ^8.0.1 eslint-plugin-import: ^2.25.2 eslint-plugin-n: ^15.0.0 @@ -1939,16 +2251,16 @@ packages: '@typescript-eslint/eslint-plugin': 5.59.1(@typescript-eslint/parser@5.59.1)(eslint@8.39.0)(typescript@5.0.4) '@typescript-eslint/parser': 5.59.1(eslint@8.39.0)(typescript@5.0.4) eslint: 8.39.0 - eslint-config-standard: 17.0.0(eslint-plugin-import@2.27.5)(eslint-plugin-n@15.7.0)(eslint-plugin-promise@6.1.1)(eslint@8.39.0) + eslint-config-standard: 17.0.0(eslint-plugin-import@2.27.5)(eslint-plugin-n@16.0.0)(eslint-plugin-promise@6.1.1)(eslint@8.39.0) eslint-plugin-import: 2.27.5(@typescript-eslint/parser@5.59.1)(eslint@8.39.0) - eslint-plugin-n: 15.7.0(eslint@8.39.0) + eslint-plugin-n: 16.0.0(eslint@8.39.0) eslint-plugin-promise: 6.1.1(eslint@8.39.0) typescript: 5.0.4 transitivePeerDependencies: - supports-color dev: true - /eslint-config-standard@17.0.0(eslint-plugin-import@2.27.5)(eslint-plugin-n@15.7.0)(eslint-plugin-promise@6.1.1)(eslint@8.39.0): + /eslint-config-standard@17.0.0(eslint-plugin-import@2.27.5)(eslint-plugin-n@16.0.0)(eslint-plugin-promise@6.1.1)(eslint@8.39.0): resolution: {integrity: sha512-/2ks1GKyqSOkH7JFvXJicu0iMpoojkwB+f5Du/1SC0PtBL+s8v30k9njRZ21pm2drKYm2342jFnGWzttxPmZVg==} peerDependencies: eslint: ^8.0.1 @@ -1958,7 +2270,7 @@ packages: dependencies: eslint: 8.39.0 eslint-plugin-import: 2.27.5(@typescript-eslint/parser@5.59.1)(eslint@8.39.0) - eslint-plugin-n: 15.7.0(eslint@8.39.0) + eslint-plugin-n: 16.0.0(eslint@8.39.0) eslint-plugin-promise: 6.1.1(eslint@8.39.0) dev: true @@ -2001,15 +2313,15 @@ packages: - supports-color dev: true - /eslint-plugin-es@4.1.0(eslint@8.39.0): - resolution: {integrity: sha512-GILhQTnjYE2WorX5Jyi5i4dz5ALWxBIdQECVQavL6s7cI76IZTDWleTHkxz/QT3kvcs2QlGHvKLYsSlPOlPXnQ==} - engines: {node: '>=8.10.0'} + /eslint-plugin-es-x@6.2.1(eslint@8.39.0): + resolution: {integrity: sha512-uR34zUhZ9EBoiSD2DdV5kHLpydVEvwWqjteUr9sXRgJknwbKZJZhdJ7uFnaTtd+Nr/2G3ceJHnHXrFhJ67n3Tw==} + engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: - eslint: '>=4.19.1' + eslint: '>=8' dependencies: + '@eslint-community/eslint-utils': 4.4.0(eslint@8.39.0) + '@eslint-community/regexpp': 4.5.0 eslint: 8.39.0 - eslint-utils: 2.1.0 - regexpp: 3.2.0 dev: true /eslint-plugin-import@2.27.5(@typescript-eslint/parser@5.59.1)(eslint@8.39.0): @@ -2045,21 +2357,21 @@ packages: - supports-color dev: true - /eslint-plugin-n@15.7.0(eslint@8.39.0): - resolution: {integrity: sha512-jDex9s7D/Qial8AGVIHq4W7NswpUD5DPDL2RH8Lzd9EloWUuvUkHfv4FRLMipH5q2UtyurorBkPeNi1wVWNh3Q==} - engines: {node: '>=12.22.0'} + /eslint-plugin-n@16.0.0(eslint@8.39.0): + resolution: {integrity: sha512-akkZTE3hsHBrq6CwmGuYCzQREbVUrA855kzcHqe6i0FLBkeY7Y/6tThCVkjUnjhvRBAlc+8lILcSe5QvvDpeZQ==} + engines: {node: '>=16.0.0'} peerDependencies: eslint: '>=7.0.0' dependencies: + '@eslint-community/eslint-utils': 4.4.0(eslint@8.39.0) builtins: 5.0.1 eslint: 8.39.0 - eslint-plugin-es: 4.1.0(eslint@8.39.0) - eslint-utils: 3.0.0(eslint@8.39.0) + eslint-plugin-es-x: 6.2.1(eslint@8.39.0) ignore: 5.2.1 - is-core-module: 2.11.0 + is-core-module: 2.12.0 minimatch: 3.1.2 - resolve: 1.22.1 - semver: 7.3.8 + resolve: 1.22.2 + semver: 7.5.1 dev: true /eslint-plugin-promise@6.1.1(eslint@8.39.0): @@ -2093,33 +2405,6 @@ packages: estraverse: 5.3.0 dev: true - /eslint-utils@2.1.0: - resolution: {integrity: sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==} - engines: {node: '>=6'} - dependencies: - eslint-visitor-keys: 1.3.0 - dev: true - - /eslint-utils@3.0.0(eslint@8.39.0): - resolution: {integrity: sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==} - engines: {node: ^10.0.0 || ^12.0.0 || >= 14.0.0} - peerDependencies: - eslint: '>=5' - dependencies: - eslint: 8.39.0 - eslint-visitor-keys: 2.1.0 - dev: true - - /eslint-visitor-keys@1.3.0: - resolution: {integrity: sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==} - engines: {node: '>=4'} - dev: true - - /eslint-visitor-keys@2.1.0: - resolution: {integrity: sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw==} - engines: {node: '>=10'} - dev: true - /eslint-visitor-keys@3.4.0: resolution: {integrity: sha512-HPpKPUBQcAsZOsHAFwTtIKcYlCje62XB7SEAcxjtmW6TD1WVpkS6i6/hOVtTZIl4zGj/mBqpFVGvaDneik+VoQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -2220,6 +2505,11 @@ packages: engines: {node: '>=0.10.0'} dev: true + /event-target-shim@5.0.1: + resolution: {integrity: sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==} + engines: {node: '>=6'} + dev: true + /execa@5.1.1: resolution: {integrity: sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==} engines: {node: '>=10'} @@ -2235,6 +2525,19 @@ packages: strip-final-newline: 2.0.0 dev: true + /extend@3.0.2: + resolution: {integrity: sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==} + dev: true + + /external-editor@3.1.0: + resolution: {integrity: sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew==} + engines: {node: '>=4'} + dependencies: + chardet: 0.7.0 + iconv-lite: 0.4.24 + tmp: 0.0.33 + dev: true + /fast-deep-equal@3.1.3: resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} dev: true @@ -2264,6 +2567,19 @@ packages: reusify: 1.0.4 dev: true + /fault@1.0.4: + resolution: {integrity: sha512-CJ0HCB5tL5fYTEA7ToAq5+kTwd++Borf1/bifxd9iT70QcXr4MRrO3Llf8Ifs70q+SJcGHFtnIE/Nw6giCtECA==} + dependencies: + format: 0.2.2 + dev: true + + /figures@3.2.0: + resolution: {integrity: sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==} + engines: {node: '>=8'} + dependencies: + escape-string-regexp: 1.0.5 + dev: true + /file-entry-cache@6.0.1: resolution: {integrity: sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==} engines: {node: ^10.12.0 || >=12.0.0} @@ -2298,6 +2614,11 @@ packages: resolution: {integrity: sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==} dev: true + /format@0.2.2: + resolution: {integrity: sha512-wzsgA6WOq+09wrU1tsJ09udeR/YZRaeArL9e1wPbFg3GG2yDnC2ldKpxs4xunpFF9DgqCqOIra3bc1HWrJ37Ww==} + engines: {node: '>=0.4.x'} + dev: true + /fs.realpath@1.0.0: resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} dev: true @@ -2328,6 +2649,11 @@ packages: resolution: {integrity: sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==} dev: true + /get-caller-file@2.0.5: + resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} + engines: {node: 6.* || 8.* || >= 10.*} + dev: true + /get-intrinsic@1.1.3: resolution: {integrity: sha512-QJVz1Tj7MS099PevUG5jvnt9tSkXN8K14dxQlikJuPt4uD9hHAHjLyLBiLR5zELelBdD9QNRAXZzsJx0WaDL9A==} dependencies: @@ -2461,6 +2787,17 @@ packages: engines: {node: '>=10.17.0'} dev: true + /iconv-lite@0.4.24: + resolution: {integrity: sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==} + engines: {node: '>=0.10.0'} + dependencies: + safer-buffer: 2.1.2 + dev: true + + /ieee754@1.2.1: + resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} + dev: true + /ignore@5.2.1: resolution: {integrity: sha512-d2qQLzTJ9WxQftPAuEQpSPmKqzxePjzVbpAVv62AQ64NTL+wR4JkrVqR/LqFsFEUsHDAiId52mJteHDFuDkElA==} engines: {node: '>= 4'} @@ -2494,6 +2831,27 @@ packages: resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} dev: true + /inquirer@8.2.5: + resolution: {integrity: sha512-QAgPDQMEgrDssk1XiwwHoOGYF9BAbUcc1+j+FhEvaOt8/cKRqyLn0U5qA6F74fGhTMGxf92pOvPBeh29jQJDTQ==} + engines: {node: '>=12.0.0'} + dependencies: + ansi-escapes: 4.3.2 + chalk: 4.1.2 + cli-cursor: 3.1.0 + cli-width: 3.0.0 + external-editor: 3.1.0 + figures: 3.2.0 + lodash: 4.17.21 + mute-stream: 0.0.8 + ora: 5.4.1 + run-async: 2.4.1 + rxjs: 7.8.1 + string-width: 4.2.3 + strip-ansi: 6.0.1 + through: 2.3.8 + wrap-ansi: 7.0.0 + dev: true + /internal-ip@7.0.0: resolution: {integrity: sha512-qE4TeD4brqC45Vq/+VASeMiS1KRyfBkR6HT2sh9pZVVCzSjPkaCEfKFU+dL0PRv7NHJtvoKN2r82G6wTfzorkw==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} @@ -2523,6 +2881,17 @@ packages: engines: {node: '>= 10'} dev: true + /is-alphabetical@1.0.4: + resolution: {integrity: sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg==} + dev: true + + /is-alphanumerical@1.0.4: + resolution: {integrity: sha512-UzoZUr+XfVz3t3v4KyGEniVL9BDRoQtY7tOyrRybkVNjDFWyo1yhXNGrrBTQxp3ib9BLAWs7k2YKBQsFRkZG9A==} + dependencies: + is-alphabetical: 1.0.4 + is-decimal: 1.0.4 + dev: true + /is-bigint@1.0.4: resolution: {integrity: sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==} dependencies: @@ -2544,6 +2913,11 @@ packages: has-tostringtag: 1.0.0 dev: true + /is-buffer@2.0.5: + resolution: {integrity: sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ==} + engines: {node: '>=4'} + dev: true + /is-builtin-module@3.2.1: resolution: {integrity: sha512-BSLE3HnV2syZ0FK0iMA/yUGplUeMmNz4AW5fnTunbCIqZi4vG3WjJT9FHMy5D69xmAYBHXQhJdALdpwVxV501A==} engines: {node: '>=6'} @@ -2562,6 +2936,12 @@ packages: has: 1.0.3 dev: true + /is-core-module@2.12.0: + resolution: {integrity: sha512-RECHCBCd/viahWmwj6enj19sKbHfJrddi/6cBDsNTKbNq0f7VeaUkBo60BqzvPqo/W54ChS62Z5qyun7cfOMqQ==} + dependencies: + has: 1.0.3 + dev: true + /is-date-object@1.0.5: resolution: {integrity: sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==} engines: {node: '>= 0.4'} @@ -2569,11 +2949,20 @@ packages: has-tostringtag: 1.0.0 dev: true + /is-decimal@1.0.4: + resolution: {integrity: sha512-RGdriMmQQvZ2aqaQq3awNA6dCGtKpiDFcOzrTWrDAT2MiWrKQVPmxLGHl7Y2nNu6led0kEyoX0enY0qXYsv9zw==} + dev: true + /is-extglob@2.1.1: resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} engines: {node: '>=0.10.0'} dev: true + /is-fullwidth-code-point@3.0.0: + resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} + engines: {node: '>=8'} + dev: true + /is-glob@4.0.3: resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} engines: {node: '>=0.10.0'} @@ -2581,6 +2970,15 @@ packages: is-extglob: 2.1.1 dev: true + /is-hexadecimal@1.0.4: + resolution: {integrity: sha512-gyPJuv83bHMpocVYoqof5VDiZveEoGoFL8m3BXNb2VW8Xs+rz9kqO8LOQ5DH6EsuvilT1ApazU0pyl+ytbPtlw==} + dev: true + + /is-interactive@1.0.0: + resolution: {integrity: sha512-2HvIEKRoqS62guEC+qBjpvRubdX910WCMuJTZ+I9yvqKU2/12eSL549HMwtabb4oupdj2sMP50k+XJfB/8JE6w==} + engines: {node: '>=8'} + dev: true + /is-ip@3.1.0: resolution: {integrity: sha512-35vd5necO7IitFPjd/YBeqwWnyDWbuLH9ZXQdMfDA8TEo7pv5X8yfrvVO3xbJbLUlERCMvf6X0hTUamQxCYJ9Q==} engines: {node: '>=8'} @@ -2614,6 +3012,11 @@ packages: engines: {node: '>=8'} dev: true + /is-plain-obj@2.1.0: + resolution: {integrity: sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==} + engines: {node: '>=8'} + dev: true + /is-regex@1.1.4: resolution: {integrity: sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==} engines: {node: '>= 0.4'} @@ -2647,6 +3050,11 @@ packages: has-symbols: 1.0.3 dev: true + /is-unicode-supported@0.1.0: + resolution: {integrity: sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==} + engines: {node: '>=10'} + dev: true + /is-weakref@1.0.2: resolution: {integrity: sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==} dependencies: @@ -2721,6 +3129,22 @@ packages: resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} dev: true + /lodash@4.17.21: + resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} + dev: true + + /log-symbols@4.1.0: + resolution: {integrity: sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==} + engines: {node: '>=10'} + dependencies: + chalk: 4.1.2 + is-unicode-supported: 0.1.0 + dev: true + + /longest-streak@2.0.4: + resolution: {integrity: sha512-vM6rUVCVUJJt33bnmHiZEvr7wPT78ztX7rojL+LW51bHtLh6HTjx84LA5W4+oa6aKEJA7jJu5LR6vQRBpA5DVg==} + dev: true + /lru-cache@6.0.0: resolution: {integrity: sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==} engines: {node: '>=10'} @@ -2749,6 +3173,39 @@ packages: '@jridgewell/sourcemap-codec': 1.4.14 dev: true + /mdast-util-from-markdown@0.8.5: + resolution: {integrity: sha512-2hkTXtYYnr+NubD/g6KGBS/0mFmBcifAsI0yIWRiRo0PjVs6SSOSOdtzbp6kSGnShDN6G5aWZpKQ2lWRy27mWQ==} + dependencies: + '@types/mdast': 3.0.11 + mdast-util-to-string: 2.0.0 + micromark: 2.11.4 + parse-entities: 2.0.0 + unist-util-stringify-position: 2.0.3 + transitivePeerDependencies: + - supports-color + dev: true + + /mdast-util-frontmatter@0.2.0: + resolution: {integrity: sha512-FHKL4w4S5fdt1KjJCwB0178WJ0evnyyQr5kXTM3wrOVpytD0hrkvd+AOOjU9Td8onOejCkmZ+HQRT3CZ3coHHQ==} + dependencies: + micromark-extension-frontmatter: 0.2.2 + dev: true + + /mdast-util-to-markdown@0.6.5: + resolution: {integrity: sha512-XeV9sDE7ZlOQvs45C9UKMtfTcctcaj/pGwH8YLbMHoMOXNNCn2LsqVQOqrF1+/NU8lKDAqozme9SCXWyo9oAcQ==} + dependencies: + '@types/unist': 2.0.6 + longest-streak: 2.0.4 + mdast-util-to-string: 2.0.0 + parse-entities: 2.0.0 + repeat-string: 1.6.1 + zwitch: 1.0.5 + dev: true + + /mdast-util-to-string@2.0.0: + resolution: {integrity: sha512-AW4DRS3QbBayY/jJmD8437V1Gombjf8RSOUCMFBuo5iHi58AGEgVCKQ+ezHkZZDpAQS75hcBMpLqjpJTjtUL7w==} + dev: true + /mdn-data@2.0.30: resolution: {integrity: sha512-GaqWWShW4kv/G9IEucWScBx9G1/vsFZZJUO+tD26M8J8z3Kw5RDQjaoZe03YAClgeS/SWPOcb4nkFBTEi5DUEA==} dev: true @@ -2762,6 +3219,21 @@ packages: engines: {node: '>= 8'} dev: true + /micromark-extension-frontmatter@0.2.2: + resolution: {integrity: sha512-q6nPLFCMTLtfsctAuS0Xh4vaolxSFUWUWR6PZSrXXiRy+SANGllpcqdXFv2z07l0Xz/6Hl40hK0ffNCJPH2n1A==} + dependencies: + fault: 1.0.4 + dev: true + + /micromark@2.11.4: + resolution: {integrity: sha512-+WoovN/ppKolQOFIAajxi7Lu9kInbPxFuTBVEavFcL8eAfVstoc5MocPmqBeAdBOJV00uaVjegzH4+MA0DN/uA==} + dependencies: + debug: 4.3.4 + parse-entities: 2.0.0 + transitivePeerDependencies: + - supports-color + dev: true + /micromatch@4.0.5: resolution: {integrity: sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==} engines: {node: '>=8.6'} @@ -2821,10 +3293,8 @@ packages: resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} dev: true - /nanoid@3.3.4: - resolution: {integrity: sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw==} - engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} - hasBin: true + /mute-stream@0.0.8: + resolution: {integrity: sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==} dev: true /nanoid@3.3.6: @@ -2845,6 +3315,18 @@ packages: resolution: {integrity: sha512-ZNaury9r0NxaT2oL65GvdGDy+5PlSaHTovT6JV5tOW07k1TQmgC0olZETa4C9KZg0+6zBr99ctTYa3Utqj9P/Q==} dev: true + /node-fetch@2.6.7: + resolution: {integrity: sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==} + engines: {node: 4.x || >=6.0.0} + peerDependencies: + encoding: ^0.1.0 + peerDependenciesMeta: + encoding: + optional: true + dependencies: + whatwg-url: 5.0.0 + dev: true + /normalize-path@3.0.0: resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} engines: {node: '>=0.10.0'} @@ -2919,6 +3401,26 @@ packages: word-wrap: 1.2.3 dev: true + /ora@5.4.1: + resolution: {integrity: sha512-5b6Y85tPxZZ7QytO+BQzysW31HJku27cRIlkbAXaNx+BdcVi+LlRFmVXzeF6a7JCwJpyw5c4b+YSVImQIrBpuQ==} + engines: {node: '>=10'} + dependencies: + bl: 4.1.0 + chalk: 4.1.2 + cli-cursor: 3.1.0 + cli-spinners: 2.9.0 + is-interactive: 1.0.0 + is-unicode-supported: 0.1.0 + log-symbols: 4.1.0 + strip-ansi: 6.0.1 + wcwidth: 1.0.1 + dev: true + + /os-tmpdir@1.0.2: + resolution: {integrity: sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==} + engines: {node: '>=0.10.0'} + dev: true + /p-event@4.2.0: resolution: {integrity: sha512-KXatOjCRXXkSePPb1Nbi0p0m+gQAwdlbhi4wQKJPI1HsMQS9g+Sqp2o+QHziPr7eYJyOZet836KoHEVM1mwOrQ==} engines: {node: '>=8'} @@ -2959,6 +3461,17 @@ packages: callsites: 3.1.0 dev: true + /parse-entities@2.0.0: + resolution: {integrity: sha512-kkywGpCcRYhqQIchaWqZ875wzpS/bMKhz5HnN3p7wveJTkTtyAB/AlnS0f8DFSqYW1T82t6yEAkEcB+A1I3MbQ==} + dependencies: + character-entities: 1.2.4 + character-entities-legacy: 1.1.4 + character-reference-invalid: 1.1.4 + is-alphanumerical: 1.0.4 + is-decimal: 1.0.4 + is-hexadecimal: 1.0.4 + dev: true + /path-exists@4.0.0: resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} engines: {node: '>=8'} @@ -3000,15 +3513,6 @@ packages: engines: {node: '>=8.6'} dev: true - /postcss@8.4.21: - resolution: {integrity: sha512-tP7u/Sn/dVxK2NnruI4H9BG+x+Wxz6oeZ1cJ8P6G/PZY0IKk4k/63TDsQf2kQq3+qoJeLm2kIBUNlZe3zgb4Zg==} - engines: {node: ^10 || ^12 || >=14} - dependencies: - nanoid: 3.3.4 - picocolors: 1.0.0 - source-map-js: 1.0.2 - dev: true - /postcss@8.4.23: resolution: {integrity: sha512-bQ3qMcpF6A/YjR55xtoTr0jGOlnPOKAIMdOWiv0EIT6HVPEaJiJB4NLljSbiHoC2RX7DN5Uvjtpbg1NPdwv1oA==} engines: {node: ^10 || ^12 || >=14} @@ -3044,6 +3548,15 @@ packages: safe-buffer: 5.2.1 dev: true + /readable-stream@3.6.2: + resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} + engines: {node: '>= 6'} + dependencies: + inherits: 2.0.4 + string_decoder: 1.3.0 + util-deprecate: 1.0.2 + dev: true + /readdirp@3.6.0: resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} engines: {node: '>=8.10.0'} @@ -3065,9 +3578,35 @@ packages: functions-have-names: 1.2.3 dev: true - /regexpp@3.2.0: - resolution: {integrity: sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg==} - engines: {node: '>=8'} + /remark-frontmatter@3.0.0: + resolution: {integrity: sha512-mSuDd3svCHs+2PyO29h7iijIZx4plX0fheacJcAoYAASfgzgVIcXGYSq9GFyYocFLftQs8IOmmkgtOovs6d4oA==} + dependencies: + mdast-util-frontmatter: 0.2.0 + micromark-extension-frontmatter: 0.2.2 + dev: true + + /remark-parse@9.0.0: + resolution: {integrity: sha512-geKatMwSzEXKHuzBNU1z676sGcDcFoChMK38TgdHJNAYfFtsfHDQG7MoJAjs6sgYMqyLduCYWDIWZIxiPeafEw==} + dependencies: + mdast-util-from-markdown: 0.8.5 + transitivePeerDependencies: + - supports-color + dev: true + + /remark-stringify@9.0.1: + resolution: {integrity: sha512-mWmNg3ZtESvZS8fv5PTvaPckdL4iNlCHTt8/e/8oN08nArHRHjNZMKzA/YW3+p7/lYqIw4nx1XsjCBo/AxNChg==} + dependencies: + mdast-util-to-markdown: 0.6.5 + dev: true + + /repeat-string@1.6.1: + resolution: {integrity: sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==} + engines: {node: '>=0.10'} + dev: true + + /require-directory@2.1.1: + resolution: {integrity: sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==} + engines: {node: '>=0.10.0'} dev: true /resolve-from@4.0.0: @@ -3084,6 +3623,23 @@ packages: supports-preserve-symlinks-flag: 1.0.0 dev: true + /resolve@1.22.2: + resolution: {integrity: sha512-Sb+mjNHOULsBv818T40qSPeRiuWLyaGMa5ewydRLFimneixmVy2zdivRl+AF6jaYPC8ERxGDmFSiqui6SfPd+g==} + hasBin: true + dependencies: + is-core-module: 2.12.0 + path-parse: 1.0.7 + supports-preserve-symlinks-flag: 1.0.0 + dev: true + + /restore-cursor@3.1.0: + resolution: {integrity: sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA==} + engines: {node: '>=8'} + dependencies: + onetime: 5.1.2 + signal-exit: 3.0.7 + dev: true + /reusify@1.0.4: resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} engines: {iojs: '>=1.0.0', node: '>=0.10.0'} @@ -3111,14 +3667,6 @@ packages: fsevents: 2.3.2 dev: true - /rollup@2.79.1: - resolution: {integrity: sha512-uKxbd0IhMZOhjAiD5oAFp7BqvkA4Dv47qpOCtaNvng4HBwdbWtdOh8f5nZNuk2rp51PMGk3bzfWu5oayNEuYnw==} - engines: {node: '>=10.0.0'} - hasBin: true - optionalDependencies: - fsevents: 2.3.2 - dev: true - /rollup@3.21.0: resolution: {integrity: sha512-ANPhVcyeHvYdQMUyCbczy33nbLzI7RzrBje4uvNiTDJGIMtlKoOStmympwr9OtS1LZxiDmE2wvxHyVhoLtf1KQ==} engines: {node: '>=14.18.0', npm: '>=8.0.0'} @@ -3127,12 +3675,23 @@ packages: fsevents: 2.3.2 dev: true + /run-async@2.4.1: + resolution: {integrity: sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ==} + engines: {node: '>=0.12.0'} + dev: true + /run-parallel@1.2.0: resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} dependencies: queue-microtask: 1.2.3 dev: true + /rxjs@7.8.1: + resolution: {integrity: sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==} + dependencies: + tslib: 2.5.0 + dev: true + /sade@1.8.1: resolution: {integrity: sha512-xal3CZX1Xlo/k4ApwCFrHVACi9fBqJ7V+mwhBsuf/1IOKbBy098Fex+Wa/5QMubw09pSZ/u8EY8PWgevJsXp1A==} engines: {node: '>=6'} @@ -3158,6 +3717,10 @@ packages: regexp-tree: 0.1.27 dev: true + /safer-buffer@2.1.2: + resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} + dev: true + /sander@0.5.1: resolution: {integrity: sha512-3lVqBir7WuKDHGrKRDn/1Ye3kwpXaDOMsiRP1wd6wpZW56gJhsbp5RqQpA6JG/P+pkXizygnr1dKR8vzWaVsfA==} dependencies: @@ -3180,6 +3743,14 @@ packages: lru-cache: 6.0.0 dev: true + /semver@7.5.1: + resolution: {integrity: sha512-Wvss5ivl8TMRZXXESstBA4uR5iXgEN/VC5/sOcuXdVLzcdkz4HWetIoRfG5gb5X+ij/G9rw9YoGn3QoQ8OCSpw==} + engines: {node: '>=10'} + hasBin: true + dependencies: + lru-cache: 6.0.0 + dev: true + /serialize-javascript@6.0.0: resolution: {integrity: sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==} dependencies: @@ -3202,6 +3773,10 @@ packages: engines: {node: '>=8'} dev: true + /shellwords@0.1.1: + resolution: {integrity: sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==} + dev: true + /side-channel@1.0.4: resolution: {integrity: sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==} dependencies: @@ -3264,11 +3839,27 @@ packages: deprecated: Please use @jridgewell/sourcemap-codec instead dev: true + /stacktrace-parser@0.1.10: + resolution: {integrity: sha512-KJP1OCML99+8fhOHxwwzyWrlUuVX5GQ0ZpJTd1DFXhdkrvg1szxfHhawXUZ3g9TkXORQd4/WG68jMlQZ2p8wlg==} + engines: {node: '>=6'} + dependencies: + type-fest: 0.7.1 + dev: true + /streamsearch@1.1.0: resolution: {integrity: sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==} engines: {node: '>=10.0.0'} dev: true + /string-width@4.2.3: + resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} + engines: {node: '>=8'} + dependencies: + emoji-regex: 8.0.0 + is-fullwidth-code-point: 3.0.0 + strip-ansi: 6.0.1 + dev: true + /string.prototype.trimend@1.0.6: resolution: {integrity: sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ==} dependencies: @@ -3285,6 +3876,12 @@ packages: es-abstract: 1.20.5 dev: true + /string_decoder@1.3.0: + resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} + dependencies: + safe-buffer: 5.2.1 + dev: true + /strip-ansi@6.0.1: resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} engines: {node: '>=8'} @@ -3443,6 +4040,10 @@ packages: resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} dev: true + /through@2.3.8: + resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} + dev: true + /tiny-glob@0.2.9: resolution: {integrity: sha512-g/55ssRPUjShh+xkfx9UPDXqhckHEsHr4Vd9zX55oSdGZc/MD0m3sferOkwWtp98bv+kcVfEHtRJgBVJzelrzg==} dependencies: @@ -3450,6 +4051,13 @@ packages: globrex: 0.1.2 dev: true + /tmp@0.0.33: + resolution: {integrity: sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==} + engines: {node: '>=0.6.0'} + dependencies: + os-tmpdir: 1.0.2 + dev: true + /to-regex-range@5.0.1: resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} engines: {node: '>=8.0'} @@ -3462,6 +4070,14 @@ packages: engines: {node: '>=6'} dev: true + /tr46@0.0.3: + resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==} + dev: true + + /trough@1.0.5: + resolution: {integrity: sha512-rvuRbTarPXmMb79SmzEp8aqXNKcK+y0XaB298IXueQ8I2PsrATcPBCSPyK/dDNa2iWOhKlfNnOjdAOTBU/nkFA==} + dev: true + /tsconfig-paths@3.14.1: resolution: {integrity: sha512-fxDhWnFSLt3VuTwtvJt5fpwxBHg5AdKWMsgcPOOIilyjymcYVZoCQF8fvFRezCNfblEXmi+PcM1eYHeOAgXCOQ==} dependencies: @@ -3505,6 +4121,16 @@ packages: engines: {node: '>=10'} dev: true + /type-fest@0.21.3: + resolution: {integrity: sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==} + engines: {node: '>=10'} + dev: true + + /type-fest@0.7.1: + resolution: {integrity: sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg==} + engines: {node: '>=8'} + dev: true + /typescript@5.0.4: resolution: {integrity: sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==} engines: {node: '>=12.20'} @@ -3539,6 +4165,24 @@ packages: busboy: 1.6.0 dev: true + /unified@9.2.2: + resolution: {integrity: sha512-Sg7j110mtefBD+qunSLO1lqOEKdrwBFBrR6Qd8f4uwkhWNlbkaqwHse6e7QvD3AP/MNoJdEDLaf8OxYyoWgorQ==} + dependencies: + '@types/unist': 2.0.6 + bail: 1.0.5 + extend: 3.0.2 + is-buffer: 2.0.5 + is-plain-obj: 2.1.0 + trough: 1.0.5 + vfile: 4.2.1 + dev: true + + /unist-util-stringify-position@2.0.3: + resolution: {integrity: sha512-3faScn5I+hy9VleOq/qNbAd6pAx7iH5jYBMS9I1HgQVijz/4mv5Bvw5iw1sC/90CODiKo81G/ps8AJrISn687g==} + dependencies: + '@types/unist': 2.0.6 + dev: true + /unocss@0.39.3(vite@3.0.9): resolution: {integrity: sha512-+BZazovI1A+jlW0+GuSSABHQjBLpu2sQkLXriBTdZiPYZAqJJdiWHuQ6VPzF4Al5WM4VPpOgX5mUYWusJ813qw==} engines: {node: '>=14'} @@ -3574,31 +4218,24 @@ packages: punycode: 2.1.1 dev: true - /vite@3.0.2: - resolution: {integrity: sha512-TAqydxW/w0U5AoL5AsD9DApTvGb2iNbGs3sN4u2VdT1GFkQVUfgUldt+t08TZgi23uIauh1TUOQJALduo9GXqw==} - engines: {node: ^14.18.0 || >=16.0.0} - hasBin: true - peerDependencies: - less: '*' - sass: '*' - stylus: '*' - terser: ^5.4.0 - peerDependenciesMeta: - less: - optional: true - sass: - optional: true - stylus: - optional: true - terser: - optional: true + /util-deprecate@1.0.2: + resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} + dev: true + + /vfile-message@2.0.4: + resolution: {integrity: sha512-DjssxRGkMvifUOJre00juHoP9DPWuzjxKuMDrhNbk2TdaYYBNMStsNhEOt3idrtI12VQYM/1+iM0KOzXi4pxwQ==} dependencies: - esbuild: 0.14.54 - postcss: 8.4.21 - resolve: 1.22.1 - rollup: 2.79.1 - optionalDependencies: - fsevents: 2.3.2 + '@types/unist': 2.0.6 + unist-util-stringify-position: 2.0.3 + dev: true + + /vfile@4.2.1: + resolution: {integrity: sha512-O6AE4OskCG5S1emQ/4gl8zK586RqA3srz3nfK/Viy0UPToBc5Trp9BVFb1u0CjsKrAWwnpr4ifM/KBXPWwJbCA==} + dependencies: + '@types/unist': 2.0.6 + is-buffer: 2.0.5 + unist-util-stringify-position: 2.0.3 + vfile-message: 2.0.4 dev: true /vite@3.0.9: @@ -3671,6 +4308,23 @@ packages: vite: 4.3.3 dev: true + /wcwidth@1.0.1: + resolution: {integrity: sha512-XHPEwS0q6TaxcvG85+8EYkbiCux2XtWG2mkc47Ng2A77BQu9+DqIOJldST4HgPkuea7dvKSj5VgX3P1d4rW8Tg==} + dependencies: + defaults: 1.0.4 + dev: true + + /webidl-conversions@3.0.1: + resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} + dev: true + + /whatwg-url@5.0.0: + resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} + dependencies: + tr46: 0.0.3 + webidl-conversions: 3.0.1 + dev: true + /which-boxed-primitive@1.0.2: resolution: {integrity: sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==} dependencies: @@ -3694,15 +4348,51 @@ packages: engines: {node: '>=0.10.0'} dev: true + /wrap-ansi@7.0.0: + resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} + engines: {node: '>=10'} + dependencies: + ansi-styles: 4.3.0 + string-width: 4.2.3 + strip-ansi: 6.0.1 + dev: true + /wrappy@1.0.2: resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} dev: true + /y18n@5.0.8: + resolution: {integrity: sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==} + engines: {node: '>=10'} + dev: true + /yallist@4.0.0: resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} dev: true + /yargs-parser@21.1.1: + resolution: {integrity: sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==} + engines: {node: '>=12'} + dev: true + + /yargs@17.7.2: + resolution: {integrity: sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==} + engines: {node: '>=12'} + dependencies: + cliui: 8.0.1 + escalade: 3.1.1 + get-caller-file: 2.0.5 + require-directory: 2.1.1 + string-width: 4.2.3 + y18n: 5.0.8 + yargs-parser: 21.1.1 + dev: true + /yocto-queue@0.1.0: resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} engines: {node: '>=10'} dev: true + + /zwitch@1.0.5: + resolution: {integrity: sha512-V50KMwwzqJV0NpZIZFwfOD5/lyny3WlSzRiXgA0G7VUnRlqttta1L6UQIHzd6EuBY/cHGfwTIck7w1yH6Q5zUw==} + dev: true diff --git a/shared/rollup.config.mjs b/shared/rollup.config.mjs index 9595b929..95042f8c 100644 --- a/shared/rollup.config.mjs +++ b/shared/rollup.config.mjs @@ -1,8 +1,12 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import { builtinModules } from "module"; import typescript from "@rollup/plugin-typescript"; import resolve from "@rollup/plugin-node-resolve"; -// import terser from "@rollup/plugin-terser"; +import terser from "@rollup/plugin-terser"; /** * Create a base rollup config @@ -11,6 +15,10 @@ import resolve from "@rollup/plugin-node-resolve"; * @returns {import('rollup').RollupOptions} */ export function createConfig({ input = "index.ts", pkg, external = [] }) { + const pluginJsName = pkg.name + .replace("@tauri-apps/plugin-", "") + .replace(/-./g, (x) => x[1].toUpperCase()); + const iifeVarName = `__TAURI_${pluginJsName.toUpperCase()}__`; return [ { input, @@ -47,5 +55,28 @@ export function createConfig({ input = "index.ts", pkg, external = [] }) { typescript({ sourceMap: true }), ], }, + { + input, + output: { + file: "src/api-iife.js", + format: "iife", + name: iifeVarName, + // IIFE is in the format `var ${iifeVarName} = (() => {})()` + // we check if __TAURI__ exists and inject the API object + banner: "if ('__TAURI__' in window) {", + // the last `}` closes the if in the banner + footer: `Object.defineProperty(window.__TAURI__, '${pluginJsName}', { value: ${iifeVarName} }) }`, + }, + // and var is not guaranteed to assign to the global `window` object so we make sure to assign it + plugins: [ + resolve(), + typescript({ + sourceMap: false, + declaration: false, + declarationDir: undefined, + }), + terser(), + ], + }, ]; } diff --git a/shared/template/Cargo.toml b/shared/template/Cargo.toml index defae478..071f5654 100644 --- a/shared/template/Cargo.toml +++ b/shared/template/Cargo.toml @@ -1,18 +1,19 @@ [package] name = "tauri-plugin-{{name}}" -version = "0.0.0" -edition.workspace = true -authors.workspace = true -license.workspace = true +version = "1.0.0" +edition = { workspace = true } +authors = { workspace = true } +license = { workspace = true } +links = "tauri-plugin-{{name}}" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [build-dependencies] -tauri-build.workspace = true +tauri-build = { workspace = true } [dependencies] -serde.workspace = true -serde_json.workspace = true -tauri.workspace = true -log.workspace = true -thiserror.workspace = true \ No newline at end of file +serde = { workspace = true } +serde_json = { workspace = true } +tauri = { workspace = true } +log = { workspace = true } +thiserror = { workspace = true } \ No newline at end of file diff --git a/shared/template/README.md b/shared/template/README.md index 9ef4ffe0..1a839763 100644 --- a/shared/template/README.md +++ b/shared/template/README.md @@ -1,10 +1,10 @@ -![{{plugin name}}](banner.jpg) +![{{plugin-name}}](banner.png) ## Install -_This plugin requires a Rust version of at least **1.64**_ +_This plugin requires a Rust version of at least **1.65**_ There are three general methods of installation that we can recommend. @@ -18,7 +18,9 @@ Install the Core plugin by adding the following to your `Cargo.toml` file: ```toml [dependencies] - = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } +tauri-plugin-{{plugin-name}} = "2.0.0-alpha" +# alternatively with Git: +tauri-plugin-{{plugin-name}} = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "v2" } ``` You can install the JavaScript Guest bindings using your preferred JavaScript package manager: @@ -26,11 +28,18 @@ You can install the JavaScript Guest bindings using your preferred JavaScript pa > Note: Since most JavaScript package managers are unable to install packages from git monorepos we provide read-only mirrors of each plugin. This makes installation option 2 more ergonomic to use. ```sh -pnpm add +pnpm add @tauri-apps/plugin-{{plugin-name}} # or -npm add +npm add @tauri-apps/plugin-{{plugin-name}} # or -yarn add +yarn add @tauri-apps/plugin-{{plugin-name}} + +# alternatively with Git: +pnpm add https://github.com/tauri-apps/tauri-plugin-{{plugin-name}}#v2 +# or +npm add https://github.com/tauri-apps/tauri-plugin-{{plugin-name}}#v2 +# or +yarn add https://github.com/tauri-apps/tauri-plugin-{{plugin-name}}#v2 ``` ## Usage @@ -42,7 +51,7 @@ First you need to register the core plugin with Tauri: ```rust fn main() { tauri::Builder::default() - .plugin() + .plugin(tauri_plugin_{{plugin-name}}::init()) .run(tauri::generate_context!()) .expect("error while running tauri application"); } diff --git a/shared/template/android/src/androidTest/java/ExampleInstrumentedTest.kt b/shared/template/android/src/androidTest/java/ExampleInstrumentedTest.kt index 24e699cc..b7ca3f66 100644 --- a/shared/template/android/src/androidTest/java/ExampleInstrumentedTest.kt +++ b/shared/template/android/src/androidTest/java/ExampleInstrumentedTest.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package {{android_package_id}} import androidx.test.platform.app.InstrumentationRegistry diff --git a/shared/template/android/src/main/java/ExamplePlugin.kt b/shared/template/android/src/main/java/ExamplePlugin.kt index 8ac527d8..9fed811c 100644 --- a/shared/template/android/src/main/java/ExamplePlugin.kt +++ b/shared/template/android/src/main/java/ExamplePlugin.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package {{android_package_id}} import android.app.Activity diff --git a/shared/template/android/src/test/java/ExampleUnitTest.kt b/shared/template/android/src/test/java/ExampleUnitTest.kt index 50792fe6..71cee3c2 100644 --- a/shared/template/android/src/test/java/ExampleUnitTest.kt +++ b/shared/template/android/src/test/java/ExampleUnitTest.kt @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + package {{android_package_id}} import org.junit.Test diff --git a/shared/template/build.rs b/shared/template/build.rs index 86ac3f0a..743096a6 100644 --- a/shared/template/build.rs +++ b/shared/template/build.rs @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + use std::process::exit; fn main() { diff --git a/shared/template/guest-js/index.ts b/shared/template/guest-js/index.ts index e69de29b..a0560385 100644 --- a/shared/template/guest-js/index.ts +++ b/shared/template/guest-js/index.ts @@ -0,0 +1,3 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT diff --git a/shared/template/ios/Package.swift b/shared/template/ios/Package.swift index ff9991fa..e4f53f0b 100644 --- a/shared/template/ios/Package.swift +++ b/shared/template/ios/Package.swift @@ -1,5 +1,7 @@ // swift-tools-version:5.3 -// The swift-tools-version declares the minimum version of Swift required to build this package. +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT import PackageDescription diff --git a/shared/template/ios/Sources/ExamplePlugin.swift b/shared/template/ios/Sources/ExamplePlugin.swift index 86140b74..7a36b76b 100644 --- a/shared/template/ios/Sources/ExamplePlugin.swift +++ b/shared/template/ios/Sources/ExamplePlugin.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import UIKit import WebKit import Tauri @@ -11,6 +15,6 @@ class ExamplePlugin: Plugin { } @_cdecl("init_plugin_{{ plugin_name_snake_case }}") -func initPlugin(name: SRString, webview: WKWebView?) { - Tauri.registerPlugin(webview: webview, name: name.toString(), plugin: ExamplePlugin()) +func initPlugin() -> Plugin { + return ExamplePlugin() } diff --git a/shared/template/ios/Tests/PluginTests/PluginTests.swift b/shared/template/ios/Tests/PluginTests/PluginTests.swift index 4f8e9ace..99992ce4 100644 --- a/shared/template/ios/Tests/PluginTests/PluginTests.swift +++ b/shared/template/ios/Tests/PluginTests/PluginTests.swift @@ -1,3 +1,7 @@ +// Copyright 2019-2023 Tauri Programme within The Commons Conservancy +// SPDX-License-Identifier: Apache-2.0 +// SPDX-License-Identifier: MIT + import XCTest @testable import ExamplePlugin diff --git a/shared/template/package.json b/shared/template/package.json index e62c3c9f..e39bca2a 100644 --- a/shared/template/package.json +++ b/shared/template/package.json @@ -1,6 +1,6 @@ { - "name": "tauri-plugin-{{name}}-api", - "version": "0.0.0", + "name": "@tauri-apps/plugin-{{name}}", + "version": "1.0.0", "license": "MIT or APACHE-2.0", "authors": [ "Tauri Programme within The Commons Conservancy" @@ -27,6 +27,6 @@ "tslib": "^2.4.1" }, "dependencies": { - "@tauri-apps/api": "^1.2.0" + "@tauri-apps/api": "2.0.0-alpha.4" } } diff --git a/shared/template/src/lib.rs b/shared/template/src/lib.rs index 77861b7f..3e0f7618 100644 --- a/shared/template/src/lib.rs +++ b/shared/template/src/lib.rs @@ -39,6 +39,7 @@ impl> crate::{{ plugin_name_pascal_case }}Ext for T /// Initializes the plugin. pub fn init() -> TauriPlugin { Builder::new("{{ plugin_name }}") + .js_init_script(include_str!("api-iife.js").to_string()) .invoke_handler(tauri::generate_handler![commands::execute]) .setup(|app, api| { #[cfg(mobile)] diff --git a/shared/template/tsconfig.json b/shared/template/tsconfig.json index 4ec6ff6a..5098169a 120000 --- a/shared/template/tsconfig.json +++ b/shared/template/tsconfig.json @@ -1 +1,4 @@ -../tsconfig.json \ No newline at end of file +{ + "extends": "../../tsconfig.base.json", + "include": ["guest-js/*.ts"] +}