ansible / galaxy

Legacy Galaxy still available as read-only on https://old-galaxy.ansible.com - looking for the new galaxy -> https://github.com/ansible/galaxy_ng
Apache License 2.0
849 stars 330 forks source link

Import fails when the file type of `README` is unknown #50

Open chouseknecht opened 6 years ago

chouseknecht commented 6 years ago

From @larskarlitski on April 28, 2017 14:39

Importing a role with a README that isn't plain text, markdown, or restructured text fails with

Unable to determine README file type. Expecting file extension to be one of: .md, .rst

The whole point of these formats is that they're readable as plain text as well. Failing the import because of this seems disproportionate.

Possible solution: treat README files with unknown extensions as plain text.

Copied from original issue: ansible/galaxy-issues#261

chouseknecht commented 6 years ago

Checking for an extension of .md or .rst is left over from the days when Galaxy converted the file to HTML. Now it accepts whatever HTML is returned from GitHub API.

We could modify it to accept files with no extension as text. Not a high priority at the moment though.