WPTT / theme-sniffer

Theme Sniffer plugin using sniffs.
MIT License
270 stars 3 forks source link

Add list of allowed licenses in the style.css #98

Closed dingo-d closed 5 years ago

dingo-d commented 5 years ago

Since I can parse style.css, and could probably parse readme.txt in the theme, it could be a good feature to have License checks to see if the specified license is in line with GPL.

I'd need a list of allowed Licenses so that I can check agains them 🙂

DannyCooper commented 5 years ago

This list is a good start - https://make.wordpress.org/themes/handbook/review/resources/#licenses-bundled-resources

Can we add a blacklist check for these URLs?

unsplash.com, sxc.hu, photopin.com, publicdomainpictures.net, splitshire.com, pixabay.com

dingo-d commented 5 years ago

Sure that could be added as well, whitelist and blacklist 🙂

DannyCooper commented 5 years ago

Blacklist alone would cut my review time in half 🔥

timelsass commented 5 years ago

https://github.com/WPTRT/theme-sniffer/pull/139 works with the readme.txt, and dives into license validation for the primary License added. It does include a json file with FSF/SPDX license coverage . We won't need to run the same tests on style.css as we can simply check that the two have matching data. @DannyCooper I added your blacklisted names in preparation for the resources section, but haven't implemented them for that section yet.

kkMatt commented 5 years ago

I just wanted to be sure that none of them will be missed - GPLv3, AGPLv3 and MIT. As we use all 3 for different projects / scopes :).

dingo-d commented 5 years ago

I'll close this because #139 has been merged. We'll work further on this (refactor the licenses to be pulled from a repo etc.).