-
Notifications
You must be signed in to change notification settings - Fork 182
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'MAIN' into cmts-factor
- Loading branch information
Showing
91 changed files
with
1,731 additions
and
3,182 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
blank_issues_enabled: false | ||
contact_links: | ||
- name: OCaml Community Forum | ||
url: https://discuss.ocaml.org/ | ||
about: Please ask and answer questions here. | ||
- name: OCaml Community Discord | ||
url: https://discord.gg/cCYQbqN | ||
about: Please ask and answer questions here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
name: Question | ||
about: Do you have a question about ocamlformat? | ||
title: 'Question: ...' | ||
labels: 'Kind/question' | ||
assignees: '' | ||
|
||
--- | ||
|
||
Please give as much context as possible. | ||
|
||
Is your question related to a specific OCaml version? | ||
Is your question related to a specific OCamlFormat version? | ||
Is your question related to a specific formatting profile or option? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
name: Style suggestion | ||
about: Suggest a different formatting style for this project | ||
title: 'Style suggestion: ...' | ||
labels: 'Kind/style-suggestion' | ||
assignees: '' | ||
|
||
--- | ||
|
||
**Current formatting** | ||
Please copy-paste your code and the formatting that is currently applied to it. | ||
|
||
**Describe the formatting you'd like** | ||
A clear and concise description of what you want to happen. | ||
|
||
**Additional context** | ||
Add any other context about the style request here. | ||
What justifies ocamlformat adding this new style? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
profile = ocamlformat | ||
break-cases = fit | ||
margin = 77 | ||
parse-docstrings = true | ||
wrap-comments = true | ||
line-endings = lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
{0 How OCamlFormat computes its configuration} | ||
|
||
{1 Configuration files} | ||
|
||
Ocamlformat fetches the following files on the file system: | ||
|
||
1. [.git], [.hg] or [dune-project] | ||
2. [.ocamlformat] and [.ocp-indent] | ||
3. [.ocamlformat-ignore] and [.ocamlformat-enable] | ||
|
||
(1.) files are used to determine the {b project root}, which can be overriden by the [--root] option, they are looked up from the path of the file to format, and upwards following parent directories, until the first one is found. | ||
|
||
(2.) and (3.) are looked up from the path of the file to format, and following up the parents up to the project root. | ||
|
||
(2.) are the {b configuration files}, they contain the options used to configure ocamlformat. A global [.ocamlformat] file can also be used: [$XDG_CONFIG_HOME/ocamlformat] (if defined). | ||
|
||
|
||
{1 How the configuration is built} | ||
|
||
The configuration files are considered in sequence, starting from the root of the project, and down to the directory of the file to format, overriding one or many options at each application. | ||
|
||
+ The initial configuration is equal to the [default] (or [conventional]) profile. | ||
+ The options passed through the configuration files are applied. | ||
+ The options passed through the [OCAMLFORMAT] environment variable are applied, overriding one or many options at a time. | ||
+ The options passed through the command line are applied, overriding one or many options at a time. | ||
|
||
When the option [--enable-outside-detected-project] is set, [.ocamlformat] files outside of the project are read, if no [.ocamlformat] file has been found then then apply the global configuration [$XDG_CONFIG_HOME/ocamlformat] (if defined). The global configuration file is ignore in any other case. | ||
|
||
When this option is not set, [.ocamlformat] files outside of the project are ignored. | ||
|
||
If no configuration file is found, the formatting is disabled. | ||
|
||
{1 Overriding the configuration in the source} | ||
|
||
Note that some options can be overriden directly in the source, with attributes like: | ||
|
||
{@ocaml[ | ||
(* attributes attached to algebraic constructs *) | ||
x [@ocamlformat "option=value,option=value"];; | ||
|
||
(* item attributes, attached to "blocks" *) | ||
y [@@ocamlformat "option=value,option=value"];; | ||
|
||
(* floating attributes, standalone *) | ||
[@@@ocamlformat "option=value,option=value"] | ||
]} | ||
|
||
All "formatting options" (listed in the {{!page-manpage_ocamlformat}manpage}) can be set in attributes. | ||
|
||
Among the non-formatting options only [enable]/[disable] can be set in floatting attributes. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -82,7 +82,6 @@ | |
(>= 1.4.0)) | ||
; for vendored odoc-parser | ||
astring | ||
result | ||
camlp-streams)) | ||
|
||
(package | ||
|
Oops, something went wrong.