private static String attr(int... code) { return new String(new char[] { 27, '[' }) + _attr(code) + "m"; }
@DefaultCommand public void run(@PipeIn InputStream pipeIn, final Resource<?> file, final PipeOut pipeOut) throws IOException { morePlugin.run(pipeIn, file, true, pipeOut); } }
@DefaultCommand public void run(@PipeIn final InputStream pipeIn, final Resource<?> file, @Option(name = "noautoexit", shortName = "x", flagOnly = true) final boolean noAutoExit, final PipeOut pipeOut) throws IOException { if (file != null) { InputStream fileInstream = null; try { fileInstream = file.getResourceInputStream(); more(fileInstream, pipeOut, noAutoExit); } finally { if (fileInstream != null) { fileInstream.close(); } } } else if (pipeIn != null) { more(pipeIn, pipeOut, noAutoExit); } }