Right now file.append can take in a line number, but this is brittle. Instead if would be nice if we could match on a placeholder comment and have rundoc figure out the line for us like:
:::>> file.before("src/main/java/com/heroku/java/GettingStartedApplication.java", match: "// Add new endpoints here")
@GetMapping("/convert")
String convert(Map<String, Object> model) {
RelativisticModel.select();
var energy = Amount.valueOf("12 GeV");
model.put("result", "E=mc^2: " + energy + " = " + energy.to(SI.KILOGRAM));
return "convert";
}
Can expand file.append to take the same kwarg.
Right now
file.appendcan take in a line number, but this is brittle. Instead if would be nice if we could match on a placeholder comment and have rundoc figure out the line for us like:Can expand
file.appendto take the same kwarg.