From d11b33030f4220e16b62bdfe94b80dc1290ead4a Mon Sep 17 00:00:00 2001 From: Axel Haustant Date: Wed, 27 Mar 2013 09:15:35 +0100 Subject: [PATCH 1/6] Use .dev suffix for development versions --- pelican/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pelican/__init__.py b/pelican/__init__.py index f2bd2e07..2e1763ac 100644 --- a/pelican/__init__.py +++ b/pelican/__init__.py @@ -25,7 +25,7 @@ from pelican.writers import Writer __major__ = 3 __minor__ = 2 __micro__ = 0 -__version__ = "{0}.{1}.{2}".format(__major__, __minor__, __micro__) +__version__ = "{0}.{1}.{2}.dev".format(__major__, __minor__, __micro__) DEFAULT_CONFIG_NAME = 'pelicanconf.py' From 469c531ae4fbc9f8093b3f50607755e3d43e3e26 Mon Sep 17 00:00:00 2001 From: Axel Haustant Date: Wed, 27 Mar 2013 09:16:19 +0100 Subject: [PATCH 2/6] Include version in doc and warn if it's a dev version. --- docs/conf.py | 16 ++++++++++++---- docs/index.rst | 15 ++++++++++++--- 2 files changed, 24 insertions(+), 7 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 40de84c7..84531182 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -4,18 +4,26 @@ import sys, os sys.path.append(os.path.abspath(os.pardir)) -from pelican import __version__, __major__ +from pelican import __version__, __major__, __minor__ # -- General configuration ----------------------------------------------------- templates_path = ['_templates'] -extensions = ['sphinx.ext.autodoc',] +extensions = ['sphinx.ext.autodoc', 'sphinx.ext.ifconfig', 'sphinx.ext.extlinks'] source_suffix = '.rst' master_doc = 'index' project = 'Pelican' copyright = '2010, Alexis Metaireau and contributors' exclude_patterns = ['_build'] -version = __version__ -release = __major__ +version = '%s.%s' % (__major__, __minor__) +release = __version__ +last_stable = '3.1.1' +rst_prolog = ''' +.. |last_stable| replace:: :pelican-doc:`{0}` +'''.format(last_stable) + +extlinks = { + 'pelican-doc': ('http://docs.getpelican.com/%s/', '') +} # -- Options for HTML output --------------------------------------------------- diff --git a/docs/index.rst b/docs/index.rst index 914c2a7e..eb8883ce 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -1,5 +1,14 @@ -Pelican -======= +Pelican |release| +================= + + +.. ifconfig:: release.endswith('.dev') + + .. warning:: + + This documentation is for the version of Pelican currently under development. + Were you looking for version |last_stable| documentation? + Pelican is a static site generator, written in Python_. @@ -12,7 +21,7 @@ Pelican is a static site generator, written in Python_. Features -------- -Pelican currently supports: +Pelican |version| currently supports: * Articles (e.g., blog posts) and pages (e.g., "About", "Projects", "Contact") * Comments, via an external service (Disqus). (Please note that while From e6e99ffbb9c671da9a80c61cf7d47c12d77f2ef4 Mon Sep 17 00:00:00 2001 From: Axel Haustant Date: Wed, 27 Mar 2013 10:11:45 +0100 Subject: [PATCH 3/6] Change current release section with a constant title --- docs/changelog.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/changelog.rst b/docs/changelog.rst index 61cae1d9..c020d7f4 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -1,7 +1,7 @@ Release history ############### -3.3 (XXXX-XX-XX) +Next release ================ * Rename signals for better consistency (some plugins may need to be updated) From c61f6f402a417e807c9cb6f01c9293fced678892 Mon Sep 17 00:00:00 2001 From: Axel Haustant Date: Wed, 27 Mar 2013 09:30:54 +0100 Subject: [PATCH 4/6] Prepare for bumpr --- bumpr.rc | 30 ++++++++++++++++++++++++++++++ docs/changelog.rst | 2 +- docs/conf.py | 6 +++--- pelican/__init__.py | 5 +---- 4 files changed, 35 insertions(+), 8 deletions(-) create mode 100644 bumpr.rc diff --git a/bumpr.rc b/bumpr.rc new file mode 100644 index 00000000..cfc90fd7 --- /dev/null +++ b/bumpr.rc @@ -0,0 +1,30 @@ +[bumpr] +file = pelican/__init__.py +vcs = git +clean = + python setup.py clean + rm -rf *egg-info build dist +tests = tox +publish = python setup.py sdist register upload +files = README.rst + +[bump] +unsuffix = true +message = Bump version {version} + +[prepare] +part = patch +suffix = dev +message = Prepare version {version} for next development cycle + +[changelog] +file = docs/changelog.rst +separator = = +bump = {version} ({date:%Y-%m-%d}) +prepare = Next release + +[readthedoc] +url = http://docs.getpelican.com/{tag} + +[commands] +bump = sed -i "s/last_stable\s*=.*/last_stable = '{version}'/" docs/conf.py diff --git a/docs/changelog.rst b/docs/changelog.rst index c020d7f4..27938d4d 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -2,7 +2,7 @@ Release history ############### Next release -================ +============ * Rename signals for better consistency (some plugins may need to be updated) * Move metadata extraction from generators to readers; metadata extraction no diff --git a/docs/conf.py b/docs/conf.py index 84531182..5ac81b9e 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -4,7 +4,7 @@ import sys, os sys.path.append(os.path.abspath(os.pardir)) -from pelican import __version__, __major__, __minor__ +from pelican import __version__ # -- General configuration ----------------------------------------------------- templates_path = ['_templates'] @@ -14,9 +14,9 @@ master_doc = 'index' project = 'Pelican' copyright = '2010, Alexis Metaireau and contributors' exclude_patterns = ['_build'] -version = '%s.%s' % (__major__, __minor__) release = __version__ -last_stable = '3.1.1' +version = '.'.join(release.split('.')[:1]) +last_stable = '3.2.2' rst_prolog = ''' .. |last_stable| replace:: :pelican-doc:`{0}` '''.format(last_stable) diff --git a/pelican/__init__.py b/pelican/__init__.py index 2e1763ac..cecab54b 100644 --- a/pelican/__init__.py +++ b/pelican/__init__.py @@ -22,10 +22,7 @@ from pelican.settings import read_settings from pelican.utils import clean_output_dir, folder_watcher, file_watcher from pelican.writers import Writer -__major__ = 3 -__minor__ = 2 -__micro__ = 0 -__version__ = "{0}.{1}.{2}.dev".format(__major__, __minor__, __micro__) +__version__ = "3.2.3.dev" DEFAULT_CONFIG_NAME = 'pelicanconf.py' From bad8cfb3d9883845c054772b75a5934a96aeb394 Mon Sep 17 00:00:00 2001 From: Axel Haustant Date: Sat, 24 Aug 2013 20:20:37 +0200 Subject: [PATCH 5/6] Added bumpr as a development requirement to perform release --- dev_requirements.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dev_requirements.txt b/dev_requirements.txt index fa2634a0..0a4a4589 100644 --- a/dev_requirements.txt +++ b/dev_requirements.txt @@ -6,3 +6,6 @@ Markdown BeautifulSoup4 lxml typogrify + +# To perform release +bumpr From 5a322ecc1e0ce0aa188f31532ea3f8fdbba925ff Mon Sep 17 00:00:00 2001 From: Axel Haustant Date: Sun, 25 Aug 2013 14:14:43 +0200 Subject: [PATCH 6/6] Pin bumpr version to avoid config breakage with new versions --- dev_requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev_requirements.txt b/dev_requirements.txt index 0a4a4589..c90ac630 100644 --- a/dev_requirements.txt +++ b/dev_requirements.txt @@ -8,4 +8,4 @@ lxml typogrify # To perform release -bumpr +bumpr==0.2.0