/* 文件写入操作 追加方式append*/
String content = "good good";
Files.write(Paths.get("/Users/www/Desktop/test.sh"),content.getBytes(StandardCharsets.UTF_8), StandardOpenOption.APPEND);
/* 文件读取操作*/
byte[] bytes = Files.readAllBytes(Paths.get("/Users/www/Desktop/test.sh"));
System.out.println(new String(bytes,StandardCharsets.UTF_8));