From 1aec0d3de610daf27a9e69b1b2ce5139987e18ed Mon Sep 17 00:00:00 2001 From: Marcus Quinn Date: Mon, 17 Mar 2025 13:41:52 +0000 Subject: [PATCH] Update version management to dynamically extract from plugin header --- wp-allstars-plugin.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/wp-allstars-plugin.php b/wp-allstars-plugin.php index 944c835..70a4e22 100644 --- a/wp-allstars-plugin.php +++ b/wp-allstars-plugin.php @@ -19,8 +19,12 @@ if ( ! defined( 'WPINC' ) ) { die; } -// Define plugin version -define( 'WP_ALLSTARS_VERSION', '0.1 (Beta)' ); +// Define plugin version - extract from plugin header +function wp_allstars_get_plugin_version() { + $plugin_data = get_file_data(__FILE__, array('Version' => 'Version')); + return $plugin_data['Version']; +} +define( 'WP_ALLSTARS_VERSION', wp_allstars_get_plugin_version() ); // Activation hook function wp_allstars_activate() {