https://github.com/ryym/rbfmt
Ruby code formatter
https://github.com/ryym/rbfmt
formatter ruby rust
Last synced: about 2 months ago
JSON representation
Ruby code formatter
- Host: GitHub
- URL: https://github.com/ryym/rbfmt
- Owner: ryym
- License: mit
- Created: 2023-12-03T23:24:49.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-07-21T12:38:09.000Z (10 months ago)
- Last Synced: 2025-02-28T16:12:15.450Z (2 months ago)
- Topics: formatter, ruby, rust
- Language: Rust
- Homepage:
- Size: 899 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
> [!WARNING]
> This is currently under development and has many TODOs and bugs.# rbfmt
Rbfmt is a yet another Ruby code formatter written in Rust, based on the Ruby's official [Prism][prism] parser.
[prism]: https://ruby.github.io/prism/
```ruby
# a.rb
foo . bar(1,2 3 # 4
)
``````bash
$ rbfmt a.rb
# a.rb
foo.bar(
1,
2,
3 # 4
)
```## Installation
```bash
$ cargo install rbfmt
```## Configuration
You can configure formatting via `.rbfmt.yml` file.
Available values and defaults:
```yaml
format:
line_width: 100
```