You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: scribblings/fmt.scrbl
+7-8Lines changed: 7 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@
22
22
23
23
This package provides a tool @exec{raco fmt} to reformat Racket code.
24
24
25
-
The package uses @racketmodname[pretty-expressive], a very expressive pretty printer library, to compute the most optimal layout of the output code, and uses @racketmodname[syntax-color/module-lexer #:indirect] to lex the input program.
25
+
The package uses @racketmodname[syntax-color/module-lexer #:indirect] to lex the input program, and uses @racketmodname[pretty-expressive], an expressive pretty printer library, to compute an optimal layout of the output code.
26
26
27
27
The interface to allow users to extend formatting style is extremely unstable and is still a work in progress. For now, the only thing that is stable is the command @exec{raco fmt}.
28
28
@@ -44,16 +44,15 @@ The @exec{raco fmt} command accepts the following flags:
44
44
@item{@DFlag{max-blank-lines} @nonterm{n} --- set the maximum consecutive blank lines limit
45
45
to @nonterm{n}, which must be either a natural number or @racket[+inf.0].
46
46
The default value is @racket[1].}
47
-
@item{@DFlag{indent} @nonterm{n} --- set the indentation level for subsequent lines to @nonterm{n},
48
-
which must be a natural number.
47
+
@item{@DFlag{indent} @nonterm{n} --- set the indentation level in spaces to @nonterm{n} for subsequent lines.
49
48
The default value is @racket[0].}
50
49
@item{@Flag{i} --- modify the input files in-place instead of outputting to standard output.
51
-
This flag has no effect if @exec{raco fmt} accepts the input from the standard input.}
50
+
This flag has no effect if @exec{raco fmt} accepts the input from standard input.}
52
51
]
53
52
54
53
@section{Examples}
55
54
56
-
Given the file @filepath{example.rkt} shown on the left, running @exec{raco fmt --width 40 example.rkt} would output the program on the right:
55
+
Given the file @filepath{example.rkt} shown on the left, running @exec{raco fmt --width 40 example.rkt} outputs the program on the right:
0 commit comments