From e80933d21e9305cbaac191cc9e5e3cdc4726cfd1 Mon Sep 17 00:00:00 2001 From: claude-bot Date: Mon, 27 Jul 2026 22:20:39 +0900 Subject: [PATCH] =?UTF-8?q?fix(installer):=20=EB=9F=B0=ED=83=80=EC=9E=84?= =?UTF-8?q?=20=ED=8F=B4=EB=8D=94=20=EC=9B=90=EB=B3=B8=20=EC=97=86=EC=9D=84?= =?UTF-8?q?=20=EB=95=8C=20=EB=B9=88=20=ED=8F=B4=EB=8D=94=20=EC=83=9D?= =?UTF-8?q?=EC=84=B1=20(assets=20=EC=A4=80=EB=B9=84=20=EC=8B=A4=ED=8C=A8?= =?UTF-8?q?=20=EC=99=84=ED=99=94)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit .minecraft/{assets,libraries,versions} 가 없으면(바닐라 미실행/다른 런처 환경) 링크를 건너뛰어 .mc_custom/ 이 아예 없어졌고, 그러면 마인크래프트가 "Unable to prepare assets for download" 로 실패했다(코드 주석에도 명시된 원인). 원본이 없으면 .mc_custom/ 을 빈 폴더로 만들어 런처가 그 gameDir 에 직접 받아가도록 수정. 0.4.20→0.4.21. Co-Authored-By: Claude Opus 4.7 --- locales/installer/ko-kr.json | 3 ++- package.json | 2 +- src/installer/main.ts | 12 ++++++++++++ 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/locales/installer/ko-kr.json b/locales/installer/ko-kr.json index c2d1c78..90e2d42 100644 --- a/locales/installer/ko-kr.json +++ b/locales/installer/ko-kr.json @@ -290,7 +290,8 @@ "settingCopyFail": "설정 복사 실패 ({{name}}): {{message}}", "settingCopySummary": "기존 마인크래프트 설정 복사: 새로 복사 {{copied}}개 / 동기화(options 류 덮어쓰기) {{synced}}개 / 보존(이미 존재) {{skipped}}개.", "settingCopyError": "기존 설정 복사 중 오류: {{message}}", - "runtimeDirMissing": ".minecraft/{{dir}} 가 없습니다. 마인크래프트 런처를 한 번 실행한 뒤 다시 시도해주세요.", + "runtimeDirMissing": ".minecraft/{{dir}} 가 없어 공용 링크를 만들 수 없습니다(런처가 이 폴더에 직접 받게 됩니다).", + "runtimeDirCreated": ".mc_custom/{{dir}} 폴더를 새로 만들었습니다(런처가 여기에 직접 다운로드).", "runtimeDirExists": ".mc_custom/{{dir}} 가 실제 폴더로 이미 존재 — 건너뜀.", "runtimeLinkCreated": "링크 생성: .mc_custom/{{dir}} → .minecraft/{{dir}}", "runtimeLinkFail": "링크 생성 실패 ({{dir}}): {{message}}", diff --git a/package.json b/package.json index a138d10..6d31e08 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "minecraft-music-quiz-installer", - "version": "0.4.20", + "version": "0.4.21", "description": "마인크래프트 음악퀴즈 간편설치기 + 관리 사이트", "main": "dist/installer/main.js", "scripts": { diff --git a/src/installer/main.ts b/src/installer/main.ts index 922bf5b..8d17d76 100644 --- a/src/installer/main.ts +++ b/src/installer/main.ts @@ -1755,7 +1755,19 @@ async function linkMinecraftRuntimeDirs(customRoot: string): Promise { const src = path.join(mcRoot, dir) const dst = path.join(customRoot, dir) if (!fs.existsSync(src)) { + // .minecraft 에 원본이 없으면(바닐라를 한 번도 안 받았거나 런처가 다른 위치를 쓰는 + // 환경) 링크를 만들 수 없다. 이때 그냥 건너뛰면 .mc_custom/ 이 아예 없어 + // 런처가 "Unable to prepare assets for download" 로 실패한다. 빈 폴더라도 만들어 + // 런처가 그 gameDir 에 직접 받아갈 수 있게 한다(없을 때만). sendLog(t('log.runtimeDirMissing', { dir })) + try { + if (!fs.existsSync(dst)) { + await fsp.mkdir(dst, { recursive: true }) + sendLog(t('log.runtimeDirCreated', { dir })) + } + } catch (err) { + sendLog(t('log.runtimeLinkFail', { dir, message: (err as Error).message })) + } continue } let existing: import('node:fs').Stats | null = null