Skip to content

Conversation

@msabramo
Copy link
Contributor

While editing readme.md for GH-17, I noticed that VS Code was
formatting lines with tabs for indentation and that it looked bad in the
diffs, because it wasn't matching the existing lines.

Ths updates .editconfig so that it uses spaces for indentation in
Markdown files, which seems to match what has been used.

$ git diff readme.md
diff --git a/readme.md b/readme.md
index 5a21992..e0f2c4a 100644
--- a/readme.md
+++ b/readme.md
@@ -24,6 +24,8 @@ $ chalk --help
   Options
     --template, -t  Style template. The `~` character negates the style.
     --demo          Demo of all Chalk styles.
+               --fake-flag1    Fake flag added BEFORE updating .editorconfig to use spaces for Markdown files
+    --fake-flag2    Fake flag added AFTER updating .editorconfig to use spaces for Markdown files

   Examples
     $ chalk red bold 'Unicorns & Rainbows'

While editing `readme.md` for chalkGH-17, I noticed that VS Code was
formatting lines with tabs for indentation and that it looked bad in the
diffs, because it wasn't matching the existing lines.

Ths updates `.editconfig` so that it uses spaces for indentation in
Markdown files, which seems to match what has been used.

```
$ git diff readme.md
diff --git a/readme.md b/readme.md
index 5a21992..e0f2c4a 100644
--- a/readme.md
+++ b/readme.md
@@ -24,6 +24,8 @@ $ chalk --help
   Options
     --template, -t  Style template. The `~` character negates the style.
     --demo          Demo of all Chalk styles.
+               --fake-flag1    Fake flag added BEFORE updating .editorconfig to use spaces for Markdown files
+    --fake-flag2    Fake flag added AFTER updating .editorconfig to use spaces for Markdown files

   Examples
     $ chalk red bold 'Unicorns & Rainbows'
```
@msabramo msabramo force-pushed the editorconfig-spaces-for-md-files branch from 972f2ef to 5f3f0ce Compare September 13, 2021 15:02
@sindresorhus
Copy link
Member

It's only using spaces there since it's a copy-paste the output of the CLI help.

@msabramo
Copy link
Contributor Author

Ah. I guess I should copy paste the actual CLI help into readme.md instead of manually editing it.

🤦‍♂️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants