fpasoterm 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. package/CHANGELOG.md +230 -0
  2. package/CONTRIBUTING.md +67 -0
  3. package/INSTALL.ja.md +204 -0
  4. package/INSTALL.md +229 -0
  5. package/LICENSE +21 -0
  6. package/README.ja.md +389 -0
  7. package/README.md +607 -0
  8. package/bin/fpasoterm +2882 -0
  9. package/completions/_fpasoterm +81 -0
  10. package/completions/fpasoterm.bash +55 -0
  11. package/completions/fpasoterm.fish +64 -0
  12. package/completions/fpasoterm.ps1 +47 -0
  13. package/docs/capability-diagnostics.en.md +77 -0
  14. package/docs/capability-diagnostics.ja.md +63 -0
  15. package/docs/completion.en.md +141 -0
  16. package/docs/completion.ja.md +113 -0
  17. package/docs/config.en.md +554 -0
  18. package/docs/config.ja.md +544 -0
  19. package/docs/debugging.en.md +72 -0
  20. package/docs/debugging.ja.md +66 -0
  21. package/docs/diagnostics.en.md +69 -0
  22. package/docs/diagnostics.ja.md +64 -0
  23. package/docs/font-diagnostics.en.md +116 -0
  24. package/docs/font-diagnostics.ja.md +105 -0
  25. package/docs/fpasoterm-plugin.d.ts +51 -0
  26. package/docs/known-issues.en.md +23 -0
  27. package/docs/known-issues.ja.md +23 -0
  28. package/docs/plugins.en.md +266 -0
  29. package/docs/plugins.ja.md +176 -0
  30. package/docs/pr-review.en.md +177 -0
  31. package/docs/pr-review.ja.md +170 -0
  32. package/docs/release-checklist.en.md +72 -0
  33. package/docs/release-checklist.ja.md +71 -0
  34. package/docs/security.en.md +36 -0
  35. package/docs/security.ja.md +31 -0
  36. package/docs/spec.en.md +106 -0
  37. package/docs/spec.ja.md +99 -0
  38. package/docs/sshfs.en.md +28 -0
  39. package/docs/sshfs.ja.md +28 -0
  40. package/docs/sync.en.md +280 -0
  41. package/docs/sync.ja.md +280 -0
  42. package/examples/apply-default-appearance.bat +8 -0
  43. package/examples/apply-default-appearance.ps1 +7 -0
  44. package/examples/apply-default-appearance.sh +7 -0
  45. package/examples/apply-runtime-appearance.bat +8 -0
  46. package/examples/apply-runtime-appearance.ps1 +7 -0
  47. package/examples/apply-runtime-appearance.sh +7 -0
  48. package/examples/config/default-appearance.toml +36 -0
  49. package/examples/config/minimal.toml +30 -0
  50. package/examples/config/profiles.toml +20 -0
  51. package/examples/config/runtime-appearance.toml +24 -0
  52. package/examples/config/sync-folder.toml +17 -0
  53. package/examples/config/tui-compatibility.toml +7 -0
  54. package/examples/config/with-plugins.toml +33 -0
  55. package/examples/plugins/hello.ts +17 -0
  56. package/examples/plugins/status-banner.ts +14 -0
  57. package/examples/plugins/theme.ts +32 -0
  58. package/examples/plugins/welcome-banner.ts +16 -0
  59. package/extra/linux/icons/hicolor/128x128/apps/fpasoterm.png +0 -0
  60. package/extra/linux/icons/hicolor/16x16/apps/fpasoterm.png +0 -0
  61. package/extra/linux/icons/hicolor/192x192/apps/fpasoterm.png +0 -0
  62. package/extra/linux/icons/hicolor/256x256/apps/fpasoterm.png +0 -0
  63. package/extra/linux/icons/hicolor/32x32/apps/fpasoterm.png +0 -0
  64. package/extra/linux/icons/hicolor/48x48/apps/fpasoterm.png +0 -0
  65. package/extra/linux/icons/hicolor/512x512/apps/fpasoterm.png +0 -0
  66. package/extra/linux/icons/hicolor/64x64/apps/fpasoterm.png +0 -0
  67. package/extra/linux/io.github.oyoguhito.fpasoterm.desktop +10 -0
  68. package/extra/logo/fpasoterm.png +0 -0
  69. package/extra/macos/fpasoterm.icns +0 -0
  70. package/extra/windows/fpasoterm.cmd +40 -0
  71. package/extra/windows/fpasoterm.ico +0 -0
  72. package/package.json +81 -0
  73. package/scripts/build-artifacts.js +183 -0
  74. package/scripts/generate-icon.js +251 -0
  75. package/scripts/init-jj-empty-main +41 -0
  76. package/scripts/install-linux-desktop.js +238 -0
  77. package/scripts/run +16 -0
  78. package/scripts/security/scan-secrets.js +89 -0
  79. package/scripts/tests/smoke.js +2476 -0
  80. package/scripts/uninstall-desktop.js +20 -0
  81. package/scripts/uninstall-linux-desktop.js +96 -0
  82. package/scripts/uninstall-windows-path.js +94 -0
  83. package/src/config.js +855 -0
  84. package/src/renderer/confirm.html +71 -0
  85. package/src/renderer/index.html +223 -0
  86. package/src/renderer/renderer.js +4166 -0
  87. package/src/renderer/styles.css +969 -0
  88. package/src/renderer/vendor/addon-fit/addon-fit.js +2 -0
  89. package/src/renderer/vendor/addon-image/LICENSE +19 -0
  90. package/src/renderer/vendor/addon-image/addon-image.js +3 -0
  91. package/src/renderer/vendor/addon-web-links/LICENSE +19 -0
  92. package/src/renderer/vendor/addon-web-links/addon-web-links.js +2 -0
  93. package/src/renderer/vendor/xterm/xterm.css +292 -0
  94. package/src/renderer/vendor/xterm/xterm.js +2 -0
  95. package/src-tauri/Cargo.lock +5253 -0
  96. package/src-tauri/Cargo.toml +29 -0
  97. package/src-tauri/build.rs +140 -0
  98. package/src-tauri/capabilities/default.json +13 -0
  99. package/src-tauri/default-config.toml +128 -0
  100. package/src-tauri/src/main.rs +9347 -0
  101. package/src-tauri/tauri.conf.json +60 -0
