claude-prism/apps/desktop/src-tauri/capabilities/default.json
delibae 37957aacb8 fix: resolve Windows project creation failure and Linux segfault
Windows (#101): Add explicit FS scopes to each permission in
default.json so Tauri's scope validator accepts Windows paths.
Remove silent .catch(() => {}) on mkdir/writeTextFile so errors
surface via toast instead of failing silently. Replace all
.split("/").pop() with .split(/[/\\]/).pop() (14 occurrences)
for correct path parsing on Windows.

Linux (#100): Add ELF linker version script (symbols.map) that
hides statically linked ICU/HarfBuzz/FreeType/Fontconfig/Graphite2
symbols from the dynamic symbol table. This prevents symbol
collisions with WebKit2GTK's own dynamic copies of these libraries,
which caused a segfault at startup. The static linking introduced
in v1.0.10 to fix #91 is preserved—ICU remains embedded in the
binary so it works across distros.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-27 15:50:11 +09:00

88 lines
3.3 KiB
JSON

{
"$schema": "https://raw.githubusercontent.com/nicegui-unofficial/nicegui-tauri-template/main/src-tauri/gen/schemas/capabilities-v2-schema.json",
"identifier": "default",
"description": "Default capabilities for the main window",
"windows": ["*"],
"permissions": [
"core:default",
"core:window:default",
"core:window:allow-create",
"core:window:allow-set-title",
"core:window:allow-show",
"core:window:allow-start-dragging",
"core:window:allow-minimize",
"core:window:allow-maximize",
"core:window:allow-toggle-maximize",
"core:window:allow-close",
"core:webview:allow-create-webview-window",
"dialog:default",
"dialog:allow-open",
"dialog:allow-save",
"dialog:allow-message",
"dialog:allow-ask",
"fs:default",
{
"identifier": "fs:allow-read",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-write",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-exists",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-mkdir",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-remove",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-rename",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-copy-file",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-read-dir",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-read-text-file",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-write-text-file",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-read-file",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-write-file",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-stat",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
{
"identifier": "fs:allow-watch",
"allow": [{ "path": "$HOME/**" }, { "path": "$DOCUMENT/**" }, { "path": "$DESKTOP/**" }, { "path": "$TEMP/**" }]
},
"shell:default",
"shell:allow-open",
"shell:allow-spawn",
"shell:allow-stdin-write",
"shell:allow-kill",
"process:default",
"process:allow-exit"
]
}