Skip to content

Commit

Permalink
Adding formatting steps to CONTRIBUTING.md.
Browse files Browse the repository at this point in the history
  • Loading branch information
codetalker7 committed Sep 4, 2023
1 parent ba22ca1 commit c109ee1
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,4 +154,20 @@ The following table shows how the Flux code is organized:
| docs | Documentation site |
| paper | Paper that describes Flux |
| src | Source for Flux |
| test | Test suites |
| test | Test suites |

### Julia Formatter

Flux also uses it's own formatting style (see `dev/flux_format.jl`), with the style defined in the `.JuliaFormatter.toml` config file. All contributors must make sure to conform to this formatting style. To do this, run the following setup file on your local repository:

```julia
julia dev/setup.jl
```

This will setup the tooling environment (defined in the `dev/` directory), and will set up a hook to run the formatter before any changes are committed. You can also manually format the codebase by running

```julia
julia dev/flux_format.jl --verbose .
```

Flux's CI will also test whether any changes you make conform to this formatting style whenever any pull request is made.

0 comments on commit c109ee1

Please sign in to comment.