Skip to content

Commit

Permalink
tweak, add for
Browse files Browse the repository at this point in the history
  • Loading branch information
fdncred committed Mar 20, 2023
1 parent e38faa9 commit a1d5bd3
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions docs/specification.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ This specification serves as a starting point to document how `nufmt` should wor

There should be an `--indent` parameter to allow one to specify the number of spaces to use for indentation.

### Supported Commands
## Supported Commands

This is the list of the supported commands and their idiomatic formatting.
This is the list of the supported commands and their idiomatic formatting. Indentation will be covered by the `--indent` flag but for these examples, 2 spaces will be used.

#### if
### if

The if clause should look like this. Indentation will be covered by the `--indent` flag but for these examples, 2 spaces will be used.
The if clause should look like this.

```rust
if condition {
Expand All @@ -25,4 +25,14 @@ if condition {
} else {
// else the last thing
}
```

### for

The for command should have formatting like this

```rust
for var in 0..100 {
// do something here
}
```

0 comments on commit a1d5bd3

Please sign in to comment.