Skip to content

Add default exclude / warning for ".m2" and/or "repository" #91

Closed

Description

@jschneider

I hat the issue that my build failed when using "-Dmaven.repo.local=.m2/repository".
This parameter is suggested when using docker to build.

Unfortunately jgitver modifies files stored within the repository.

Adding exclusions to the jtiver-config.xml solves this issue. But it has been very hard for me to diagnose this problem.

Could you add these default exclusions:

    <exclusion>.repository</exclusion> <!-- often used by jenkins -->
    <exclusion>target</exclusion>
    <exclusion>.m2</exclusion>
  </exclusions>

or at least add warnings when entering a directory that is called "repository"?

Activity

  1. McFoggy commented on Jul 7, 2018

    @McFoggy
    Contributor

    This parameter is suggested when using docker to build.

    what is documented is to copy your local repository to /root/.m2 which is the default location of the maven local repository for root user. But it is a bit strange then to map/copy the project under build at the same place.
    Having default directories excluded is a decision a bit difficult to take without enough background on the possible use cases.
    As you noticed, even in such a bad situation, by configuration, jgitver is able to work properly. A better documentation on this point might be enough.

  2. jschneider commented on Jul 7, 2018

    @jschneider
    ContributorAuthor

    The problem is: It is very hard to identify the root problem from the given error messages.
    It took me a long time to figure it out - and I know JGitver very well...

    But I understand that there might be false positives.

  3. McFoggy commented on Jul 8, 2018

    @McFoggy
    Contributor

    with experience & the behavior described in #90, all POMs resolved with the same version as the project, it was clear that jgitver was changing the versions. It is such a behavior that needs to be better documented regarding what is occurring and how to correct it.
    Honestly I think a better documentation, wiki, faq is the first thing to do.

  4. added a commit that references this issue on Jul 9, 2018
    3dd317b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions