newBufferedReader requires a charset: java.nio.file.Files.newBufferedReader(flagFile, UTF_8);