Build and Version Numbering for Java Projects (ant, cvs, hudson)

后端 未结 9 980
野的像风
野的像风 2020-11-29 14:38

What are current best-practices for systematic build numbering and version number management in Java projects? Specifically:

  • How to manage build numbers sy

9条回答
  •  有刺的猬
    2020-11-29 15:19

    For several of my projects I capture the subversion revision number, time, user who ran the build, and some system information, stuff them into a .properties file that gets included in the application jar, and read that jar at runtime.

    The ant code looks like this:

    
    
    
    
        
            
                
        
        
        
    
                
            
            
            
            
            
        
    
    

    It's simple to extend this to include whatever information you might want to add.

提交回复
热议问题