Skip to content

feat: Add a .editorconfig.#102

Merged
stasadev merged 4 commits intoddev:mainfrom
mparker17:add-editorconfig
May 1, 2026
Merged

feat: Add a .editorconfig.#102
stasadev merged 4 commits intoddev:mainfrom
mparker17:add-editorconfig

Conversation

@mparker17
Copy link
Copy Markdown
Contributor

The Issue

(I didn't create an issue for this)

I was working on a shell script for for another addon request, and noticed that my editor's defaults didn't match ddev conventions. I went looking for a .editorconfig and didn't find one in the repo I was working on, so I tried adding one.

In a review, @stasadev asked me to update the template (i.e.: this repo) with an editorconfig; and update the UpdateChecker, and update the .gitattributes.

How This PR Solves The Issue

Adds an editorconfig. Adds a simple test for it in UpdateChecker. Adds the .editorconfig to the export-ignore list.

Manual Testing Instructions

  1. Clone this branch
  2. Create a new .sh file in the project using an editor that supports the EditorConfig standard with default configuration
  3. Press the tab key:
    • Expected behavior: your cursor is indented 2 spaces
    • Previous behavior: your cursor is indented by something else (for me it was 4 spaces; but depending on the editor, it could be 8 spaces or 1 tab)

Automated Testing Overview

I updated the UpdateChecker test to look for the charset = utf-8 line, since that's probably a thing that should be in all ddev add-ons.

Release/Deployment Notes

None.

Copy link
Copy Markdown
Member

@stasadev stasadev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

Comment thread .editorconfig Outdated
@stasadev stasadev merged commit f0c1a3a into ddev:main May 1, 2026
2 checks passed
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