Невозможно зафиксировать файлы в github во время выпуска mvn: подготовиться при весенней загрузке - PullRequest
0 голосов
/ 19 января 2019

Пожалуйста, объясните мне, как действовать дальше, выполняя релиз mvn: подготовьтесь в моем весеннем загрузочном проекте и также расскажите, как добавить ключ ssh в мой проект, если это необходимо.Я перепробовал много решений, но ни одно из них не работает, так как каждый раз отображается одна и та же ошибка, и это мой проект на основе модульного подхода, и я использую IDE IntelliJ.

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release- plugin:2.5.3:prepare (default-cli) on project vj-pet-clinic: Unable to commit files
[ERROR] Provider message:
[ERROR] The git-push command failed.
[ERROR] Command output:
[ERROR] git@github.com: Permission denied (publickey).
[ERROR] fatal: Could not read from remote repository.
[ERROR] Please make sure you have the correct access rights
[ERROR] and the repository exists.
[ERROR]
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1]
http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

Мой файл pom.xml: -

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<packaging>pom</packaging>
<modules>
    <module>pet-clinic-data</module>
    <module>pet-clinic-web</module>
</modules>
<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>2.1.2.RELEASE</version>
    <relativePath /> <!-- lookup parent from repository -->
</parent>
<groupId>com.vinamra</groupId>
<artifactId>vj-pet-clinic</artifactId>
<version>0.0.1</version>
<name>vj-pet-clinic</name>
<description>VJ pet clinic project</description>

<properties>
    <java.version>1.8</java.version>
</properties>

<dependencies>
</dependencies>

<build>
    <plugins>
        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>
        </plugin>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-release-plugin</artifactId>
            <version>2.5.3</version>
            <configuration>
                <goals>install</goals>
                <checkModificationExcludes>
                    <checkModificationExclude>pom.xml</checkModificationExclude>
                </checkModificationExcludes>
            </configuration>
        </plugin>
    </plugins>
</build>

<scm>
  <developerConnection>scm:git:git@github.com:username/repository.git</developerConnection>
  <tag>vj-pet-clinic-0.0.1</tag>

Пожалуйста, помогите мне, как подтолкнуть релиз плагина с помощью Maven.

1 Ответ

0 голосов
/ 19 января 2019

Вы можете использовать HTTPS вместо SSH, чтобы избежать обмена ключами.Вот пример:

  <scm>
        <url>https://github.com/(username)/(repo)</url>
        <connection>scm:git:https://github.com/(username)/(repo).git</connection>
  </scm>

Замените (username) и (repo) соответственно.

...