Skip to content

Commit 7692b64

Browse files
authored
Merge pull request #44 from jfy133/document-maintaining-multiple-versions
Document how to handle multiple mainline versions of a version
2 parents 30a1031 + 4daa6c9 commit 7692b64

1 file changed

Lines changed: 70 additions & 0 deletions

File tree

source/contributor/guidelines.rst

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -786,3 +786,73 @@ a distribution mechanism for packages, so it is not appropriate for software
786786
development work on a package (like supporting an additional platform) to be
787787
exclusivly performed in the Bioconda repo. It's important to engage the
788788
upstream authors on such efforts if at all possible.
789+
790+
Updating multiple software major versions simultaneously
791+
----------------------------------------------------------
792+
793+
In some cases, a particular software package may support updates and patches for
794+
two major versions of a tool at the same time.
795+
For example, a developer continues relasing fixes to v2.x series, even if most
796+
development continues on a v3.x series.
797+
798+
To continue to support releases of both versions of a tool within a Bioconda
799+
recipe, there are two options for this.
800+
801+
Linked packages
802+
^^^^^^^^^^^^^^^
803+
804+
You can use the main recipe `meta.yaml` for the more recent major
805+
version, and place the older version in a subdirectory with it's own ``meta.yaml``.
806+
In this case the name of the tool will be the same
807+
808+
An example of this is the `mitos
809+
<https://github.com/bioconda/bioconda-recipes/tree/c2b7cbc80054a309e8fc3c91f9efed4e642e447d/recipes/mitos>`_ package.
810+
811+
.. code-block:: tree
812+
813+
recipes/mitos
814+
├── meta.yaml
815+
└── mitos1
816+
└── meta.yaml
817+
818+
The original ``mitos`` v1 recipe is under the ``mitos1/`` directory, but the
819+
`meta.yaml` for the more recent v2 file is in a dedicated sub directory.
820+
821+
Independent packages
822+
^^^^^^^^^^^^^^^^^^^^
823+
824+
Alternatively, create a second independent recipe with the version number suffixed
825+
to the name.
826+
Note that this method will mean that the tool will have two separate names, and older
827+
versions cannot be installed from the newer package.
828+
829+
An example for this is ``gatk`` package, where GATK v3 is stored as `gatk` and the
830+
newer gatk4 version packaged as an independently named ``gatk4`` recipe.
831+
832+
.. code-block:: tree
833+
834+
recipes/gatk
835+
├── 3.5
836+
│ ├── build.sh
837+
│ ├── gatk.py
838+
│ ├── gatk-register.sh
839+
│ ├── meta.yaml
840+
│ └── post-link.sh
841+
├── 3.6
842+
│ ├── build.sh
843+
│ ├── gatk.py
844+
│ ├── gatk-register.sh
845+
│ ├── meta.yaml
846+
│ └── post-link.sh
847+
├── build.sh
848+
├── gatk.py
849+
├── gatk-register.sh
850+
├── meta.yaml
851+
└── post-link.sh
852+
recipes/gatk4
853+
├── build_main.sh
854+
├── build_spark.sh
855+
└── meta.yaml
856+
857+
In this case the directories ``gatk`` and ``gatk4`` sit alongside each other rather than
858+
nested.

0 commit comments

Comments
 (0)