Making WordPress.org

Opened 3 years ago

Last modified 10 months ago

#2743 new enhancement

Improvement of New Readme Validator

Reported by: Asif2BD Owned by:
Milestone: Plugin Directory v3 - Future Priority: normal
Component: Plugin Directory Keywords: needs-patch close


Otto explained this validator is still new and could use some improvement, I personally think it needs some basic feature, right now it's just checking if there is a contributor or if there is an upgrade notice. What about formatting proper markdown? Like what if the format is wrong, or the name is too long? Ultimately though validator is not a real-time scanner, still its a good guide for a new developer. They might get the wrong msz about plugin directory best practice.

You can find the current validator code [here](https://meta.trac.wordpress.org/browser/sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/readme)

I propose the following Improvement -

1) Let's show a preview of the entered readme.txt

2) Instead of just checking if a block exist like this

if ( ! count( $readme->contributors ) ) {
	                        /* Translators: Plugin header tag; */
	                        $warnings[] = sprintf( __( 'No %s listed.', 'wporg-plugins' ), '<code>Contributors</code>' );

We should check the size of a section, is the format is ok, like all the format is closed properly.

3) Give feedbacks like Plugin Name is too wrong, or must have at least one screenshot.

4) Instead of just showing md style format, is it possible to show styles with present Plugin Directory?

This is based on my conversation with @otto42 & @sergey, check this [slack archives](https://wordpress.slack.com/archives/C02QB8GMM/p1492199946799705).

Change History (5)

#1 @Otto42
3 years ago

  • Milestone set to Plugin Directory v3 - Future
  • Priority changed from high to normal

This ticket was mentioned in Slack in #meta by tellyworth. View the logs.

3 years ago

#3 @SergeyBiryukov
2 years ago

Let's show a preview of the entered readme.txt

Related: #2538

#4 @SergeyBiryukov
2 years ago

  • Keywords has-screenshots removed

#5 @tellyworth
10 months ago

  • Keywords close added

Are these suggestions all still relevant, or have some changed? Can someone perhaps describe the needed validations in more detail - for instance, exactly which sections should have what length limits?

Note: See TracTickets for help on using tickets.