Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-2234

activeProfile in ~/.m2/settings.xml is ignored when profiles section is missing or empty

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0.4
    • 2.0.9
    • Profiles, Settings
    • None

    Description

      When i have this settings.xml file in my user home dir, the activeProfile setting is simply ignored by Maven:
      <settings>
      <activeProfiles>
      <activeProfile>env-test</activeProfile>
      </activeProfiles>
      </settings>

      Adding an empty profiles section does not help:
      <settings>
      <profiles>
      </profiles>
      <activeProfiles>
      <activeProfile>env-test</activeProfile>
      </activeProfiles>
      </settings>

      Well, adding a dummy profile makes it work:
      <settings>
      <profiles>
      <profile>
      <id>dummy</id>
      </profile>
      </profiles>
      <activeProfiles>
      <activeProfile>env-test</activeProfile>
      </activeProfiles>
      </settings>

      Funny, isn't it?

      Regards,
      Manfred

      Attachments

        Issue Links

          Activity

            People

              brett Brett Porter
              manolito Manfred Geiler
              Votes:
              7 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: