Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow extension for the README file #972

Closed
mateuszpawlik opened this issue Jan 12, 2022 · 11 comments · Fixed by #1033
Closed

Allow extension for the README file #972

mateuszpawlik opened this issue Jan 12, 2022 · 11 comments · Fixed by #1033
Labels
enhancement New feature or request

Comments

@mateuszpawlik
Copy link
Contributor

mateuszpawlik commented Jan 12, 2022

GitLab, and it seems that also GitHub, cannot render markdown if the file doesn't have an extension. Currently, BIDS Validator complains that there is no README file although README.md is there. I think this is due to the following rule:

https://github.com/bids-standard/bids-specification/blob/febae4fb9b2c9f055dc1392e0283c85f05618de0/src/schema/rules/top_level_files.yaml#L2:L5

Could we change that and support file extensions for the README file? I know it would require a few changes in the documentation and maybe the validator but if we could work out the list, I'm willing to work on it.

@VisLab
Copy link
Member

VisLab commented Jan 12, 2022

This would be a welcome addition and might encourage annotators to write a better README. Many people already use markdown for the README because OpenNeuro displays the file without the extension as markdown.

@sappelhoff
Copy link
Member

I agree that these are good arguments to allow .md (and .txt) 👍

@sappelhoff sappelhoff added the enhancement New feature or request label Jan 12, 2022
@sappelhoff
Copy link
Member

This also came up before https://github.com/bids-standard/bids-validator/pull/1281#discussion_r630118909

@effigies comment from back then shows that he'd also be in favor of supporting this (with a small caveat):

I would be +1 for permitting markdown, at least. It opens up a smallish can of worms as we now get into the role of arbitrating the set of acceptable markup languages.

@mateuszpawlik
Copy link
Contributor Author

This also came up before bids-standard/bids-validator#1281 (comment)

Thanks for finding it.

I would be +1 for permitting markdown, at least. It opens up a smallish can of worms as we now get into the role of arbitrating the set of acceptable markup languages.

I wouldn't go a far as limiting and verifying Markdown flavors. I think it is just about the file extension. As per specification, README file is a free-form text. On the other hand, the recommended README template uses Markdown already.

And if you would like to limit the Markdown flavor, I propose something standard, like CommonMark, since both GitHub and GitLab flavors are its supersets.

@sappelhoff sappelhoff modified the milestone: 1.7.0 Jan 30, 2022
@sappelhoff
Copy link
Member

We decided to deal with this after the 1.7.0 release. I think most of us agree that allowing common extensions will be fine, and we just need to decide on the subset of extensions and then implement it in the spec, examples, and validator.

I am personally in favor of permitting TXT, MD, RST - because all of these can be read reasonably well in a text document even without any rendering.

@mateuszpawlik
Copy link
Contributor Author

I'm happy to help and I have time to commit.

@sappelhoff
Copy link
Member

Good to hear! I think you could start to open PRs then, and we can iterate there.

@sappelhoff
Copy link
Member

@mateuszpawlik -- just a short reminder that I think your proposal is worthwhile implementing. Let me know if you ran out of time and want me /someone else to do it instead.

@mateuszpawlik
Copy link
Contributor Author

I'm sorry but I didn't have a long enough stretch to figure out where to start and where exactly the changes should be implemented. I still would like to do it because it's a nice, simple enough exercise to understand the ecosystem. Maybe there are some contribution details that list the things to change? If not, I'll start making a list tomorrow. Would that work?

@sappelhoff
Copy link
Member

These are two important documents to read:

As for making the changes, that'd be in the specification text - probably somewhere here:

For the validator, you could open an issue on https://github.com/bids-standard/bids-validator/ and we can try to see where to put the check there. I wouldn't know that off the top of my head

@mateuszpawlik
Copy link
Contributor Author

I've started working but failed already while building #1030 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants