in the CLI we've always called it roc format
I think we should probably change to roc fmt
fmt is what Go (the original) calls it, and so do zig and cargoNum, Str, Dict)thoughts?
I'm really no fan of all the abbreviations. Just more stuff to keep in mind especially when tab completions (or for formatting likely wanted on save) is a thing. But that's the usual discussion between conciseness versus clarity / readability.
that's fair, but it's also true that we already embrace them in general :smile:
So eventually also roc chk, roc bld and the like?
We could always accept both
I think CLIs don't take advantage of aliases enough
Totally agree. I love that I jj it has one letter short forms for everything. jj b c for jj bookmark create
Obviously rocs commands don't get some long in name as a source control program, but still relevant.
I don't like the shorthand versions. I much prefer the full word, format build check etc
I think it's friendlier for people who aren't already familiar with the tools. The first time you see fmt you might think what is "f.m.t"? or bld "b.l.d"?
That's why I prefer both. Fast for people who know. Long for people who are new/don't know/don't want to remember
Like I see we reason we can't accept all of roc format, roc fmt and roc f.
The reason I don't think we should (by default) is that all the tutorials and guides etc around will be fractured with different ways of doing the same thing which I think can be confusing.
It's not something I feel really strongly about, but I definitely prefer keeping it simple.
That's fair. I would assume anything trying to teach would use the long form, but it isn't guaranteed
Good point but I think the level of tutorial would assume the level of the reader. Like, roc format for beginners and roc fmt for advanced users.
However anyone can define aliases for their shell, and probably single roc format is good for ubiquitous consistency and clarity
I don't think shells allow multi-word aliases. It also, just isn't as convenient and can't be used in scripts.
Kiryl Dziamura schrieb:
Good point but I think the level of tutorial would assume the level of the reader. Like,
roc formatfor beginners androc fmtfor advanced users.
However anyone can define aliases for their shell, and probably singleroc formatis good for ubiquitous consistency and clarity
I think this would be even more dangerous. You imply advanced users use fmt. Now if one fancies himself advanced, yet works in a team, you've got colliding worlds. As much as I appreciate conciseness, I've seen more harm being done by abbreviations then good. More in a business / domain context, but as soon as you've got new joiners not deep in the domain or not in the context and you've got abbreviations everywhere it's a real pain as people misunderstand and usually don't query if they think they know what it's for.
Yet here also not feeling that strong. I'd personally anyways see most people not running this in CLI. I'd assume most users would at one point rely on the IDE to format on save.
This seems analogous to the common thing commands do with flags, where they have command --full-name-of-flag or command -f.
That would point toward us allowing format and f (but not fmt) so we have one obviously canonical name and one that's obviously only an abbreviation for the command line
Of note, I don't think this should every really cause meaningful problems. All the short and long forms should be explained by roc --help
So if someone see one and doesn't know what it means, they can just type in one command and learn exactly want it does
Totally agree that it is basically equivalent to short and long forms of flags.
I think the topic of whether we should allow single-letter aliases (e.g. f versus writing it out) is decoupled from this
I've never heard of beginners being confused about what fmt does and then the "aha" moment being that it was expanded to "format" :sweat_smile:
seems like the experiment that Go, Rust, and Zig have done has revealed that fmt is totally fine in practice, whereas nobody has tried bld or chk as far as I know
and I'm not advocating for any others - this is mostly about having used cargo fmt and zig fmt and feeling like ours is longer unnecessarily :smile:
it's like we've deviated from both the original and the most established name in order to make it more verbose
I mean, we're not talking about fmt exclusively. For me, "format" looks much more alien than "fmt", I used to call :fmt in helix and would never even think about typing :format.
But would it become a rule for other cases?
I want to scope this thread to literally the following:
roc format vs roc fmthappy to talk about shorthands, other commands, etc. in other threads, but I believe this is a decision we can make in isolation because there's plenty of precedent for doing so
e.g. it's cargo check, cargo build, cargo fmt and cargo doesn't have single-letter abbreviations
same with Zig
we don't need to couple this decision to the design of other commands
I personally trust fmt more than format. For me the second is associated with format drive lol
I'd like to support both. Flags and subcommands are easy to forget so I always appreciate some flexibility.
I also side with fmt because less to type and I see it in other places too.
I like fmt. It has precident, and the less I need to type when working in the terminal, the faster I can be.
Last updated: Jun 16 2026 at 16:19 UTC