devel-versioning.rst
author Oleksandr Gavenko <gavenkoa@gmail.com>
Mon, 22 Feb 2016 12:41:52 +0200
changeset 1903 901e7394849f
parent 1334 9bf0d5a1f0cf
child 1905 fba288d59662
permissions -rw-r--r--
Decrease intent to increase space usage on mobile.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1334
9bf0d5a1f0cf Include common header with quick links.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1115
diff changeset
     1
.. -*- coding: utf-8; -*-
9bf0d5a1f0cf Include common header with quick links.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1115
diff changeset
     2
.. include:: HEADER.rst
1032
4decc3e00bb6 Fix coding and contents.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1009
diff changeset
     3
921
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     4
=================
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     5
 Version format.
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     6
=================
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     7
.. contents::
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     8
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
     9
Feature set versioning.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    10
=======================
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    11
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    12
Feature set versioning pretend to show how serious changes made according to
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    13
feature availability and how compatible these versions.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    14
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    15
Marketing versioning.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    16
=====================
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    17
1007
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    18
Marketing versioning schema used for marketing, advertising, branding purpose.
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    19
It is usually inconsistent and can changed over the time.
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    20
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    21
Examples of marketing version schema:
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    22
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    23
 * Years.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    24
 * Ancient gods.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    25
 * Star/satellite/galactic names.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    26
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    27
Look thread for GDB:
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    28
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    29
  http://www.cygwin.com/ml/gdb/2007-07/msg00061.html
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    30
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    31
There discussed:
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    32
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    33
 * Is it essential to update major version if significant change made for
1097
6acae85ed54b small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1059
diff changeset
    34
   licence? Answer: **NO**!
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    35
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    36
   GPLv3 is a big deal spread out over the whole GNU project, but not a big deal
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    37
   for GDB in particular.
1097
6acae85ed54b small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1059
diff changeset
    38
 * Is it right follow date version schema regardless major changes? Answer:
6acae85ed54b small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1059
diff changeset
    39
   **NO**!
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    40
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    41
   Many OS distribution encode year in versions but versions does not present
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    42
   featureset but package set instead.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    43
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    44
Year as version name.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    45
---------------------
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    46
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    47
If year used as version some people can decide that 2005 is too old and broken
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    48
if it used in 2007. So companies release product by leading year number. So in
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    49
2007 they release 2008 version.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    50
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    51
Version name components.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    52
========================
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    53
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    54
 * major
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    55
 * minor
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    56
 * patch (patchlevel), micro
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    57
 * rev (revision)
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    58
 * build
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    59
 * date
1007
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    60
 * hotfix, fix
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    61
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    62
Version components usually combined in such group::
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    63
1007
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    64
  major.minor.build
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    65
  major.minor.date
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    66
  major.minor.hotfix
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    67
  major.minor.hotfix.build
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    68
  major.minor.rev
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    69
  major.minor.rev.build
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    70
  major.current.age
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    71
1007
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    72
Its conventional to have at least a major and minor number.
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    73
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    74
Prefixing version with a "v" seems to be less common.
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
    75
