Skip to content

Commit

Permalink
docs: Remove last broad cSpell bypass regex and fix all violations (#…
Browse files Browse the repository at this point in the history
…2802)

Remove last broad cSpell bypass regex and fix all violations
This bypassed all code blocks within markdown files
(I didn't notice this one before because it was just for markdowns; it explains some weirdness I was seeing)
Now the only remaining restriction is about colors, which I like
Also removed all usages of cSpell:disable in favor of word-specific bypasses
  • Loading branch information
luanpotter committed Oct 8, 2023
1 parent 5bcba9a commit 9b16b17
Show file tree
Hide file tree
Showing 15 changed files with 29 additions and 33 deletions.
1 change: 1 addition & 0 deletions .github/.cspell/dart_dictionary.txt
@@ -1,4 +1,5 @@
# keywords/terms specific to the Dart/Flutter ecosystem
canvaskit # CLI option that improves rendering on web https://docs.flutter.dev/platform-integration/web/renderers#command-line-options
cupertino # Flutter module containing iOS-style widgets
dartdoc # documentation tool for dart
dartdocs # plural of dartdoc
Expand Down
1 change: 1 addition & 0 deletions .github/.cspell/flame_dictionary.txt
Expand Up @@ -5,6 +5,7 @@ Audioplayers # A Flutter plugin to play multiple simultaneously audio files http
BGUG # Break Guns Using Gems, a game by BlueFire https://github.com/bluefireteam/bgug
Bodymovin # An After Effects extension to export Lottie animations https://aescripts.com/bodymovin/
Dashbook # UI development tool for Flutter https://github.com/bluefireteam/dashbook
emberquest # Ember Quest, our platformer tutorial game
Hermione # A character from the book Harry Potter
Kawabunga # Word expressing exhilaration, of unclear origins but popularized by the show Teenage Mutant Ninja Turtles
Mocktail # A library for Dart that automatically creates mocks for tests https://github.com/felangel/mocktail
Expand Down
2 changes: 2 additions & 0 deletions .github/.cspell/people_usernames.txt
@@ -1,5 +1,6 @@
# specific people's names and/or usernames
akida # github.com/akida
bluefireteam # github.com/bluefireteam
erayzesen # erayzesen.itch.io
erickzanardo # github.com/erickzanardo
feroult # github.com/feroult
Expand All @@ -9,6 +10,7 @@ luanpotter # github.com/luanpotter
Lukas # github.com/spydon
pgainullin # github.com/pgainullin
Schnurber # github.com/schnurber
subosito # github.com/subosito
spydon # github.com/spydon
stpasha # github.com/stpasha
tavian # tavianator.com
Expand Down
8 changes: 0 additions & 8 deletions .github/cspell.json
Expand Up @@ -23,14 +23,6 @@
"people_usernames",
"words_dictionary"
],
"languageSettings": [
{
"languageId": "markdown",
"ignoreRegExpList": [
"/^\\s*```[\\s\\S]*?^\\s*```/gm"
]
}
],
"dictionaryDefinitions": [
{
"name": "dart_dictionary",
Expand Down
2 changes: 1 addition & 1 deletion doc/bridge_packages/flame_forge2d/joints.md
Expand Up @@ -283,7 +283,7 @@ joint.

```{warning}
Many users have tried to adapt the mouse joint for game play. Users often want
to achieve precisepositioning and instantaneous response. The mouse joint
to achieve precise positioning and instantaneous response. The mouse joint
doesn't work very well in that context. You may wish to consider using
kinematic bodies instead.
```
Expand Down
2 changes: 1 addition & 1 deletion doc/flame/rendering/particles.md
Expand Up @@ -279,7 +279,7 @@ game.add(
Renders given `dart:ui` image within the particle tree.

```dart
// During game initialisation
// During game initialization
await Flame.images.loadAll(const [
'image.png',
]);
Expand Down
4 changes: 3 additions & 1 deletion doc/other_modules/jenny/index.md
@@ -1,3 +1,5 @@
<!-- cSpell:ignore Slughorn horcrux horcruxes Moste Potente -->

# Jenny

The **jenny** library is a toolset for adding *dialogue* into a game. The dialogue may be quite
Expand Down Expand Up @@ -58,7 +60,7 @@ title: Slughorn_encounter
Slughorn: Oh hello, Tom, is there anything I can help you with?
Tom: Good {time_of_day()}, Professor.
-> I was curious about the 12 uses of the dragon blood.
Slughorn: Such an inquisitive mind! You can read about that in the "Most \
Slughorn: Such an inquisitive mind! You can read about that in the "Moste \
Potente Potions" in the Restricted Section of the library.
<<give restricted_library_pass>>
Tom: Thank you, Professor, this is very munificent of you.
Expand Down
Expand Up @@ -74,10 +74,10 @@ title: Blacksmith
// - money(): returns the current amount of money that the player has.
// At the same time, functions `round()` and `plural()` are built-in.
<<if broken("mainhand")>>
<<local $repair_cost = round(value("mainhand") / 5)>>
<<if broken("main_hand")>>
<<local $repair_cost = round(value("main_hand") / 5)>>
Blacksmith: Your {name("mainhand")} seems to be completely broken!
Blacksmith: Your {name("main_hand")} seems to be completely broken!
Blacksmith: I can fix it for just {plural($repair_cost, "% coin")}
-> Ok, do it <<if money() >= $repair_cost>>
-> I'll be fine...
Expand Down
Expand Up @@ -55,6 +55,7 @@ the first word is the singular form, while others are different plurals -- their
depend on a particular language. For example, in Ukrainian locale (`uk`) the function `plural()`
requires 3 words: the singular form, the "few" plural form, and the "many" plural form:

<!--- cSpell:ignore мене монета монети монет -->
```yarn
// Assuming locale == 'uk'
У мене є {plural($coins, "% монета", "% монети", "% монет")}.
Expand Down Expand Up @@ -85,7 +86,7 @@ given name does not exist in the project, an exception will be thrown.
title: LuckyWheel
---
<<if visit_count("LuckyWheel") < 5>>
Clown: Would you like to speen a wheel and get fabulous prizes?
Clown: Would you like to spin a wheel and get fabulous prizes?
-> I sure do!
<<jump SpinLuckyWheel>>
-> I don't talk to strangers...
Expand Down Expand Up @@ -118,8 +119,8 @@ title: MerchantDialogue
<<if not visited("MerchantDialogue")>>
// This part of the dialogue will run only during the first interaction
// with the merchant.
Merchant: Greetings! My name is Hazeem
Merchant: I offer exquisute wares for the most fastidious customers!
Merchant: Greetings! My name is Linn.
Merchant: I offer exquisite wares for the most fastidious customers!
Player: Hi. I'm Bob. I like stuff.
<<endif>>
...
Expand Down
3 changes: 2 additions & 1 deletion doc/other_modules/jenny/language/lines.md
Expand Up @@ -135,11 +135,12 @@ is a `#` symbol followed by any text that doesn't contain whitespace.
Hashtags are used to add line-level metadata. There can be no line content after a hashtag (though
comments are allowed). A line can have multiple hashtags associated with it.

<!-- cSpell:ignore HPMOR (Harry Potter and the Methods of Rationality) -->
```yarn
title: Hashtags
---
Harry: There is no justice in the laws of Nature, Headmaster, no term for \
fairness in the equations of motion. #sad // HPMOR.39
fairness in the equations of motion. #sad // HPMOR.39
Harry: The universe is neither evil, nor good, it simply does not care.
Harry: The stars don't care, or the Sun, or the sky.
Harry: But they don't have to! We care! #elated #volume:+1
Expand Down
7 changes: 5 additions & 2 deletions doc/other_modules/jenny/language/markup.md
@@ -1,3 +1,6 @@
<!-- cSpell:ignore lorem ipsum dolor sit amet, consectetur adipiscing elit -->
<!-- cSpell:ignore Malfoy -->

# Markup

**Markup** is a mechanism for annotating fragments of a dialogue line. They are somewhat similar to
Expand Down Expand Up @@ -27,7 +30,7 @@ The special **close-all** markup tag `[/]` closes all currently opened markup ra
handy in situations where the name of the markup tag is long and you don't want to repeat it:

```yarn
Lorem ipsum dolor sit amet, [Incididunt]consectetur adipiscing elit[/]
Lorem ipsum dolor sit amet, [bold]consectetur adipiscing elit[/]
```

The **self-closing** markup tags have the form `[tag_name/]`. These tags mark a single location
Expand All @@ -36,7 +39,7 @@ space after the tag will be removed from the resulting text. If this is undesire
add an extra space after the markup tag:

```yarn
Lorem ipsum dolor sit amet, [carramba/] consectetur adipiscing elit.
Lorem ipsum dolor sit amet, [wave/] consectetur adipiscing elit.
```

Markup tags also accept parameters, which are similar to HTML tag attributes. The names of these
Expand Down
2 changes: 1 addition & 1 deletion doc/other_modules/oxygen/oxygen.md
Expand Up @@ -69,7 +69,7 @@ This allows easy access to the methods on the game class.
class YourSystem extends System with GameRef<YourGame> {
@override
void init() {
// Access to game using the .game propery
// Access to game using the .game property
}
// ...
Expand Down
6 changes: 2 additions & 4 deletions packages/flame/test/components/text_box_component_test.dart
Expand Up @@ -6,9 +6,6 @@ import 'package:flame/palette.dart';
import 'package:flame_test/flame_test.dart';
import 'package:flutter_test/flutter_test.dart';

// disable cspell as this file contains character dialogue
// cSpell:disable

void main() {
group('TextBoxComponent', () {
test('size is properly computed', () async {
Expand Down Expand Up @@ -147,8 +144,9 @@ void main() {
align: Anchor.topRight,
),
_FramedTextBox(
// cSpell:ignore runn'st (old english)
text: 'To move is to stir, and to be valiant is to stand. '
'Therefore, if thou art moved, thou runnst away.',
"Therefore, if thou art moved, thou runn'st away.",
position: Vector2(10, 370),
size: Vector2(390, 220),
align: Anchor.bottomRight,
Expand Down
5 changes: 1 addition & 4 deletions packages/flame_jenny/jenny/test/dialogue_runner_test.dart
Expand Up @@ -6,9 +6,6 @@ import 'package:test/test.dart';
import 'test_scenario.dart';
import 'utils.dart';

// disable cspell as this file contains character dialogue
// cSpell:disable

void main() {
group('DialogueRunner', () {
test('plain dialogue', () async {
Expand Down Expand Up @@ -245,7 +242,7 @@ void main() {
colorID: 0
position: 763,472
---
A: HAHAHA
A: HA HA HA
===''',
testPlan: '''
line: A: Hey, I'm a character in a script!
Expand Down
Expand Up @@ -6,9 +6,6 @@ import 'package:test/test.dart';
import '../../test_scenario.dart';
import '../../utils.dart';

// disable cspell as this file contains character dialogue
// cSpell:disable

void main() {
group('SetCommand', () {
test('tokenize <<set>>', () {
Expand Down Expand Up @@ -45,6 +42,7 @@ void main() {
});

test('Basic.plan', () async {
// cSpell:ignore noooo haha aargh
await testScenario(
input: r'''
<<declare $foo as Number>>
Expand All @@ -67,7 +65,7 @@ void main() {
<<if $foo is 54>>
haha nice now 'set' works even when deeply nested
<<else>>
aaargh >:(
aargh >:(
<<endif>>
===
''',
Expand Down

0 comments on commit 9b16b17

Please sign in to comment.