dist-archive-command icon indicating copy to clipboard operation
dist-archive-command copied to clipboard

Only use version from plugin header.

Open BrianHenryIE opened this issue 1 year ago • 1 comments

The minimum definition for a plugin file says its set of headers must have the Plugin Name header. This PR changes the version parsing code to only consider a parsed version if it is part of a PHP file's plugin headers, by checking does the "Plugin Name" header exist first.

Previously, it was considering any @version in any PHP docblock.

Fixes #92

Edit: looks like I didn't start the branch off upstream/master. I'll rewrite it soon.

BrianHenryIE avatar May 02 '24 04:05 BrianHenryIE

Yes! it happens to me sometimes that it gets the first PHP in the folder and it does not get the Plugin name. +1

davidperezgar avatar Dec 15 '24 11:12 davidperezgar