fix(IconExporter): ZIP 파일을 icons 폴더 안에 생성하도록 수정
This commit is contained in:
parent
27888c557d
commit
6a3d698d9a
2 changed files with 20 additions and 20 deletions
|
|
@ -65,11 +65,11 @@
|
|||
│ ├── blocks/
|
||||
│ │ ├── brass_casing.png
|
||||
│ │ └── ...
|
||||
│ └── items/
|
||||
│ ├── brass_ingot.png
|
||||
│ └── ...
|
||||
└── icons_create_20251226_181500.zip ← 자동 생성
|
||||
```
|
||||
│ │ └── items/
|
||||
│ │ ├── brass_ingot.png
|
||||
│ │ └── ...
|
||||
│ └── create_20251226_181500.zip ← 자동 생성
|
||||
└── ...
|
||||
|
||||
---
|
||||
|
||||
|
|
@ -87,6 +87,7 @@
|
|||
## 📁 구조
|
||||
|
||||
```
|
||||
|
||||
IconExporter/
|
||||
├── src/main/
|
||||
│ ├── kotlin/com/beemer/iconexporter/
|
||||
|
|
@ -97,7 +98,8 @@ IconExporter/
|
|||
│ └── resources/
|
||||
│ └── META-INF/ # 모드 메타데이터
|
||||
└── build.gradle
|
||||
```
|
||||
|
||||
````
|
||||
|
||||
---
|
||||
|
||||
|
|
@ -113,6 +115,6 @@ IconExporter/
|
|||
|
||||
```bash
|
||||
./gradlew build
|
||||
```
|
||||
````
|
||||
|
||||
빌드된 JAR: `build/libs/iconexporter-1.0.0.jar`
|
||||
|
|
|
|||
|
|
@ -265,22 +265,20 @@ object IconExportManager {
|
|||
}
|
||||
}
|
||||
|
||||
/** icons 폴더를 ZIP으로 압축 파일명: icons_<modFilter>_<timestamp>.zip */
|
||||
/** icons 폴더를 ZIP으로 압축 파일명: <modFilter>_<timestamp>.zip */
|
||||
private fun createZipArchive(iconsDir: Path): Path? {
|
||||
if (!iconsDir.exists()) {
|
||||
return null
|
||||
}
|
||||
|
||||
val mc = Minecraft.getInstance()
|
||||
val gameDir = mc.gameDirectory.toPath()
|
||||
|
||||
// ZIP 파일명 생성
|
||||
val timestamp =
|
||||
java.time.LocalDateTime.now()
|
||||
.format(java.time.format.DateTimeFormatter.ofPattern("yyyyMMdd_HHmmss"))
|
||||
val modName = currentModFilter ?: "all"
|
||||
val zipFileName = "icons_${modName}_$timestamp.zip"
|
||||
val zipPath = gameDir.resolve(zipFileName)
|
||||
val zipFileName = "${modName}_$timestamp.zip"
|
||||
// icons 폴더 안에 ZIP 생성
|
||||
val zipPath = iconsDir.resolve(zipFileName)
|
||||
|
||||
IconExporter.LOGGER.info("ZIP 압축 생성 중: {}", zipPath)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue