fix: Fix command argument formatting in terminal initlinux

This commit is contained in:
l061x 2025-12-26 18:56:24 +08:00 committed by GitHub
parent ffadc6721b
commit c5ec9e1f05
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -55,7 +55,7 @@ const initTerm = async (cwd: string) => {
await nextTick();
terminalRef.value!.acceptParams({
endpoint: '/api/v2/hosts/terminal',
args: `command=${encodeURIComponent(`clear && cd ${cwd}`)}`,
args: `command=${encodeURIComponent(`clear && cd "${cwd}"`)}`,
error: '',
initCmd: '',
});