code blocks: use properties language

This commit is contained in:
Yann Cébron 2024-11-14 11:25:43 +01:00
parent fb3d2c1c1a
commit 6b26006b86
8 changed files with 14 additions and 13 deletions

View File

@ -85,9 +85,10 @@ While `SimpleProperty` elements will provide us with their key and value, we hav
Since we would like to show this comment in the documentation as well, we need a small helper function that extracts the text from the comment.
This function will reside in the `SimpleUtil` class and will find, for instance, the comment preceding `apikey` in the following short example:
```text
#An application programming interface key (API key) is a unique identifier
#used to authenticate a user, developer, or calling program to an API.
```properties
# An application programming interface key (API key) is a unique
# identifier used to authenticate a user, developer, or calling
# program to an API.
apikey=ph342m91337h4xX0r5k!11Zz!
```

View File

@ -38,11 +38,11 @@ Define a formatter that removes extra spaces except for the single spaces around
<compare type="top-bottom">
```
```properties
foo = bar
```
```
```properties
foo = bar
```
</compare>

View File

@ -101,7 +101,7 @@ Run the plugin by using the Gradle [`runIde`](creating_plugin_project.md#running
Create a <path>test.simple</path> file with the following content:
```text
```properties
# You are reading the ".properties" entry.
! The exclamation mark can also mark text as comments.
website = https://en.wikipedia.org/

View File

@ -14,7 +14,7 @@
Create the <path>DefaultTestData.simple</path> file in the <path>testData</path> directory.
This file contains test Simple language properties that will be completed in a test Java file (see the `Test` class later in this section).
```bash
```properties
```
{src="simple_language_plugin/src/test/testData/DefaultTestData.simple"}

View File

@ -15,7 +15,7 @@
## Define the Test Data
Create the <path>FindUsagesTestData.simple</path> file in the <path>testData</path> directory.
```bash
```properties
```
{src="simple_language_plugin/src/test/testData/FindUsagesTestData.simple"}

View File

@ -17,7 +17,7 @@ See also [`FormatterTestCase`](%gh-ic%/platform/testFramework/src/com/intellij/p
## Define Test Data
Create the <path>FormatterTestData.simple</path> file in the <path>testData</path> directory.
```bash
```properties
```
{src="simple_language_plugin/src/test/testData/FormatterTestData.simple"}

View File

@ -35,7 +35,7 @@ private recover_property ::= !(KEY|SEPARATOR|COMMENT)
Create the <path>ParsingTestData.simple</path> properties file in the <path>testData</path> folder.
Note the last few lines define a purposely incorrect key.
```bash
```properties
```
{src="simple_language_plugin/src/test/testData/ParsingTestData.simple"}
@ -51,7 +51,7 @@ Use the <control>Copy PSI</control> button to copy the expected PSI structure to
## Define the Output Reference Test Data
Create a file <path>ParsingTestData.txt</path> with the copied PSI tree.
```text
```properties
```
{src="simple_language_plugin/src/test/testData/ParsingTestData.txt"}

View File

@ -15,7 +15,7 @@
## Define Input Test Data
Create the <path>RenameTestData.simple</path> properties file in the <path>testData</path> directory.
```bash
```properties
```
{src="simple_language_plugin/src/test/testData/RenameTestData.simple"}
@ -31,7 +31,7 @@ Create the <path>RenameTestDataAfter.simple</path> file in the <path>testData</p
This file contains the expected outcome of the test.
Note the `website =` in <path>RenameTestData.simple</path> should be renamed to `websiteUrl =` by the test.
```bash
```properties
```
{src="simple_language_plugin/src/test/testData/RenameTestDataAfter.simple"}