6

In my POM file I include:

<plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <version>3.0.0</version>
                <executions>
                    <execution>
                        <id>add-source</id>
                        <phase>generate-sources</phase>
                        <goals>
                            <goal>add-source</goal>
                        </goals>
                        <configuration>
                            <sources>
                                <source>target/generated-sources/avro</source>
                            </sources>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

Always show these in the POM file in red colour

build-helper-maven-plugin
3.0.0

I tried a lot of things, for example, I updated the MAVEN by using the MAVEN settings on the right side of the Intellij IDEA, but it didn't work. always when I make Compile the following message appears:

Could not transfer artifact org.codehaus.mojo:build-helper-maven-plugin:pom:3.0.0 from/to central (https://repo.maven.apache.org/maven2): /home/ameerb/.m2/repository/org/codehaus/mojo/build-helper-maven-plugin/3.0.0/build-helper-maven-plugin-3.0.0.pom.part.lock (No such file or directory)

Can you please show me what is the cause and what is the solution?

Sarru Uken
  • 83
  • 1
  • 4
  • 1. Delete the relevant part from your local repository. 2. Check if network/proxy/firewall blocks the access to MavenCentral. – J Fabian Meier Oct 29 '19 at 11:53
  • Thanks, @JFMeier , but: related to (1.) unfortunately the relevant directory does not exist to delete it!!. I mean when I cd to "~/.m2/repository/org/codehaus/mojo" the are nothing but the following directory "exec-maven-plugin" and "mojo-parent", so what the relevant repo should I delete it???. related to (2) I disabled the firewall and the problem not solved !!! – Sarru Uken Oct 29 '19 at 15:08
  • 1
    Perhaps the process is unable to write to the directory `/home/ameerb/.m2/repository/org/codehaus/mojo/build-helper-maven-plugin/3.0.0/`? Take a look at the file permissions from your `.m2` and downwards. – gjoranv Oct 30 '19 at 16:22
  • @gjoranv thank you very much, it was a permissions problem. – Sarru Uken Mar 09 '20 at 01:39

0 Answers0