Pretty Print R Code in the Terminal

Replace the standard print method for functions with one that performs syntax highlighting, using ANSI colors, if the terminal supports them.


Linux Build Status Windows Build status CRAN RStudio mirror downloads Coverage Status

Replace the standard print method for functions with one that performs syntax highlighting, using ANSI colors, if the terminal supports them.

Installation

source("https://install-github.me/r-lib/prettycode")

Usage

Just load the package and start printing functions to the screen. Long functions are automatically paged using the default pager.

License

MIT © Gábor Csárdi

News

1.0.1

  • Avoid registering the print.function S3 method. This is needed to avoid a new R CMD check check

1.0.0

First public release.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("prettycode")

1.0.1 by Gábor Csárdi, 7 months ago


https://github.com/r-lib/prettycode#readme


Report a bug at https://github.com/r-lib/prettycode/issues


Browse source code at https://github.com/cran/prettycode


Authors: Gábor Csárdi


Documentation:   PDF Manual  


MIT + file LICENSE license


Imports crayon, utils, withr

Suggests covr, mockery, testthat


Imported by tracer.


See at CRAN