fix(826-2): 내 기계 옮김 = 다음 번호 큰 쪽
- 옛 코드 창이 옛 내기계.json 을 다시 써도 폴더 다음 번호가 뒤로 안 감 · 시험 한 줄 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -92,8 +92,8 @@ def _move(folder: Path | None = None) -> None:
|
||||
for row in got.get("줄") or []:
|
||||
if isinstance(row, dict) and mine(row.get("키")):
|
||||
atomic_write_json(base / f"{row['키']}.json", row)
|
||||
if not (base / NEXT).is_file():
|
||||
atomic_write_json(base / NEXT, {"다음": int(got.get("다음") or 1)})
|
||||
had = int(_load(base / NEXT).get("다음") or 1) # 옛 코드 창이 다시 쓴 옛 파일도 — 번호는 큰 쪽
|
||||
atomic_write_json(base / NEXT, {"다음": max(had, int(got.get("다음") or 1))})
|
||||
old.unlink()
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user