How to define ConfigurationOf with a #development version that is baseline dependent?

In Pharo, I want to define a Metacello ConfigurationOfNand2Tetris that has only one package:

 ConfigurationOfNand2Tetris>>baseline01: spec <version: '0.1-baseline'> spec for: #common do: [ spec blessing: #baseline; repository: 'http://www.smalltalkhub.com/mc/DamienCassou/Nand2Tetris/main'; package: 'Nand2Tetris' ] ConfigurationOfNand2Tetris>>development: spec <symbolicVersion: #development> spec for: #common version: '0.1-baseline'. 

When I execute MetacelloToolBox validateConfiguration: ConfigurationOfNand2Tetris , I always get 2 warnings:

  • Warning: the symbolic version of #development refers to the version of '0.1-baseline', whose blessing #baseline is not #development {notDevelopmentVersion} [#validateVersionSpecForSymbolicVersion: symbolicVersion:]
  • A warning. Only the baseline is determined (no version is defined). {onlyBaselineVersion} [#validatePragmas]
+6
source share
3 answers

If you just want to depend on the baseline, the metaphor for this in Metacello is to use the blessing #bleedingEdge . In addition, you can explicitly deny other symbolic versions:

 ConfigurationOfNand2Tetris>>baseline01: spec <version: '0.1-baseline'> spec for: #common do: [ spec blessing: #baseline; repository: 'http://www.smalltalkhub.com/mc/DamienCassou/Nand2Tetris/main'; package: 'Nand2Tetris' ] ConfigurationOfNand2Tetris>>bleedingEdge: spec <symbolicVersion: #bleedingEdge> spec for: #common version: '0.1-baseline'. ConfigurationOfNand2Tetris>>development: spec <symbolicVersion: #'development'> spec for: #'common' version: #'notDefined'. ConfigurationOfNand2Tetris>>stable: spec <symbolicVersion: #'stable'> spec for: #'common' version: #'notDefined'. 

The idea here is that #stable and #development refer to explicitly modified versions, while #bleedingEdge always refers to the latest versions.

This should avoid the first warning. I think, until you release the version, you can safely ignore the second warning.

+6
source

Usually you define the baseline, and then also the #versionN: method:

 ConfigurationOfNand2Tetris>>version01: spec <version: '0.1' imports: #('0.1-baseline')> spec for: #common do: [ spec blessing: #baseline; package: 'Nand2Tetris' with: 'Nand2Tetris-yourname.22']. 
+3
source

I think you forgot to implement:

 ConfigurationOfNand2Tetris>>version01: spec <version: '0.1' imports: #('0.1-baseline' )> spec for: #'common' do: [ spec blessing: #'development'. spec description: 'some description'. spec author: 'yourName'. spec timestamp: '1/15/2013 16:13'. spec package: 'Nand2Tetris' with: 'Nand2Tetris-yourName.versionNumber'] 

Then you should change:

 ConfigurationOfNand2Tetris>>development: spec <symbolicVersion: #development> spec for: #'common' version: '0.1'. 
+2
source

All Articles