Skip to main content
Engineering LibreTexts

6.1: Versioning Your Code with Monticello

  • Page ID
    44018
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    A versioning system helps you to store and log multiple versions of your code. In addition, it may help you manage concurrent accesses to a common source code repository. It keeps track of all changes to a set of documents and enables several developers to collaborate. As soon as the size of your software increases beyond a few classes, you probably need a versioning system.

    Many different versioning systems are available. CVS1, Subversion2, and Git3 are probably the most popular. In principle you could use them to manage the development of Pharo software projects, but such a practice would disconnect the versioning system from the Pharo environment. In addition, CVS-like tools only version plain text files and not individual packages, classes or methods. We would therefore lack the ability to track changes at the appropriate level of granularity. If the versioning tools know that you store classes and methods instead of plain text, they can do a better job of supporting the development process.

    There are multiple repositories to store your projects. SmalltalkHub4 and Squeaksource 35 are the two main and free-to-use repositories. They are versioning systems for Pharo in which classes and methods, rather than lines of text, are the units of change. In this chapter we will use SmalltalkHub, but Squeaksource 3 can be use similarly. SmalltalkHub is a central online repository in which you can store versions of your applications using Monticello. SmalltalkHub is the equivalent of SourceForge, and Monticello the equivalent of CVS.

    In this chapter, you will learn how to use use Monticello and SmalltalkHub to manage your software. We have already been acquainted with Monticello briefly in earlier chapters6. This chapter delves into the details of Monticello and describes some additional features that are useful for versioning large applications.


    1. http://www.nongnu.org/cvs
    2. http://subversion.tigris.org
    3. http://git-scm.com/
    4. http://smalltalkhub.com/
    5. http://ss3.gemstone.com/
    6. “A first application” and “The Pharo programming environment”

    This page titled 6.1: Versioning Your Code with Monticello is shared under a CC BY-SA 3.0 license and was authored, remixed, and/or curated by Alexandre Bergel, Damien Cassou, Stéphane Ducasse, Jannik Laval (Square Bracket Associates) via source content that was edited to the style and standards of the LibreTexts platform; a detailed edit history is available upon request.