package/INSTALL.md ADDED
@@ -0,0 +1,229 @@
1
+ # Installation
2
+
3
+ Japanese version: [INSTALL.ja.md](INSTALL.ja.md).
4
+
5
+ ## npm
6
+
7
+ After the package is published, install the command from the npm registry:
8
+
9
+ ```sh
10
+ npm install -g fpasoterm
11
+ fpasoterm
12
+ ```
13
+
14
+ If your network makes npm's automatic audit request noisy, use `--no-audit` for local installs. CI still runs the explicit security checks in this repository.
15
+ Check which version and build commit are on the command path:
16
+
17
+ ```sh
18
+ fpasoterm --version
19
+ fpasoterm -v
20
+ ```
21
+
22
+ On Windows, run `fpasoterm --version` after installing a newer `.exe` or `.msi`. If it still prints the old version, the old executable is still being launched from `Path`, the Start menu, or a pinned shortcut. Close running fpasoterm windows, install the newer package again, then start fpasoterm from the updated shortcut.
23
+
24
+ Windows builds place `fpasoterm.cmd` beside the release executable. Use this
25
+ console wrapper for `--version`, `--plugin-path`, `--plugin-info`, and other
26
+ CLI-only operations; it runs the executable directly so stdout, stderr, and
27
+ the exit code return to PowerShell or cmd. Normal launches remain detached:
28
+
29
+ ```powershell
30
+ .\src-tauri\target\release\fpasoterm.cmd --version
31
+ .\src-tauri\target\release\fpasoterm.cmd --plugin-path
32
+ .\src-tauri\target\release\fpasoterm.cmd --help
33
+ .\src-tauri\target\release\fpasoterm.cmd
34
+ ```
35
+
36
+ PowerShell command completion is available from the same wrapper:
37
+
38
+ ```powershell
39
+ .\src-tauri\target\release\fpasoterm.cmd --completion powershell | Out-String | Invoke-Expression
40
+ ```
41
+
42
+ For Bash, Zsh, Fish, persistent setup, and the Windows limitations of
43
+ `cmd.exe`, see [Command Completion](docs/completion.en.md).
44
+
45
+ ## Development Build
46
+
47
+ Linux development requires the Tauri/WebKitGTK system packages:
48
+
49
+ ```sh
50
+ sudo apt install build-essential curl libgtk-3-dev libwebkit2gtk-4.1-dev libayatana-appindicator3-dev librsvg2-dev
51
+ ```
52
+
53
+ ```sh
54
+ npm install
55
+ ./scripts/run
56
+ ```
57
+
58
+ For quick behavior checks while developing, use the Tauri dev runtime:
59
+
60
+ ```sh
61
+ ./bin/fpasoterm --dev
62
+ ```
63
+
64
+ This does not create release bundles. It also ignores an existing `src-tauri/target/release/fpasoterm`, so renderer and Tauri source changes are reflected without reinstalling the desktop entry.
65
+ Add `--foreground --console-diagnostics` only when you need logs in the current console.
66
+ The first `--dev` launch may still take a few minutes because Cargo has to create the Tauri debug binary. Later launches reuse that build cache.
67
+
68
+ Install a local `fpasoterm` command for this checkout:
69
+
70
+ ```sh
71
+ npm run install:desktop
72
+ fpasoterm
73
+ ```
74
+
75
+ The command is written to `~/.local/bin/fpasoterm` unless `XDG_BIN_HOME` is set.
76
+
77
+ Update an existing local command, launcher entry, and icon installation:
78
+
79
+ ```sh
80
+ npm run update:desktop
81
+ ```
82
+
83
+ Update an npm-installed package from the terminal:
84
+
85
+ ```sh
86
+ fpasoterm --self-update
87
+ ```
88
+
89
+ For a source checkout, update the checkout with your normal git or jj workflow,
90
+ then refresh the installed command, launcher entry, and icons:
91
+
92
+ ```sh
93
+ fpasoterm --update-desktop
94
+ ```
95
+
96
+ For a clean non-jj git checkout, this can be automated:
97
+
98
+ ```sh
99
+ fpasoterm --self-update-checkout
100
+ ```
101
+
102
+ Run `npm run update:desktop` after changing the checkout path, launcher icon,
103
+ installed command wrapper, Rust source, or renderer assets. It overwrites the
104
+ desktop launcher and rebuilds the local runtime so the next icon or command
105
+ launch uses the current checkout. It is not required for `./bin/fpasoterm --dev ...`.
106
+
107
+ `npm run update:desktop` is for Linux and ChromeOS desktop integration. On
108
+ Windows it intentionally makes no desktop changes; update by installing the
109
+ current `.msi` or `.exe` artifact instead.
110
+
111
+ To remove an npm global installation, including its npm-managed `fpasoterm`
112
+ command, run:
113
+
114
+ ```sh
115
+ npm uninstall -g fpasoterm
116
+ ```
117
+
118
+ This does not remove a source-checkout desktop launcher, user config, cache, or
119
+ app data. If `type -a fpasoterm` still shows a command afterward, it is another
120
+ installation such as a source-checkout launcher.
121
+
122
+ On Windows, run the same command in PowerShell or Command Prompt. Open a new
123
+ terminal afterward, then use `where.exe fpasoterm` or
124
+ `Get-Command fpasoterm -All` to check for another remaining command.
125
+
126
+ From a source checkout, remove its local command, desktop launcher entry,
127
+ installed launcher icons, user config, runtime cache, and Tauri/WebKit app data:
128
+
129
+ ```sh
130
+ npm run uninstall:desktop
131
+ ```
132
+
133
+ On Windows, `npm run uninstall:desktop` only removes fpasoterm-specific
134
+ directories from the current user's `Path` if they were added during local
135
+ testing. It does not remove the global npm package, source checkout, user
136
+ config, cache, or app data. Shared npm directories are left untouched.
137
+
138
+ To remove both installation types, run `npm run uninstall:desktop` from the
139
+ source checkout first, then run `npm uninstall -g fpasoterm`.
140
+
141
+ To expose the local command during development:
142
+
143
+ ```sh
144
+ npm link
145
+ fpasoterm
146
+ ```
147
+
148
+ If ChromeOS/Baguette shows black, white, or flickering surfaces during transparency testing, start with:
149
+
150
+ ```sh
151
+ fpasoterm --disable-dmabuf
152
+ ```
153
+
154
+ ## Release Artifacts
155
+
156
+ To create artifacts for the current development machine:
157
+
158
+ ```sh
159
+ npm run build:artifacts
160
+ ```
161
+
162
+ Generated files are written to `artifacts/`. Source archives are always generated. Platform bundles depend on the current OS, so a local Linux build creates Linux packages only.
163
+
164
+ Tagged GitHub Releases build the broader release set in GitHub Actions:
165
+
166
+ - source package and portable source archive
167
+ - Linux x64 `.deb` / `.rpm`
168
+ - Linux arm64 `.deb` / `.rpm` for ChromeOS/Baguette and other arm64 Linux environments
169
+ - macOS x64 bundle
170
+ - macOS arm64 bundle
171
+ - Windows x64 bundle and `fpasoterm-<version>-windows-cli.cmd` console wrapper
172
+
173
+ Install the Debian package locally:
174
+
175
+ ```sh
176
+ sudo apt install ./artifacts/fpasoterm_1.3.0_arm64-linux-arm64.deb
177
+ ```
178
+
179
+ ## Linux Desktop Entry
180
+
181
+ The desktop entry template is:
182
+
183
+ ```text
184
+ extra/linux/io.github.oyoguhito.fpasoterm.desktop
185
+ ```
186
+
187
+ The application icon is:
188
+
189
+ ```text
190
+ extra/logo/fpasoterm.png
191
+ ```
192
+
193
+ For macOS app bundles, use:
194
+
195
+ ```text
196
+ extra/macos/fpasoterm.icns
197
+ ```
198
+
199
+ For Windows app bundles, use:
200
+
201
+ ```text
202
+ extra/windows/fpasoterm.ico
203
+ ```
204
+
205
+ Install the desktop entry and hicolor launcher icons into the current user's data directory:
206
+
207
+ ```sh
208
+ npm run install:desktop
209
+ ```
210
+
211
+ For unpacked checkout installs, the installed desktop entry rewrites `Exec=` to
212
+ the absolute `~/.local/bin/fpasoterm` wrapper path and does not set `TryExec`.
213
+ The wrapper records the Node.js executable used during installation and also
214
+ falls back to common `node` paths. This avoids ChromeOS launcher failures when
215
+ the launcher environment does not include the user's shell `PATH`.
216
+
217
+ The installed desktop entry uses `StartupWMClass=fpasoterm` and
218
+ `Icon=io.github.oyoguhito.fpasoterm`. The GTK application id is disabled so
219
+ multiple fpasoterm windows can be started from the CLI or launcher while the
220
+ launcher still resolves the fpasoterm shelf icon and hover name. The installer
221
+ writes both `io.github.oyoguhito.fpasoterm.png` and `fpasoterm.png` icon names
222
+ into the hicolor icon theme.
223
+
224
+ Regenerate launcher icon sizes after replacing `extra/logo/fpasoterm.png`:
225
+
226
+ ```sh
227
+ npm run generate:icons
228
+ npm run update:desktop
229
+ ```
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 oyoguhito
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.ja.md ADDED
@@ -0,0 +1,389 @@
1
+ # fpasoterm
2
+
3
+ ![fpasoterm logo](extra/logo/fpasoterm.png)
4
+
5
+ 英語版: [README.md](README.md)。インストール手順は[日本語](INSTALL.ja.md)と[English](INSTALL.md)を参照してください。
6
+
7
+ fpasoterm は Tauri、xterm.js、Rust PTY bridge を使った Terminal アプリです。ChromeOS Linux での日本語入力を重視しつつ、将来的に他 OS へ展開しやすい構成にしています。
8
+
9
+ screen / tmux / byobu / zellij / herdr などの terminal multiplexer と併用する前提です。fpasoterm 自身では画面分割を行いませんが、titlebar の `Tile` button で複数 window を並べられます。
10
+
11
+ これは意図した責務境界です。pane / session管理、shell command、job control、multiplexer設定に加え、Vim、Emacs、Fresh、Helix などの TUI editor が提供する編集機能も、原則として再実装しません。これらの workflow は shell、multiplexer、TUI editor へ委ね、fpasoterm は terminal surface、OS integration、local customization hook を担当します。追加すると便利な挙動は、原則として本体を肥大化させず plugin として提供します。一方で、これらの multiplexer と TUI editor を問題なく利用できる互換性の維持・改善は優先します。
12
+
13
+ fpasoterm は `かな` / `英数` キーを横取りしません。日本語入力の切替と composition は OS webview と xterm.js に任せます。
14
+
15
+ IME、描画、clipboard、window問題を再現して確認する手順は
16
+ [デバッグガイド](docs/debugging.ja.md)を参照してください。
17
+
18
+ window menu の `Font / Glyph Test` では、使用中のterminal font設定とCJK、半角カナ、罫線、記号、Nerd Font glyphを確認できます。詳細は[Font / Glyph Diagnostics](docs/font-diagnostics.ja.md)を参照してください。
19
+
20
+ window menu の `Diagnostics > Capability Test` では、terminal environmentとtruecolor、OSC 52、OSC 8、OSC 9/99、OSC 7、OSC 133、bracketed paste、bellの対応状況を確認できます。同じpanelで次回のterminal session用にUTF-8、Shift_JIS、EUC-JPのoutput decoderも保存できます。詳細は[Terminal Capability Diagnostics](docs/capability-diagnostics.ja.md)を参照してください。
21
+
22
+ shellがOSC 7でlocal current directoryを通知している場合、`Ctrl+Shift+o`または**Window > New CWD**で同じdirectoryから別のfpasoterm windowを開けます。
23
+
24
+ terminal outputのURLとOSC 8 hyperlinkは明示的な確認dialogを表示します。URLは常にcopyでき、外部browserでopenするには`[security] osc8Open = true`も必要です。absolute pathはcopy-only linkです。
25
+
26
+ ## 必要な環境
27
+
28
+ 詳細な導入手順は [INSTALL.ja.md](INSTALL.ja.md) を参照してください。ChromeOS Linux で開発する場合は、Node.js、Rust、および Tauri/WebKitGTK 用の system package が必要です。
29
+
30
+ ## 起動
31
+
32
+ 起動:
33
+
34
+ ```sh
35
+ npm install
36
+ ./scripts/run
37
+ ```
38
+
39
+ リリース用 bundle を作らず、まず起動だけ確認する場合:
40
+
41
+ ```sh
42
+ ./bin/fpasoterm --dev
43
+ ```
44
+
45
+ この起動方法は古い `src-tauri/target/release/fpasoterm` が存在していても無視し、localhost の開発serverを使わないdebug binaryで現在のsourceを使います。
46
+ 現在のコンソールでログを見たい場合だけ `--foreground --console-diagnostics` を追加してください。
47
+
48
+ shell で `exit` を実行すると fpasoterm のウィンドウも閉じます。
49
+
50
+ ## コマンドラインオプション
51
+
52
+ cached runtime を使用する通常起動ではコンソールから切り離して起動し、すぐに shell prompt が戻ります。
53
+
54
+ ```sh
55
+ fpasoterm
56
+ ```
57
+
58
+ source checkoutまたはnpm packageの初回起動でlocal Cargo buildが必要な場合は、CLIを接続したまま`phase 1/3`の準備、`phase 2/3`のcompiler progress、`phase 3/3`のnative window起動を表示します。Cargo errorもこのterminalへ表示し、window process起動後にpromptが戻ります。runtime解決、Cargo build、desktop spawnの経過時間とcompiler outputはLinux/macOSでは`~/.cache/fpasoterm/launcher.log`、Windowsでは`%LOCALAPPDATA%\\fpasoterm\\launcher.log`にも記録します。desktop processの終了まで待機したい場合だけ、`--foreground --console-diagnostics`を使ってください。
59
+
60
+ オプション一覧:
61
+
62
+ ```sh
63
+ fpasoterm --help
64
+ ```
65
+
66
+ Bash、Zsh、Fish、PowerShellではcommand completionを使えます。例えば現在の
67
+ Bash shellで有効にするには次を実行します。
68
+
69
+ ```bash
70
+ source <(fpasoterm --completion bash)
71
+ ```
72
+
73
+ 永続的な導入とWindows PowerShellの手順は[コマンド補完](docs/completion.ja.md)を参照してください。アプリ更新後に新しいCLI optionをTab補完へ反映したい場合だけ、使用するshellに対して永続completionを再導入します。
74
+
75
+ 起動せずに version を確認:
76
+
77
+ ```sh
78
+ fpasoterm --version
79
+ fpasoterm -v
80
+ fpasoterm --update-check
81
+ fpasoterm --doctor
82
+ ```
83
+
84
+ GUIではhamburger menuから**Help**を開き、**Check for Updates**を選択します。同じpanelに現在のbuild、npmの最新版、更新状況が表示されます。Helpを開いただけでは通信しません。
85
+
86
+ `--update-check` はnpmの`latest` releaseを明示的に問い合わせ、更新の有無を表示します。起動時、`--help`、`--version`では自動実行しません。
87
+
88
+ `--doctor`はread-onlyの保守reportです。Node launcherでは選択中のconfig、npm latest、`npm audit --omit=dev`を確認し、更新が必要な場合も`--self-update`を案内するだけで自動更新はしません。standalone binaryではconfigと更新情報を確認し、npm package contextが無いためnpm auditは`unavailable`として表示します。
89
+
90
+ 一時的な設定上書き:
91
+
92
+ ```sh
93
+ fpasoterm --config ~/.config/fpasoterm/User/work.toml
94
+ fpasoterm --size 1200x760
95
+ fpasoterm --width 1200 --height 760
96
+ fpasoterm --shell /bin/fish
97
+ fpasoterm --cwd .
98
+ fpasoterm --cwd ~/work/project --title project
99
+ fpasoterm --command "tmux attach -t work"
100
+ fpasoterm --title work --titlebar-color '#2e7d32'
101
+ ```
102
+
103
+ よく使う一時指定には短縮形も使えます。
104
+
105
+ ```sh
106
+ fpasoterm -t work -b '#2e7d32' -z 1200x760 -s /bin/fish -o .
107
+ fpasoterm -e "tmux attach -t work"
108
+ ```
109
+
110
+ 起動中の window は、POSIX shell を使っている場合は terminal 内の command からも変更できます。
111
+
112
+ ```sh
113
+ printf '\033]0;work\a\r\n'
114
+ printf '\033]777;titlebarColor=#2e7d32\a\r\n'
115
+ printf '\033]777;opacity=0.65\a\r\n'
116
+ printf '\033]777;title=work;titlebarColor=#2e7d32\a\r\n'
117
+ ```
118
+
119
+ Windows PowerShell や cmd.exe では、この `printf` 例はそのまま使えません。
120
+ PowerShell 形式、または下記 helper script を使ってください。
121
+
122
+ ```powershell
123
+ [Console]::Write("$([char]27)]777;title=work;titlebarColor=#2e7d32$([char]7)`r`n")
124
+ ```
125
+
126
+ runtime config sample は次で適用できます。
127
+
128
+ ```sh
129
+ ./examples/apply-runtime-appearance.sh
130
+ ```
131
+
132
+ Windows PowerShell または cmd.exe では次を使えます。
133
+
134
+ ```powershell
135
+ .\examples\apply-runtime-appearance.ps1
136
+ .\examples\apply-runtime-appearance.bat
137
+ ```
138
+
139
+ この sample は title を `RUNTIME SAMPLE ACTIVE` にし、titlebar をピンク、
140
+ terminal 背景と文字色を分かりやすく変更します。
141
+
142
+ 起動中の window を標準の見た目へ戻す場合:
143
+
144
+ ```sh
145
+ ./examples/apply-default-appearance.sh
146
+ ```
147
+
148
+ Windows PowerShell または cmd.exe では次を使えます。
149
+
150
+ ```powershell
151
+ .\examples\apply-default-appearance.ps1
152
+ .\examples\apply-default-appearance.bat
153
+ ```
154
+
155
+ path を手動指定する場合:
156
+
157
+ ```sh
158
+ config_path="$(pwd)/examples/config/runtime-appearance.toml"
159
+ printf '\033]777;config=%s\a\r\n' "$config_path"
160
+ ```
161
+
162
+ Windows PowerShell で path を手動指定する場合:
163
+
164
+ ```powershell
165
+ $configPath = Resolve-Path .\examples\config\runtime-appearance.toml
166
+ [Console]::Write("$([char]27)]777;config=$configPath$([char]7)`r`n")
167
+ ```
168
+
169
+ runtime config 適用では、現在の shell session は維持されます。
170
+ `window.title`、`window.titlebarColor`、`window.width`、`window.height`、
171
+ `terminal.fontSize`、`terminal.lineHeight`、`terminal.fontFamily`、`terminal.backgroundOpacity`、`terminal.theme` など、起動中に反映可能な表示設定を適用します。
172
+ `terminal.shell` のように新しい PTY が必要な設定は次回起動時に反映されます。
173
+
174
+ 起動せずに解決済み設定と plugin 読み込み状況を確認:
175
+
176
+ ```sh
177
+ fpasoterm --show-config
178
+ fpasoterm --config ~/.config/fpasoterm/User/work.toml --show-config
179
+ ```
180
+
181
+ windowを開かずに設定を検証し、Issue向けMarkdown reportを作成する場合:
182
+
183
+ ```sh
184
+ fpasoterm --config-check
185
+ fpasoterm --doctor
186
+ fpasoterm --diagnostics
187
+ fpasoterm --copy-diagnostics
188
+ fpasoterm --open-log-dir
189
+ ```
190
+
191
+ 出力内容、exit status、clipboard要件は[設定と診断](docs/diagnostics.ja.md)を参照してください。
192
+
193
+ 名前付きの表示・shell profileを一回の起動だけ使う場合は
194
+ `fpasoterm --profile <name>`を使用します。詳細は[Profile](docs/config.ja.md#profile)を参照してください。
195
+
196
+ 起動中のwindowを新しいwindowを開かずに一覧表示:
197
+
198
+ ```sh
199
+ fpasoterm --list
200
+ fpasoterm -l
201
+ ```
202
+
203
+ 各行にprocess/session ID、表示title、起動時刻を表示します。
204
+
205
+ process ID、表示titleの完全一致、または予約targetの`all`で起動中のwindowを閉じます:
206
+
207
+ ```sh
208
+ fpasoterm --close 12345
209
+ fpasoterm -q review-shell
210
+ fpasoterm --close all
211
+ ```
212
+
213
+ Windows の packaged `fpasoterm.exe` を直接起動した場合、`--show-config` は
214
+ 解決済み runtime config を JSON で出力します。Node launcher を使える場合は
215
+ TOML と plugin load detail を表示します。
216
+ Windows で古い installer から上書き更新した後は `fpasoterm --version` を確認してください。
217
+ 古い UI が表示され、かつ `--version` も古い version を返す場合、`Path`、Start menu、pinned shortcut のいずれかが古い executable を起動しています。起動中の fpasoterm を閉じ、新しい installer を再実行してから更新後の shortcut で起動してください。
218
+
219
+ `config.toml` の plugin を有効化・無効化:
220
+
221
+ ```sh
222
+ fpasoterm --enable-plugin hello,theme
223
+ fpasoterm --disable-plugin hello,theme
224
+ ```
225
+
226
+ plugin enable/disable command は Node launcher が処理します。packaged binary
227
+ を直接起動している場合は、`config.toml` を手動編集するか、npm install された
228
+ `fpasoterm` command を使ってください。
229
+
230
+ デバッグ時にコンソールへ接続したまま起動する場合:
231
+
232
+ ```sh
233
+ fpasoterm --foreground --console-diagnostics
234
+ ```
235
+
236
+ source checkout で動作だけ確認する場合:
237
+
238
+ ```sh
239
+ ./bin/fpasoterm --dev
240
+ ```
241
+
242
+ ChromeOS/Baguette で透過や描画が不安定な場合:
243
+
244
+ ```sh
245
+ fpasoterm --disable-dmabuf
246
+ ```
247
+
248
+ ## 設定とプラグイン
249
+
250
+ fpasoterm は以下の設定を読み込みます。
251
+
252
+ ```text
253
+ ~/.config/fpasoterm/User/config.toml
254
+ ```
255
+
256
+ 初回起動時には以下にサンプルを書き出します。
257
+
258
+ ```text
259
+ ~/.config/fpasoterm/User/config.toml.example
260
+ ```
261
+
262
+ 例:
263
+
264
+ ```toml
265
+ [terminal]
266
+ fontSize = 15
267
+ lineHeight = 1
268
+ fontFamily = "Noto Sans Mono CJK JP, monospace"
269
+
270
+ [plugins]
271
+ enabled = ["plugins/example.ts"]
272
+ ```
273
+
274
+ プラグインは `~/.config/fpasoterm/User/plugins/` 配下に置きます。JavaScript (`.js`) と TypeScript (`.ts`) に対応しています。TypeScript plugin は起動時に `~/.config/fpasoterm/User/cache/plugins/` へ変換されます。plugin は renderer context で動作するため、内容を確認した信頼できるローカル file だけを有効にしてください。pluginとsync folderの信頼境界は[セキュリティ](docs/security.ja.md)を参照してください。
275
+
276
+ plugin は `version` を参照し、`onReady()` で起動後の処理を登録し、`registerCommand()` で hamburger menu の `Plugins` submenu に action を追加できます。`fpasoterm --plugin-list` でlocalの `User/plugins` にある検出済み・有効な plugin を確認し、`--plugin-enable` / `--plugin-disable` で有効 list を更新できます。`--plugin-info welcome-banner`ではsource、有効状態、description、load statusを確認できます。有効化またはsource変更後は対象windowを再起動してください。
277
+
278
+ review済みのlocal pluginとそのenabled entryを削除する場合は`fpasoterm --plugin-uninstall <file>`を使用します。これはlocal-onlyの操作であり、公開port catalogへは接続しません。
279
+
280
+ ports repository全体をcloneせず、Node.jsも使わずにreview済み公開pluginを取得する場合は、`fpasoterm --plugin-install appearance/teal`を実行します。内容確認後に有効化する場合だけ`--enable`を追加します。固定repository、検証、上書き条件は[プラグイン](docs/plugins.ja.md)を参照してください。
281
+
282
+ review済みのlocal `fpasoterm-plugins` checkoutからは、`fpasoterm --plugin-install appearance/teal --plugin-ports-dir ./fpasoterm-plugins --enable`を使用します。単独の信頼済みsource fileは`fpasoterm --plugin-install-file ./my-plugin.ts --enable`でcopyできます。ports projectはcatalog / INDEX検索とplugin開発・検証用で、利用者向けのinstallはfpasoterm本体が行います。
283
+
284
+ `fpasoterm --plugin-search [query]`はpluginを導入せず、公開port metadataだけを検索します。各結果にはcopyして使える`--plugin-install` commandとremote公式`INDEX`であるsourceを表示します。`--plugin-list`はlocal-onlyであり、networkには接続しません。
285
+
286
+ 最小の TypeScript plugin:
287
+
288
+ ```ts
289
+ /// <reference path="/path/to/fpasoterm/docs/fpasoterm-plugin.d.ts" />
290
+
291
+ const api = window.fpasotermPluginApi;
292
+ api.log('example plugin loaded');
293
+ api.terminal.options.cursorBlink = true;
294
+ ```
295
+
296
+ IME composition は表示専用です。WebView/xterm.js の入力経路で受け取った文字を、fpasoterm が抑止・再送・置換・直接確定することはありません。
297
+
298
+ 全デフォルト設定は [設定](docs/config.ja.md) にまとめています。plugin runtime/API contractは [プラグイン](docs/plugins.ja.md)、対応 API declarationは [`docs/fpasoterm-plugin.d.ts`](docs/fpasoterm-plugin.d.ts) を参照してください。設定 sample は [examples/config](examples/config)、最小のlocal plugin sampleは [examples/plugins](examples/plugins) にあります。review済みの公開pluginは、ports catalog、compatibility check、update、contribution workflowを管理する [fpasoterm-plugins](https://github.com/oyoguhito/fpasoterm-plugins) を使用してください。
299
+
300
+ 複数端末間のメンテナンス用途では、Google Drive for desktop などのローカル同期フォルダを使って、diagnostics と terminal output log を共有できます。Google Drive API や OAuth は使いません。詳細は [Sync Folder](docs/sync.ja.md) を参照してください。
301
+ Kitty Graphics Protocol、SIXEL、iTerm inline image は、image stream により Tauri/WebKitGTK renderer が停止することがあるため、現在は未対応です。`Ctrl+Shift+B` の Broadcast Input は対象の local fpasoterm window を選択して同じ command を送信できます。`fpasoterm --broadcast "command"` でも同じ操作を実行でき、trusted な同期フォルダを使う場合は別 machine で既に起動している全 instance にも短寿命 command を送れます。詳細は [設定](docs/config.ja.md) と [Sync Folder](docs/sync.ja.md) を参照してください。
302
+ 初回設定は `fpasoterm --setup-sync` で質問に答えるだけで作成できます。
303
+ Windows の source checkout では `node .\bin\fpasoterm --setup-sync` を使います。
304
+ `fpasoterm --sync-status` で folder health と channel を確認でき、`fpasoterm --sync-clean` は期限切れの sync command file だけを削除します。
305
+ terminal output log は hamburger menu の `Log Start (^S)` / `Log Stop (^S)` または `Ctrl+Shift+S` で取得し、`Log Show (^P)` または `Ctrl+Shift+P` で active log または `Log Stop` で閉じた最後の log を表示できます。共有したい場合は `logging.directory` を同期フォルダに向けます。
306
+ log panel には検索欄と `Search` ボタンがあり、表示中の log から次の一致文字列を選択してその位置へ scroll できます。`N` は次、`P` は前の一致箇所へ移動します。log text area に focus がある場合は `j` / `k` でも同じ移動ができ、矢印キーは通常の log scroll に使えます。
307
+
308
+ npm registry から global install する場合:
309
+
310
+ ```sh
311
+ npm install -g fpasoterm
312
+ fpasoterm
313
+ ```
314
+
315
+ 開発中に link する場合:
316
+
317
+ ```sh
318
+ npm link
319
+ fpasoterm
320
+ ```
321
+
322
+ または:
323
+
324
+ ```sh
325
+ npm install -g .
326
+ fpasoterm
327
+ ```
328
+
329
+ 診断:
330
+
331
+ ```sh
332
+ FPASOTERM_DEBUG_KEYS=1 ./scripts/run
333
+ cat ~/.config/fpasoterm/User/logs/fpasoterm-debug.log
334
+ ```
335
+
336
+ アイコンを変更する場合は `extra/logo/fpasoterm.png` を差し替え、以下を実行します。
337
+
338
+ ```sh
339
+ npm run generate:icons
340
+ npm run install:desktop
341
+ ```
342
+
343
+ ChromeOS Linux launcher は `extra/linux/icons/hicolor/` に生成されるサイズ別 PNG を使います。Android native package を作る場合は、この PNG を adaptive icon の元画像として使います。
344
+
345
+ ## アイコン
346
+
347
+ project icon は `extra/logo/fpasoterm.png` です。Linux/ChromeOS launcher は `extra/linux/icons/hicolor/` の icon theme file を使います。macOS bundle は `extra/macos/fpasoterm.icns`、Windows bundle は `extra/windows/fpasoterm.ico` を使います。
348
+
349
+ ## ライセンス
350
+
351
+ MIT。詳細は [LICENSE](LICENSE) を参照してください。
352
+
353
+ ## コントリビュート
354
+
355
+ [CONTRIBUTING.ja.md](CONTRIBUTING.ja.md) を参照してください。英語版は
356
+ [CONTRIBUTING.md](CONTRIBUTING.md)です。release 履歴は [CHANGELOG.md](CHANGELOG.md) に記録します。
357
+
358
+ ## jj repository 初期化
359
+
360
+ `main` bookmark は空の initial commit を指します。初期化は次を実行します。
361
+
362
+ ```sh
363
+ cd fpasoterm
364
+ ./scripts/init-jj-empty-main
365
+ ```
366
+
367
+ ## チェック
368
+
369
+ ```sh
370
+ npm run check
371
+ npm run scan:secrets
372
+ desktop-file-validate extra/linux/io.github.oyoguhito.fpasoterm.desktop
373
+ npm run audit:prod
374
+ ```
375
+
376
+ GitHub Actions は push と pull request で同じ check と Linux artifact build を実行します。正式な cross-platform artifact は tag-based Release workflow で生成します。
377
+
378
+ ## ドキュメント
379
+
380
+ - [仕様](docs/spec.ja.md)
381
+ - [設定](docs/config.ja.md)
382
+ - [Sync Folder](docs/sync.ja.md)
383
+ - [Pull request review](docs/pr-review.ja.md)
384
+ - [デバッグガイド](docs/debugging.ja.md)
385
+ - [リリースチェックリスト](docs/release-checklist.ja.md)
386
+ - [既知課題](docs/known-issues.ja.md)
387
+ ### SSHFS mount
388
+
389
+ `Sync > SSHFS Mounts`からremote directoryを`User/mounts/<name>`へmountできます。既定では通常のSSH key、config、agentを使い、任意のpasswordはそのmount時だけ使用して保存しません。詳細は[SSHFS mount](docs/sshfs.ja.md)を参照してください。