1098
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    76
Version in package/release name.
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    77
================================
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    78
::
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    79
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    80
  PACKAGE-MAJ.MIN.FIX.tar.gz   (Common style)
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    81
  PACKAGE-MAJ.MIN.FIX.zip
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    82
  PACKAGE-MAJ.MIN.FIX-DISTROFIX.tar.gz  (Cygwin style)
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    83
  PACKAGE_EPOCH:MAJ.MIN.FIX-DISTROFIX_ARCH.deb (Debian style)
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    84
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    85
From "Debian Policy Manual"::
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    86
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    87
  Package names must consist only of lower case letters (`a-z'), digits
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    88
  (`0-9'), plus (`+') and minus (`-') signs, and periods (`.').  They
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    89
  must be at least two characters long and must start with an
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    90
  alphanumeric character.
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    91
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    92
If you look carefully there are no any ``_`` (underscore) chars!! Also ``-`` is
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    93
portable char in file name accoding to POSIX.
db420d971363 Version in package/release name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1097
diff changeset
    94
1057
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
    95
Versioning for libraries/modules/components.
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
    96
============================================
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
    97
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    98
Major version component.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
    99
------------------------
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   100
1007
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   101
Major number change means that fundamental change made in the architecture of
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   102
the system the new version is incompatible with the old one, upgrade between
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   103
versions is non-trivial, and any dependent of the prior version will require
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   104
code changes to upgrade to the new package.
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   105
1004
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   106
Major number rare changed (this can take a lot of year).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   107
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   108
Minor version component.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   109
------------------------
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   110
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   111
Minor number change means that the new version is backward compatible with the
1007
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   112
previous version but has significant enhancements over the previous version
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   113
(like new functionality or changed UI).
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   114
1004
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   115
Functional enhancement releases. Contain new or significantly changed
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   116
functionality and/or layout.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   117
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   118
New releases are usually only published several times a year or less.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   119
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   120
Revision, micro, bugfix version component.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   121
------------------------------------------
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   122
1007
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   123
Revision number is updated whenever a bugfix or security patche is applied to
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   124
the build such that it doesn't bring a compatibility change or introduce newer
f7a62b2027ea Version components usually combined in such group.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1004
diff changeset
   125
features.
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   126
1004
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   127
Patches are released frequently (sometimes daily).
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1003
diff changeset
   128
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   129
Milestone markers.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   130
------------------
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   131
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   132
 * a (alpha) means new development is complete and code checkins are frozen.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   133
   Alpha builds should work well enough to be testable.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   134
 * b (beta) means most severe bugs are fixed and end users can start trying the
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   135
   release.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   136
 * rc (release candidate) are believed to meet all of the criteria for release
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   137
   and can be installed on test instances of production systems.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   138
1107
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   139
Compatibility formula.
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   140
----------------------
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   141
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   142
Assume that app linked with new version of lib. Thus::
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   143
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   144
  is_compatible_with_old(old, new) {
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   145
    if (old.major != new.major) return 0;
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   146
    if (old.minor > new.minor) return 0;
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   147
    return 1;
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   148
  }
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   149
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   150
Assume that app linked with old version of lib. Thus::
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   151
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   152
  is_compatible_with_new(old, new) {
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   153
    if (old.major != new.major) return 0;
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   154
    return 1;
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   155
  }
4473feb406cf Move "Compatibility formula" to proper place.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1106
diff changeset
   156
1057
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   157
Versioning for products.
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   158
========================
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   159
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   160
Versioning for products differ from versioning for libraries.
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   161
1099
97e0815972e0 Switching from old to new require upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1098
diff changeset
   162
Product is a set of conponents that stalled to some versions. Components can be
1057
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   163
switches as written for library versioning:
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   164
1099
97e0815972e0 Switching from old to new require upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1098
diff changeset
   165
 * Any fix releases interchanged, greater version mean less bug count.
97e0815972e0 Switching from old to new require upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1098
diff changeset
   166
 * Any minor release interchanged with next minor releases.
97e0815972e0 Switching from old to new require upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1098
diff changeset
   167
 * Major release does not interchanged at all, switching from old to new require
97e0815972e0 Switching from old to new require upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1098
diff changeset
   168
   upgrade.
1057
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   169
1058
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   170
Product update vs upgrade.
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   171
--------------------------
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   172
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   173
Product update involve:
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   174
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   175
 * Replacing product executable files, resources files.
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   176
 * Config files and user data stay unchanged.
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   177
1099
97e0815972e0 Switching from old to new require upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1098
diff changeset
   178
Product upgrade involve:
1058
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   179
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   180
 * Replacing product executable files, resources files.
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   181
 * Config files and used data require modification and performed by upgrade
1099
97e0815972e0 Switching from old to new require upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1098
diff changeset
   182
   scripts or manually by user (if this is ever possible).
1058
cd1062303157 Product update vs upgrade.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1057
diff changeset
   183
1100
b1bc3f723e14 Build data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1099
diff changeset
   184
Build data.
b1bc3f723e14 Build data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1099
diff changeset
   185
===========
947
1c8a139fc25d Release build version data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 921
diff changeset
   186
1c8a139fc25d Release build version data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 921
diff changeset
   187
 * Build number.
1c8a139fc25d Release build version data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 921
diff changeset
   188
 * Build date.
1057
8e946a8709e0 Versioning for products.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1042
diff changeset
   189
 * VCS revision.
947
1c8a139fc25d Release build version data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 921
diff changeset
   190
 * Branch-tag used.
1c8a139fc25d Release build version data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 921
diff changeset
   191
 * Overnight build (Y/N).
1c8a139fc25d Release build version data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 921
diff changeset
   192
 * QA tested (Y/N).
1c8a139fc25d Release build version data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 921
diff changeset
   193
 * QA test results (Pass/Fail).
1100
b1bc3f723e14 Build data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1099
diff changeset
   194
 * Location of full build logs.
947
1c8a139fc25d Release build version data.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 921
diff changeset
   195
1042
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   196
Stop your VCS hook to update version!
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   197
=====================================
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   198
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   199
Don't update version without human decision.
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   200
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   201
Why do not do this on success build:
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   202
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   203
 * You can have several build machine which may concurrently update version.
1101
33ba35eff910 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1100
diff changeset
   204
 * There does not exist tools for easy querying for status of build by its
33ba35eff910 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1100
diff changeset
   205
   number (as ok/fail, build configuration, date, coverage, lint checks status,
33ba35eff910 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1100
diff changeset
   206
   etc).
1042
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   207
 * Some part of development team may not have permission for bumping version and
1102
01d500f0b867 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1101
diff changeset
   208
   they must revert some automatically updated files after build.
1042
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   209
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   210
Why do not do this from pre-/post-commit hooks:
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   211
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   212
 * Some changes can only partially introduce feature/bugfix.
dd197cbdaf21 Stop your VCS hook to update version!
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1032
diff changeset
   213
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   214
Version ordering formula.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   215
=========================
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   216
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   217
Strongly recommend:
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   218
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   219
 * Numbers are not decimal fractions. They are integers separated by delimiters.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   220
 * Only offically released versions of the program get version numbers.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   221
   Development snapshots don't. Nor do test releases.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   222
 * If the last component is zero, it may be omitted. Do not distinguish version
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   223
   X.Y from version X.Y.0.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   224
 * Avoid using anything other than numbers in version numbers.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   225
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   226
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   227
Debian version ordering formula.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   228
--------------------------------
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   229
1104
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   230
The version number of a package.  The format is::
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   231
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   232
  [<epoch>`:']<upstream_version>[`-'<debian_revision>]
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   233
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   234
The three components here are:
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   235
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   236
``epoch``
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   237
     This is a single (generally small) unsigned integer.  It may be
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   238
     omitted, in which case zero is assumed.  If it is omitted then
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   239
     the <upstream_version> may not contain any colons.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   240
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   241
     It is provided to allow mistakes in the version numbers of older
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   242
     versions of a package, and also a package's previous version
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   243
     numbering schemes, to be left behind.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   244
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   245
``upstream_version``
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   246
     This is the main part of the version number.  It is usually the
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   247
     version number of the original ("upstream") package from which
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   248
     the ``.deb`` file has been made, if this is applicable.  Usually
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   249
     this will be in the same format as that specified by the upstream
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   250
     author(s); however, it may need to be reformatted to fit into the
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   251
     package management system's format and comparison scheme.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   252
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   253
     The comparison behavior of the package management system with
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   254
     respect to the <upstream_version> is described below.  The
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   255
     <upstream_version> portion of the version number is mandatory.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   256
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   257
     The <upstream_version> may contain only alphanumerics[1] and the characters
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   258
     ``.`` ``+`` ``-`` ``:`` ``~`` (full stop, plus, hyphen, colon, tilde) and
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   259
     should start with a digit. If there is no <debian_revision> then hyphens
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   260
     are not allowed; if there is no <epoch> then colons are not allowed.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   261
1106
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   262
``debian_revision``
1104
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   263
     This part of the version number specifies the version of the
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   264
     Debian package based on the upstream version.  It may contain
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   265
     only alphanumerics and the characters ``+`` ``.`` ``~`` (plus, full
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   266
     stop, tilde) and is compared in the same way as the
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   267
     <upstream_version> is.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   268
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   269
     It is optional; if it isn't present then the <upstream_version>
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   270
     may not contain a hyphen.  This format represents the case where
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   271
     a piece of software was written specifically to be turned into a
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   272
     Debian package, and so there is only one "debianisation" of it
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   273
     and therefore no revision indication is required.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   274
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   275
     It is conventional to restart the <debian_revision> at ``1`` each
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   276
     time the <upstream_version> is increased.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   277
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   278
     The package management system will break the version number apart
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   279
     at the last hyphen in the string (if there is one) to determine
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   280
     the <upstream_version> and <debian_revision>.  The absence of a
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   281
     <debian_revision> compares earlier than the presence of one (but
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   282
     note that the <debian_revision> is the least significant part of
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   283
     the version number).
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   284
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   285
The <upstream_version> and <debian_revision> parts are compared by the
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   286
package management system using the same algorithm:
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   287
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   288
The strings are compared from left to right.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   289
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   290
First the initial part of each string consisting entirely of non-digit
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   291
characters is determined.  These two parts (one of which may be empty)
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   292
are compared lexically.  If a difference is found it is returned.  The
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   293
lexical comparison is a comparison of ASCII values modified so that
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   294
all the letters sort earlier than all the non-letters and so that a
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   295
tilde sorts before anything, even the end of a part.  For example, the
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   296
following parts are in sorted order from earliest to latest: ``~~``,
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   297
``~~a``, ``~``, the empty part, ``a``.[2]
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   298
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   299
Then the initial part of the remainder of each string which consists
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   300
entirely of digit characters is determined.  The numerical values of
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   301
these two parts are compared, and any difference found is returned as
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   302
the result of the comparison.  For these purposes an empty string
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   303
(which can only occur at the end of one or both version strings being
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   304
compared) counts as zero.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   305
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   306
These two steps (comparing and removing initial non-digit strings and
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   307
initial digit strings) are repeated until a difference is found or
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   308
both strings are exhausted.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   309
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   310
Note that the purpose of epochs is to allow us to leave behind
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   311
mistakes in version numbering, and to cope with situations where the
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   312
version numbering scheme changes.  It is _not_ intended to cope with
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   313
version numbers containing strings of letters which the package
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   314
management system cannot interpret (such as ``ALPHA`` or ``pre-``), or
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   315
with silly orderings (the author of this manual has heard of a package
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   316
whose versions went ``1.1``, ``1.2``, ``1.3``, ``1``, ``2.1``, ``2.2``,
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   317
``2`` and so forth).
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   318
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   319
[1]  Alphanumerics are ``A-Za-z0-9`` only.
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   320
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   321
[2]  One common use of ``~`` is for upstream pre-releases.  For example,
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   322
     ``1.0~beta1~svn1245`` sorts earlier than ``1.0~beta1``, which sorts
2b8f6be245c0 Debian version ordering formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1102
diff changeset
   323
     earlier than ``1.0``.
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   324
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   325
Semver version ordering formula.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   326
--------------------------------
1059
d5b0b9cc4b49 Fix indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1058
diff changeset
   327
::
948
23cb71bb2b5d Versioning formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 947
diff changeset
   328
1059
d5b0b9cc4b49 Fix indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1058
diff changeset
   329
  if (A.major != B.major) return A.major > B.major;
d5b0b9cc4b49 Fix indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1058
diff changeset
   330
  if (A.minor != B.minor) return A.minor > B.minor;
d5b0b9cc4b49 Fix indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1058
diff changeset
   331
  if (A.patch != B.patch) return A.patch > B.patch;
d5b0b9cc4b49 Fix indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1058
diff changeset
   332
  if (A.special == B.special) return 0;
d5b0b9cc4b49 Fix indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1058
diff changeset
   333
  if (A.special == "") return 1;
d5b0b9cc4b49 Fix indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1058
diff changeset
   334
  if (B.special == "") return -1;
d5b0b9cc4b49 Fix indent.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1058
diff changeset
   335
  return A.special > B.special;
948
23cb71bb2b5d Versioning formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 947
diff changeset
   336
949
57b995de80b5 Compatibility formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 948
diff changeset
   337
**NOTE** Accoding to this definition 1.0.1rc1 < 1.0.1rc10 < 1.0.1rc2 which is
57b995de80b5 Compatibility formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 948
diff changeset
   338
non meaningful.
57b995de80b5 Compatibility formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 948
diff changeset
   339
1003
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   340
Odd/even numbering.
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   341
-------------------
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   342
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   343
Who use:
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   344
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   345
  GLib GTK+ Gimp GNOME Kaffe
4b8b3daac0db Feature set versioning. Marketing versioning. Year as version name. Version name components. Version
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 950
diff changeset
   346
1008
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   347
Forms of compatibility.
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   348
=======================
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   349
1113
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   350
Backward/forward compatibility.
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   351
-------------------------------
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   352
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   353
Backward compatibility for library, file format, protocol means that new version
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   354
of program can work with old library, file format, protocol.
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   355
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   356
Forward compatibility for library, file format, protocol means that old version
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   357
of program can work with new library, file format, protocol but without using
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   358
any benefits from new versions and more essentially without posibility damage
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   359
any user data.
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   360
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   361
Example of backward compatibility: adding to graphic library new image format
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   362
for reading/saving.
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   363
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   364
Example of forward compatibility: old browser ignore any new (unknown) HTML
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   365
tags.
c55780172a46 Backward/forward compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1112
diff changeset
   366
1112
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   367
Source/binary compatibility.
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   368
----------------------------
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   369
1108
60726f28b999 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1107
diff changeset
   370
Runtime or binary compatibility mean that binary can be swaped with another
60726f28b999 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1107
diff changeset
   371
version without breaking normal program work.
1008
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   372
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   373
Compile time or source compatibility mean that supplied header/interfaces allow
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   374
successful compiling/linking.
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   375
1009
be52d3742472 Protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1008
diff changeset
   376
Examples:
1008
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   377
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   378
 * Change type of argument in method to more generic take source compatibility
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   379
   but break binary compatibility.
1108
60726f28b999 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1107
diff changeset
   380
 * Adding new method to abstract class take binary compatibility but break
1008
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   381
   compilation (unimplement method error).
4ddb673763e6 Forms of compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1007
diff changeset
   382
1112
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   383
Format or protocol compatibility.
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   384
---------------------------------
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   385
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   386
File format or protocol backward compatibility mean that new program can use old
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   387
format or protocol.
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   388
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   389
In order to do that file format or protocol MUST store or provide some
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   390
versioning information. Usually this done by:
1009
be52d3742472 Protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1008
diff changeset
   391
1112
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   392
 * Separate versioning field in data.
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   393
 * New prefix or name in data.
91e7ec70a38e Format or protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1108
diff changeset
   394
 * List of feature requirements, supported algorighm, etc.
1009
be52d3742472 Protocol compatibility.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1008
diff changeset
   395
1114
9131b58f51c4 It is essential to make file format or protocol extensible.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1113
diff changeset
   396
It is essential to make code that detect unknown or possibly new format or
9131b58f51c4 It is essential to make file format or protocol extensible.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1113
diff changeset
   397
protocol and stop working with them to avoid user data corruption.
1108
60726f28b999 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1107
diff changeset
   398
1114
9131b58f51c4 It is essential to make file format or protocol extensible.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1113
diff changeset
   399
It is essential to make file format or protocol extensible. This can be achieved
9131b58f51c4 It is essential to make file format or protocol extensible.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1113
diff changeset
   400
by:
9131b58f51c4 It is essential to make file format or protocol extensible.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1113
diff changeset
   401
9131b58f51c4 It is essential to make file format or protocol extensible.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1113
diff changeset
   402
 * Reserving some possible names/prefixes for future use.
9131b58f51c4 It is essential to make file format or protocol extensible.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1113
diff changeset
   403
 * Generalising file format or protocol to envelop more cases.
1108
60726f28b999 small fix
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1107
diff changeset
   404
1115
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   405
Extracting version from VCS.
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   406
============================
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   407
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   408
Including version in sources.
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   409
=============================
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   410
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   411
Don't use any ``$REVISION`` like keywords (usual practice in CVS, SVN)!
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   412
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   413
Use sed, awk, M4 or any other preprocessor for non-compiled or non-preprocessed
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   414
files (like .lisp, .py, .java files)::
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   415
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   416
  $ cat my-version.el.in
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   417
  (defvar my-major-version @VMAJOR@
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   418
    "Major version.")
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   419
  (defvar my-major-version @VMAJOR@
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   420
    "Major version.")
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   421
  (provide 'my-version)
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   422
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   423
  $ cat Makefile
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   424
  %: %.in
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   425
      sed -e 's|@VMAJOR@|$(VMAJOR)|' -e 's|@VMINOR@|$(VMINOR)|' <$< >$@
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   426
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   427
Pass version component to preprocessed file (like .c, .cxx files) through
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   428
preprocessor::
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   429
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   430
  $ cat my-version.c
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   431
  int get_major_version() { return VMAJOR; }
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   432
  int get_minor_version() { return VMINOR; }
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   433
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   434
  $ cat Makefile
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   435
  %.o: %.c
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   436
      $(CC) -DVMAJOR=$(VMAJOR) -DVMINOR=$(VMINOR) -o $@ $<
abbbaffa9c9f Including version in sources.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1114
diff changeset
   437
921
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   438
Reference.
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   439
==========
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   440
948
23cb71bb2b5d Versioning formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 947
diff changeset
   441
  http://semver.org/
23cb71bb2b5d Versioning formula.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 947
diff changeset
   442
                Semantic Versioning
1106
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   443
  http://www.debian.org/doc/debian-policy/ch-controlfields.html#s-f-Version
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   444
                Debian
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   445
  http://www.openbsd.org/faq/ports/specialtopics.html
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   446
                OpenBSD
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   447
  http://java.sun.com/j2se/versioning_naming.html
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   448
                Oracle
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   449
  http://www.intel.com/support/graphics/sb/CS-020667.htm
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   450
                Intel
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   451
  http://wiki.eclipse.org/index.php/Version_Numbering
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   452
                Eclipse
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   453
  http://apr.apache.org/versioning.html
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   454
                Apache
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   455
  http://www106.pair.com/rhp/parallel.html
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   456
                Conflict resolution
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   457
  http://www.rpm.org/wiki/PackagerDocs/Dependencies
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   458
                RH
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   459
  http://www.rpm.org/max-rpm/s1-rpm-depend-manual-dependencies.html
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   460
                RH
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   461
  http://fedoraproject.org/wiki/Packaging/NamingGuidelines
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   462
                RH
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   463
  http://wikis.sun.com/display/IpsBestPractices/Packaging+Best+Practices+-+Versioning
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   464
                Oracle
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   465
  http://docs.codehaus.org/display/MAVEN/Dependency+Mediation+and+Conflict+Resolution
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   466
                Maven
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   467
  http://docs.codehaus.org/display/MAVEN/Versioning
24c790c45f8b Add a lot of Reference.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1104
diff changeset
   468
                Maven
921
c1264ffd1a37 Toolkit version format
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   469