Created
March 2, 2025 12:50
-
-
Save floehopper/c17d7eef02037d045ed9eccf38864e88 to your computer and use it in GitHub Desktop.
Formatter suitable for zed editor using erb_lint gem
This file contains hidden or 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
#!/usr/bin/env sh | |
bundle exec erb_lint --autocorrect --stdin $1 2>/dev/null | sed '1,/^================/d' |
This file contains hidden or 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
{ | |
"languages": { | |
"ERB": { | |
"formatter": [ | |
{ | |
"external": { | |
"command": "$PATH_TO_FORMATTER/erb-lint-formatter", | |
"arguments": ["{buffer_path}"] | |
} | |
} | |
] | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment