Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Separate style and phpBB versions in style.cfg #706

Merged
merged 2 commits into from

3 participants

cyberalien added some commits
@cyberalien cyberalien [ticket/10762] Changing version format in style.cfg
Splitting version into style_version and phpbb_version in style.cfg

PHPBB3-10762
e769e0f
@cyberalien cyberalien [ticket/10762] Check for phpbb_version when installing style
Check if phpbb_version exists when installing style. Do not warn users about installing outdated styles yet, that part of acp_styles will be changed in different branch.

PHPBB3-10762
bb62804
@callumacrae callumacrae commented on the diff
phpBB/includes/acp/acp_styles.php
@@ -1056,7 +1056,7 @@ public function sort_styles($style1, $style2)
*/
protected function read_style_cfg($dir)
{
- static $required = array('name', 'version', 'copyright');
+ static $required = array('name', 'phpbb_version', 'copyright');

Why not require style_version, too?

style_version is only for style author's reference, it isn't used anywhere in phpBB, so I don't see a point in making it mandatory.

True, but it could be used in the future, right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
@naderman
Owner

Can we please have a proper discussion of this on Area51 first? Do styles need separate version numbers should they always be the same as the phpBB version? What is the purpose of this exactly? Can a style (especially an inherited one which only adds a single image or something) not be compatible with multiple phpBB versions? Before you change this, let's figure it out properly.

I'll close the PR for the time being, please reopen it after discussion on area51.

@naderman naderman closed this
@naderman
Owner

Oops, I opened the wrong ticket ... There is an RFC for this on area51. I take that back. Sorry. Nonetheless, please point a few more developers at the RFC to take a look and comment. RFCs aren't accepted just cause nobody read them yet.

RFC URL: http://area51.phpbb.com/phpBB/viewtopic.php?f=108&t=42767

@naderman naderman reopened this
@cyberalien

Marked as WIP to prevent this from being merged. This is still being discussed at area51

@naderman
Owner

Merging as per RFC topic, although we will probably change the format of the file later.

@naderman naderman merged commit bb62804 into phpbb:develop
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Apr 4, 2012
  1. @cyberalien

    [ticket/10762] Changing version format in style.cfg

    cyberalien authored
    Splitting version into style_version and phpbb_version in style.cfg
    
    PHPBB3-10762
  2. @cyberalien

    [ticket/10762] Check for phpbb_version when installing style

    cyberalien authored
    Check if phpbb_version exists when installing style. Do not warn users about installing outdated styles yet, that part of acp_styles will be changed in different branch.
    
    PHPBB3-10762
This page is out of date. Refresh to see the latest.
View
2  phpBB/includes/acp/acp_styles.php
@@ -1056,7 +1056,7 @@ public function sort_styles($style1, $style2)
*/
protected function read_style_cfg($dir)
{
- static $required = array('name', 'version', 'copyright');
+ static $required = array('name', 'phpbb_version', 'copyright');

Why not require style_version, too?

style_version is only for style author's reference, it isn't used anywhere in phpBB, so I don't see a point in making it mandatory.

True, but it could be used in the future, right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
$cfg = parse_cfg_file($this->styles_path . $dir . '/style.cfg');
// Check if it is a valid file
View
3  phpBB/styles/prosilver/style.cfg
@@ -18,7 +18,8 @@
# General Information about this style
name = prosilver
copyright = © phpBB Group, 2007
-version = 3.1.0-dev
+style_version = 3.1.0-dev
+phpbb_version = 3.1.0-dev
# Defining a different template bitfield
# template_bitfield = lNg=
View
3  phpBB/styles/subsilver2/style.cfg
@@ -18,7 +18,8 @@
# General Information about this style
name = subsilver2
copyright = © 2005 phpBB Group
-version = 3.1.0-dev
+style_version = 3.1.0-dev
+phpbb_version = 3.1.0-dev
# Defining a different template bitfield
# template_bitfield = lNg=
Something went wrong with that request. Please try again.