How can I update a property in a Maven POM?

后端 未结 7 678
耶瑟儿~
耶瑟儿~ 2020-12-13 18:23

I have two top-level Maven projects, backend and frontend, that advance versions at their own individual pace. Since each has multiple modules, I d

7条回答
  •  悲哀的现实
    2020-12-13 19:13

    I had the same problem and found nothing that changes pom properties in the file. I ended up using sed like you suggested:

    cat pom.xml | sed -e "s%0.0.1-SNAPSHOT%$bamboo_planRepository_branch%" > pom.xml.transformed;
    rm pom.xml;
    mv pom.xml.transformed pom.xml;
    

提交回复
热议问题