Skip to content

Commit

Permalink
Changes PGN files extension to .pgn
Browse files Browse the repository at this point in the history
  • Loading branch information
fathzer committed Apr 16, 2024
1 parent ffa41bc commit e332e86
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/com/fathzer/jchess/GameRecorder.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public static void commit(Settings settings, Color player1Color, GameHistory his
}

private static PrintWriter out() throws IOException {
final Path file = Path.of("./data/pgn", PGNWriter.DATE_FORMAT.format(LocalDate.now())+".txt");
final Path file = Path.of("./data/pgn", PGNWriter.DATE_FORMAT.format(LocalDate.now())+".pgn");
Files.createDirectories(file.getParent());
final PrintWriter printer = new PrintWriter(Files.newBufferedWriter(file, StandardOpenOption.CREATE, StandardOpenOption.APPEND));
if (Files.size(file)!=0) {
Expand Down

0 comments on commit e332e86

Please sign in to comment.