jgm / djot

A light markup language
https://djot.net
MIT License
1.63k stars 43 forks source link

Recommended file extension? #156

Closed jez closed 1 year ago

jez commented 1 year ago

https://github.com/jgm/djot/blob/374381b314c1f0a38f063e8de370f2cbfc4a4deb/editors/vim/ftdetect/djot.vim#L1

The included Vim plugin makes it clear that the expectation is to use *.dj as the file extension for djot-formatted documents.

I couldn't find a mention of this in any of the public docs. Did my search skills fail me? Otherwise, might I suggest tweaking some of the existing docs to publicize this extension more widely, so that tools do not diverge too far from each other?

jgm commented 1 year ago

Yes, we could do this, if there aren't problems with .dj. I just started using that without putting much thought into it.

jez commented 1 year ago

For what it's worth, there is no entry for ".dj" in the languages.yml file used by github/linguist:

https://github.com/github/linguist/blob/master/lib/linguist/languages.yml

(The closest thing I see in that file is that .djs is in use by another language.)

GitHub does not represent all software in the world, but it does at least lend a degree of confidence that the .dj suffix might not already be in widespread use.

xxxserxxx commented 1 year ago

I think it would be valuable to specify this, officially. Declare a mime-type, even. More than just being helpful in avoiding confusion, it may prevent some unfortunate conflicts down the road; I'm thinking about "jpg" and "jpeg".