mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-19 23:02:24 +00:00
Always use UTF-8
This commit is contained in:
1 parent
0cf9f0bf58
commit
01847e44de
26 files changed
+189
-117
No files matched your search
+4
-4
@@ -2,6 +2,7 @@ package io.ebeaninternal.dbmigration.model;
|
||||
|
||||
import io.ebean.config.DatabaseConfig;
|
||||
import io.ebean.config.dbplatform.DatabasePlatform;
|
||||
import io.ebean.util.IOUtils;
|
||||
import io.ebeaninternal.dbmigration.ddlgeneration.DdlBuffer;
|
||||
import io.ebeaninternal.dbmigration.ddlgeneration.DdlHandler;
|
||||
import io.ebeaninternal.dbmigration.ddlgeneration.DdlWrite;
|
||||
@@ -14,7 +15,6 @@ import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
import java.io.Writer;
|
||||
import java.util.List;
|
||||
@@ -70,16 +70,16 @@ public class PlatformDdlWriter {
|
||||
*/
|
||||
protected void writePlatformDdl(DdlWrite write, File resourcePath, String fullVersion) throws IOException {
|
||||
if (!write.isApplyEmpty()) {
|
||||
try (FileWriter applyWriter = createWriter(resourcePath, fullVersion, ".sql")) {
|
||||
try (Writer applyWriter = createWriter(resourcePath, fullVersion, ".sql")) {
|
||||
writeApplyDdl(applyWriter, write);
|
||||
applyWriter.flush();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected FileWriter createWriter(File path, String fullVersion, String suffix) throws IOException {
|
||||
protected Writer createWriter(File path, String fullVersion, String suffix) throws IOException {
|
||||
File applyFile = new File(path, fullVersion + suffix);
|
||||
return new FileWriter(applyFile);
|
||||
return IOUtils.newWriter(applyFile);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in new issue
Block a user